code: def get_ancestral_step(sigma_from, sigma_to, eta=1.0):
      if not eta:
          return sigma_to, 0.0
      sigma_up = torch.minimum(
          sigma_to,
          eta
          * (
              sigma_to**2
              * (sigma_from**2 - sigma_to**2)
              / sigma_from**2
          )
          ** 0.5,
      )
      sigma_down = (sigma_to**2 - sigma_up**2) ** 0.5
      return sigma_down, sigma_up
  
imports: import torch
  from scipy import integrate
  from ...util import append_dims
label_desc: Use image node_id 2 for calling a global function with example usage: get_ancestral_step(sigma_from, sigma_to, eta) and returns: sigma_down,  sigma_up, sigma_to,  int