stochastic_karras_ve.md 2.23 KB
Newer Older
Patrick von Platen's avatar
Patrick von Platen committed
1
<!--Copyright 2023 The HuggingFace Team. All rights reserved.
2
3
4
5
6
7
8
9
10
11
12

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
specific language governing permissions and limitations under the License.
-->

Kashif Rasul's avatar
Kashif Rasul committed
13
14
# Stochastic Karras VE

15
[Elucidating the Design Space of Diffusion-Based Generative Models](https://huggingface.co/papers/2206.00364) is by Tero Karras, Miika Aittala, Timo Aila and Samuli Laine. This pipeline implements the stochastic sampling tailored to variance expanding (VE) models.
Kashif Rasul's avatar
Kashif Rasul committed
16

17
The abstract from the paper:
Kashif Rasul's avatar
Kashif Rasul committed
18

19
*We argue that the theory and practice of diffusion-based generative models are currently unnecessarily convoluted and seek to remedy the situation by presenting a design space that clearly separates the concrete design choices. This lets us identify several changes to both the sampling and training processes, as well as preconditioning of the score networks. Together, our improvements yield new state-of-the-art FID of 1.79 for CIFAR-10 in a class-conditional setting and 1.97 in an unconditional setting, with much faster sampling (35 network evaluations per image) than prior designs. To further demonstrate their modular nature, we show that our design changes dramatically improve both the efficiency and quality obtainable with pre-trained score networks from previous work, including improving the FID of an existing ImageNet-64 model from 2.07 to near-SOTA 1.55.*
Kashif Rasul's avatar
Kashif Rasul committed
20

21
<Tip>
Kashif Rasul's avatar
Kashif Rasul committed
22

Steven Liu's avatar
Steven Liu committed
23
Make sure to check out the Schedulers [guide](../../using-diffusers/schedulers) to learn how to explore the tradeoff between scheduler speed and quality, and see the [reuse components across pipelines](../../using-diffusers/loading#reuse-components-across-pipelines) section to learn how to efficiently load the same components into multiple pipelines.
Kashif Rasul's avatar
Kashif Rasul committed
24

25
</Tip>
Kashif Rasul's avatar
Kashif Rasul committed
26

27
28
## KarrasVePipeline
[[autodoc]] KarrasVePipeline
29
30
	- all
	- __call__
31
32
33

## ImagePipelineOutput
[[autodoc]] pipelines.ImagePipelineOutput