Clusterize FRB profiles using hierarchical clustering, plot corresponding parameters distributions. Input files (waterfall data, CHIME catalog) are stored in the
resources/ directory, output files are stored in the
The vos Python module for downloading waterfall data: CANFAR storage system
pip install vos --upgrade --user
Python code related to DM calculations, estimations, and analysis: FRB
For FRB dependencies see: Installing FRB
git clone https://github.com/FRBs/FRB.git cd FRB ; python setup.py install --user ; cd ..
git clone https://github.com/FRBs/ne2001.git cd ne2001 ; python setup.py install --user ; cd ..
pip install --upgrade pip pip install astropy
Installation/upgrade of side packages, which might be required for the version compatibility
pip install --user --upgrade lxml pandas ipython scipy matplotlib seaborn h5py
cosmocalcv0.1.2 and refactor it to be able to run under Python 3 (
2to3software is used and should be installed via package manager):
curl https://files.pythonhosted.org/packages/ca/61/df95b65cd3cf3abdffcbeea6c77a6d8964a8fb625a88eccd9c73d2bfdbf0/cosmocalc-0.1.2.tar.gz | tar -x cd cosmocalc-0.1.2 ; 2to3 -w cosmocalc.py ; python setup.py install --user ; cd ..
For the fast reproduction of the main results one can run
python frb_profiles_clustering.py --use-preprocessed --use-precalculated-z.
Instead of preprocessed signal data, waterfall data can also be used, which is located in CANFAR storage and which can be downloaded with the
-d flag. For the data to be used, it shoud be in the
resources/ folder and have a following name:
To obtain preprocessed signals, run
python repack_waterfall.py. It would download waterfall data from CANFAR storage one at a time and save only calibrated profiles – mean of calibrated waterfall data over each frequency channel.
python frb_profiles_clustering.py several flags are available:
-d, --download: download waterfall data from CANFAR storage
-ef, --emission_freq: set emission frequency (MHz) used in brightness temperature calculations. Default value is 600 MHz
--use-preprocessed: use preprocessed signal profiles
--use-precalculated-z: use precalculated red-shift values
--use-latex: enable LaTeX support for plots