burn icon indicating copy to clipboard operation
burn copied to clipboard

Precision errors running tests

Open McArthur-Alford opened this issue 1 year ago • 2 comments

Describe the bug When running the tests, I run into some precision errors. I have ran them a handful of times, and they seem to consistently be the following two tests:

tests::jit::module_nearest_interpolate::tests::test_downsample_interpolation
tests::jit_fusion::module_nearest_interpolate::tests::test_downsample_interpolation

The full log is:

failures:

---- tests::jit::module_nearest_interpolate::tests::test_downsample_interpolation stdout ----
thread 'tests::jit::module_nearest_interpolate::tests::test_downsample_interpolation' panicked at crates/burn-wgpu/src/lib.rs:73:5:
Tensors are not approx eq:
  => Position 3: 7 != 6 | difference 1 > tolerance 0.0010000000000000002
  => Position 9: 161 != 160 | difference 1 > tolerance 0.0010000000000000002
  => Position 15: 315 != 314 | difference 1 > tolerance 0.0010000000000000002
  => Position 21: 469 != 468 | difference 1 > tolerance 0.0010000000000000002

---- tests::jit_fusion::module_nearest_interpolate::tests::test_downsample_interpolation stdout ----
thread 'tests::jit_fusion::module_nearest_interpolate::tests::test_downsample_interpolation' panicked at crates/burn-wgpu/src/lib.rs:73:5:
Tensors are not approx eq:
  => Position 3: 7 != 6 | difference 1 > tolerance 0.0010000000000000002
  => Position 9: 161 != 160 | difference 1 > tolerance 0.0010000000000000002
  => Position 15: 315 != 314 | difference 1 > tolerance 0.0010000000000000002
  => Position 21: 469 != 468 | difference 1 > tolerance 0.0010000000000000002

To Reproduce

  1. Clone the latest version of main
  2. Use run-checks.sh and wait for the errors

Hardware:

  • OS: Linux (NixOS 24.04 with kernel 6.7.6)
  • GPU: AMD ATI Radeon RX 6900 XT
  • CPU: Intel i9-12900k

McArthur-Alford avatar Mar 15 '24 14:03 McArthur-Alford

As I noted in #1444 I ignored these tests too on my local run. Hardware:

Arch Linux, kernel on 6.7.9 Intel i7-13700K AMD Radeon RX 5700 XT

WorldSEnder avatar Mar 15 '24 15:03 WorldSEnder

@nathanielsimard since you guys are working on this

antimora avatar Mar 15 '24 20:03 antimora