mirror of
https://github.com/RVC-Boss/GPT-SoVITS.git
synced 2026-06-03 20:40:30 +08:00
Update Flash Attn Installation
This commit is contained in:
parent
d5ed91deb5
commit
319a09fa2d
@ -59,17 +59,17 @@ source "$HOME/.bashrc"
|
|||||||
|
|
||||||
"$HOME/conda/bin/conda" install gcc=11 gxx ffmpeg uv cmake make unzip $SYSROOT_PKG "libstdcxx-ng>=11" -y
|
"$HOME/conda/bin/conda" install gcc=11 gxx ffmpeg uv cmake make unzip $SYSROOT_PKG "libstdcxx-ng>=11" -y
|
||||||
|
|
||||||
|
cd workspace
|
||||||
|
|
||||||
if [ "$CUDA_VERSION" = "12.8" ]; then
|
if [ "$CUDA_VERSION" = "12.8" ]; then
|
||||||
"$HOME/conda/bin/uv" pip install ".[cu128]" --no-cache-dir --python "$(which python)"
|
"$HOME/conda/bin/uv" pip install ".[cu128]" --no-cache-dir --python "$HOME/conda/bin/python"
|
||||||
"$HOME/conda/bin/conda" install cuda-nvcc=12.8 -y
|
|
||||||
elif [ "$CUDA_VERSION" = "12.6" ]; then
|
elif [ "$CUDA_VERSION" = "12.6" ]; then
|
||||||
"$HOME/conda/bin/uv" pip install ".[cu126]" --no-cache-dir --python "$(which python)"
|
"$HOME/conda/bin/uv" pip install ".[cu126]" --no-cache-dir --python "$HOME/conda/bin/python"
|
||||||
"$HOME/conda/bin/conda" install cuda-nvcc=12.6 -y
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
export PATH="$HOME/conda/bin:$PATH"
|
export PATH="$HOME/conda/bin:$PATH"
|
||||||
|
|
||||||
"$HOME/conda/bin/uv" pip install ".[flash-attn]" --python "$(which python)"
|
"$HOME/conda/bin/uv" pip install ".[flash-attn]" --python "$HOME/conda/bin/python"
|
||||||
"$HOME/conda/bin/uv" cache clean
|
"$HOME/conda/bin/uv" cache clean
|
||||||
|
|
||||||
rm $LOG_PATH
|
rm $LOG_PATH
|
||||||
|
|||||||
@ -331,7 +331,6 @@ switch ($Device) {
|
|||||||
}
|
}
|
||||||
Write-Info "Installing PyTorch For CUDA 12.8..."
|
Write-Info "Installing PyTorch For CUDA 12.8..."
|
||||||
Invoke-PIP ".[cu128]"
|
Invoke-PIP ".[cu128]"
|
||||||
Invoke-Conda cuda-nvcc=12.8
|
|
||||||
Write-Info "Installing Flash Attn..."
|
Write-Info "Installing Flash Attn..."
|
||||||
Invoke-PIP ".[flash-attn]"
|
Invoke-PIP ".[flash-attn]"
|
||||||
Write-Success "Flash Attn Installed"
|
Write-Success "Flash Attn Installed"
|
||||||
@ -346,7 +345,6 @@ switch ($Device) {
|
|||||||
}
|
}
|
||||||
Write-Info "Installing PyTorch For CUDA 12.6..."
|
Write-Info "Installing PyTorch For CUDA 12.6..."
|
||||||
Invoke-PIP ".[cu126]"
|
Invoke-PIP ".[cu126]"
|
||||||
Invoke-Conda cuda-nvcc=12.6
|
|
||||||
Write-Info "Installing Flash Attn..."
|
Write-Info "Installing Flash Attn..."
|
||||||
Invoke-PIP ".[flash-attn]"
|
Invoke-PIP ".[flash-attn]"
|
||||||
Write-Success "Flash Attn Installed"
|
Write-Success "Flash Attn Installed"
|
||||||
|
|||||||
@ -392,14 +392,12 @@ if [ "$USE_CUDA" = true ] && [ "$WORKFLOW" = false ]; then
|
|||||||
fi
|
fi
|
||||||
echo -e "${INFO}Installing PyTorch For CUDA 12.8..."
|
echo -e "${INFO}Installing PyTorch For CUDA 12.8..."
|
||||||
run_pip_quiet ".[cu128]"
|
run_pip_quiet ".[cu128]"
|
||||||
run_conda_quiet cuda-nvcc=12.8
|
|
||||||
elif [ "$CUDA" = 126 ]; then
|
elif [ "$CUDA" = 126 ]; then
|
||||||
if awk "BEGIN {exit !($CUDAVERSION < 12.0)}"; then
|
if awk "BEGIN {exit !($CUDAVERSION < 12.0)}"; then
|
||||||
echo -e "${WARNING}CUDA 12.6 Is Not Supported By Current Driver"
|
echo -e "${WARNING}CUDA 12.6 Is Not Supported By Current Driver"
|
||||||
fi
|
fi
|
||||||
echo -e "${INFO}Installing PyTorch For CUDA 12.6..."
|
echo -e "${INFO}Installing PyTorch For CUDA 12.6..."
|
||||||
run_pip_quiet ".[cu126]"
|
run_pip_quiet ".[cu126]"
|
||||||
run_conda_quiet cuda-nvcc=12.6
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo -e "${INFO}Installing Flash Attn"
|
echo -e "${INFO}Installing Flash Attn"
|
||||||
|
|||||||
@ -75,6 +75,12 @@ dependency-metadata = [
|
|||||||
{ name = "faster-whisper", requires-dist = [], requires-python = ">=3.10" },
|
{ name = "faster-whisper", requires-dist = [], requires-python = ">=3.10" },
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[tool.uv.extra-build-dependencies]
|
||||||
|
flash-attn = [{ requirement = "torch", match-runtime = true }]
|
||||||
|
|
||||||
|
[tool.uv.extra-build-variables]
|
||||||
|
flash-attn = { FLASH_ATTENTION_SKIP_CUDA_BUILD = "TRUE" }
|
||||||
|
|
||||||
[tool.uv.pip]
|
[tool.uv.pip]
|
||||||
no-binary = ["opencc"]
|
no-binary = ["opencc"]
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user