2023-12-05 07:15:37 +00:00
|
|
|
#!/bin/bash
|
2024-02-14 20:44:12 +00:00
|
|
|
set -e
|
2023-12-05 07:15:37 +00:00
|
|
|
##
|
|
|
|
## A bash script installs the required dependencies of VALL-E-X and prepares the environment
|
2024-02-14 20:44:12 +00:00
|
|
|
export SHA=c0ddebaaaf8ffd1b3529c2bb654e650bce2f790f
|
2023-12-05 07:15:37 +00:00
|
|
|
|
2024-03-07 13:37:45 +00:00
|
|
|
if [ "$BUILD_TYPE" != "cublas" ]; then
|
|
|
|
echo "[exllamav2] Attention!!! Nvidia GPU is required - skipping installation"
|
|
|
|
exit 0
|
|
|
|
fi
|
|
|
|
|
|
|
|
export PATH=$PATH:/opt/conda/bin
|
2024-01-06 12:32:28 +00:00
|
|
|
source activate transformers
|
2023-12-05 07:15:37 +00:00
|
|
|
|
|
|
|
echo $CONDA_PREFIX
|
|
|
|
|
2024-02-14 20:44:12 +00:00
|
|
|
git clone https://github.com/turboderp/exllamav2 $CONDA_PREFIX/exllamav2
|
|
|
|
|
|
|
|
pushd $CONDA_PREFIX/exllamav2
|
|
|
|
|
|
|
|
git checkout -b build $SHA
|
|
|
|
|
|
|
|
# TODO: this needs to be pinned within the conda environments
|
|
|
|
pip install -r requirements.txt
|
|
|
|
|
|
|
|
popd
|
2023-12-05 07:15:37 +00:00
|
|
|
|
2024-01-07 23:37:02 +00:00
|
|
|
cp -rfv $CONDA_PREFIX/exllamav2/* ./
|
|
|
|
|
|
|
|
if [ "$PIP_CACHE_PURGE" = true ] ; then
|
|
|
|
pip cache purge
|
|
|
|
fi
|