Skip to content

Commit

Permalink
fix: progress latent collection bug
Browse files Browse the repository at this point in the history
  • Loading branch information
brycedrennan committed Jan 3, 2024
1 parent 5ad9c3c commit 59206e6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion imaginairy/api/generate_refiners.py
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,8 @@ def latent_logger(latents):
condition_scale=prompt.prompt_strength,
**text_conditioning_kwargs,
)
lc.progress_latent_callback(x)
if lc.progress_latent_callback:
lc.progress_latent_callback(x)
# trying to clear memory. not sure if this helps
sd.unet.set_context(context="self_attention_map", value={})
sd.unet._reset_context()
Expand Down

0 comments on commit 59206e6

Please sign in to comment.