class_docstr: Implement of GAT
      
class_docstr_tok: ["Implement","of","GAT"]
code: def get_subgraph_by_edge_split(
      self, idx, edge_src, edge_dst, edge_split, num_nodes
  ):
      start = 0 if idx == 0 else edge_split[idx - 1]
      if start == edge_split[idx]:
          return None
      new_edge_src = edge_src[start : edge_split[idx]].reshape([-1, 1])
      new_edge_dst = edge_dst[start : edge_split[idx]].reshape([-1, 1])
      graph = pgl.Graph(
          num_nodes=num_nodes,
          edges=paddle.concat([new_edge_src, new_edge_dst], axis=1),
      )
      return graph
  
file_path: PGL/examples/NeurIPS2022-OGB-Challenge/MAG240M/models/r_unimp_peg_gpr_m2v.py
imports: import pgl
  import paddle
  import paddle.nn
  import paddle.nn.functional
  from .gat_conv_peg import linear_init, GATConv
  import numpy
label_desc: Use image node_id 2 for calling the GNNModel obj's underlying member method code with example usage: obj.get_subgraph_by_edge_split(idx, edge_src, edge_dst, edge_split, num_nodes) and returns: graph, None