code: def test_cluster_gcn_correctness(get_dataset, sparse_format):
      dataset = get_dataset("Cora")
      data = dataset[0].clone()
      data.n_id = torch.arange(data.num_nodes)
      cluster_data = ClusterData(
          data,
          num_parts=10,
          log=False,
          sparse_format=sparse_format,
      )
      loader = ClusterLoader(cluster_data, batch_size=3, shuffle=False)
  
      for batch1 in loader:
          batch1.validate()
          batch2 = data.subgraph(batch1.n_id)
          assert batch1.num_nodes == batch2.num_nodes
          assert batch1.num_edges == batch2.num_edges
          assert torch.equal(batch1.x, batch2.x)
          assert torch.equal(
              batch1.edge_index,
              sort_edge_index(
                  batch2.edge_index,
                  sort_by_row=sparse_format == "csr",
              ),
          )
  
file_path: pytorch_geometric/test/loader/test_cluster.py
imports: import pytest
  import torch
  from torch_geometric.data import Data
  from torch_geometric.loader import ClusterData, ClusterLoader
  from torch_geometric.testing import onlyFullTest, onlyOnline
  from torch_geometric.utils import sort_edge_index
label_desc: Use image node_id 3 for calling a global function with example usage: test_cluster_gcn_correctness(get_dataset, sparse_format) without return types