-
Notifications
You must be signed in to change notification settings - Fork 21
Updated IGRF coefficients to 14th gen #52
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
Conversation
Ref: https://www.ncei.noaa.gov/products/international-geomagnetic-reference-field and https://www.ngdc.noaa.gov/IAGA/vmod/coeffs/igrf14coeffs.txt (cropped to keep the same number of coefficients as was previously used). Closes PRBEM#51
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for updating the IGRF coefficients @thomas-nilsson-irfu. I see that the tests failed as the output values changed slightly from the reference. Would you mind update the reference values in test_IRBEM.py? Below I've copied the failed test outputs.
Let me know if that is too much of a hassle and I can help out.
=========================== short test summary info ============================
FAILED python/IRBEM/test_IRBEM.py::TestIRBEM::test_find_magequator - AssertionError: 626.22582957[231](https://github.com/PRBEM/IRBEM/actions/runs/12013233237/job/33486280234?pr=52#step:8:232)21 != 626.2135860526192 within 7 places (0.012243519692901828 difference)
FAILED python/IRBEM/test_IRBEM.py::TestIRBEM::test_find_mirror_point - AssertionError: 42271.43059990003 != 42271.69731031445 within 7 places (0.26671041442023125 difference)
FAILED python/IRBEM/test_IRBEM.py::TestIRBEM::test_footPoint - AssertionError: 99.99412846343064 != 99.9906483758779 within 7 places (0.0034800875527452035 difference)
FAILED python/IRBEM/test_IRBEM.py::TestIRBEM::test_get_field_multi - AssertionError: np.float64(-21079.764883133903) != -21079.870874468797 within 7 places (np.float64(0.10599133489449741) difference)
FAILED python/IRBEM/test_IRBEM.py::TestIRBEM::test_get_mlt - AssertionError: 9.56999052595853 != 9.569987066693876 within 7 places (3.459264654281924e-06 difference)
FAILED python/IRBEM/test_IRBEM.py::TestIRBEM::test_lstar_array - AssertionError: 3.5597242229067536 != 3.5597506994978874 within 7 places (2.647659113375056e-05 difference)
FAILED python/IRBEM/test_IRBEM.py::TestIRBEM::test_lstar_datetime_obj - AssertionError: 3.5597242229067536 != 3.5597506994978874 within 7 places (2.647659113375056e-05 difference)
FAILED python/IRBEM/test_IRBEM.py::TestIRBEM::test_lstar_datetime_str - AssertionError: 3.5597242229067536 != 3.5597506994978874 within 7 places (2.647659113375056e-05 difference)
FAILED python/IRBEM/test_IRBEM.py::TestIRBEM::test_lstar_time_str - AssertionError: 3.5597242229067536 != 3.5597506994978874 within 7 places (2.647659113375056e-05 difference)Note the values were changed one after another as tests failed, starting with the ones described in comment on pull request 52, and as one part of the test completed the next value was out of limit and corrected. I have corrected values here until the test script ran clean, but some values (if not tested fully by the test suite) may still need some more attention. Also included here is a change of Makefile to ensure the instructions in README.install actually runs and produce some output to help the user compile the code. (i.e. the `make all.help`, `make install.help`, `make test.help`). Also added a .gitignore entry for ".venv/" (created as part of installing the IRBEM python package locally, on Linux with Python3.12, following instructions https://packaging.python.org/en/latest/guides/installing-using-pip-and-virtual-environments/#create-a-new-virtual-environment)
As described on: https://docs.github.com/en/actions/using-github-hosted-runners/using-github-hosted-runners/about-github-hosted-runners the current macos-latest is "macos-14" which, according to: https://github.com/actions/runner-images/blob/main/images/macos/macos-14-Readme.md#language-and-runtime only has gfortran-12, gfortran-13 and gfortran-14 installed by default. Added here in hope that the CI/CD test job succeeds also for MacOS. Also included is an update to my affil. & ORCID in the .zenod.json file
|
Dear @mshumko, With best regards, |
mshumko
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These changes look good. Thanks @thomas-nilsson-irfu for your work with the IGRF coefficients, fixing the OSX GitHub Action, updating the test suite, and other code updates.
Ref:
https://www.ncei.noaa.gov/products/international-geomagnetic-reference-field and https://www.ngdc.noaa.gov/IAGA/vmod/coeffs/igrf14coeffs.txt (cropped to keep the same number of coefficients as was previously used).
Closes #51
See issue #orCloses #)While I have tried to be thorough in this pull request, feel free to check and correct me (with a comment or direct edit) in case of any problems.