calibration tool for photometric data
Project description
PhotCalib
Calibration tool for Prisitine CaHK data. For more details see Martin, Starkenburg & Yuan 2023
Installation
Before installation, make sure you have pytorch or install essential dependencies :
pip install -r requirements.txt
Installation from PyPI
pip install photcalib
Manual installation
download the repository and run the setup
python setup.py install
Getting started
cd examples
To Calibrate CaHK data using the trained run model
python calib_raw.py 25Am02 25Am02 -D cpu
The first run name represents the run to train the calibration model.
The second run name represents the run to be calibrated.
D (str) is the device (default:cpu, gpu) to run pytorch. If gpu is chosen, it will use the first graphic card cuda:0 by default.
To train calibration run model: .. code:
python calib_mod.py 25Am02
Spceify the run for calibration using the input file as examples/data/inputs_run.npy, which is generated using Prepare_input.ipynb
Specify the device and training parameters (the followings are the default settings)
python calib_mod.py 17Am05 -D cpu -lr 1e-6 -n 400 -mom 0.9 -thr 1e-2
D (str) is the device (default:cpu, mps, gpu) to run pytorch.
n (int) is the number of training epochs.
lr (float) is the initial learning rate, which will decrease using scheduler (see details at https://pytorch.org/docs/stable/generated/torch.optim.lr_scheduler.ReduceLROnPlateau).
thr (float) is the threshold of the scheduler.
mom (float) is the momentum of gradient descent.
Citing this work
Martin, F.N., Starkenburg, E., & Yuan, Z. et al. (A&A 2024) https://www.aanda.org/articles/aa/full_html/2024/12/aa47633-23/aa47633-23.html
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file photcalib-0.6.tar.gz.
File metadata
- Download URL: photcalib-0.6.tar.gz
- Upload date:
- Size: 12.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
24d7395929950bfe83d139e09f987cebb3de66efbc475f14bccdf258e83ccbb0
|
|
| MD5 |
10c7f5920133c2d62313c033f76409fe
|
|
| BLAKE2b-256 |
78eb600fef9ccc1ffdf0e9cba93af63023acee52949ff8591e5efb346284485b
|
File details
Details for the file photcalib-0.6-py3-none-any.whl.
File metadata
- Download URL: photcalib-0.6-py3-none-any.whl
- Upload date:
- Size: 13.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.12.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f4aebab87c5c60c3156e7cc79957cd836e1f978a43e4b0224a111ee276aa1c2a
|
|
| MD5 |
a0fc00157e9e9cfc4de3e6a77409eebd
|
|
| BLAKE2b-256 |
f4adf53d1d004312a747a01720f9c4f2acfaa2207c24182e7955b613cc172682
|