code: def __init__(self):
      super(Discriminator, self).__init__()
  
      def convlayer(
          n_input, n_output, k_size=4, stride=2, padding=0, bn=False
      ):
          block = [
              nn.Conv2d(
                  n_input,
                  n_output,
                  kernel_size=k_size,
                  stride=stride,
                  padding=padding,
                  bias=False,
              )
          ]
          if bn:
              block.append(nn.BatchNorm2d(n_output))
          block.append(nn.LeakyReLU(0.2, inplace=True))
          return block
  
      self.model = nn.Sequential(
          *convlayer(opt.channels * 2, 32, 4, 2, 1),
          *convlayer(32, 64, 4, 2, 1),
          *convlayer(64, 128, 4, 2, 1, bn=True),
          *convlayer(128, 256, 4, 2, 1, bn=True),
          *convlayer(256, 512, 4, 2, 1, bn=True),
          *convlayer(512, 1024, 4, 2, 1, bn=True),
          nn.Conv2d(1024, 1, 4, 1, 0, bias=False),  # FC with Conv.
      )
  
file_path: gans-with-pytorch/ralsgan/ralsgan.py
imports: import argparse
  import numpy
  import torch
  from torch import nn, optim
  from torch.autograd.variable import Variable
  from torchvision import transforms, datasets
  import os
label_desc: Use image node_id 1 to create a new Discriminator object from inherited base classes: nn with example: obj = Discriminator()