Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions tests/models/quantization/test_gpt_oss.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
Run: pytest tests/models/quantization/test_gpt_oss.py
"""

import importlib
import importlib.metadata
import importlib.util
from dataclasses import dataclass

import huggingface_hub
Expand Down Expand Up @@ -104,7 +104,7 @@ def test_gpt_oss_attention_quantization(
)

rtol = 0.02
assert (
measured_accuracy - rtol < expected_accuracy
and measured_accuracy + rtol > expected_accuracy
), f"Expected: {expected_accuracy} | Measured: {measured_accuracy}"
assert measured_accuracy >= expected_accuracy - rtol, (
f"Accuracy {measured_accuracy:.4f} is below threshold "
f"{expected_accuracy - rtol:.4f} (expected >= {expected_accuracy} - {rtol})"
)