code: def forward(self, batch: tensor_dict_type, **kwargs: Any) -> Tensor:
      net = batch[INPUT_KEY]
      net = self.in_conv(net)
      net = self.mid(net)
      for block in self.upsample_blocks[::-1]:
          net = block(net)
      net = self.out(net)
      if kwargs.get("resize", True):
          net = self.resize(net)
      return net
  
imports: import torch.nn
  from torch import Tensor
  from typing import Any
  from typing import List
  from typing import Optional
  from cftool.types import tensor_dict_type
  from .schema import DecoderMixin
  from ....constants import INPUT_KEY
  from ..encoder.vqgan import normalize
  from ..encoder.vqgan import AttnBlock
  from ..encoder.vqgan import ResidualBlock
  from ....misc.toolkit import interpolate
  from ....modules.blocks import Conv2d
label_desc: Use image node_id 2 for calling the VQGANDecoder obj's underlying member method code with example usage: obj.forward(batch) and returns: net