Use ComfyUI (SDXL) on MacOS (MacBook Pro M1)
- Dominant language
- Python
- Stars
- 133k
- Forks
- 15.7k
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 158
Description
Hi
I try ComfyUI on my MacBook Pro M1.
On the Load Defaut Model and (revAnimated_v11.safetensors SD1.5) generate image take a few secondes, maibye 40-50 secondes is very quick and nice
But on the SDXL ... it's take 45mn, 1h i dont understund why :/
I try 2 models but is the same ...
I share you some screens if can help ?

Here, 2 template i have tested:
[SDXL + Refiner (default).json](https://github.com/comfyanonymous/ComfyUI/files/13257627/SDXL.%2B.Refiner.default.json)
[Workflow SDXL BASE-REFINER-LORA.json](https://github.com/comfyanonymous/ComfyUI/files/13257628/Workflow.SDXL.BASE-REFINER-LORA.json)
If can help i see this in console:
```
╭─ ~/ComfyUI master !1 ?2 ──────────────────────────────────────────── ✔ 21:14:44 ─╮
╰─ python3 main.py ─╯
Total VRAM 16384 MB, total RAM 16384 MB
Set vram state to: SHARED
Device: mps
VAE dtype: torch.float32
Using sub quadratic optimization for cross attention, if you have memory or speed issues try using: --use-split-cross-attention
Starting server
To see the GUI go to: http://127.0.0.1:8188
got prompt
model_type EPS
adm 2816
Using split attention in VAE
Working with z of shape (1, 4, 32, 32) = 4096 dimensions.
Using split attention in VAE
missing {'cond_stage_model.clip_l.text_projection', 'cond_stage_model.clip_l.logit_scale'}
left over keys: dict_keys(['cond_stage_model.clip_l.transformer.text_model.embeddings.position_ids'])
Requested to load SDXLClipModel
Loading 1 new model
Requested to load SDXL
Loading 1 new model
0%| | 0/20 [00:00>> import torch
>>> if torch.backends.mps.is_available():
... mps_device = torch.device("mps")
... x = torch.ones(1, device=mps_device)
... print (x)
... else:
... print ("MPS device not found.")
...
tensor([1.], device='mps:0')
>>>
```
Other Test:
```
╭─ ~ ──────────────────────────────────────────────── ✔ 23:36:57 ─╮
╰─ python3 ─╯
Python 3.11.6 (main, Oct 2 2023, 13:45:54) [Clang 15.0.0 (clang-1500.0.40.1)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
>>> print(torch.__version__)
2.1.0
>>> print(torch.backends.mps.is_available())
True
>>> print(torch.backends.mps.is_built())
True
>>>
```
Contributor guide
Assessment
This issue has not been assessed yet.