[Edge][WP3] Add CPU OmniPlatform (AR + generation stages on vLLM's CPU backend)
* vllm_omni/platforms/cpu/platform.py: CPUOmniPlatform(OmniPlatform, CpuPlatform) selected when VLLM_TARGET_DEVICE=cpu or a +cpu vLLM wheel is installed (builtin plugin "cpu"; explicit CPU target short-circuits accelerator probes like vLLM does). NUMA-based memory queries, one logical device, no graph wrapper (sentinel type for isinstance checks), inductor opt-in via VLLM_OMNI_CPU_INDUCTOR=1, diffusion stages unsupported. * vllm_omni/platforms/cpu/worker: CPUARWorker / CPUGenerationWorker compose vLLM's CPUWorker with the Omni mixin (XPU pattern); CPUARModelRunner / CPUGenerationModelRunner compose the Omni runners with CPUModelRunner (no graphs, no async omni output; sleep/wake return error ACKs). * patch.py skips the CuMem patch on CPU-only torch; Qwen3-TTS speaker encoder and prompt-embeds dtype follow the model dtype (float32/float16 on CPU). * vllm_omni/deploy/qwen3_tts.yaml: `platforms: cpu:` overlay (eager, no async scheduling, absolute kv_cache_memory_bytes, disjoint OMP thread ranges). * requirements/cpu.txt (+psutil, intel-openmp), docs/getting_started/installation/cpu.md. Measured (this x86 Xeon 8480C host, vllm 0.28.0+cpu, bf16, 12+4 threads): Qwen3-TTS 0.6B CustomVoice end-to-end on CPU, 12 prompts: TTFA p50 292 ms, RTF ~1.7 (25-frame chunk ~4.6 s), init 185 s. Result JSON + init timeline committed under benchmarks/tts/edge_results/. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
1 parent
55192de984
commit
35e43b9983
18 files changed
+1740
-7
No files matched your search
@@ -136,3 +136,41 @@ platforms:
|
||||
- stage_id: 1
|
||||
compilation_config:
|
||||
cudagraph_mode: PIECEWISE
|
||||
# CPU OmniPlatform (VLLM_TARGET_DEVICE=cpu or a +cpu vLLM wheel). vLLM's
|
||||
# CpuPlatform already forces async_scheduling=False, no CUDA graphs and
|
||||
# CPU_ATTN; the values below size the two stages for a CPU box. Nested
|
||||
# layout: engine args under ``engine_args``, placement under ``runtime``.
|
||||
# gpu_memory_utilization is read by the CPU worker as a NUMA-node memory
|
||||
# fraction, so an absolute kv_cache_memory_bytes is set instead.
|
||||
# Thread ranges are per-stage (disjoint) so the two workers do not pin the
|
||||
# same cores; deploy_profile="auto" derives them from the probed topology.
|
||||
cpu:
|
||||
stages:
|
||||
- stage_id: 0
|
||||
engine_args:
|
||||
enforce_eager: true
|
||||
async_scheduling: false
|
||||
max_num_seqs: 2
|
||||
max_num_batched_tokens: 2048
|
||||
max_model_len: 2048
|
||||
gpu_memory_utilization: 0.05
|
||||
dtype: bfloat16
|
||||
kv_cache_memory_bytes: 4294967296
|
||||
runtime:
|
||||
devices: "cpu"
|
||||
env:
|
||||
VLLM_CPU_OMP_THREADS_BIND: "0-11"
|
||||
- stage_id: 1
|
||||
engine_args:
|
||||
enforce_eager: true
|
||||
async_scheduling: false
|
||||
max_num_seqs: 2
|
||||
max_num_batched_tokens: 8192
|
||||
max_model_len: 8192
|
||||
gpu_memory_utilization: 0.05
|
||||
dtype: bfloat16
|
||||
kv_cache_memory_bytes: 2147483648
|
||||
runtime:
|
||||
devices: "cpu"
|
||||
env:
|
||||
VLLM_CPU_OMP_THREADS_BIND: "12-15"
|
||||
Reference in new issue
Block a user