code: def __init__(
      self,
      sigma=1.0,
      n_group_size=1,
      dur_model_config=None,
      f0_model_config=None,
      energy_model_config=None,
      vpred_model_config=None,
      loss_weights=None,
  ):
      super(RADTTSLoss, self).__init__()
      self.sigma = sigma
      self.n_group_size = n_group_size
      self.loss_weights = loss_weights
      self.attn_ctc_loss = ForwardSumLoss()
      self.loss_weights = loss_weights
      self.loss_fns = {}
      if dur_model_config is not None:
          self.loss_fns[
              "duration_model_outputs"
          ] = AttributePredictionLoss(
              "duration",
              dur_model_config,
              loss_weights["dur_loss_weight"],
          )
  
      if f0_model_config is not None:
          self.loss_fns["f0_model_outputs"] = AttributePredictionLoss(
              "f0",
              f0_model_config,
              loss_weights["f0_loss_weight"],
              sigma=1.0,
          )
  
      if energy_model_config is not None:
          self.loss_fns[
              "energy_model_outputs"
          ] = AttributePredictionLoss(
              "energy",
              energy_model_config,
              loss_weights["energy_loss_weight"],
          )
  
      if vpred_model_config is not None:
          self.loss_fns[
              "vpred_model_outputs"
          ] = AttributePredictionLoss(
              "vpred",
              vpred_model_config,
              loss_weights["vpred_loss_weight"],
          )
  
file_path: NeMo/nemo/collections/tts/losses/radttsloss.py
imports: import torch
  from torch.nn import functional
  from nemo.collections.tts.losses.aligner_loss import ForwardSumLoss
  from nemo.collections.tts.parts.utils.helpers import get_mask_from_lengths
  from nemo.core.classes import Loss
label_desc: Use image node_id 1 to create a new RADTTSLoss object from inherited base classes: Loss with example: obj = RADTTSLoss(sigma, n_group_size, dur_model_config, f0_model_config, energy_model_config, vpred_model_config, loss_weights)