The PgLis model
PgLis is a model developed to forecast the flux of solar-modulated galactic cosmic-rays near Earth. This package was created to simplify and systematise the access to the flux model presented in the article Pelosi et al. (2026) New model for long-term forecasting of galactic cosmic rays, Phys. Rev. D 114, 063005, DOI:10.1103/npfk-lwy9.
We modelled the different transport parameters that cosmic rays experience as they traverse the heliosphere to arrive at Earth (article link available soon), parametrised them as functions of solar activity, using the widely available sunspot number as a proxy (see NOAA), which we delay according to Tomassetti et al. (2022) to account for transport time.
This allows us to estimate the fluxes of cosmic nuclei near Earth, from Hydrogen to Nickel, as they evolve with solar activity.
This package is a Python implementation that interpolated between the pre-computed tables available in Zenodo. It downloads the data from Zenodo and the sunspot numbers from NOAA.
Flux model for both solar magnetic polarities, for cosmic hydrogen.
Scientific background
The modulation of galactic cosmic rays, driven by the evolution of the heliospheric magnetic field, strongly influences the intensity of cosmic rays reaching near-Earth space. Characterizing this process is crucial both for advancing our understanding of cosmic ray transport and for assessing radiation exposure and related hazards in space environments.
Here we present the PgLis model, a newly developed forecasting framework built upon our previous work, designed for the long-term forecasting of galactic cosmic-ray fluxes.
The model is the result of a collaboration between the Università degli Studi di Perugia (Pg) and the Laboratório de Instrumentação e Física Experimental de Partículas in Lisbon (Lis), and is based on a numerical description of charged-particle transport in the heliosphere and its dependence on solar activity.
The PgLis model has been validated using multi-species flux measurements from space-based instruments such as PAMELA, AMS-02, and ACE. Its strategy is based upon Hilbert-Huang transform filtering and cross-correlation between delayed solar proxies and effective model parameters.
It demonstrates a demonstrably good performance across a broad multichannel and multi-species testing dataset, spanning different energy ranges and solar phases. These advancements enhance its applicability to space radiation monitoring and forecasting. Furthermore, when coupled with solar-proxy forecasting models, PgLis enables decadal-scale predictions of galactic cosmic-ray fluxes, thereby supporting long-term planning and radiation-risk assessment for future space missions.
Usage examples
More examples can be found in the tutorial.
Getting the flux for a given time
# setup model
model = pglis.solar_mod()
# defining the time - 2001/06/01
t = datetime.datetime(2001, 6, 1).timestamp()
# getting the flux as a dataframe
df = model.get_dataframe_flux_vs_energy(Z=1, time=t)
Installation
From GitHub
To install this package you can run the following commands:
# download the repository
git clone https://github.com/pglis-team/pglis.git
# install the package
python3 -m pip install .
From PyPi
python3 -m pip install pglis
Uninstalling the package
To remove the package you must first remove the data, this can be done by running a command that comes bundled with the package:
pglis-cleanup
To uninstall the package, regardless of the data, you can simply run the following command:
python3 -m pip uninstall pglis
Authors
David Pelosi1,2, Fernando Barão3,4, Bruna Bertucci1,2, Emanuele Fiandrini1,2, Miguel Orcinha2 and Nicola Tomassetti1,2
1 Università degli Studi di Perugia, Perugia 06100, Italy
2 INFN - Perugia, Perugia 06100, Italy
3 Laboratório de Instrumentação e Física Experimental de Partículas, Lisboa 1000, Portugal
4 Instituto Superior Técnico, Lisboa 1049, Portugal
Maintainers
David Pelosi1,2 E-mail
Miguel Orcinha2 E-mail
How to cite
If you find this package useful and use it in your work, please cite the publication that it's based on, Pelosi et al. (2026) New model for long-term forecasting of galactic cosmic rays, Phys. Rev. D 114, 063005, DOI:10.1103/npfk-lwy9.
The heatmaps with the discretised model used in this package can be found in Zenodo.
Acknowledgements
This work as been developped with support from Agenzia Spaziale Italiana (ASI), under ASI-UniPG 2019-2-HH.0, ASI-INFN 2019-19 HH.0, its amendment 2021-43 HH.0, the Italian Ministry of University and Research (MUR) through the program "Dipartimenti di Eccellenza 2023-2027" and Fundação para a Ciência e Tecnologia (FCT) under grant 2024.00992.CERN, Portugal.
Metadata
Release files for pglis 1.0.4
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 |
|---|---|---|---|---|
| pglis-1.0.4.tar.gz | 30.0 kB | Without provenance | Details for pglis-1.0.4.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pglis-1.0.4-py3-none-any.whl | Python 3 | none | any | Details for pglis-1.0.4-py3-none-any.whl |
Total release size: 58.9 kB
Release files / pglis-1.0.4.tar.gz
| Download URL | pglis-1.0.4.tar.gz |
|---|---|
| Size | 30.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4256b6c02e3e087799838aab4fdc198a9af5433d32c09e83f49476ce41624b26
|
|
BLAKE2b-256 checksum How to use checksums |
03c2ef55f30875b728cdb49bb2a93f6c61655507cc17cefb8f7ecbc69a170b53
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.13
|
Release files / pglis-1.0.4-py3-none-any.whl
| Download URL | pglis-1.0.4-py3-none-any.whl |
|---|---|
| Size | 28.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a441abebf32618e35340276da5c70d8e70165280eb659efe30ebe95b0dd7ecf8
|
|
BLAKE2b-256 checksum How to use checksums |
069ace002e995baba2194e4608c64f8b560991e0f7299528ecae61ae4e7b46cd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.13
|
Security for pglis 1.0.4
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.