class_docstr: This module resizes a list of image tensors to the given size.
  
  Additionally, also returns the original image sizes for further post-processing.
class_docstr_tok: ["This","module","resizes","a","list","of","image","tensors","to","the","given","size",".","Additionally",",","also","returns","the","original","image","sizes","for","further","post-processing","."]
code: def forward(
      self, imgs: list[Tensor]
  ) -> tuple[Tensor, list[ImageSize]]:
      # TODO: support other input formats e.g. file path, numpy
      resized_imgs, original_sizes = [], []
      for i in range(len(imgs)):
          img = imgs[i]
          # NOTE: assume that image layout is CHW
          original_sizes.append(
              ImageSize(height=img.shape[1], width=img.shape[2])
          )
          resized_imgs.append(
              # TODO: fix kornia resize to support onnx
              torch.nn.functional.interpolate(
                  img.unsqueeze(0),
                  size=self.size,
                  mode=self.interpolation_mode,
              )
          )
      return concatenate(resized_imgs), original_sizes
  
imports: from __future__ import annotations
  from dataclasses import dataclass
  from enum import Enum
  from typing import Optional
  import torch
  from kornia.core import Module, Tensor, concatenate
  from kornia.core.check import KORNIA_CHECK_SHAPE
  from kornia.image.base import ImageSize
label_desc: Use image node_id 2 for calling the ResizePreProcessor obj's underlying member method code with example usage: obj.forward(imgs) and returns: concatenate,  original_sizes