Giter Club home page Giter Club logo

astro_rcnn's Introduction

Astro R-CNN

Detect, classify, and deblend sources in astronomical images using Mask R-CNN: a deep learning approach to image segmentation.

Reference Paper: Burke et al. 2019, MNRAS, 490 3952.

Corresponding Author: Colin J. Burke, University of Illinois at Urbana-Champaign

Contributors (in alphabetical order): Patrick D. Aleo, Colin J. Burke, Yu-Ching Chen, Joshua Yao-Yu Lin, Xin Liu, Anshul Shah.

Updated Walkthrough:

See our updated notebook here using the detectron2 framework. The training time is now dramatically decreased (~minutes) and code highly extendable! This version supersedes the Matterport Mask R-CNN implementation and includes options to customize the network architecture.

Description:

Astro R-CNN is a deep learning method for efficiently performing all tasks of source detection, classification, and deblending on astronomical images.

Setup:

pip install -r requirements.txt

Usage:

./astro_rcnn detect example

This will run the model in inference mode with pre-trained DECam weights (use GPU for best performance). The result will be a multi-extension FITS file output_0.fits with a segmentation mask cutout in each extension corresponding to an object detection (extension number=SOURCE_ID). In each header, you will find the CLASS_ID (star=1,galaxy=2), bounding box (BBOX: y1,x1,y2,x2), and detection confidence (SCORE).

infrence Example of Astro R-CNN detection on a real DECam image. See demo_decam.ipynb for an interactive demonstration, including how to train on your own images.

deblending

Examples of Astro R-CNN deblending on a real DECam image.

This is a simple repository intended for demonstration purposes. In general, the pre-trained weights should work reasonably well for any optical telescope data provided it is normalized properly. For use with full-scale images or surveys, please contact the authors.

Training:

To train your own model, first download PhoSim training data (or make your own) into the project root directory: training set (1,000 images) validation set (250 images).

Then, try:

./astro_rcnn train trainingset,validationset

Depending on your setup, you should adjust the configuration settings and decide which weights to initialize with in astro_rcnn.py.

If you would like a simulated test dataset beyond example (1 image) to assess the network's performance: test set (50 images).

./astro_rcnn assess testset

This will generate mean AP score plots for stars and galaxies in testset.

Also available are real DECam datasets of clusters of galaxies: ACO 1689 (50 images).

Future Work:

  • Upgrade to detectron2 framework and work on the programming and user interface
  • Support for more than 3 bands
  • Support for arbitrary effective exposure times in bands
  • Generalizations to arbitarily-sized images
  • Add generative predictor for source profile inference
  • Comparison with SCARLET and other codes in crowded fields using deblending-sensitive metrics

Please contact the authors if you are interested in contributing!

astro_rcnn's People

Contributors

colinsheppard10 avatar patrickaleo avatar anshulshah957 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.