class_docstr: A context manager to enable multi-threading in
  :class:`~torch.utils.data.DataLoader` workers.
  It changes the default value of threads used in the loader from :obj:`1`
  to :obj:`worker_threads`.
code: def _mt_init_fn(self, worker_id: int) -> None:
      try:
          torch.set_num_threads(int(self._worker_threads))
      except IndexError:
          raise ValueError(
              f"Cannot set {self.worker_threads} threads "
              f"in worker {worker_id}"
          )
  
      # Chain worker init functions:
      self._old_worker_init_fn(worker_id)
  
imports: import glob
  import logging
  import os
  import os.path
  import warnings
  from contextlib import contextmanager
  from typing import Any, Callable, Dict, List, Optional, Union
  import psutil
  import torch
  from torch_geometric.data import HeteroData
label_desc: Use image node_id 1 for calling the MultithreadingMixin obj's underlying member method code with example usage: obj._mt_init_fn(worker_id) without return types