std1.0.0-beta-7 SafeC docs

std :: ml::diffusion

Function std::dpm_solver_2_step

#include <std/ml/diffusion.h> source

generic<M: DenoiseModel> &FloatTensor dpm_solver_2_step(
    &M model,
    const &FloatTensor x_cur,
    const &FloatTensor epsPred,
    float alpha_cur,
    float sigma_cur,
    float alpha_next,
    float sigma_next,
)

Order-2 (midpoint variant, r1=1/2): evaluates the eps-model a second time at the log-SNR midpoint between the current and next step for a higher-accuracy update: model.predict(x_s, sigma_s) at the midpoint sample / noise level, returning the predicted eps.