The new generative process provides a general update rule for generating a sample at time t-1 from a sample at time t. This update rule has three parts: first, a term based on the predicted original data; second, a term that points back in the direction of the noisy input at time t; and third, a random noise term. The amount of random noise is controlled by the sigma parameter. Different choices of sigma result in different generative processes, all using the same underlying neural network. When sigma is chosen to match the original DDPM formulation, the process becomes a DDPM. A special case occurs when sigma is set to zero for all steps. In this case, the forward process becomes deterministic, and the random noise term in the generative process disappears. The resulting model becomes an implicit probabilistic model, where samples are generated from latent variables through a fixed, deterministic procedure. We name this model the Denoising Diffusion Implicit Model, or DDIM, because it is an implicit model trained with the DDPM objective, even though the forward process is no longer a diffusion. 4.2. Accelerated generation processes In the previous sections, the generative process was forced to have the same number of steps, T, as the forward process. However, since the training objective does not depend on the specific forward procedure, we can consider forward processes with fewer steps. This allows us to accelerate the corresponding generative processes without having to train a new model. We can define the forward process over a smaller subset of timesteps, say S steps instead of T. This creates a "sampling trajectory" that is much shorter than the original. The generative process then samples according to this shorter, reversed trajectory. When the number of sampling steps is much smaller than T, we can achieve significant speedups. Using a similar argument as before, we can justify using the same pre-trained model for these accelerated processes. Only slight changes to the update rule are needed. This means we can train a model with a large number of forward steps but then choose to sample using only a fraction of them, trading off some quality for a massive gain in speed. 4.3. Relevance to Neural ODEs We can rewrite the DDIM update rule in a form that highlights its similarity to the Euler method for solving ordinary differential equations, or ODEs. In the limit of continuous time, the DDIM sampling process corresponds to solving a specific ODE. This connection suggests that, unlike DDPM, we can also reverse the generation process in DDIM, going from an image at time 0 to a latent code at time T. This is because we can simulate the reverse of the ODE. This ability to create a latent encoding of an observation could be useful for downstream tasks. In a concurrent work, Song and colleagues proposed a "probability flow ODE" based on score matching. We can show that our ODE is equivalent to a special case of theirs. Proposition 1 states that the ODE corresponding to DDIM with an optimal model has an equivalent probability flow ODE corresponding to the "Variance-Exploding" SDE from the work of Song and colleagues. While the underlying ODEs are equivalent, the discrete sampling procedures are slightly different, which can lead to different results, especially when using fewer sampling steps. Our method takes Euler steps with respect to a change in the noise level, while their method takes steps with respect to a change in time. 5. Experiments In this section, we show that DDIMs outperform DDPMs in terms of image generation when fewer iterations are considered, giving speed-ups of 10 to 100 times over the original DDPM generation process. Moreover, unlike DDPMs, DDIMs can perform meaningful interpolation directly from the latent space and can reconstruct samples from their latent codes. For our experiments, we use the same pre-trained model for each dataset, with T set to 1000. The only change we make is how we produce samples from the model. We control the number of sampling steps and the stochasticity of the process using a parameter eta. When eta is 0, the process is a deterministic DDIM. When eta is 1, it corresponds to a DDPM. We also consider a variant of DDPM with a larger noise variance, which was used in the original DDPM implementation for generating CIFAR10 samples. 5.1. Sample quality and efficiency We report the quality of generated samples using the Frechet Inception Distance, or FID, for the CIFAR10 and CelebA datasets. As expected, sample quality improves as we use more sampling steps, showing a trade-off between quality and computation. Our results show that DDIM, with eta equals 0, achieves the best sample quality when the number of sampling steps is small. For example, on CIFAR10 with only 100 steps, DDIM achieves an FID of 4.16, which is close to the 4.04 FID it gets with the full 1000 steps. The original DDPM, in contrast, performs much worse with fewer steps. The DDPM variant with larger noise, which achieves the best score of 3.17 with 1000 steps, performs very poorly with short trajectories. Visual inspection of the generated samples confirms these findings. DDPM samples degrade rapidly when using only 10 sampling steps, while DDIM samples remain high quality. Furthermore, the time needed to produce a sample scales linearly with the number of sampling steps. This means DDIM is highly efficient. It can produce samples with quality comparable to 1000-step models using only 20 to 100 steps, which represents a 10 to 50 times speed-up. For instance, on the CelebA dataset, the FID score of a 100-step DDPM is similar to that of a 20-step DDIM. 5.2. Sample consistency in DDIMs For DDIM, the generative process is deterministic, meaning the final image depends only on the initial random noise at time T. We observed that if we start with the same initial noise and generate images using different numbers of steps, the high-level features of the images remain remarkably similar. In many cases, samples generated with only 20 steps are already very close to those generated with 1000 steps, differing only in fine details. This suggests that the initial noise acts as an informative latent encoding for the image's main features, while the generation process fills in the details. 5.3. Interpolation in deterministic generative processes Since the high-level features of a DDIM sample are encoded by the initial noise, we investigated whether we could perform semantic interpolation, similar to what is seen in GANs. This is different from DDPMs, where the stochastic process means the same initial noise can lead to very different images. We found that simple linear interpolation between two initial noise vectors in DDIM leads to smooth, semantically meaningful interpolations between the corresponding images. This allows for high-level control over the generated images directly through the latent variables, an ability that DDPMs lack. 5.4. Reconstruction from Latent Space Because DDIM is related to an ODE, it should be possible to run the process in reverse to encode an image into a latent variable, and then run it forward to reconstruct the image. We tested this on the CIFAR-10 test set and measured the reconstruction error. Our results show that DDIMs have very low reconstruction error, and the error decreases as more steps are used for encoding and decoding. With 1000 steps, the per-dimension mean squared error is as low as 0.0001. This property, similar to that of Neural ODEs and normalizing flows, is not possible for the stochastic DDPMs. 6. Related Work Our work is based on a large family of existing methods on learning generative models as transition operators of Markov chains, with contributions from researchers like Sohl-Dickstein, Bengio, Salimans, Song, Goyal, and Levy. Among these, denoising diffusion probabilistic models, or DDPMs, by Ho and colleagues, and noise conditional score networks, or NCSNs, by Song and colleagues, have recently achieved high sample quality comparable to GANs from Brock and Karras. DDPMs optimize a variational lower bound to the log-likelihood, whereas NCSNs optimize the score matching objective from Hyvärinen over a data density estimate, a connection explored by Vincent and Raphan. Despite their different motivations, DDPMs and NCSNs are closely related. Both use a denoising autoencoder objective for many noise levels, and both use a procedure similar to Langevin dynamics, a concept from Neal, to produce samples. Since Langevin dynamics is a discretization of a gradient flow, as shown by Jordan and colleagues, both DDPM and NCSN require many steps to achieve good sample quality. This aligns with the observation that both models have trouble generating high-quality samples in just a few iterations. DDIM, on the other hand, is an implicit generative model, a class of models described by Mohamed and colleagues, where samples are uniquely determined from latent variables. Hence, DDIM has certain properties that resemble GANs, by Goodfellow and colleagues, and invertible flows, by Dinh and colleagues, such as the ability to produce semantically meaningful interpolations. We derive DDIM from a purely variational perspective, where the restrictions of Langevin dynamics are not relevant. This could partially explain why we are able to observe superior sample quality compared to DDPM under fewer iterations.