class_docstr: Compute Discriminator Loss values depending on training
  configuration 
class_docstr_tok: ["Compute","Discriminator","Loss","values","depending","on","training","configuration"]
code: def __init__(self, C):
      super(DiscriminatorLoss, self).__init__()
      assert not (
          C.use_mse_gan_loss and C.use_hinge_gan_loss
      ), " [!] Cannot use HingeGANLoss and MSEGANLoss together."
  
      self.use_mse_gan_loss = C.use_mse_gan_loss
      self.use_hinge_gan_loss = C.use_hinge_gan_loss
  
      if C.use_mse_gan_loss:
          self.mse_loss = MSEDLoss()
      if C.use_hinge_gan_loss:
          self.hinge_loss = HingeDLoss()
  
imports: import torch
  from torch import nn
  from torch.nn import functional
label_desc: Use image node_id 1 to create a new DiscriminatorLoss object from inherited base classes: nn with example: obj = DiscriminatorLoss(C)