Skip to content
This repository was archived by the owner on Oct 11, 2024. It is now read-only.

Commit

Permalink
Fix default length_penalty to 1.0 (vllm-project#2667)
Browse files Browse the repository at this point in the history
  • Loading branch information
zspo authored and alexm-redhat committed Feb 13, 2024
1 parent 4115939 commit 2e50fb5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vllm/sequence.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ def get_cumulative_logprob(self) -> float:
return self.data.cumulative_logprob

def get_beam_search_score(self,
length_penalty: float = 0.0,
length_penalty: float = 1.0,
seq_len: Optional[int] = None,
eos_token_id: Optional[int] = None) -> float:
"""Calculate the beam search score with length penalty.
Expand Down

0 comments on commit 2e50fb5

Please sign in to comment.