Skip to content

Commit 9f8b50a

Browse files
richardsliuMu Huai
authored andcommitted
[CI] Add TPU v1 test (vllm-project#14834)
Signed-off-by: Richard Liu <[email protected]> Signed-off-by: Mu Huai <[email protected]>
1 parent db478c9 commit 9f8b50a

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

.buildkite/run-tpu-v1-test.sh

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
#!/bin/bash
2+
3+
set -e
4+
5+
# Build the docker image.
6+
docker build -f Dockerfile.tpu -t vllm-tpu .
7+
8+
# Set up cleanup.
9+
remove_docker_container() { docker rm -f tpu-test || true; }
10+
trap remove_docker_container EXIT
11+
# Remove the container that might not be cleaned up in the previous run.
12+
remove_docker_container
13+
14+
# For HF_TOKEN.
15+
source /etc/environment
16+
# Run a simple end-to-end example.
17+
docker run --privileged --net host --shm-size=16G -it \
18+
-e "HF_TOKEN=$HF_TOKEN" -e "VLLM_USE_V1=1" --name tpu-test \
19+
vllm-tpu /bin/bash -c "python3 -m pip install git+https://github.com/thuml/depyf.git \
20+
&& python3 -m pip install pytest \
21+
&& python3 -m pip install lm_eval[api]==0.4.4 \
22+
&& pytest -v -s /workspace/vllm/tests/tpu/test_custom_dispatcher.py \
23+
&& pytest -v -s /workspace/vllm/tests/v1/tpu/test_basic.py \
24+
&& pytest -v -s /workspace/vllm/tests/entrypoints/llm/test_accuracy.py::test_lm_eval_accuracy_v1_engine \
25+
&& python3 /workspace/vllm/tests/tpu/test_compilation.py \
26+
&& python3 /workspace/vllm/tests/tpu/test_quantization_accuracy.py \
27+
&& python3 /workspace/vllm/examples/offline_inference/tpu.py"

0 commit comments

Comments
 (0)