mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-08-03 07:26:31 +08:00
Add --deterministic option to make pytorch use deterministic algorithms.
This commit is contained in:
4
main.py
4
main.py
@@ -64,6 +64,10 @@ if __name__ == "__main__":
|
||||
os.environ['CUDA_VISIBLE_DEVICES'] = str(args.cuda_device)
|
||||
print("Set cuda device to:", args.cuda_device)
|
||||
|
||||
if args.deterministic:
|
||||
if 'CUBLAS_WORKSPACE_CONFIG' not in os.environ:
|
||||
os.environ['CUBLAS_WORKSPACE_CONFIG'] = ":4096:8"
|
||||
|
||||
import cuda_malloc
|
||||
|
||||
import comfy.utils
|
||||
|
Reference in New Issue
Block a user