class_docstr: GPU Sampler for homogeneous graph 
class_docstr_tok: ["GPU","Sampler","for","homogeneous","graph"]
code: def sample_neighbors(self, nodes):
      graph_list = []
      for size in self.samples:
          # If you want to sample with faster speed, you can refer to
          # the corresponding geometric API documents for modification.
          (
              neighbors,
              neighbors_count,
          ) = paddle.geometric.sample_neighbors(
              self.row, self.colptr, nodes, sample_size=size
          )
          (
              edge_src,
              edge_dst,
              sample_index,
          ) = paddle.geometric.reindex_graph(
              nodes, neighbors, neighbors_count
          )
          subgraph = pgl.Graph(
              num_nodes=sample_index.shape[0],
              edges=paddle.concat(
                  [
                      edge_src.reshape([-1, 1]),
                      edge_dst.reshape([-1, 1]),
                  ],
                  axis=-1,
              ),
          )
          graph_list.append((subgraph, nodes.shape[0]))
          nodes = sample_index
      return graph_list[::-1], nodes
  
imports: import time
  import copy
  import numpy
  import paddle
  import pgl
  from pgl import graph_kernel
  from pgl.sampling.custom import subgraph
  from pgl.utils.logger import log
  from pgl.utils.helper import to_paddle_tensor
label_desc: Use image node_id 2 for calling the NeighborSampler obj's underlying member method code with example usage: obj.sample_neighbors(nodes) and returns: graph_list,  nodes