A birthday present for myself this year was a mac-mini 4 with 16G of RAM and 256G of storage. It’s kind of my first personal mac device. How do I plan to toss it. First, let’s confirm how running Flux works.
intend
git
To install git on a mac, you need to install homebrew first.Official website address
安装homebrew
1
2
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
Install git
1
2
brew install git
confyui
Now open source software installation, the official website are written in detail, do it basically.Mac Installation Links
conda
1
2
curl -O https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-arm64.sh
sh Miniconda3-latest-MacOSX-arm64.sh
Create a confyUI environment
1
conda create -n confyui python=3.12.4
Enter conda
1
coda activate confyui
PyTorch
1
pip3 install --pre torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/nightly/cpu
Verify that the installation is working
1
2
3
4
5
6
7
8
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.")
You’ll see it normally.
1
tensor([1.], device='mps:0')
abort
1
quit()
confyui
Install confyui, very simple, just git download. Currently confyui updates very quickly, only download master on it.
1
2
3
git clone https://github.com/comfyanonymous/ComfyUI.git
cd confyui
pip install -r requirement.txt
Once the installation is complete, you can run directly
1
python main.py
Flux
Flux installation at ConfyUI, which has the relevantModule Download Address
You need to pay attention to the path where the files are stored, as mentioned in the article.
- Model: flux1-dev-fp8.safetensors.
- flux_text_encoders: clip_l.safetensors, t5xxl_fp8_e4m3fn.safetensors two files, directory: ComfyUI/models/clip/
- VAE: ae.safetensors Catalog: ComfyUI/models/vae/