[CI/Build] Replace math.isclose with pytest.approx (#18703)
Signed-off-by: DarkLight1337 <tlleungac@connect.ust.hk>
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
import math
|
||||
import os
|
||||
|
||||
import pytest
|
||||
@@ -39,4 +38,4 @@ def test_mteb(server):
|
||||
print("SentenceTransformer main score: ", st_main_score)
|
||||
print("Difference: ", st_main_score - vllm_main_score)
|
||||
|
||||
assert math.isclose(st_main_score, vllm_main_score, rel_tol=1e-4)
|
||||
assert st_main_score == pytest.approx(vllm_main_score, rel=1e-4)
|
||||
|
||||
Reference in New Issue
Block a user