Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test_gaussian fails for fedora rawhide #256

Open
jdkloe opened this issue Jul 19, 2024 · 0 comments
Open

test_gaussian fails for fedora rawhide #256

jdkloe opened this issue Jul 19, 2024 · 0 comments

Comments

@jdkloe
Copy link
Contributor

jdkloe commented Jul 19, 2024

For fedora-rawhide (to be fedora-41) software versions have been updated to be:
Python version 3.13.0b3
matplotlib version 3.9.1
eccodes version 2.35.0

For these versions, all tests pass except for test_gaussian:

# pytest test_gaussian.py --mpl --mpl-baseline-path=`pwd`/baseline_images
================================== test session starts ===================================
platform linux -- Python 3.13.0b3, pytest-7.4.3, pluggy-1.3.0
Matplotlib: 3.9.1
Freetype: 2.13.2
rootdir: /builddir/build/BUILD/pygrib-2.1.6-build/pygrib-2.1.6-tmp-test/test
plugins: mpl-0.13
collected 1 item                                                                         

test_gaussian.py F                                                                 [100%]

======================================== FAILURES ========================================
_____________________________________ test_gaussian ______________________________________
Error: Image files did not match.
  RMS Value: 31.307504414099967
  Expected:  
    /tmp/tmpolc15yoq/test_gaussian.test_gaussian/baseline.png
  Actual:    
    /tmp/tmpolc15yoq/test_gaussian.test_gaussian/result.png
  Difference:
    /tmp/tmpolc15yoq/test_gaussian.test_gaussian/result-failed-diff.png
  Tolerance: 
    20
================================ short test summary info =================================
FAILED test_gaussian.py::test_gaussian - Failed: Error: Image files did not match.
=================================== 1 failed in 1.16s ====================================

From visual inspection of the generated image it is clear that the generated image has been shifted upwards by a few pixels compared to the baseline reference inside its black framing rectangle, and this framing rectangle has at the same time increased size by a few pixels. The picture itself is still identical to the baseline.

As a workaround in the mpl_image_compare decorator, the tolerance can be increased from 20 to 32. Then the test passes again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant