class_docstr: Implement of Partition Wrapper
class_docstr_tok: ["Implement","of","Partition","Wrapper"]
code: def __init__(self, graph_wrapper, part_id, num_parts):
      super(PartitionWrapper, self).__init__()
  
      # Copy Node's information
      for key, value in graph_wrapper.node_feat.items():
          self.node_feat_tensor_dict[key] = value
  
      self._num_nodes = graph_wrapper.num_nodes
      self._graph_lod = graph_wrapper.graph_lod
      self._num_graph = graph_wrapper.num_graph
  
      # Dropout Edges
      src, dst = graph_wrapper.edges
      keeped = L.cast((dst % num_parts) == part_id, dtype="float32")
  
      keeped = keeped > 0.5
      self.keeped = keeped
      self._num_edges = L.reduce_sum(L.cast(keeped, "int32"))
      # L.Print(self._num_edges, message="Part-%s num edges" % part_id)
      src = paddle_helper.masked_select(src, keeped)
      dst = paddle_helper.masked_select(dst, keeped)
      src.stop_gradient = True
      dst.step_gradient = True
      self._edges_src = src
      self._edges_dst = dst
  
      for key, value in graph_wrapper.edge_feat.items():
          self.edge_feat_tensor_dict[key] = paddle_helper.masked_select(
              value, keeped
          )
  
      self._edge_uniq_dst, _, uniq_count = L.unique_with_counts(
          dst, dtype="int32"
      )
      self._edge_uniq_dst.stop_gradient = True
      last = L.reduce_sum(uniq_count, keep_dim=True)
      uniq_count = L.cumsum(uniq_count, exclusive=True)
      self._edge_uniq_dst_count = L.concat([uniq_count, last])
      self._edge_uniq_dst_count.stop_gradient = True
      self._indegree = get_degree(self._edges_dst, self._num_nodes)
  
file_path: PGL/ogb_examples/nodeproppred/ogbn-proteins/unimp_cross_feat/module/transformer_gat_pgl.py
imports: import paddle.fluid
  import paddle.fluid.layers
  from pgl import graph_wrapper
  from pgl.utils import paddle_helper
  import math
label_desc: Use image node_id 1 to create a new PartitionWrapper object from inherited base classes: graph_wrapper with example: obj = PartitionWrapper(graph_wrapper, part_id, num_parts)