class_docstr: A wrapper for discrete schedule DDPM models that output eps (the predicted
  noise).
class_docstr_tok: ["A","wrapper","for","discrete","schedule","DDPM","models","that","output","eps","(","the","predicted","noise",")","."]
code: def loss(self, input, noise, sigma, **kwargs):
      c_out, c_in = [
          append_dims(x, input.ndim) for x in self.get_scalings(sigma)
      ]
      noised_input = input + noise * append_dims(sigma, input.ndim)
      eps = self.get_eps(
          noised_input * c_in, self.sigma_to_t(sigma), **kwargs
      )
      return (eps - noise).pow(2).flatten(1).mean(1)
  
imports: import math
  import torch
  import torchsde
  from scipy import integrate
  from torch import nn
  from torchdiffeq import odeint
  from tqdm.auto import tqdm, trange
label_desc: Use image node_id 4 for calling the DiscreteEpsDDPMDenoiser obj's underlying member method code with example usage: obj.loss(input, noise, sigma) and returns: unknown