Spaces:
Runtime error
Runtime error
fix bug
Browse files
app.py
CHANGED
@@ -116,6 +116,7 @@ def main():
|
|
116 |
model.register_tokenmap_hooks()
|
117 |
else:
|
118 |
model.reset_attention_maps()
|
|
|
119 |
plain_img = model.produce_attn_maps([base_text_prompt], [negative_text],
|
120 |
height=height, width=width, num_inference_steps=steps,
|
121 |
guidance_scale=guidance_weight)
|
|
|
116 |
model.register_tokenmap_hooks()
|
117 |
else:
|
118 |
model.reset_attention_maps()
|
119 |
+
model.remove_tokenmap_hooks()
|
120 |
plain_img = model.produce_attn_maps([base_text_prompt], [negative_text],
|
121 |
height=height, width=width, num_inference_steps=steps,
|
122 |
guidance_scale=guidance_weight)
|