code: def adaptive_avg_pool2d(input, output_size):
      """Handle empty batch dimension to adaptive_avg_pool2d.
  
      Args:
          input (tensor): 4D tensor.
          output_size (int, tuple[int,int]): the target output size.
      """
      if input.numel() == 0 and obsolete_torch_version(
          TORCH_VERSION, (1, 9)
      ):
          if isinstance(output_size, int):
              output_size = [output_size, output_size]
          output_size = [*input.shape[:2], *output_size]
          empty = NewEmptyTensorOp.apply(input, output_size)
          return empty
      else:
          return F.adaptive_avg_pool2d(input, output_size)
  
file_path: mmdetection/mmdet/models/layers/brick_wrappers.py
imports: import torch
  import torch.nn
  import torch.nn.functional
  from mmcv.cnn.bricks.wrappers import NewEmptyTensorOp, obsolete_torch_version
  from mmdet.registry import MODELS
label_desc: Use image node_id 1 for calling a global function with example usage: adaptive_avg_pool2d(input, output_size) and returns: empty, F