[Perf][VoxCPM2][Ming-Flash-Omni] Use global CUDA graph pool (#3361)

Signed-off-by: Nick Cao <ncao@redhat.com>
This commit is contained in:
Nick Cao authored and GitHub committed 2026-05-20 05:01:42 +00:00
1 parent 12bcc32c3d
commit 06ab723afc
2 files changed
+4 -9

No files matched your search

@@ -30,6 +30,7 @@ import torch.nn as nn
import torch.nn.functional as F
from transformers import PreTrainedTokenizerBase, Qwen2Config, Qwen2Model, StaticCache
from vllm.logger import init_logger
from vllm.platforms import current_platform
from x_transformers.x_transformers import RotaryEmbedding, apply_rotary_pos_emb
from vllm_omni.model_executor.layers.timestep_embedding import DiTTimestepEmbedding
@@ -479,7 +480,7 @@ class CFMGraphExecutor:
self.sde_rnd_placeholder = torch.empty_like(sde_rnd)
self.graph = torch.cuda.CUDAGraph()
with torch.cuda.graph(self.graph):
with torch.cuda.graph(self.graph, pool=current_platform.get_global_graph_pool()):
self.gen_lat_placeholder = self.cfm.sample(
self.last_hidden_state_placeholder,
self.his_lat_placeholder,