In this repository, we provide a toolbox namely MCRGNet
to classify radio galaxies of different morphologies. Our method is designed based on the state-of-the-art Convolutional Neural Network (CNN), which is trained and applied under a three step framework as
- Pretraining the network unsupervisedly with unlabeled samples (P).
- Finetuing the pretrained network parameters supervisedly with labeled samples (F).
- Classify a new radio galaxy by the trained network. (C).
To utilize our toolbox on radio galaxy morphology classification, a convolutional autoencoder (CAE) network should be trained in advance and saved. Installation of our python based scripts is as follows,
$ cd MCRGNet
$ <sudo> pip install <--user> .
To run our scripts, some python packages are required, which are listed as follows.
The requirements file is provided in this repository, by which the required packages can be installed easily. We advice the users to configure these packages in a virtual environment.
- initialize env
$ <sudo> pip install virtualenv
$ cd MCRGNet
$ virtualenv ./env
- install required packages
$ cd MCRGNet
$ env/bin/pip install -r ./requirements.txt
In addition, the computation can be accelerated by paralledly processing with GPUs. In this work, our scripts are written under the guide of Nvidia CUDA, thus the Nvidia GPU hardware is also required. You can either refer to the official guide to install CUDA, or refer to this brief guide by us.
To use the MCRGNet, we provide demos to show how to pretrain and finetune the network. Note that the jupyter-notebook is required.
- cae-pretrain-demo: Pre-train the network
- cnn-finetune-demo: Fine-tune the network
In the toolbox, you can design your own CAE and CNN network of optional layers as well as parameters by the Class ConvNet
, please refer to the script for details.
Some useful command-line-executable python scripts are also provided and archived in the utils folder,
- dataDownload: Retrieve radio galaxy samples from the FIRST archive.
- getEstLabel: Get estimated label for the radio galaxies to be classified.
In addition, some new tools are on the way, cheers
- Zhixian MA <
zxma_sjtu(at)qq.com
>
Unless otherwise declared:
- Codes developed are distributed under the MIT license;
- Documentations and products generated are distributed under the Creative Commons Attribution 3.0 license;
- Third-party codes and products used are distributed under their own licenses.
Coming soon...