LM/vLLM: Difference between revisions
< LM
Jump to navigation
Jump to search
| (9 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
== | == compose (Works!) == | ||
<syntaxhighlight lang="yaml"> | |||
services: | |||
vllm-xpu: | |||
image: vllm/vllm-openai-xpu:latest | |||
container_name: vllm-xpu-qwen38 | |||
privileged: true | |||
network_mode: host | |||
shm_size: "32g" | |||
devices: | |||
- /dev/dri:/dev/dri | |||
volumes: | |||
- ${HOME}/.cache/huggingface:/root/.cache/huggingface | |||
environment: | |||
- HF_HOME=/root/.cache/huggingface | |||
- HF_TOKEN=${HF_TOKEN:-} | |||
- no_proxy=localhost,127.0.0.1 | |||
- ZE_FLAT_DEVICE_HIERARCHY=COMPOSITE | |||
- ZE_AFFINITY_MASK=0 | |||
- VLLM_WORKER_MULTIPROC_METHOD=spawn | |||
- PYTORCH_ALLOC_CONF=expandable_segments:True | |||
- VLLM_XPU_ENABLE_XPU_GRAPH=1 | |||
ports: | |||
- "9000:9000" | |||
entrypoint: ["vllm", "serve"] | |||
command: | |||
- "SergiioB/Qwen3.8-27B-GPTQ-Int4-sym-G128-MTP-BF16" | |||
- "--served-model-name=qwen38" | |||
- "--port=9000" | |||
- "--host=0.0.0.0" | |||
- "--quantization=gptq" | |||
- "--dtype=float16" | |||
- "--max-model-len=131072" | |||
- "--gpu-memory-utilization=0.88" | |||
- "--kv-cache-dtype=fp8" | |||
- "--max-num-seqs=1" | |||
- "--max-num-batched-tokens=8192" | |||
- "--trust-remote-code" | |||
- "--enable-auto-tool-choice" | |||
- "--tool-call-parser=qwen3_xml" | |||
- "--reasoning-parser=qwen3" | |||
- "--limit-mm-per-prompt={\"image\":10}" | |||
- "--speculative-config={\"method\":\"mtp\",\"num_speculative_tokens\":4}" | |||
restart: no | |||
</syntaxhighlight> | |||
<syntaxhighlight lang="bash"> | |||
sudo usermod -aG docker $USER | |||
docker compose up | |||
</syntaxhighlight> | |||
== docker.io == | |||
<syntaxhighlight lang="bash"> | |||
sudo apt install docker.io | |||
sudo docker pull intel/vllm | |||
docker run -t -d --shm-size 10g --net=host --ipc=host --privileged \ | |||
-v /dev/dri/by-path:/dev/dri/by-path --name=vllm-test \ | |||
--device /dev/dri:/dev/dri --entrypoint=/bin/bash intel/vllm:latest | |||
</syntaxhighlight> | |||
== source == | |||
<syntaxhighlight lang="bash"> | <syntaxhighlight lang="bash"> | ||
| Line 39: | Line 108: | ||
== TODO == | == TODO == | ||
* https://hub.docker.com/r/intel/vllm | |||
* https://hub.docker.com/u/intel/?page=1&search=vllm | |||
* https://docs.vllm.ai/en/stable/getting_started/installation/gpu/#requirements | * https://docs.vllm.ai/en/stable/getting_started/installation/gpu/#requirements | ||
* https://www.pugetsystems.com/labs/articles/intel-arc-pro-b70-multi-gpu-ai-inference-performance/ | |||
* https://github.com/Hal9000AIML/arc-pro-b70-inference-setup-ubuntu-server | |||
* https://sergiiob.dev/posts/intel-arc-b70-vllm-initial-mxfp4-test/ | |||
* https://forum.level1techs.com/t/intel-b70-launch-unboxed-and-tested/247873 | |||
* https://huggingface.co/blog/MatrixYao/intel-gpu | |||
Latest revision as of 10:51, 31 August 2026
compose (Works!)
services:
vllm-xpu:
image: vllm/vllm-openai-xpu:latest
container_name: vllm-xpu-qwen38
privileged: true
network_mode: host
shm_size: "32g"
devices:
- /dev/dri:/dev/dri
volumes:
- ${HOME}/.cache/huggingface:/root/.cache/huggingface
environment:
- HF_HOME=/root/.cache/huggingface
- HF_TOKEN=${HF_TOKEN:-}
- no_proxy=localhost,127.0.0.1
- ZE_FLAT_DEVICE_HIERARCHY=COMPOSITE
- ZE_AFFINITY_MASK=0
- VLLM_WORKER_MULTIPROC_METHOD=spawn
- PYTORCH_ALLOC_CONF=expandable_segments:True
- VLLM_XPU_ENABLE_XPU_GRAPH=1
ports:
- "9000:9000"
entrypoint: ["vllm", "serve"]
command:
- "SergiioB/Qwen3.8-27B-GPTQ-Int4-sym-G128-MTP-BF16"
- "--served-model-name=qwen38"
- "--port=9000"
- "--host=0.0.0.0"
- "--quantization=gptq"
- "--dtype=float16"
- "--max-model-len=131072"
- "--gpu-memory-utilization=0.88"
- "--kv-cache-dtype=fp8"
- "--max-num-seqs=1"
- "--max-num-batched-tokens=8192"
- "--trust-remote-code"
- "--enable-auto-tool-choice"
- "--tool-call-parser=qwen3_xml"
- "--reasoning-parser=qwen3"
- "--limit-mm-per-prompt={\"image\":10}"
- "--speculative-config={\"method\":\"mtp\",\"num_speculative_tokens\":4}"
restart: no
sudo usermod -aG docker $USER
docker compose up
docker.io
sudo apt install docker.io
sudo docker pull intel/vllm
docker run -t -d --shm-size 10g --net=host --ipc=host --privileged \
-v /dev/dri/by-path:/dev/dri/by-path --name=vllm-test \
--device /dev/dri:/dev/dri --entrypoint=/bin/bash intel/vllm:latest
source
uv venv --python 3.12 --seed --managed-python
source .venv/bin/activate
git clone https://github.com/vllm-project/vllm.git
cd vllm
pip install --upgrade pip
pip install -v -r requirements/xpu.txt
pip uninstall -y triton triton-xpu
pip install triton-xpu==3.7.2 --extra-index-url https://download.pytorch.org/whl/xpu
VLLM_TARGET_DEVICE=xpu pip install --no-build-isolation -e . -v
# check device
python -c "import torch; print(torch.xpu.is_available()); print(torch.xpu.device_count())"
# download model
hf download ciocan/gemma-4-E4B-it-W4A16
# Run
vllm serve unsloth/gemma-4-E4B-it-qat-GGUF --device xpu
Path
TODO
- https://hub.docker.com/r/intel/vllm
- https://hub.docker.com/u/intel/?page=1&search=vllm
- https://docs.vllm.ai/en/stable/getting_started/installation/gpu/#requirements
- https://www.pugetsystems.com/labs/articles/intel-arc-pro-b70-multi-gpu-ai-inference-performance/
- https://github.com/Hal9000AIML/arc-pro-b70-inference-setup-ubuntu-server
- https://sergiiob.dev/posts/intel-arc-b70-vllm-initial-mxfp4-test/
- https://forum.level1techs.com/t/intel-b70-launch-unboxed-and-tested/247873
- https://huggingface.co/blog/MatrixYao/intel-gpu