class_docstr: Reorder node list and indice trace list
class_docstr_tok: ["Reorder","node","list","and","indice","trace","list"]
code: def _reorder_idx_trace(self, reorder_map):
      # reorder list
      new_idx_trace_list = [
          None for _ in range(len(self.trace_indice.indice_trace_list))
      ]
      for old_idx, new_idx in reorder_map.items():
          new_idx_trace_list[
              new_idx
          ] = self.trace_indice.indice_trace_list[old_idx]
      self.trace_indice.indice_trace_list = new_idx_trace_list
      # update compute
      for idx_trace in self.trace_indice.indice_trace_list:
          compute = idx_trace["compute"]
          for dim_compute in compute:
              for idx, i in enumerate(dim_compute):
                  dim_compute[idx] = reorder_map[i]
      # update source
      for idx_trace in self.trace_indice.indice_trace_list:
          source = idx_trace["source"]
          for dim_idx, dim_source in enumerate(source):
              new_dim_source = {}
              for k, v in dim_source.items():
                  new_dim_source[reorder_map[k]] = v
              source[dim_idx] = new_dim_source
  
file_path: colossalai/colossalai/autochunk/reorder_graph.py
imports: from .trace_indice import TraceIndice
  from .utils import NodeMgr
label_desc: Use image node_id 6 for calling the ReorderGraph obj's underlying member method code with example usage: obj._reorder_idx_trace(reorder_map) without return types