"tests/vscode:/vscode.git/clone" did not exist on "6bb2bc71e299c2f0d9ecb1fcebe54aa64e658307"
Unverified Commit 8db957ee authored by jianzheng's avatar jianzheng Committed by GitHub
Browse files

[bugfix] fixed parameter “n” when set parameter “bestof” > 1 (#10854)


Signed-off-by: default avatarjianzheng <57654625+o2363286@users.noreply.github.com>
parent c9ca4fce
......@@ -293,8 +293,9 @@ class SamplingParams(
raise ValueError(
f"best_of must be greater than or equal to n, "
f"got n={self.n} and best_of={self.best_of}.")
self._real_n = self.n
self.n = self.best_of
if not self._real_n:
self._real_n = self.n
self.n = self.best_of
if 0 < self.temperature < _MAX_TEMP:
logger.warning(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment