Ming Li commited on
Commit
3dd8e2c
1 Parent(s): bd5248b

turn off xformers

Browse files
Files changed (1) hide show
  1. model.py +2 -2
model.py CHANGED
@@ -57,8 +57,8 @@ class Model:
57
  base_model_id, safety_checker=None, controlnet=controlnet, torch_dtype=torch.float16
58
  )
59
  pipe.scheduler = UniPCMultistepScheduler.from_config(pipe.scheduler.config)
60
- if self.device.type == "cuda":
61
- pipe.enable_xformers_memory_efficient_attention()
62
  pipe.to(self.device)
63
  torch.cuda.empty_cache()
64
  gc.collect()
 
57
  base_model_id, safety_checker=None, controlnet=controlnet, torch_dtype=torch.float16
58
  )
59
  pipe.scheduler = UniPCMultistepScheduler.from_config(pipe.scheduler.config)
60
+ # if self.device.type == "cuda":
61
+ # pipe.enable_xformers_memory_efficient_attention()
62
  pipe.to(self.device)
63
  torch.cuda.empty_cache()
64
  gc.collect()