macOS 部署安装 IndexTTS2
IndexTTS2 macOS 部署安装步骤
1. 前置要求
首先确保已安装 Git 和 Git-LFS
# 安装 Homebrew(如果还没有) /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" # 安装 Git 和 Git-LFS brew install git git-lfs # 启用 Git-LFS git lfs install 2. 克隆仓库
git clone https://github.com/index-tts/index-tts.git cd index-tts git lfs pull # 下载大文件 3. 安装 uv 包管理器
# 方式一:使用 Homebrew(推荐) brew install uv 4. 安装依赖
# 如果网络较慢,可使用国内镜像 uv sync --all-extras --default-index "https://mirrors.aliyun.com/pypi/simple" # 或使用清华镜像 uv sync --all-extras --default-index "https://mirrors.tuna.tsinghua.edu.cn/pypi/web/simple" # 如果网络正常,直接运行 uv sync --all-extras 5. 下载模型
使用 ModelScope
uv tool install "modelscope" modelscope download --model IndexTeam/IndexTTS-2--local_dir checkpoints 6. 验证安装
# 检查 PyTorch GPU 加速(macOS 可能不支持 CUDA,但支持 Metal) uv run tools/gpu_check.py ➜ index-tts git:(main) uv run tools/gpu_check.py Scanning for PyTorch hardware acceleration devices... PyTorch: No devices found forNVIDIACUDA/AMD ROCm backend. PyTorch: No devices found for Intel XPU backend. PyTorch: Apple MPS is available!* Number ofMPS devices found:1 Hardware acceleration detected. Your system is ready!7. 启动 Web 界面
uv run webui.py http://127.0.0.1:7860
sudo asitop 