code: def __init__(self, num_classes, pretrained=True, **kwargs):
      super(ResNetDUC, self).__init__()
      resnet = models.resnet152()
      if pretrained:
          resnet.load_state_dict(torch.load(res152_path))
      self.layer0 = nn.Sequential(
          resnet.conv1, resnet.bn1, resnet.relu, resnet.maxpool
      )
      self.layer1 = resnet.layer1
      self.layer2 = resnet.layer2
      self.layer3 = resnet.layer3
      self.layer4 = resnet.layer4
  
      for n, m in self.layer3.named_modules():
          if "conv2" in n:
              m.dilation = (2, 2)
              m.padding = (2, 2)
              m.stride = (1, 1)
          elif "downsample.0" in n:
              m.stride = (1, 1)
      for n, m in self.layer4.named_modules():
          if "conv2" in n:
              m.dilation = (4, 4)
              m.padding = (4, 4)
              m.stride = (1, 1)
          elif "downsample.0" in n:
              m.stride = (1, 1)
  
      self.duc = _DenseUpsamplingConvModule(8, 2048, num_classes)
  
file_path: pywick/pywick/models/segmentation/duc_hdc.py
imports: import torch
  from torch import nn
  from torchvision import models
  from .config import res152_path
label_desc: Use image node_id 1 to create a new ResNetDUC object from inherited base classes: nn with example: obj = ResNetDUC(num_classes, pretrained)