/DI-Project

Public Repository for Direct Imaging Project using CNN

Primary LanguagePython

Direct Imaging of Exoplanets with Deep Learning

A public repository to store the code used in the paper "Pushing the Limits of Exoplanet Discovery via Direct Imaging with Deep Learning". If you use this code, please cite the paper:

Yip, K. H., Nikolaou, N., Coronica, P., Tsiaras, A., Edwards, B., Changeat Q., Morvan, M., Biller, B., Hinkley, S., Salmond, J., Archer, M., Sumption P., Choquet, E., Soummer, R., Pueyo, L., Waldmann, I. P., "Pushing the limits of exoplanet discovery via direct imaging with deep learning", In proceedings of ECML/PKDD 2019 (To Appear)

Data

Data can be downloaded at: https://osf.io/ez7pk/

Descirption of the data

Folder 'CNN':

  • master_training.npy: Collection of negative (speckle, no planet) simulated frames (generated by GAN) used for training the CNN.
  • master_test.npy: Collection of negative (speckle, no planet) simulated frames (generated by GAN) used for testing.
  • tinyPSF.npy: Simulated PSF (Point Spread Function) generated by TinyTim.

Folder 'Raw Data': Original Science Frames taken by HST NICMOS from the STScI Archive (DR2).

Folder 'GAN':

  • Real_train.npy: Filtered, normalised science frames used to train the GAN
  • Real_test_unknown.npy: Normalised science frames reserved for data exploration.
  • Real_test_confirmed.npy: Detected bright source signal, reserved for performance evaluation once CNN is trained.

Paper

https://arxiv.org/pdf/1904.06155.pdf

Using the GAN

To train the GAN, please type the following command in the terminal:

$python train-dcgan.py --dataset LINK/TO/DATAFILES --epoch 35 --batch_size 50 —loss_ftn dcgan

Once you finished training the GAN, you can inspect the quality of the images it can produce by asking it to generate images unseen by the network.

$python complete.py --imgSize 64 --dataset LINK/TO/UNSEENDATA --batch_size 1 --nIter 2000 --train_size 75

batch_size specifies the number of input images you pass through to the GAN at each time nIter specifies the number of restoration iterations the GAN must go through before outputing the final image. train_size specifies the number of input images

Using the CNN

The CNN requires as input the training data, the test data and the PSF for planet injection. Using this information, the CNN will generate another set of images, this time positive (speckle+planet) for supervised training.

To train the CNN, please change directory into the CNN folder and type the following command in the terminal:

$python CNN_keras.py --datapath LINK/TO/TRAINING --testpath LINK/TO/TEST --psf_path LINK/TO/PSF --checkpt LINK/TO/FOLDER

The checkpoint folder contains the training history (training_0.csv) and the checkpoint of the final trained model.

There are a number of hyperparameters available for the user to fine-tune. Feel free to experiment with them! Please refer to the code or the paper for detailed settings to recreate the paper's results.

License

Creative Commons Licence
This work is licensed under a Creative Commons Attribution 4.0 International License.