Restore install.py for omnivoice --no-deps only
requirements.txt cannot install omnivoice (it would pull in torch==2.8.* and break ComfyUI). install.py now does exactly one thing: install omnivoice --no-deps, skipped if already present. All other deps remain in requirements.txt for ComfyUI Manager to handle normally. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -18,13 +18,16 @@ A ComfyUI custom node for [OmniVoice](https://github.com/k2-fsa/OmniVoice) — a
|
|||||||
git clone https://github.com/ethanfel/ComfyUI-Omnivoice.git
|
git clone https://github.com/ethanfel/ComfyUI-Omnivoice.git
|
||||||
```
|
```
|
||||||
|
|
||||||
2. Install `omnivoice` **without its pinned torch** (one-time manual step):
|
2. Install via **ComfyUI Manager** (recommended) — it runs `install.py` and `requirements.txt` automatically.
|
||||||
|
|
||||||
|
Or manually:
|
||||||
```bash
|
```bash
|
||||||
pip install omnivoice --no-deps
|
pip install omnivoice --no-deps
|
||||||
|
pip install -r requirements.txt
|
||||||
```
|
```
|
||||||
> **Why `--no-deps`?** omnivoice pins `torch==2.8.*` from a CUDA 12.8 index. Installing it normally would overwrite ComfyUI's torch build. The `--no-deps` flag skips that pin; ComfyUI's existing torch works fine at runtime.
|
> **Why `--no-deps` for omnivoice?** It pins `torch==2.8.*` from a CUDA 12.8 index. Installing it normally would overwrite ComfyUI's torch build. `install.py` handles this automatically; `requirements.txt` covers the remaining deps safely.
|
||||||
|
|
||||||
3. Restart ComfyUI. ComfyUI Manager will install the remaining dependencies from `requirements.txt` automatically. The nodes will appear under the **OmniVoice** category.
|
3. Restart ComfyUI. The nodes will appear under the **OmniVoice** category.
|
||||||
|
|
||||||
## Nodes
|
## Nodes
|
||||||
|
|
||||||
|
|||||||
+21
@@ -0,0 +1,21 @@
|
|||||||
|
"""
|
||||||
|
ComfyUI Manager calls this file before installing requirements.txt.
|
||||||
|
|
||||||
|
omnivoice cannot be listed in requirements.txt because its default install
|
||||||
|
pins torch==2.8.* from a CUDA 12.8 index, which would overwrite ComfyUI's
|
||||||
|
torch build. We install it here with --no-deps to skip that pin.
|
||||||
|
All other dependencies are declared normally in requirements.txt.
|
||||||
|
"""
|
||||||
|
import subprocess
|
||||||
|
import sys
|
||||||
|
|
||||||
|
|
||||||
|
def _installed(package):
|
||||||
|
import importlib.util
|
||||||
|
return importlib.util.find_spec(package) is not None
|
||||||
|
|
||||||
|
|
||||||
|
if not _installed("omnivoice"):
|
||||||
|
subprocess.check_call([
|
||||||
|
sys.executable, "-m", "pip", "install", "omnivoice", "--no-deps"
|
||||||
|
])
|
||||||
Reference in New Issue
Block a user