code: def test_global_settings():
      """Ensure that GlobalSettings acts as a proper thread-local borg"""
  
      def check_settings(index):
          # Force a race condition
          if index == 0:
              sleep(0.1)
          cuml.global_settings.index = index
          sleep(0.5)
          return (
              cuml.global_settings.index == index
              and cuml.global_settings.index == GlobalSettings().index
          )
  
      results = [delayed(check_settings)(index) for index in range(5)]
  
      assert (delayed(all)(results)).compute()
  
file_path: cuml/python/cuml/tests/dask/test_dask_global_settings.py
imports: from time import sleep
  import pytest
  from dask import delayed
  import cuml
  from cuml import set_global_output_type, using_output_type
  from cuml.internals.api_context_managers import _using_mirror_output_type
  from cuml.internals.global_settings import _global_settings_data, _GlobalSettingsData, GlobalSettings
label_desc: Use image node_id 5 for calling a global function with example usage: test_global_settings() and returns: unknown