Browse Source

Use inference_mode instead of no_grad.

pull/225/head
comfyanonymous 2 years ago
parent
commit
f67c00622f
  1. 2
      execution.py

2
execution.py

@ -143,7 +143,7 @@ class PromptExecutor:
else:
self.server.client_id = None
with torch.no_grad():
with torch.inference_mode():
for x in prompt:
recursive_output_delete_if_changed(prompt, self.old_prompt, self.outputs, x)

Loading…
Cancel
Save