class_docstr: Note: most parameters has default dummy value,
        which is convenient when used in script.
        please pass in custom implements as you wish
class_docstr_tok: ["Note",":","most","parameters","has","default","dummy","value",",","which","is","convenient","when","used","in","script",".","please","pass","in","custom","implements","as","you","wish"]
code: def __init__(
      self,
      device: device_type = device_type.CPU,
      computing: Optional["KVTableContext"] = None,
      federation: Optional["Federation"] = None,
      metrics_handler: Optional = None,
      namespace: Optional[NS] = None,
      cipher: Optional[CipherKit] = None,
  ) -> None:
      self._device = device
      self._computing = computing
      self._federation = federation
      self._metrics_handler = metrics_handler
      self._namespace = namespace
      self._cipher = cipher
  
      if self._namespace is None:
          self._namespace = default_ns
      if self._cipher is None:
          self._cipher: CipherKit = CipherKit(device)
      self._cipher.set_ctx(self)
  
      self._role_to_parties = None
      self._is_destroyed = False
  
      self._mpc = None
  
imports: import logging
  import typing
  from typing import Iterable, Literal, Optional, Tuple, TypeVar, overload
  from fate.arch.trace import auto_trace
  from ._cipher import CipherKit
  from ._metrics import InMemoryMetricsHandler, MetricsWrap
  from ._namespace import NS, default_ns
  from ._parties import Parties, Party
  from ..unify import device
label_desc: Use image node_id 1 to create a new Context object  with example: obj = Context(device, computing, federation, metrics_handler, namespace, cipher)