- Replace torchlibrosa with custom LibrosaSTFT and LibrosaISTFT wrappers - Maintain full API compatibility with existing FDomainHelper code - No quality loss - mathematically equivalent FFT implementations - Handles batch processing and device/dtype preservation - Removes dependency since we already require librosa - ~0.1-0.2s slower per audio (CPU instead of GPU STFT) but acceptable trade-off
97 lines
3.9 KiB
Plaintext
97 lines
3.9 KiB
Plaintext
# TTS Audio Suite - Universal TTS for ComfyUI
|
|
# Comprehensive multi-engine TTS with Python 3.13 compatibility
|
|
|
|
# --- INSTALLATION METHOD ---
|
|
# This custom node uses install.py for intelligent dependency management.
|
|
# ComfyUI Manager automatically runs install.py which handles:
|
|
# - Python 3.13 compatibility issues (MediaPipe → OpenSeeFace fallback)
|
|
# - NumPy version conflicts (constraints to avoid Numba issues)
|
|
# - Package dependency conflicts (selective --no-deps installation)
|
|
# - All bundled engines: ChatterBox, F5-TTS, Higgs Audio
|
|
# - Optional features: RVC voice conversion, mouth movement analysis
|
|
|
|
# --- CORE SAFE PACKAGES ---
|
|
# These packages rarely cause conflicts and install normally
|
|
|
|
# Foundation ML packages
|
|
torch>=2.0.0
|
|
torchaudio>=2.0.0
|
|
numpy>=1.26.4,<2.3.0 # Compatible with both numpy 1.26.4 and 2.x series
|
|
|
|
# Audio processing (safe)
|
|
soundfile>=0.12.0
|
|
sounddevice>=0.4.0
|
|
|
|
# Text processing (safe)
|
|
jieba
|
|
pypinyin
|
|
unidecode
|
|
phonemizer # IPA phonemization for multilingual TTS (requires espeak system dependency)
|
|
omegaconf>=2.3.0
|
|
transformers>=4.51.3 # Required for VibeVoice compatibility (VibeVoice requires 4.51.3+), also supports Higgs Audio
|
|
|
|
# ML utilities (safe)
|
|
accelerate
|
|
datasets
|
|
requests
|
|
dacite
|
|
bitsandbytes>=0.47.0 # 4-bit quantization support for VibeVoice memory efficiency
|
|
|
|
# Bundled engine dependencies (safe)
|
|
conformer>=0.3.2 # ChatterBox engine
|
|
x-transformers
|
|
torchdiffeq # F5-TTS differential equations
|
|
wandb # F5-TTS logging
|
|
ema-pytorch # F5-TTS exponential moving average
|
|
vocos # F5-TTS vocoder
|
|
|
|
# Audio restoration
|
|
# VoiceFixer is bundled in utils/voicefixer_bundled/
|
|
# Uses librosa (already required) for STFT/ISTFT instead of torchlibrosa - reduces dependencies
|
|
|
|
# IndexTTS-2 engine dependencies (safe)
|
|
cn2an>=0.5.22 # Chinese number to Arabic number conversion
|
|
g2p-en>=2.1.0 # English grapheme-to-phoneme conversion
|
|
keras>=2.9.0 # Deep learning framework
|
|
modelscope>=1.27.0 # Chinese model hub for IndexTTS-2
|
|
munch>=4.0.0 # Dictionary access with dot notation
|
|
json5>=0.12.0 # JSON5 parsing for IndexTTS-2 config files
|
|
ninja>=1.11.0 # Build tool for CUDA kernel compilation (BigVGAN optimization)
|
|
sentencepiece>=0.2.1 # Text tokenization
|
|
textstat>=0.7.10 # Text statistics and readability
|
|
|
|
# RVC voice conversion (safe)
|
|
monotonic-alignment-search
|
|
faiss-cpu>=1.7.4
|
|
praat-parselmouth>=0.4.6 # Praat-based f0 extraction for RVC (pm method)
|
|
pyworld>=0.3.5 # World vocoder for RVC harvest/dio methods
|
|
torchfcpe>=0.0.4 # Fast Context-based Pitch Estimation for RVC (fcpe method)
|
|
|
|
# Optional performance enhancements
|
|
# sageattention # Optional: GPU-optimized mixed-precision attention for VibeVoice (requires CUDA SM80+)
|
|
|
|
# Computer vision (safe)
|
|
pillow
|
|
|
|
# --- PROBLEMATIC PACKAGES ---
|
|
# These are installed by install.py with special handling:
|
|
# - librosa (--no-deps): Forces numpy downgrade
|
|
# - descript-audio-codec (--no-deps): Conflicts with protobuf
|
|
# - cached-path (--no-deps): Forces package downgrades
|
|
# - torchcrepe (--no-deps): Conflicts via librosa dependency
|
|
# - onnxruntime (--no-deps): Forces numpy 2.3.x, needed for OpenSeeFace
|
|
# - opencv-python (--no-deps): Forces numpy downgrade
|
|
|
|
# --- PYTHON 3.13 NOTES ---
|
|
# ✅ All TTS engines work (ChatterBox, F5-TTS, Higgs Audio)
|
|
# ✅ RVC voice conversion works
|
|
# ✅ OpenSeeFace mouth movement (experimental alternative)
|
|
# ❌ MediaPipe incompatible (binary compatibility issue)
|
|
|
|
# --- BUNDLED ENGINES ---
|
|
# All engines are bundled to avoid external dependency conflicts:
|
|
# - ChatterBox: engines/chatterbox/ (modified for ComfyUI)
|
|
# - F5-TTS: engines/f5_tts/ (numpy 2.x compatible fork)
|
|
# - Higgs Audio: engines/higgs_audio/ (transformers 4.46+ compatible)
|
|
# - IndexTTS-2: engines/index_tts/ (emotion disentanglement TTS)
|