code: def _assert_is_identical_batchedhetero(bg1, bg2):
      assert_is_identical_hetero(bg1, bg2)
      for ntype in bg1.ntypes:
          assert bg1.batch_num_nodes(ntype) == bg2.batch_num_nodes(
              ntype
          )
      for canonical_etype in bg1.canonical_etypes:
          assert bg1.batch_num_edges(
              canonical_etype
          ) == bg2.batch_num_edges(canonical_etype)
  
imports: import io
  import pickle
  import unittest
  import backend
  import dgl
  import dgl.function
  import networkx
  import pytest
  import scipy.sparse
  from dgl.graph_index import create_graph_index
  from dgl.utils import toindex
  from utils import assert_is_identical, assert_is_identical_hetero, check_graph_equal, get_cases, parametrize_idtype
label_desc: Use image node_id 3 for calling a global function with example usage: _assert_is_identical_batchedhetero(bg1, bg2) without return types