code: def get_collective_keys():
      """Return a singleton instance of CollectiveKey."""
      global _collective_keys
      if _collective_keys:
          return _collective_keys
      _collective_keys_lock.acquire()
  
      try:
          if _collective_keys:
              return _collective_keys
          collective_keys = CollectiveKey()
          _collective_keys = collective_keys
          return _collective_keys
      finally:
          _collective_keys_lock.release()
  
file_path: autodist/autodist/kernel/synchronization/collective_key.py
imports: import threading
  import hashlib
  from autodist.const import MAX_INT32
label_desc: Use image node_id 1 for calling a global function with example usage: get_collective_keys() and returns: _collective_keys, _collective_keys, _collective_keys