try to fix ci oserror (#5024)

This commit is contained in:
Xiaoyu Zhang
2025-04-03 17:45:05 +08:00
committed by GitHub
parent 9d0b36c47a
commit 772d2a191d

View File

@@ -8,19 +8,26 @@ FLASHINFER_REPO="${FLASHINFER_REPO:-https://flashinfer.ai/whl/cu124/torch2.5/fla
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
bash "${SCRIPT_DIR}/killall_sglang.sh" bash "${SCRIPT_DIR}/killall_sglang.sh"
pip install --upgrade pip # Clean up existing installations
pip uninstall flashinfer -y pip uninstall -y flashinfer flashinfer_python sgl-kernel sglang vllm || true
pip install -e "python[all]" --find-links https://flashinfer.ai/whl/cu124/torch2.5/flashinfer-python pip cache purge
rm -rf /root/.cache/flashinfer rm -rf /root/.cache/flashinfer
# Force reinstall flashinfer and torch_memory_saver rm -rf /usr/local/lib/python3.10/dist-packages/flashinfer*
pip install flashinfer_python==0.2.3 --find-links ${FLASHINFER_REPO} --force-reinstall --no-deps rm -rf /usr/local/lib/python3.10/dist-packages/sgl_kernel*
pip install sgl-kernel==0.0.6 --force-reinstall
# Update pip
pip install --upgrade pip
# Install flashinfer and sgl-kernel
pip install flashinfer_python==0.2.3 --find-links ${FLASHINFER_REPO} --no-cache-dir
pip install sgl-kernel==0.0.6 --no-cache-dir
# Install the main package
pip install -e "python[all]" --find-links ${FLASHINFER_REPO}
# Install additional dependencies
pip install torch_memory_saver pip install torch_memory_saver
pip install transformers==4.50.0 sentence_transformers accelerate==1.4.0 peft pandas datasets timm torchaudio pip install transformers==4.50.0 sentence_transformers accelerate==1.4.0 peft pandas datasets timm torchaudio
# For compling xgrammar kernels # For compling xgrammar kernels
pip install cuda-python nvidia-cuda-nvrtc-cu12 pip install cuda-python nvidia-cuda-nvrtc-cu12
pip uninstall vllm -y || true