code: def test_networkx_compatibility(graph_file):
      # test to make sure cuGraph and Nx build similar Graphs
      # Read in the graph
      dataset_path = graph_file.get_path()
      M = utils.read_csv_for_nx(dataset_path, read_weights_in_sp=True)
  
      # create a NetworkX DiGraph
      nxG = nx.from_pandas_edgelist(
          M,
          source="0",
          target="1",
          edge_attr="weight",
          create_using=nx.DiGraph(),
      )
  
      # create a cuGraph Directed Graph
      gdf = cudf.from_pandas(M)
      cuG = cugraph.from_cudf_edgelist(
          gdf,
          source="0",
          destination="1",
          edge_attr="weight",
          create_using=cugraph.Graph(directed=True),
      )
  
      _compare_graphs(nxG, cuG)
  
file_path: cugraph/python/cugraph/cugraph/tests/nx/test_nx_convert.py
imports: import pytest
  import pandas
  import networkx
  import cudf
  import cugraph
  from cugraph.testing import utils, DEFAULT_DATASETS
label_desc: Use image node_id 2 for calling a global function with example usage: test_networkx_compatibility(graph_file) without return types