espnet2.enh.diffusion.sdes.OUVPSDE
espnet2.enh.diffusion.sdes.OUVPSDE
class espnet2.enh.diffusion.sdes.OUVPSDE(beta_min, beta_max, stiffness=1, N=1000, **ignored_kwargs)
Bases: SDE
OUVPSDE class.
!!! SGMSE authors observed instabilities around t=0.2. !!!
Construct an Ornstein-Uhlenbeck Variance Preserving SDE:
dx = -1/2 * beta(t) * stiffness * (y-x) dt + sqrt(beta(t)) * dw
with
beta(t) = beta_min + t(beta_max - beta_min)
Note that the “steady-state mean” y is not provided at construction, but must rather be given as an argument to the methods which require it (e.g., sde or marginal_prob).
- Parameters:
- beta_min – smallest sigma.
- beta_max – largest sigma.
- stiffness – stiffness factor of the drift. 1 by default.
- N – number of discretization steps
property T
End time of the SDE.
copy()
marginal_prob(x0, t, y)
Parameters to determine the marginal distribution of
the SDE, $p_t(x|args)$.
prior_logp(z)
Compute log-density of the prior distribution.
Useful for computing the log-likelihood via probability flow ODE.
- Parameters:z – latent code
- Returns: log probability density
prior_sampling(shape, y)
Generate one sample from the prior distribution,
$p_T(x|args)$ with shape shape.
sde(x, t, y)