feat: add support for DEIS multistep scheduler
This commit is contained in:
parent
05756b2b08
commit
6b6f2f0eff
|
@ -18,6 +18,11 @@ from diffusers import (
|
|||
PNDMScheduler,
|
||||
)
|
||||
|
||||
try:
|
||||
from diffusers import DEISMultistepScheduler
|
||||
except:
|
||||
from .stub_scheduler import StubScheduler as DEISMultistepScheduler
|
||||
|
||||
from ..params import DeviceParams, Size
|
||||
from ..utils import ServerContext, run_gc
|
||||
|
||||
|
@ -29,6 +34,7 @@ latent_factor = 8
|
|||
pipeline_schedulers = {
|
||||
"ddim": DDIMScheduler,
|
||||
"ddpm": DDPMScheduler,
|
||||
"deis-multi": DEISMultistepScheduler,
|
||||
"dpm-multi": DPMSolverMultistepScheduler,
|
||||
"dpm-single": DPMSolverSinglestepScheduler,
|
||||
"euler": EulerDiscreteScheduler,
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
from typing import Any
|
||||
|
||||
|
||||
class StubScheduler():
|
||||
def step(self, model_output: Any, timestep: int, sample: Any, return_dict: bool = True) -> None:
|
||||
raise NotImplemented("scheduler not available, try updating diffusers")
|
|
@ -44,6 +44,7 @@ export const PLATFORM_LABELS: Record<string, string> = {
|
|||
export const SCHEDULER_LABELS: Record<string, string> = {
|
||||
'ddim': 'DDIM',
|
||||
'ddpm': 'DDPM',
|
||||
'deis-multi': 'DEIS Multistep',
|
||||
'dpm-multi': 'DPM Multistep',
|
||||
'dpm-single': 'DPM Singlestep',
|
||||
'euler': 'Euler',
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
"CUDA",
|
||||
"ddim",
|
||||
"ddpm",
|
||||
"deis",
|
||||
"denoise",
|
||||
"denoising",
|
||||
"directml",
|
||||
|
|
Loading…
Reference in New Issue