class_docstr: Head network for proposal-based mask segmentation. Performs RoiAlign, some convolutions and applies sigmoid on the
  output logits to allow for overlapping classes.
code: def __init__(self, cf, conv):
      super(Mask, self).__init__()
      self.pool_size = cf.mask_pool_size
      self.pyramid_levels = cf.pyramid_levels
      self.dim = conv.dim
      self.conv1 = conv(
          cf.end_filts,
          cf.end_filts,
          ks=3,
          stride=1,
          pad=1,
          norm=cf.norm,
          relu=cf.relu,
      )
      self.conv2 = conv(
          cf.end_filts,
          cf.end_filts,
          ks=3,
          stride=1,
          pad=1,
          norm=cf.norm,
          relu=cf.relu,
      )
      self.conv3 = conv(
          cf.end_filts,
          cf.end_filts,
          ks=3,
          stride=1,
          pad=1,
          norm=cf.norm,
          relu=cf.relu,
      )
      self.conv4 = conv(
          cf.end_filts,
          cf.end_filts,
          ks=3,
          stride=1,
          pad=1,
          norm=cf.norm,
          relu=cf.relu,
      )
      if conv.dim == 2:
          self.deconv = nn.ConvTranspose2d(
              cf.end_filts, cf.end_filts, kernel_size=2, stride=2
          )
      else:
          self.deconv = nn.ConvTranspose3d(
              cf.end_filts, cf.end_filts, kernel_size=2, stride=2
          )
  
      self.relu = (
          nn.ReLU(inplace=True)
          if cf.relu == "relu"
          else nn.LeakyReLU(inplace=True)
      )
      self.conv5 = conv(
          cf.end_filts, cf.head_classes, ks=1, stride=1, relu=None
      )
      self.sigmoid = nn.Sigmoid()
  
imports: import utils.model_utils
  import utils.exp_utils
  from cuda_functions.nms_2D.pth_nms import nms_gpu
  from cuda_functions.nms_3D.pth_nms import nms_gpu
  from cuda_functions.roi_align_2D.roi_align.crop_and_resize import CropAndResizeFunction
  from cuda_functions.roi_align_3D.roi_align.crop_and_resize import CropAndResizeFunction
  import numpy
  import torch
  import torch.nn
  import torch.nn.functional
  import torch.utils
label_desc: Use image node_id 1 to create a new Mask object from inherited base classes: nn with example: obj = Mask(cf, conv)