mirror of
https://github.com/huggingface/text-generation-inference.git
synced 2025-09-12 12:54:52 +00:00
Fix the condition.
This commit is contained in:
parent
188ceb2fef
commit
986071197b
@ -118,8 +118,7 @@ class ResponseComparator(JSONSnapshotExtension):
|
|||||||
and token.text == other.text
|
and token.text == other.text
|
||||||
and (
|
and (
|
||||||
self.ignore_logprob
|
self.ignore_logprob
|
||||||
or token.logprob == other.logprob
|
or (token.logprob == other.logprob and token.logprob is None)
|
||||||
and token.logprob is None
|
|
||||||
or math.isclose(token.logprob, other.logprob, rel_tol=self.rtol)
|
or math.isclose(token.logprob, other.logprob, rel_tol=self.rtol)
|
||||||
)
|
)
|
||||||
and token.special == other.special
|
and token.special == other.special
|
||||||
|
Loading…
Reference in New Issue
Block a user