Many approaches to astronomical data reduction and analysis cannot tolerate missing data: corrupted pixels must first have their values imputed. This paper presents astrofix, a robust and flexible image imputation algorithm based on Gaussian Process Regression (GPR). Through an optimization process, astrofix chooses and applies a different interpolation kernel to each image, using a training set extracted automatically from that image. It naturally handles clusters of bad pixels and image edges and adapts to various instruments and image types. The mean absolute error of astrofix is several times smaller than that of median replacement and interpolation by a Gaussian kernel. We demonstrate good performance on both imaging and spectroscopic data, including the SBIG 6303 0.4m telescope and the FLOYDS spectrograph of Las Cumbres Observatory and the CHARIS integral-field spectrograph on the Subaru Telescope.
- Pub Date:
- March 2021
- Astrophysics - Instrumentation and Methods for Astrophysics;
- Astrophysics - Astrophysics of Galaxies;
- Astrophysics - Solar and Stellar Astrophysics
- Submitted to AAS Journals. 12 pages, 11 figures. The algorithm is implemented in the Python package astrofix, which is available at https://github.com/HengyueZ/astrofix