code: def my_threads() -> Dict[str, int]:
      """
      Returns [(thread_id, thread_name)]
      """
      pid = os.getpid()
      threads = Counter()
      proc_dir = f"/proc/{pid}/task"
  
      for tid_entry in os.listdir(proc_dir):
          comm_path = os.path.join(proc_dir, tid_entry, "comm")
  
          if os.path.exists(comm_path):
              with open(comm_path, "r") as comm_file:
                  thread_name = comm_file.read().strip()
                  threads[thread_name] += 1
      return threads
  
file_path: ray/python/ray/tests/test_actor_bounded_threads.py
imports: import sys
  import os
  import ray
  import logging
  from typing import Dict
  from collections import Counter
  import pytest
label_desc: Use image node_id 1 for calling a global function with example usage: my_threads() and returns: threads