code: def flatten(cls, obj):
      ret, schema = super().flatten(obj.get_fields())
      size = obj.image_size
      if not isinstance(size, torch.Tensor):
          size = torch.tensor(size)
      return ret + (size,), schema
  
imports: import collections
  from dataclasses import dataclass
  from typing import Callable, List, Optional, Tuple
  import torch
  from torch import nn
  from detectron2.structures import Boxes, Instances, ROIMasks
  from detectron2.utils.registry import _convert_target_to_string, locate
  from .torchscript_patch import patch_builtin_len
label_desc: Use image node_id 2 for calling the InstancesSchema obj's underlying member method code with example usage: obj.flatten(cls, obj) and returns: unknown,  schema