-
Notifications
You must be signed in to change notification settings - Fork 6.7k
Open
Labels
staleIssues that haven't received updatesIssues that haven't received updates
Description
Hello team, quick question to make sure I understand the behavior of the step function in LCM Scheduler.
diffusers/src/diffusers/schedulers/scheduling_lcm.py
Lines 534 to 543 in a7361dc
| # 1. get previous step value | |
| prev_step_index = self.step_index + 1 | |
| if prev_step_index < len(self.timesteps): | |
| prev_timestep = self.timesteps[prev_step_index] | |
| else: | |
| prev_timestep = timestep | |
| # 2. compute alphas, betas | |
| alpha_prod_t = self.alphas_cumprod[timestep] | |
| alpha_prod_t_prev = self.alphas_cumprod[prev_timestep] if prev_timestep >= 0 else self.final_alpha_cumprod |
Here, it seems that the condition prev_timestep >= 0 is always True, because timestep and self.timesteps[prev_step_index] cannot be negative. This would mean that self.final_alpha_cumprod is never used. Is there a way in which prev_timestep can be negative?
Metadata
Metadata
Assignees
Labels
staleIssues that haven't received updatesIssues that haven't received updates