code: def _merge_graph(self, from_graph):
      to_graph = self.logical_graph
      id_to_new_node = {}  # old node ID -> new node object
  
      for old_node in from_graph.nodes:
          new_node = OriginNode(
              to_graph,
              old_node.graph,
              old_node,
              old_node.name,
              old_node.operation,
              _internal=True,
          )._register()
          id_to_new_node[old_node.id] = new_node
  
      for edge in from_graph.edges:
          new_head = id_to_new_node[edge.head.id]
          new_tail = id_to_new_node[edge.tail.id]
          Edge(
              (new_head, edge.head_slot),
              (new_tail, edge.tail_slot),
              _internal=True,
          )._register()
  
imports: import copy
  from typing import Dict, Tuple, Any, Type, cast
  from nni.common.device import Device, CPUDevice
  from nni.mutable.utils import uid
  from nni.nas.space import Edge, Graph, GraphModelSpace, Node
  from nni.nas.space.graph_op import Cell, Operation, _IOPseudoOperation
label_desc: Use image node_id 3 for calling the LogicalPlan obj's underlying member method code with example usage: obj._merge_graph(from_graph) without return types