code: def _forward(
      self,
      network: nn.Module,
      denoiser: Denoiser,
      cond: Dict,
      input: torch.Tensor,
      batch: Dict,
  ) -> Tuple[torch.Tensor, Dict]:
      additional_model_inputs = {
          key: batch[key]
          for key in self.batch2model_keys.intersection(batch)
      }
      sigmas = self.sigma_sampler(input.shape[0]).to(input)
  
      noise = torch.randn_like(input)
      if self.offset_noise_level > 0.0:
          offset_shape = (
              (input.shape[0], 1, input.shape[2])
              if self.n_frames is not None
              else (input.shape[0], input.shape[1])
          )
          noise = noise + self.offset_noise_level * append_dims(
              torch.randn(offset_shape, device=input.device),
              input.ndim,
          )
      sigmas_bc = append_dims(sigmas, input.ndim)
      noised_input = self.get_noised_input(sigmas_bc, noise, input)
  
      model_output = denoiser(
          network, noised_input, sigmas, cond, **additional_model_inputs
      )
      w = append_dims(self.loss_weighting(sigmas), input.ndim)
      return self.get_loss(model_output, input, w)
  
file_path: generative-models/sgm/modules/diffusionmodules/loss.py
imports: from typing import Dict, List, Optional, Tuple, Union
  import torch
  import torch.nn
  from ...modules.autoencoding.lpips.loss.lpips import LPIPS
  from ...modules.encoders.modules import GeneralConditioner
  from ...util import append_dims, instantiate_from_config
  from .denoiser import Denoiser
label_desc: Use image node_id 4 for calling the StandardDiffusionLoss obj's underlying member method code with example usage: obj._forward(network, denoiser, cond, input, batch) and returns: self