[bugfix] fix bug when top_logprobs=0 with spec decoding (#30059)

Signed-off-by: realliujiaxu <realliujiaxu@163.com>
This commit is contained in:
realliujiaxu
2025-12-12 09:03:35 -08:00
committed by GitHub
parent f3237f3f6b
commit d2c919dcc2
3 changed files with 5 additions and 3 deletions
+1 -1
View File
@@ -145,7 +145,7 @@ class RejectionSampler(nn.Module):
)
logprobs_tensors = None
if sampling_metadata.max_num_logprobs:
if sampling_metadata.max_num_logprobs is not None:
logprobs_tensors = self._get_logprobs_tensors(
sampling_metadata.max_num_logprobs,
metadata,