DiffusionScheduler class
Scheduler / sampler algorithm — forward-looking union.
Pre-IDL sources all expose the same eight cases (DPM++ 2M Karras, DPM++ 2M, DPM++ 2M SDE, DDIM, Euler, Euler Ancestral, PNDM, LMS); see: Swift DiffusionTypes.swift:184 (.dpmPP2MKarras .. .lms) Kotlin DiffusionTypes.kt:155 (DPM_PP_2M_KARRAS .. LMS) RN DiffusionTypes.ts:48 (DPMPP2MKarras .. LMS) Web DiffusionTypes.ts:3 (numeric DPM_PP_2M_Karras .. LMS, matches C ABI) C ABI rac_diffusion_types.h:31 (RAC_DIFFUSION_SCHEDULER_*)
This proto enum extends that with two values that downstream backends are expected to grow into but no SDK exposes yet:
- DDPM — original Ho et al. 2020 sampler
- LCM — Latent Consistency Model sampler (paired with the LCM model variant; today Swift/Kotlin reuse DPM++ 2M Karras for LCM models because no LCM scheduler case exists). And it intentionally omits DPMPP_2M_SDE, which exists in every SDK today but is being collapsed back into DPMPP_2M for the v1 IDL surface (the SDE variant is purely an algorithmic toggle on DPM++ 2M; backends accept either tag).
Drift reconciliation:
- Swift/Kotlin/RN/Web/C-ABI carriers of DPMPP_2M_SDE must round-trip that case to DIFFUSION_SCHEDULER_DPMPP_2M (lossy in name, equivalent in semantics — the SDE flag is a backend implementation detail).
- DDPM and LCM are new slots; SDKs that don't yet recognize them must fall back to DIFFUSION_SCHEDULER_DPMPP_2M_KARRAS (the recommended default).
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- name → String
-
This enum's name, as specified in the .proto file.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- value → int
-
This enum's integer value, as specified in the .proto file.
finalinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
Returns this enum's
nameor thevalueif names are not represented.inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
valueOf(
int value) → DiffusionScheduler?
Constants
- DIFFUSION_SCHEDULER_DDIM → const DiffusionScheduler
- DIFFUSION_SCHEDULER_DDPM → const DiffusionScheduler
- DIFFUSION_SCHEDULER_DPMPP_2M → const DiffusionScheduler
- DIFFUSION_SCHEDULER_DPMPP_2M_KARRAS → const DiffusionScheduler
- DIFFUSION_SCHEDULER_DPMPP_2M_SDE → const DiffusionScheduler
- DIFFUSION_SCHEDULER_EULER → const DiffusionScheduler
- DIFFUSION_SCHEDULER_EULER_A → const DiffusionScheduler
- DIFFUSION_SCHEDULER_LCM → const DiffusionScheduler
- DIFFUSION_SCHEDULER_LMS → const DiffusionScheduler
- DIFFUSION_SCHEDULER_PNDM → const DiffusionScheduler
- DIFFUSION_SCHEDULER_UNSPECIFIED → const DiffusionScheduler
-
values
→ const List<
DiffusionScheduler>