code: def _test_common_rcnn_batch(batch):
      (images, targets), records = batch
  
      assert isinstance(images, list)
      assert len(images) == 2
      assert images[0].dtype == torch.float
      assert images[0].shape == (3, 375, 500)
  
      assert isinstance(targets, list)
      assert isinstance(targets[0], dict)
      assert len(targets) == 2
  
      for target in targets:
          assert target["labels"].dtype == torch.int64
          assert torch.all(
              target["labels"] == tensor([1, 2], dtype=torch.int64)
          )
  
          assert target["boxes"].dtype == torch.float
          assert torch.all(
              target["boxes"]
              == tensor(
                  [[1, 2, 3, 4], [10, 20, 30, 40]], dtype=torch.float
              )
          )
  
imports: import pytest
  from icevision.all import *
  from icevision.models.torchvision import faster_rcnn, mask_rcnn, keypoint_rcnn
label_desc: Use image node_id 3 for calling a global function with example usage: _test_common_rcnn_batch(batch) without return types