scikit-hep / pyhf

pure-Python HistFactory implementation with tensors and autodiff
https://pyhf.readthedocs.io/
Apache License 2.0
283 stars 83 forks source link

fix(backport): Access jax.config from jax #2423

Closed matthewfeickert closed 9 months ago

matthewfeickert commented 9 months ago

Description

Backport PR https://github.com/scikit-hep/pyhf/pull/2376

Checklist Before Requesting Reviewer

Before Merging

For the PR Assignees:

* Backport PR https://github.com/scikit-hep/pyhf/pull/2376
* As of jax and jaxlib v0.4.20 accessing jax.config from the jax.config
  submodule is deprecated and it should be accessed from the jax top
  level API instead.

   ```
   >>> from jax.config import config
   <stdin>:1: DeprecationWarning: Accessing jax.config via the jax.config submodule is deprecated
   ```
codecov[bot] commented 9 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

:exclamation: No coverage uploaded for pull request base (release/v0.7.x@51e55f7). Click here to learn what that means.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## release/v0.7.x #2423 +/- ## ================================================= Coverage ? 98.21% ================================================= Files ? 69 Lines ? 4543 Branches ? 803 ================================================= Hits ? 4462 Misses ? 47 Partials ? 34 ``` | [Flag](https://app.codecov.io/gh/scikit-hep/pyhf/pull/2423/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=scikit-hep) | Coverage Δ | | |---|---|---| | [contrib](https://app.codecov.io/gh/scikit-hep/pyhf/pull/2423/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=scikit-hep) | `27.53% <0.00%> (?)` | | | [doctest](https://app.codecov.io/gh/scikit-hep/pyhf/pull/2423/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=scikit-hep) | `60.99% <0.00%> (?)` | | | [unittests-3.10](https://app.codecov.io/gh/scikit-hep/pyhf/pull/2423/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=scikit-hep) | `96.25% <0.00%> (?)` | | | [unittests-3.11](https://app.codecov.io/gh/scikit-hep/pyhf/pull/2423/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=scikit-hep) | `96.25% <0.00%> (?)` | | | [unittests-3.7](https://app.codecov.io/gh/scikit-hep/pyhf/pull/2423/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=scikit-hep) | `96.23% <0.00%> (?)` | | | [unittests-3.8](https://app.codecov.io/gh/scikit-hep/pyhf/pull/2423/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=scikit-hep) | `96.27% <0.00%> (?)` | | | [unittests-3.9](https://app.codecov.io/gh/scikit-hep/pyhf/pull/2423/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=scikit-hep) | `96.30% <0.00%> (?)` | | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=scikit-hep#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.