Skip to content

Commit

Permalink
Readme compiled reqs (#868)
Browse files Browse the repository at this point in the history
* Update commands to use relative paths

* Allow copy/paste of win32 commands in powershell

* Add macOS commands & output to correct files
  • Loading branch information
webfiltered authored Feb 10, 2025
1 parent a1d490e commit 1b7a8ed
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 6 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@ comfyui
# built assets
assets/ComfyUI
assets/cpython*.tar.gz
assets/override.txt
assets/python
assets/requirements.*
assets/user
Expand Down
20 changes: 15 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -192,16 +192,26 @@ yarn make --windows

The `requirements.compiled` file is a pre-compiled requirements file that is used to install the dependencies for the application. It is generated by the `comfy-cli`.

For windows, you can generate the requirements.compiled file by running the following command:
You can generate the compiled requirements files by running the following commands from the project root directory:

```bash
#### Windows

```powershell
## Nvidia Cuda requirements
uv pip compile C:\OneDrive\Documents\GitHub\electron\assets\ComfyUI\requirements.txt C:\OneDrive\Documents\GitHub\electron\assets\ComfyUI\custom_nodes\ComfyUI-Manager\requirements.txt --emit-index-annotation --emit-index-url --index-strategy unsafe-best-match -o C:\OneDrive\Documents\GitHub\electron\assets\requirements.compiled --override C:\OneDrive\Documents\GitHub\electron\assets\override.txt
--index-url https://pypi.org/simple
uv pip compile assets\ComfyUI\requirements.txt assets\ComfyUI\custom_nodes\ComfyUI-Manager\requirements.txt --emit-index-annotation --emit-index-url --index-strategy unsafe-best-match -o assets\requirements\windows_nvidia.compiled --override assets\override.txt `
--index-url https://pypi.org/simple `
--extra-index-url https://download.pytorch.org/whl/cu126
## CPU requirements
uv pip compile C:\OneDrive\Documents\GitHub\electron\assets\ComfyUI\requirements.txt C:\OneDrive\Documents\GitHub\electron\assets\ComfyUI\custom_nodes\ComfyUI-Manager\requirements.txt --emit-index-annotation --emit-index-url --index-strategy unsafe-best-match -o C:\OneDrive\Documents\GitHub\electron\assets\requirements.compiled --override C:\OneDrive\Documents\GitHub\electron\assets\override.txt
uv pip compile assets\ComfyUI\requirements.txt assets\ComfyUI\custom_nodes\ComfyUI-Manager\requirements.txt --emit-index-annotation --emit-index-url --index-strategy unsafe-best-match -o assets\requirements\windows_cpu.compiled `
--index-url https://pypi.org/simple
```

#### macOS

```bash
## macOS requirements
uv pip compile assets/ComfyUI/requirements.txt assets/ComfyUI/custom_nodes/ComfyUI-Manager/requirements.txt --emit-index-annotation --emit-index-url --index-strategy unsafe-best-match -o assets/requirements/macos.compiled --override assets/override.txt \
--index-url https://pypi.org/simple
```

Expand Down
6 changes: 6 additions & 0 deletions assets/override.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# ensure usage of GPU_OPTION.NVIDIA version of pytorch
--extra-index-url https://download.pytorch.org/whl/cu126
torch
torchaudio
torchsde
torchvision

0 comments on commit 1b7a8ed

Please sign in to comment.