comfyanonymous / ComfyUI

The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface.
https://www.comfy.org/
GNU General Public License v3.0
49.7k stars 5.23k forks source link

Can it run on M1? #135

Closed guangxinzhao closed 1 year ago

guangxinzhao commented 1 year ago

Can it run on M1?

thinkyhead commented 1 year ago

Yes, but only with CPU-based generation, which takes over 3.1 seconds per generation-step on an M1 Ultra. To prepare the installation, make a local copy of ComfyUI, set up Miniconda, open a Terminal in the ComfyUI folder, and then:

conda create -n comfyui python=3.10 -y
conda activate comfyui
pip install -r requirements.txt

Run the web interface with:

conda activate comfyui && python ./main.py --cpu

And open the browser to http://127.0.0.1:8188

GaidamakUA commented 1 year ago

Hope this pull request gets accepted soon. https://github.com/comfyanonymous/ComfyUI/pull/244 But for now you can use fork from this PR. It's ~3 times faster than CPU.

enzyme69 commented 1 year ago

@GaidamakUA how to test / check if this additional magic repo to make the MPS faster actually works?

GaidamakUA commented 1 year ago

@enzyme69 Forget it. My PR was accepted. ComfyUI is now GPU accelerated on Macs.

GaidamakUA commented 1 year ago

@comfyanonymous Please, close the issue. It is solved.