Skip to content

Commit f919d4c

Browse files
authored
[BugFix] Fix logits repetition penalty cuda check (#22592)
1 parent afa5b7c commit f919d4c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

vllm/_custom_ops.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,7 @@ def apply_repetition_penalties(logits: torch.Tensor, prompt_mask: torch.Tensor,
311311
output_mask: A boolean tensor indicating which tokens appear in the output.
312312
repetition_penalties: The repetition penalties of shape (num_seqs, ).
313313
"""
314-
if current_platform.is_cuda() and logits.is_contiguous():
314+
if logits.is_cuda and logits.is_contiguous():
315315
apply_repetition_penalties_cuda(logits, prompt_mask, output_mask,
316316
repetition_penalties)
317317
else:

0 commit comments

Comments
 (0)