code: def test_from_dglgraph_homogeneous():
      dgl_g = dgl.rand_graph(1000, 10 * 1000)
  
      # Check if the original edge id exist in edge attributes when the
      # original_edge_id is set to False.
      gb_g = gb.from_dglgraph(
          dgl_g, is_homogeneous=False, include_original_edge_id=False
      )
      assert (
          gb_g.edge_attributes is None
          or gb.ORIGINAL_EDGE_ID not in gb_g.edge_attributes
      )
  
      gb_g = gb.from_dglgraph(
          dgl_g, is_homogeneous=True, include_original_edge_id=True
      )
      # Get the COO representation of the FusedCSCSamplingGraph.
      num_columns = gb_g.csc_indptr.diff()
      rows = gb_g.indices
      columns = torch.arange(gb_g.total_num_nodes).repeat_interleave(
          num_columns
      )
  
      original_edge_ids = gb_g.edge_attributes[gb.ORIGINAL_EDGE_ID]
      assert torch.all(dgl_g.edges()[0][original_edge_ids] == rows)
      assert torch.all(dgl_g.edges()[1][original_edge_ids] == columns)
  
      assert gb_g.total_num_nodes == dgl_g.num_nodes()
      assert gb_g.total_num_edges == dgl_g.num_edges()
      assert gb_g.node_type_offset is None
      assert gb_g.type_per_edge is None
      assert gb_g.node_type_to_id is None
      assert gb_g.edge_type_to_id is None
  
imports: import os
  import pickle
  import re
  import tempfile
  import unittest
  import backend
  import dgl
  import dgl.graphbolt
  import pytest
  import torch
  import torch.multiprocessing
  from dgl.graphbolt.base import etype_str_to_tuple
  from scipy import sparse
  from ..None import gb_test_utils
label_desc: Use image node_id 26 for calling a global function with example usage: test_from_dglgraph_homogeneous() without return types