Skip to content

Commit c188fcb

Browse files
Merge branch 'Lightning-AI:master' into doc_update_fix20799
2 parents 0edf0d0 + fafc239 commit c188fcb

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

requirements/fabric/test.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
coverage ==7.8.0
1+
coverage ==7.8.2
22
numpy >=1.17.2, <1.27.0
33
pytest ==8.3.5
44
pytest-cov ==6.1.1

requirements/pytorch/test.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
coverage ==7.8.0
1+
coverage ==7.8.2
22
pytest ==8.3.5
33
pytest-cov ==6.1.1
44
pytest-timeout ==2.4.0

tests/tests_pytorch/models/test_torchscript.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@ def test_torchscript_input_output(modelclass):
4444
model_output = model(model.example_input_array)
4545

4646
script_output = script(model.example_input_array)
47-
assert torch.allclose(script_output, model_output)
47+
assert torch.allclose(script_output, model_output, rtol=1e-5, atol=1e-8), (
48+
f"Scripted output {script_output} does not match model output {model_output}."
49+
)
4850

4951

5052
@pytest.mark.skipif(_IS_WINDOWS and _TORCH_GREATER_EQUAL_2_4, reason="not close on Windows + PyTorch 2.4")

0 commit comments

Comments
 (0)