File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -37,19 +37,13 @@ PYTHON_VERSION="3.12" setup_uv
3737fetch_and_deploy_gh_release " libretranslate" " LibreTranslate/LibreTranslate" " tarball"
3838
3939msg_info " Setup LibreTranslate (Patience)"
40- TORCH_VERSION=$( grep -Eo ' "torch ==[0-9]+\.[0-9]+\.[0-9]+' /opt/libretranslate/pyproject.toml |
41- tail -n1 | sed ' s/.*==//' )
42- if [[ -z " $TORCH_VERSION " ]]; then
43- TORCH_VERSION=" 2.5.0"
44- fi
4540cd /opt/libretranslate
4641$STD uv venv --clear .venv --python 3.12
4742$STD source .venv/bin/activate
4843$STD uv pip install --upgrade pip
4944$STD uv pip install " setuptools<81"
5045$STD uv pip install Babel==2.12.1
5146$STD .venv/bin/python scripts/compile_locales.py
52- $STD uv pip install " torch==${TORCH_VERSION} " --extra-index-url https://download.pytorch.org/whl/cpu
5347$STD uv pip install " numpy<2"
5448$STD uv pip install .
5549$STD uv pip install libretranslate
You can’t perform that action at this time.
0 commit comments