def __setstate__()

in ez_wsi_dicomweb/patch_embedding_endpoints.py [0:0]


  def __setstate__(self, dct: MutableMapping[str, Any]) -> None:
    """Init class state from pickle serialization."""
    self.__dict__ = dct
    if self._max_threads < 2:
      self._thread_pool = None
    else:
      self._thread_pool = concurrent.futures.ThreadPoolExecutor(
          max_workers=self._max_threads
      )
    self._icc_profile_cache = cachetools.LRUCache(
        self._dicom_instance_icc_profile_cache_count
    )
    self._icc_profile_cache_lock = threading.Lock()