Hermes Bot commited on
Commit
eb20296
·
1 Parent(s): 68fa46a

Remove stray plus signs from should_use_bf16 override

Browse files
Files changed (1) hide show
  1. comfy_integration/setup.py +6 -5
comfy_integration/setup.py CHANGED
@@ -171,11 +171,12 @@ def initialize_comfyui():
171
  model_mgmt.get_torch_device = _cpu_fallback_get_torch_device
172
  import importlib
173
  importlib.reload(model_mgmt)
174
- + # Override should_use_bf16 to avoid any CUDA device property queries on CPU‑only systems.
175
- + def _safe_should_use_bf16(device, model_params=None):
176
- + """Return False unconditionally – no BF16 support on CPU‑only environment."""
177
- + return False
178
- + model_mgmt.should_use_bf16 = _safe_should_use_bf16
 
179
 
180
  print("--- Environment Ready ---")
181
 
 
171
  model_mgmt.get_torch_device = _cpu_fallback_get_torch_device
172
  import importlib
173
  importlib.reload(model_mgmt)
174
+ # Override should_use_bf16 to avoid any CUDA device property queries on CPU‑only systems.
175
+ def _safe_should_use_bf16(device, model_params=None):
176
+ """Return False unconditionally – no BF16 support on CPU‑only environment."""
177
+ return False
178
+ model_mgmt.should_use_bf16 = _safe_should_use_bf16
179
+
180
 
181
  print("--- Environment Ready ---")
182