Skip to content

Commit 06335fb

Browse files
authored
Merge branch 'main' into main
2 parents 14b34fa + d006f07 commit 06335fb

File tree

2 files changed

+28
-5
lines changed

2 files changed

+28
-5
lines changed

src/diffusers/schedulers/scheduling_dpmsolver_multistep.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,8 @@ class DPMSolverMultistepScheduler(SchedulerMixin, ConfigMixin):
136136
sampling, and `solver_order=3` for unconditional sampling.
137137
prediction_type (`str`, defaults to `epsilon`, *optional*):
138138
Prediction type of the scheduler function; can be `epsilon` (predicts the noise of the diffusion process),
139-
`sample` (directly predicts the noisy sample`) or `v_prediction` (see section 2.4 of [Imagen
140-
Video](https://imagen.research.google/video/paper.pdf) paper).
139+
`sample` (directly predicts the noisy sample), `v_prediction` (see section 2.4 of [Imagen
140+
Video](https://imagen.research.google/video/paper.pdf) paper), or `flow_prediction`.
141141
thresholding (`bool`, defaults to `False`):
142142
Whether to use the "dynamic thresholding" method. This is unsuitable for latent-space diffusion models such
143143
as Stable Diffusion.
@@ -174,6 +174,10 @@ class DPMSolverMultistepScheduler(SchedulerMixin, ConfigMixin):
174174
Whether to use the uniform-logSNR for step sizes proposed by Lu's DPM-Solver in the noise schedule during
175175
the sampling process. If `True`, the sigmas and time steps are determined according to a sequence of
176176
`lambda(t)`.
177+
use_flow_sigmas (`bool`, *optional*, defaults to `False`):
178+
Whether to use flow sigmas for step sizes in the noise schedule during the sampling process.
179+
flow_shift (`float`, *optional*, defaults to 1.0):
180+
The shift value for the timestep schedule for flow matching.
177181
final_sigmas_type (`str`, defaults to `"zero"`):
178182
The final `sigma` value for the noise schedule during the sampling process. If `"sigma_min"`, the final
179183
sigma is the same as the last sigma in the training schedule. If `zero`, the final sigma is set to 0.

src/diffusers/schedulers/scheduling_flow_match_euler_discrete.py

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,30 @@ class FlowMatchEulerDiscreteScheduler(SchedulerMixin, ConfigMixin):
5454
Args:
5555
num_train_timesteps (`int`, defaults to 1000):
5656
The number of diffusion steps to train the model.
57-
timestep_spacing (`str`, defaults to `"linspace"`):
58-
The way the timesteps should be scaled. Refer to Table 2 of the [Common Diffusion Noise Schedules and
59-
Sample Steps are Flawed](https://huggingface.co/papers/2305.08891) for more information.
6057
shift (`float`, defaults to 1.0):
6158
The shift value for the timestep schedule.
59+
use_dynamic_shifting (`bool`, defaults to False):
60+
Whether to apply timestep shifting on-the-fly based on the image resolution.
61+
base_shift (`float`, defaults to 0.5):
62+
Value to stabilize image generation. Increasing `base_shift` reduces variation and image is more consistent
63+
with desired output.
64+
max_shift (`float`, defaults to 1.15):
65+
Value change allowed to latent vectors. Increasing `max_shift` encourages more variation and image may be
66+
more exaggerated or stylized.
67+
base_image_seq_len (`int`, defaults to 256):
68+
The base image sequence length.
69+
max_image_seq_len (`int`, defaults to 4096):
70+
The maximum image sequence length.
71+
invert_sigmas (`bool`, defaults to False):
72+
Whether to invert the sigmas.
73+
shift_terminal (`float`, defaults to None):
74+
The end value of the shifted timestep schedule.
75+
use_karras_sigmas (`bool`, defaults to False):
76+
Whether to use Karras sigmas for step sizes in the noise schedule during sampling.
77+
use_exponential_sigmas (`bool`, defaults to False):
78+
Whether to use exponential sigmas for step sizes in the noise schedule during sampling.
79+
use_beta_sigmas (`bool`, defaults to False):
80+
Whether to use beta sigmas for step sizes in the noise schedule during sampling.
6281
"""
6382

6483
_compatibles = []

0 commit comments

Comments
 (0)