Files
sglang/scripts/ci_install_dependency.sh

30 lines
862 B
Bash
Raw Normal View History

#!/bin/bash
# Install the dependency in CI.
set -euxo pipefail
2024-10-30 02:49:08 -07:00
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
bash "${SCRIPT_DIR}/killall_sglang.sh"
2024-11-30 00:24:30 -08:00
2025-04-03 17:45:05 +08:00
# Clean up existing installations
pip uninstall -y flashinfer flashinfer_python sgl-kernel sglang vllm || true
pip cache purge
rm -rf /root/.cache/flashinfer
rm -rf /usr/local/lib/python3.10/dist-packages/flashinfer*
rm -rf /usr/local/lib/python3.10/dist-packages/sgl_kernel*
# Update pip
2024-10-26 04:32:36 -07:00
pip install --upgrade pip
2024-12-01 01:47:30 -08:00
# Install sgl-kernel
pip install sgl-kernel==0.0.9.post2 --no-cache-dir
2025-04-03 17:45:05 +08:00
# Install the main package
pip install -e "python[all]"
2025-04-03 17:45:05 +08:00
# Install additional dependencies
pip install torch_memory_saver
2025-04-21 07:06:34 +08:00
pip install transformers==4.51.0 sentence_transformers accelerate peft pandas datasets timm torchaudio
2024-12-01 01:47:30 -08:00
# For compling xgrammar kernels
pip install cuda-python nvidia-cuda-nvrtc-cu12