Table of Contents
Fetching ...

Flexible Simulation Based Inference for Galaxy Photometric Fitting with Synthesizer

Thomas Harvey, Christopher C. Lovell, Sophie Newman, Christopher J. Conselice, Duncan Austin, William J. Roper, Aswin P. Vijayan, Stephen M. Wilkins, Patricia Iglesias-Navarro, Vadim Rusakov, Qiong Li, Nathan Adams, Kai Magdwick, Caio M. Goolsby, Marc Huertas-Company, Matthew Ho

TL;DR

This work presents synference, a scalable SBI framework for galaxy SED fitting that couples the Synthesizer forward model with the LtU-ILI validation toolkit to produce full Bayesian posteriors for galaxy properties from photometry. By training on up to $10^6$ simulated galaxies with an 8-parameter physical model and 14-band JWST/HST data, the authors demonstrate excellent parameter recovery (e.g., $R^2=0.99$ for $\log M_*$) and well-calibrated posteriors, while achieving substantial speedups (roughly $10^3$--$10^5$) over nested sampling or MCMC. The framework supports flexible SFHs, emission components, and multiple SPS grids, enabling rapid model comparison (e.g., BPASS vs FSPS) and joint redshift-parameter inference (Model 2) on real data from the JADES GOODS-South field. The results underscore the potential of amortized SBI to transform analyses of next-generation surveys by delivering fast, fully Bayesian inferences across massive galaxy catalogs, with robust validation and extensible support for spectroscopy and complex forward models.

Abstract

We introduce Synference, a new, flexible Python framework for galaxy SED fitting using simulation-based inference (SBI). Synference leverages the Synthesizer package for flexible forward-modelling of galaxy SEDs and integrates the LtU-ILI package to ensure best practices in model training and validation. In this work we demonstrate Synference by training a neural posterior estimator on $10^6$ simulated galaxies, based on a flexible 8-parameter physical model, to infer galaxy properties from 14-band HST and JWST photometry. We validate this model, demonstrating excellent parameter recovery (e.g. R$^2>$0.99 for M$_\star$) and accurate posterior calibration against nested sampling results. We apply our trained model to 3,088 spectroscopically-confirmed galaxies in the JADES GOODS-South field. The amortized inference is exceptionally fast, having nearly fixed cost per posterior evaluation and processing the entire sample in $\sim$3 minutes on a single CPU (18 galaxies/CPU/sec), a $\sim$1700$\times$ speedup over traditional nested sampling or MCMC techniques. We demonstrate Synference's ability to simultaneously infer photometric redshifts and physical parameters, and highlight its utility for rapid Bayesian model comparison by demonstrating systematic stellar mass differences between two commonly used stellar population synthesis models. Synference is a powerful, scalable tool poised to maximise the scientific return of next-generation galaxy surveys.

Flexible Simulation Based Inference for Galaxy Photometric Fitting with Synthesizer

TL;DR

This work presents synference, a scalable SBI framework for galaxy SED fitting that couples the Synthesizer forward model with the LtU-ILI validation toolkit to produce full Bayesian posteriors for galaxy properties from photometry. By training on up to simulated galaxies with an 8-parameter physical model and 14-band JWST/HST data, the authors demonstrate excellent parameter recovery (e.g., for ) and well-calibrated posteriors, while achieving substantial speedups (roughly --) over nested sampling or MCMC. The framework supports flexible SFHs, emission components, and multiple SPS grids, enabling rapid model comparison (e.g., BPASS vs FSPS) and joint redshift-parameter inference (Model 2) on real data from the JADES GOODS-South field. The results underscore the potential of amortized SBI to transform analyses of next-generation surveys by delivering fast, fully Bayesian inferences across massive galaxy catalogs, with robust validation and extensible support for spectroscopy and complex forward models.

Abstract

We introduce Synference, a new, flexible Python framework for galaxy SED fitting using simulation-based inference (SBI). Synference leverages the Synthesizer package for flexible forward-modelling of galaxy SEDs and integrates the LtU-ILI package to ensure best practices in model training and validation. In this work we demonstrate Synference by training a neural posterior estimator on simulated galaxies, based on a flexible 8-parameter physical model, to infer galaxy properties from 14-band HST and JWST photometry. We validate this model, demonstrating excellent parameter recovery (e.g. R0.99 for M) and accurate posterior calibration against nested sampling results. We apply our trained model to 3,088 spectroscopically-confirmed galaxies in the JADES GOODS-South field. The amortized inference is exceptionally fast, having nearly fixed cost per posterior evaluation and processing the entire sample in 3 minutes on a single CPU (18 galaxies/CPU/sec), a 1700 speedup over traditional nested sampling or MCMC techniques. We demonstrate Synference's ability to simultaneously infer photometric redshifts and physical parameters, and highlight its utility for rapid Bayesian model comparison by demonstrating systematic stellar mass differences between two commonly used stellar population synthesis models. Synference is a powerful, scalable tool poised to maximise the scientific return of next-generation galaxy surveys.

Paper Structure

This paper contains 36 sections, 9 equations, 12 figures, 4 tables.

Figures (12)

  • Figure 1: Schematic illustration of the synference workflow. User-defined inputs are shown on the left, including the physical model configuration within synthesizer, the choice of instrumentation (photometric filters, wavelength range, spectral resolution), as well as the SBI model hyperparameters for the neural density estimator, which utilizes the ltu-ili package ho2024ltu with either the sbitejero2020sbi or lampeboelts2024sbi backends. The synference framework processes these to generate a library of mock observations, either using the synthesizer package or directly from a user-provided model. From this library we generate a training array for the SBI model, then train a neural density estimator to emulate the posterior or likelihood. The hyperparameters can be optionally optimized using optunaakiba2019optuna. The amortized trained model can then be utilized for direct inference from observed data to generate reliable Bayesian posterior estimates. Optionally these posteriors can be used to reconstruct the predicted SED of the galaxy.
  • Figure 2: An illustration of the empirical noise model for the F444W filter. The upper panel shows the relationship between the noiseless input magnitude ($m$) and the scattered, noisy magnitude ($m'$). The lower panel shows the relationship between the input magnitude and the assigned photometric uncertainty ($\sigma'$). The blue points show true flux and uncertainty measurements from the JADES photometric catalogue.
  • Figure 3: Model 1 NPE hyperparameter importance and logarithmic P($\theta|x)$ contours for key hyperparameters as determined by Optuna testing akiba2019optuna. The upper panel shows the importance of each hyperparameter to the objective optimization for the overall trial, as well as individually for the mixture density network (MDN) and neural spline flow (NSF) network architectures we tested. The lower panels show objective contours for hyperparameter pairs for the learning rate, training batch size, early stopping criteria and network specific parameters controlling the width and depth of the neural networks. Based on $\sim$3000 trials, the optimal model utilized a NSF architecture with hyperparameters given in the inset table.
  • Figure 4: Model performance metrics and calibration tests for Model 1. Upper panels: True vs recovered parameter estimates for key model parameters as meausred with the subset of the validation dataset with $\langle \rm SNR \rangle> 5$. Each panel has the posterior rank histogram inset showing the posterior calibration, and the coefficient of determination $R^2$ and root mean square error (RMSE) are provided for each parameter. A rank histogram evaluates calibration by plotting the distribution of the true value's rank relative to sorted samples from the model's posterior predictive distribution; a flat, uniform histogram is ideal, indicating that the true values are statistically indistinguishable from the predicted samples. Lower right: Coverage plots for individual parameters showing unbiased estimates. This compares the nominal credible level (the "expected" coverage probability, e.g., 95%) on the x-axis against the empirical coverage (the actual proportion of true values that fall within that predicted interval) on the y-axis. The 1:1 diagonal line represents perfect calibration, where the model's reported uncertainty (e.g., a 95% interval) perfectly matches its empirical performance (it contains the true value exactly 95% of the time). Lower left: Tests of Accuracy with Random Points metric lemos2023sampling showing the model calibration relative to the ideal 1:1 line. TARP evaluates the average calibration of the model across the entire data distribution. It plots the nominal credible level (x-axis) against the expected coverage probability (y-axis), which is the empirical coverage averaged over all possible data points.
  • Figure 5: Corner plot for a single mock galaxy comparing multivariate posterior constraints from SBI (in red) to the ground-truth value (black point) as well as reference nested-sampling (labelled as NS) results using dynesty (in blue). Contours show the $1\sigma$ and $2\sigma$ regions. Model 1 accurately recovers the stellar mass, metallicity, dust attenuation and SFH. In the upper right the true and recovered SED and SFH models are shown showing accurate SFH and SED recovery for this galaxy in both cases.
  • ...and 7 more figures