vllm.models.deepseek_v41.nvidia.decoder_replay_cudagraph
¶
CUDA graphs of the decoder replay layers on a step's replay batch.
Classes:
-
DecoderReplayCudaGraphManager–Breakable PIECEWISE graphs of the replay layers keyed by the replay batch's
DecoderReplayCudaGraphManager
¶
Bases: CudaGraphManager
Breakable PIECEWISE graphs of the replay layers keyed by the replay batch's padded size. They read the layer inputs from static buffers.
Methods:
-
capture_replay_graphs–Capture each size on the replay batch
preparesets on the layers. -
run–Replay the forward context's graph on
rowsofinputs.
Source code in vllm/models/deepseek_v41/nvidia/decoder_replay_cudagraph.py
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 | |
capture_replay_graphs(prepare, stream=None)
¶
Capture each size on the replay batch prepare sets on the layers.
On the model graphs' stream they share its free blocks of the graph
pool: a replay graph runs in a model graph's eager break, after it has
gathered its inputs into input_buffers and before the model graph
reads its outputs from the break's own buffers, so no model graph
tensor in the pool is live while it runs. Aux hidden states captured
before the replay layers would be, so with those it keeps its own.
Source code in vllm/models/deepseek_v41/nvidia/decoder_replay_cudagraph.py
run(rows, inputs)
¶
Replay the forward context's graph on rows of inputs.