code: def check_node_edge_attributes(graph1, graph2, attributes, attr_name):
      for name, attr in attributes.items():
          edge_attributes_1 = getattr(graph1, attr_name)
          edge_attributes_2 = getattr(graph2, attr_name)
          assert name in edge_attributes_1
          assert name in edge_attributes_2
          assert torch.equal(edge_attributes_1[name], attr)
          check_tensors_on_the_same_shared_memory(
              edge_attributes_1[name], edge_attributes_2[name]
          )
  
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 21 for calling a global function with example usage: check_node_edge_attributes(graph1, graph2, attributes, attr_name) without return types