code: def upconv_block(
      in_nc,
      out_nc,
      upscale_factor=2,
      kernel_size=3,
      stride=1,
      bias=True,
      pad_type="zero",
      norm_type=None,
      act_type="relu",
      mode="nearest",
      convtype="Conv2D",
  ):
      """Upconv layer"""
      upscale_factor = (
          (1, upscale_factor, upscale_factor)
          if convtype == "Conv3D"
          else upscale_factor
      )
      upsample = Upsample(scale_factor=upscale_factor, mode=mode)
      conv = conv_block(
          in_nc,
          out_nc,
          kernel_size,
          stride,
          bias=bias,
          pad_type=pad_type,
          norm_type=norm_type,
          act_type=act_type,
          convtype=convtype,
      )
      return sequential(upsample, conv)
  
imports: from collections import OrderedDict
  import math
  import torch
  import torch.nn
  import torch.nn.functional
label_desc: Use image node_id 4 for calling a global function with example usage: upconv_block(in_nc, out_nc, upscale_factor, kernel_size, stride, bias, pad_type, norm_type, act_type, mode, convtype) and returns: sequential