class_docstr: _DistSpec
  
  A class indicates Distributed Specification.
  The DistSpec is only works for the tensor parallel process groups.
  Because the dist spec of data parallel process group can be automatically deduced.
  This is an internal data structure.
  The API for users should be `ShardSpec` and `ReplicaSpec`.
  
  Args:
      dist_placement_pattern (DistPlacementPattern): the pattern describing how tensors are distributed among processes.
                                              The dist_placement_pattern is picked from a limited set, now including two patterns: replicate and shard.
      process_group (Optional[ProcessGroup], optional): the process group contains processes. Defaults to None.
code: def __repr__(self) -> str:
      attr_list = []
      for attr in dir(self):
          if not attr.startswith("__"):
              attr_list.append(f"{attr}={str(getattr(self, attr))}")
      attr_str = ", ".join(attr_list)
      return "DistSpec(" + attr_str + ")"
  
file_path: ColossalAI/colossalai/legacy/tensor/distspec.py
imports: from enum import Enum
  from typing import List
label_desc: Use image node_id 3 for calling the _DistSpec obj's underlying member method code with example usage: obj.__repr__() and returns: unknown