threeML / hawc_hal

HAWC Accelerated Likelihood - python-only framework for HAWC data analysis
BSD 3-Clause "New" or "Revised" License
11 stars 21 forks source link

Numpy no longer includes warnings module as attribute as of numpy v1.24.3 #89

Closed torresramiro350 closed 1 year ago

torresramiro350 commented 1 year ago

Numpy no longer has the attribute warnings and causes some of the tests to fail. This is because of the call to numpy.warnings.catch_warnings() from hawc_hal/healpix_handling/gnomonic_projection.py. The issue can be fixed by simply importing warnings as most of the desired functionality comes from that module.

Aside from fixing the issue mentioned above, there are some minor differences, such as the formatting of the code and removing a few unused module imports.