# RCPANN - Ring Current Proton ANN Model
[![N|Solid](https://cldup.com/dTxpPi9lDf.thumb.png)](https://nodesource.com/products/nsolid)
The Ring Current Proton Artificial Neural Network (RCPANN) model specifies the ring current proton distribution using artificial neural network (multi-layer perceptron).
This model is based on RBSP/RBSPICE measurements from 2013-2018. The RBSPICE measures proton flux at 14 energy channels from 45 keV to 598 keV, and this model provides proton spin-averaged flux in those 14 energy channels. The data for the training and modeling are available at https://doi.org/10.5281/zenodo.7651736. The training program are available ar https://github.com/jinxingli87/RCPANN.
## How to use the RCPANN model
First, pip install the 'rcpann' package. Tensorflow and Pytorch packages are required.
```sh
pip3 install rcpann
```
## ✨ Example 1: Predict proton flux at a specific moment
Input: iek, coord in shape of either (4,) or (1,4), and tstr in form of 'yyyy-mm-dd hh:mm:ss'
The iek should be a number between 0 and 13, and the corresponding energy is listed below.
|iek|0|1|2|3|4|5|6|7|8|9|10|11|12|13|
| ------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ |
|Energy (keV)|45|55|67|82|99|121|148|181|220|269|328|400|489|598|
```python3
from rcpann import *
iek=1
coord=np.array([3.5, 0.0, 1.0, 0.0]) # L=3.5, cos(theta)=0, sin(theta)=1.0, Lat=0.0, which means MLT = 6h
print(pflux(iek,coord,tstr = '2017-03-01 22:42:00'))
```
## ✨ Example 2. Model the global distribution of proton flux
```python3
from rcpann import *
iek=1
tstr1='2017-03-01 22:42:00'
tstr2='2017-03-04 23:59:00'
rcpann_global_dist(iek,tstr1,tstr2)
```
Please contact jinxing.li.87@gmail.com for support.
## License
MIT
**Free Software, Hell Yeah!**
Raw data
{
"_id": null,
"home_page": "",
"name": "rcpann",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "python,Ring Current,Space,Space physics,Radiation belt,magnetosphere",
"author": "Jinxing Li",
"author_email": "<jinxing.li.87@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/68/88/bfd4aa114c84c480ebd110376a77e89e0880ca4640c8b631c6417655cdef/rcpann-0.0.7.tar.gz",
"platform": null,
"description": "\n# RCPANN - Ring Current Proton ANN Model\n\n[![N|Solid](https://cldup.com/dTxpPi9lDf.thumb.png)](https://nodesource.com/products/nsolid)\n\nThe Ring Current Proton Artificial Neural Network (RCPANN) model specifies the ring current proton distribution using artificial neural network (multi-layer perceptron).\n\nThis model is based on RBSP/RBSPICE measurements from 2013-2018. The RBSPICE measures proton flux at 14 energy channels from 45 keV to 598 keV, and this model provides proton spin-averaged flux in those 14 energy channels. The data for the training and modeling are available at https://doi.org/10.5281/zenodo.7651736. The training program are available ar https://github.com/jinxingli87/RCPANN.\n\n## How to use the RCPANN model\nFirst, pip install the 'rcpann' package. Tensorflow and Pytorch packages are required. \n```sh\npip3 install rcpann\n```\n\n## \u2728 Example 1: Predict proton flux at a specific moment\nInput: iek, coord in shape of either (4,) or (1,4), and tstr in form of 'yyyy-mm-dd hh:mm:ss'\nThe iek should be a number between 0 and 13, and the corresponding energy is listed below.\n|iek|0|1|2|3|4|5|6|7|8|9|10|11|12|13|\n| ------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ | ------ |------ |\n|Energy (keV)|45|55|67|82|99|121|148|181|220|269|328|400|489|598|\n```python3\nfrom rcpann import *\niek=1\ncoord=np.array([3.5, 0.0, 1.0, 0.0]) # L=3.5, cos(theta)=0, sin(theta)=1.0, Lat=0.0, which means MLT = 6h\nprint(pflux(iek,coord,tstr = '2017-03-01 22:42:00'))\n```\n\n## \u2728 Example 2. Model the global distribution of proton flux\n```python3\nfrom rcpann import *\niek=1\ntstr1='2017-03-01 22:42:00'\ntstr2='2017-03-04 23:59:00'\nrcpann_global_dist(iek,tstr1,tstr2)\n```\n\n\n\nPlease contact jinxing.li.87@gmail.com for support.\n\n\n## License\n\nMIT\n\n**Free Software, Hell Yeah!**\n\n\n",
"bugtrack_url": null,
"license": "",
"summary": "Ring Current Proton Artifician Neural Network Model",
"version": "0.0.7",
"project_urls": null,
"split_keywords": [
"python",
"ring current",
"space",
"space physics",
"radiation belt",
"magnetosphere"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "d85e457c1a759dbe8964e40312b0c6c07f9eca6933ed80ca6ed3e1e703d4cc90",
"md5": "2531aaeb896ef6ebc9f2c3e90310d452",
"sha256": "668b019848e7530e5d34126594b9aafd770f3f81d888e6e9beca36880ee74bae"
},
"downloads": -1,
"filename": "rcpann-0.0.7-py3-none-any.whl",
"has_sig": false,
"md5_digest": "2531aaeb896ef6ebc9f2c3e90310d452",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 17785695,
"upload_time": "2023-12-27T20:51:11",
"upload_time_iso_8601": "2023-12-27T20:51:11.871367Z",
"url": "https://files.pythonhosted.org/packages/d8/5e/457c1a759dbe8964e40312b0c6c07f9eca6933ed80ca6ed3e1e703d4cc90/rcpann-0.0.7-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "6888bfd4aa114c84c480ebd110376a77e89e0880ca4640c8b631c6417655cdef",
"md5": "5bbe33747ba6af2ee47460e044eaf763",
"sha256": "07577c616244655b4fc71c27db4e505adc87d1935b262f78bff2dbeb94d1b371"
},
"downloads": -1,
"filename": "rcpann-0.0.7.tar.gz",
"has_sig": false,
"md5_digest": "5bbe33747ba6af2ee47460e044eaf763",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 17407040,
"upload_time": "2023-12-27T20:51:27",
"upload_time_iso_8601": "2023-12-27T20:51:27.564128Z",
"url": "https://files.pythonhosted.org/packages/68/88/bfd4aa114c84c480ebd110376a77e89e0880ca4640c8b631c6417655cdef/rcpann-0.0.7.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-12-27 20:51:27",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "rcpann"
}