NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Fast automated analysis of strong gravitational lenses with convolutional neural networks

Yashar Hezaveh, Laurence Perreault-Levasseur, Philip J. MarshallNature 2017 · DOI

Abstract

Traditional methods for analyzing strong gravitational lenses rely on computationally intensive maximum likelihood estimation, which can take weeks per lens. This paper presents a fully automated approach using Convolutional Neural Networks (CNNs) to estimate lensing parameters directly from images. The proposed method achieves a speedup of approximately seven orders of magnitude—processing 100 lenses per second on a single GPU—while maintaining accuracy comparable to traditional methods. By leveraging automated preprocessing and massive data augmentation, the system demonstrates robustness to realistic telescope artifacts and real-world data from the Hubble Space Telescope.

Introduction

Strong gravitational lensing is a critical tool in astrophysics for mapping dark matter and mass distributions in foreground galaxies. However, the current standard for parameter extraction involves "forward modeling," an iterative process of simulating lenses to match observed data. This manual, expert-intensive process is a significant bottleneck for upcoming large-scale surveys like the LSST, which are expected to discover tens of thousands of new lenses. To address this, we frame lens parameter estimation as a direct image-to-parameter regression problem using deep learning.

Methods

The core of the approach involves training CNNs to learn the inverse mapping from raw pixel data to the five parameters of the Singular Isothermal Ellipsoid (SIE) density profile: Einstein radius ($\theta_E$), complex ellipticity ($\epsilon_x, \epsilon_y$), and center coordinates ($x, y$).

Architecture and Training

We adapted three established architectures—Inception-v4, AlexNet, and Overfeat—alongside a custom CNN. The final classification layers were replaced with regression layers. An ensemble approach was used, combining the outputs of all four networks through a final trainable layer. Training utilized half a million simulated lensing systems, incorporating real unlensed galaxy images from the Galaxy Zoo and GREAT3 datasets.

Automated Preprocessing

To eliminate the need for manual masking of foreground galaxy light, we employed Independent Component Analysis (ICA) on multi-wavelength images. ICA exploits the statistical independence and color differences between foreground and background galaxies to automatically separate lens light from the distorted arcs.

Data Augmentation

To ensure real-world applicability, training images were subjected to extreme augmentation, including PSF blurring, Poisson and Gaussian noise, simulated cosmic rays, hot pixels, and random masks. This approach allows the network to handle telescope artifacts without requiring explicit training on real noise samples.

Results

The combined network demonstrates exceptional performance in both speed and accuracy. Inference for 100 systems takes approximately one second on a single GPU, representing a $10^7$ speedup over traditional methods.

Table 1: Comparison of parameter estimation errors across different network architectures and the combined ensemble.

As shown in Table 1, the combined network achieves 68% error margins of 0.02" for the Einstein radius and 0.04 for both ellipticity and center coordinates on simulated test data. Validation on nine real lenses from the SL2S survey imaged by the Hubble Space Telescope showed that CNN predictions were consistent with previously published parameters obtained through traditional modeling, falling within 95% confidence intervals.

Discussion and Future Work

While the CNN approach offers unprecedented speed, it currently provides point estimates rather than full posterior probability distributions. Future work will explore Bayesian Neural Networks or Monte Carlo Dropout to quantify uncertainties. Additionally, the network's performance is sensitive to out-of-distribution data, such as high external shear not present in the training set. Despite these limitations, the ability to perform real-time analysis as data streams from telescopes marks a fundamental shift in gravitational lens research, enabling the processing of massive datasets from next-generation surveys.

Summary updated

BibTeX
@inproceedings{hezaveh2017fast,
  author = {Yashar Hezaveh and Laurence Perreault-Levasseur and Philip J. Marshall},
  title = {{Fast automated analysis of strong gravitational lenses with convolutional neural networks}},
  booktitle = {Nature},
  year = {2017},
  doi = {10.1038/nature23463},
}
Figure