Buckets:
| # HeliosScheduler | |
| `HeliosScheduler` didasarkan pada sampling flow-matching piramidal yang diperkenalkan dalam [Helios](https://huggingface.co/papers). | |
| ## HeliosScheduler[[diffusers.HeliosScheduler]] | |
| #### diffusers.HeliosScheduler[[diffusers.HeliosScheduler]] | |
| ```python | |
| diffusers.HeliosScheduler(num_train_timesteps: int = 1000, shift: float = 1.0, stages: int = 3, stage_range: list = [0, 0.3333333333333333, 0.6666666666666666, 1], gamma: float = 0.3333333333333333, thresholding: bool = False, prediction_type: str = 'flow_prediction', solver_order: int = 2, predict_x0: bool = True, solver_type: str = 'bh2', lower_order_final: bool = True, disable_corrector: list[int] = [], solver_p: SchedulerMixin = None, use_flow_sigmas: bool = True, scheduler_type: str = 'unipc', use_dynamic_shifting: bool = False, time_shift_type: typing.Literal['exponential', 'linear'] = 'exponential') | |
| ``` | |
| [Sumber](https://github.com/huggingface/diffusers/blob/main/src/diffusers/schedulers/scheduling_helios.py#L35) | |
| #### convert_model_output[[diffusers.HeliosScheduler.convert_model_output]] | |
| ```python | |
| convert_model_output(model_output: Tensor, *args, sample: Tensor = None, sigma: Tensor = None, **kwargs) | |
| ``` | |
| [Sumber](https://github.com/huggingface/diffusers/blob/main/src/diffusers/schedulers/scheduling_helios.py#L371) | |
| **Parameter:** | |
| model_output (`torch.Tensor`) : Output langsung dari model difusi yang dipelajari. | |
| timestep (`int`) : Langkah waktu diskret saat ini dalam rantai difusi. | |
| sample (`torch.Tensor`) : Instans saat ini dari sampel yang dibuat oleh proses difusi. | |
| sigma (`torch.Tensor`, *opsional*) : sigma dari langkah saat ini dalam jadwal noise. | |
| **Mengembalikan:** `torch.Tensor` | |
| Output model yang telah dikonversi. | |
| Konversi keluaran model ke tipe yang sesuai yang dibutuhkan oleh algoritma UniPC. | |
| #### init_sigmas[[diffusers.HeliosScheduler.init_sigmas]] | |
| ```python | |
| init_sigmas() | |
| ``` | |
| [Sumber](https://github.com/huggingface/diffusers/blob/main/src/diffusers/schedulers/scheduling_helios.py#L90) | |
| inisialisasi timesteps dan sigmas global | |
| #### init_sigmas_for_each_stage[[diffusers.HeliosScheduler.init_sigmas_for_each_stage]] | |
| ```python | |
| init_sigmas_for_each_stage() | |
| ``` | |
| [Sumber](https://github.com/huggingface/diffusers/blob/main/src/diffusers/schedulers/scheduling_helios.py#L108) | |
| Inisialisasi timesteps untuk setiap tahap | |
| #### multistep_uni_c_bh_update[[diffusers.HeliosScheduler.multistep_uni_c_bh_update]] | |
| ```python | |
| multistep_uni_c_bh_update(this_model_output: Tensor, *args, last_sample: Tensor = None, this_sample: Tensor = None, order: int = None, sigma_before: Tensor = None, sigma: Tensor = None, **kwargs) | |
| ``` | |
| [Sumber](https://github.com/huggingface/diffusers/blob/main/src/diffusers/schedulers/scheduling_helios.py#L591) | |
| **Parameter:** | |
| this_model_output (`torch.Tensor`) : Output model pada `x_t`. | |
| this_timestep (`int`) : Langkah waktu saat ini `t`. | |
| last_sample (`torch.Tensor`) : Sampel yang dihasilkan sebelum prediktor terakhir `x_{t-1}`. | |
| this_sample (`torch.Tensor`) : Sampel yang dihasilkan setelah predictor terakhir `x_{t}`. | |
| order (`int`) : Nilai `p` dari UniC-p pada langkah ini. Orde akurasi efektif seharusnya `order + 1`. | |
| sigma_before (`torch.Tensor`, *opsional*) : sigma dari langkah sebelumnya dalam jadwal noise. | |
| sigma (`torch.Tensor`, *opsional*) : sigma dari langkah saat ini dalam jadwal noise. | |
| **Mengembalikan:** `torch.Tensor` | |
| Tensor sampel yang dikoreksi pada langkah waktu saat ini. | |
| Satu langkah untuk UniC (versi B(h)). | |
| #### multistep_uni_p_bh_update[[diffusers.HeliosScheduler.multistep_uni_p_bh_update]] | |
| ```python | |
| multistep_uni_p_bh_update(model_output: Tensor, *args, sample: Tensor = None, order: int = None, sigma: Tensor = None, sigma_next: Tensor = None, **kwargs) | |
| ``` | |
| [Sumber](https://github.com/huggingface/diffusers/blob/main/src/diffusers/schedulers/scheduling_helios.py#L453) | |
| **Parameter:** | |
| model_output (`torch.Tensor`) : Output langsung dari model difusi yang dipelajari pada timestep saat ini. | |
| prev_timestep (`int`) : Langkah waktu diskrit sebelumnya dalam rantai difusi. | |
| sample (`torch.Tensor`) : Instans saat ini dari sampel yang dibuat oleh proses difusi. | |
| order (`int`) : Urutan UniP pada timestep ini (sesuai dengan *p* dalam UniPC-p). | |
| sigma (`torch.Tensor`, *opsional*) : sigma dari langkah saat ini dalam jadwal noise. | |
| sigma_next (`torch.Tensor`, *opsional*) : sigma dari langkah berikutnya dalam jadwal noise. | |
| **Mengembalikan:** `torch.Tensor` | |
| Tensor sampel pada langkah waktu sebelumnya. | |
| Satu langkah untuk UniP (versi B(h)). Sebagai alternatif, `self.solver_p` digunakan jika ditentukan. | |
| #### set_begin_index[[diffusers.HeliosScheduler.set_begin_index]] | |
| ```python | |
| set_begin_index(begin_index: int = 0) | |
| ``` | |
| [Sumber](https://github.com/huggingface/diffusers/blob/main/src/diffusers/schedulers/scheduling_helios.py#L182) | |
| **Parameter:** | |
| begin_index (`int`) : Indeks awal untuk penjadwal. | |
| Menetapkan indeks awal untuk penjadwal. Fungsi ini harus dijalankan dari pipeline sebelum inferensi. | |
| #### set_timesteps[[diffusers.HeliosScheduler.set_timesteps]] | |
| ```python | |
| set_timesteps(num_inference_steps: int, stage_index: int | None = None, device: typing.Union[str, torch.device] = None, sigmas: bool | None = None, mu: bool | None = None, is_amplify_first_chunk: bool = False) | |
| ``` | |
| [Sumber](https://github.com/huggingface/diffusers/blob/main/src/diffusers/schedulers/scheduling_helios.py#L195) | |
| Mengatur timesteps dan sigmas untuk setiap tahap | |
| #### time_shift[[diffusers.HeliosScheduler.time_shift]] | |
| ```python | |
| time_shift(mu: float, sigma: float, t: Tensor) | |
| ``` | |
| [Sumber](https://github.com/huggingface/diffusers/blob/main/src/diffusers/schedulers/scheduling_helios.py#L259) | |
| **Parameter:** | |
| mu (`float`) : Parameter mu untuk pergeseran waktu. | |
| sigma (`float`) : Parameter sigma untuk pergeseran waktu. | |
| t (`torch.Tensor`) : Langkah-langkah waktu (timesteps) input. | |
| **Mengembalikan:** `torch.Tensor` | |
| Langkah-langkah waktu yang digeser. | |
| Terapkan pergeseran waktu ke sigmas. | |
| scheduling_helios | |
Xet Storage Details
- Size:
- 6 kB
- Xet hash:
- f0ba8bffc9a05d161cd23de55d0487a58c0440acbfa175cec0be1fb5e0e10552
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.