Skip to content
Closed
Show file tree
Hide file tree
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
5 changes: 2 additions & 3 deletions .github/workflows/linux_cuda_wheel.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,9 @@ jobs:
# For the actual release we should add that label and change this to
# include more python versions.
python-version: ['3.10']
# We test against 12.6 to avoid having too big of a CI matrix,
# We test against 12.6 and 13.0 to avoid having too big of a CI matrix,
# but for releases we should add 12.8.
# TODO add 13.0!
cuda-version: ['12.6']
cuda-version: ['12.6', '13.0']
# TODO: put back ffmpeg 5 https://github.com/pytorch/torchcodec/issues/325
ffmpeg-version-for-tests: ['4.4.2', '6', '7']

Expand Down
2 changes: 1 addition & 1 deletion test/test_decoders.py
Original file line number Diff line number Diff line change
Expand Up @@ -1224,7 +1224,7 @@ def test_full_and_studio_range_bt709_video(self, asset):
cpu_frame = decoder_cpu.get_frame_at(frame_index).data

if cuda_version_used_for_building_torch() >= (12, 9):
torch.testing.assert_close(gpu_frame, cpu_frame, rtol=0, atol=2)
torch.testing.assert_close(gpu_frame, cpu_frame, rtol=0, atol=3)
elif cuda_version_used_for_building_torch() == (12, 8):
assert psnr(gpu_frame, cpu_frame) > 20

Expand Down
2 changes: 1 addition & 1 deletion test/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ def psnr(a, b, max_val=255) -> float:
def assert_frames_equal(*args, **kwargs):
if sys.platform == "linux":
if args[0].device.type == "cuda":
atol = 2
atol = 3
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should be able to preserve the previous stricter with CUDA < 13 with something like:

Suggested change
atol = 3
atol = 3 if cuda_version_used_for_building_torch() >= (13, 0) else 2

if get_ffmpeg_major_version() == 4:
assert_tensor_close_on_at_least(
args[0], args[1], percentage=95, atol=atol
Expand Down
Loading