support qwen2 running on ascend npu device (#7022)

Co-authored-by: 刁莹煜 <diaoyingyu1@hisilicon.com>
This commit is contained in:
Yijie Zhu
2025-06-18 02:24:10 +08:00
committed by GitHub
parent 10d60cd41b
commit a39d928782
9 changed files with 63 additions and 16 deletions

View File

@@ -51,6 +51,10 @@
"server_process, port = launch_server_cmd(\n",
" \"python3 -m sglang.launch_server --model-path qwen/qwen2.5-0.5b-instruct --host 0.0.0.0\"\n",
")\n",
"## To run qwen2.5-0.5b-instruct model on the Ascend-Npu, you can execute the following command:\n",
"# server_process, port = launch_server_cmd(\n",
"# \"python3 -m sglang.launch_server --model-path qwen/qwen2.5-0.5b-instruct --host 0.0.0.0 --device npu --tp 2 --attention-backend torch_native\"\n",
"# )\n",
"\n",
"wait_for_server(f\"http://localhost:{port}\")"
]