Skip to content

Commit

Permalink
work around unexplained crash when timesteps=1000 (CompVis#440)
Browse files Browse the repository at this point in the history
* work around unexplained crash when timesteps=1000

* this fix seems to work
  • Loading branch information
lstein committed Sep 9, 2022
1 parent c33a84c commit 6531446
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ldm/modules/diffusionmodules/util.py
Expand Up @@ -81,7 +81,9 @@ def make_ddim_timesteps(

# assert ddim_timesteps.shape[0] == num_ddim_timesteps
# add one to get the final alpha values right (the ones from first scale to data during sampling)
steps_out = ddim_timesteps + 1
# steps_out = ddim_timesteps + 1
steps_out = ddim_timesteps

if verbose:
print(f'Selected timesteps for ddim sampler: {steps_out}')
return steps_out
Expand Down

0 comments on commit 6531446

Please sign in to comment.