neos
neuralnice end-to-end optimized statistics
About
Leverages the shoulders of giants (jax and pyhf) to differentiate through a high-energy physics analysis workflow, including the construction of the frequentist profile likelihood.
If you're more of a video person, see this talk given by Nathan on the broader topic of differentiable programming in high-energy physics, which also covers neos.
Example usage -- train a neural network to optimize an expected p-value
setup
In a python 3 environment, run the following:
pip install --upgrade pip setuptools wheel
pip install neos
pip install git+http://github.com/scikit-hep/pyhf.git@make_difffable_model_ctor
With this, you should be able to run the demo notebook demo.ipynb on your pc :)
This workflow is as follows:
- From a set of normal distributions with different means, we'll generate four blobs of
(x,y)points, corresponding to a signal process, a nominal background process, and two variations of the background from varying the background distribution's mean up and down. - We'll then feed these points into the previously defined neural network for each blob, and construct a histogram of the output using kernel density estimation. The difference between the two background variations is used as a systematic uncertainty on the nominal background.
- We can then leverage the magic of
pyhfto construct an event-counting statistical model from the histogram yields. - Finally, we calculate the p-value of a test between the nominal signal and background-only hypotheses. This uses the familiar profile likelihood-based test statistic.
This counts as one forward pass of the workflow -- we then optimize the neural network by gradient descent, backpropagating through the whole analysis!
Thanks
A big thanks to the teams behind jax, fax, jaxopt and pyhf for their software and support.
Metadata
Release files for neos 0.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| neos-0.3.0.tar.gz | 3.1 MB | Without provenance | Details for neos-0.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| neos-0.3.0-py3-none-any.whl | Python 3 | none | any | Details for neos-0.3.0-py3-none-any.whl |
Total release size: 3.1 MB
Release files / neos-0.3.0.tar.gz
| Download URL | neos-0.3.0.tar.gz |
|---|---|
| Size | 3.1 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7b30c44fbd388a3c2fd0cd614e66192a65824a270aac1735033fd01dc80cdeb8
|
|
BLAKE2b-256 checksum How to use checksums |
63b2bb50a117f3d181090b29aae46205670420de4b612ad5004689df671f4d19
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.9.13
|
Release files / neos-0.3.0-py3-none-any.whl
| Download URL | neos-0.3.0-py3-none-any.whl |
|---|---|
| Size | 7.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
abd8bf07476dbdbb23d870fa5d2aa3eb3c8001815c0d10c9a06c0f2adf894818
|
|
BLAKE2b-256 checksum How to use checksums |
35f34bd54f218b8281c137c84cce152cc06da5a73b440f1e06f8774835804e75
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.9.13
|
Security for neos 0.3.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.