astronomy/ai produced the result/Monthly Notices of the Royal Astronomical Society 2022 · v2
Neural networks stand in for slow galaxy clustering calculations in cosmology analyses
Researchers trained six small neural networks to reproduce an effective field theory model of how galaxies cluster, then used the trained stand-in, called EFTEMU, in place of the slower model code when fitting mock survey data.
spectrum · one line per step, placed by what the step does · bright lines used AI
matryoshka II: accelerating effective field theory analyses of the galaxy power spectrum
Monthly Notices of the Royal Astronomical Society, 2022
doi:10.1093/mnras/stac3326 · record aix-00047 v2 · checked 2026-10-08
- AI was for
- Simulation surrogate
- Model family
- Multilayer perceptron
- Checked by
- Held-out2000 tested
- Code
- available
The finding the paper is about came from the AI.
What this research was about
Galaxies are not scattered at random. They gather in sheets and filaments, a pattern laid down by the early universe and stretched by gravity ever since. Cosmologists summarise that pattern with the galaxy power spectrum, which says how much clustering there is at each distance scale. Comparing a measured power spectrum with theory can pin down the ingredients of the universe. The snag is the theory itself. The effective field theory of large-scale structure predicts the power spectrum for a given set of cosmological parameters, but each prediction takes a noticeable amount of computing. Fitting data means asking for such predictions many thousands of times over, as a sampler wanders through the possible universes.
The authors set out to replace that repeated calculation with something quick. The effective field theory prediction splits into pieces that depend only on the cosmology and pieces describing how galaxies trace the underlying matter, known as bias parameters. Only the first kind needs the heavy machinery. If a trained model could supply those pieces fast enough and accurately enough, the rest could be assembled by hand, and the full fitting procedure would run on ordinary hardware.
Where AI came in
The AI here is a surrogate: a stand-in for a physics code. The team drew ten thousand sets of five cosmological parameters, spread across the ranges covered by two existing simulation suites, and used the codes PyBird and CLASS to compute the cosmology-dependent components of the power spectrum at three redshifts. Eight thousand of those sets became training data. Six small networks were trained with TensorFlow, each with two hidden layers, one per group of components for each of the two measured quantities. Together they form the emulator, EFTEMU. Predictions are finished off by combining the network outputs with bias parameters analytically.
The remaining two thousand cosmologies were held back as a test. On these the emulator's predictions agreed with PyBird to better than one per cent at the one-sigma level for the bias parameter sets tried. The emulator was then used as the model inside mock fits, where a sampler explores which cosmologies match simulated survey measurements. Those fits recovered the input cosmology to within one sigma at each redshift and for mock volumes up to (5000 Mpc/h) cubed. Median parameter values shifted by at most about 0.6 sigma from PyBird's own posteriors, with interval widths agreeing to about ten per cent. A single prediction took a few milliseconds on a laptop.
Written by AIxSci from the checked record below, to give context for readers outside the field. It is not part of the record.
The work
Technical · from the record
The authors trained six shallow fully connected neural networks to reproduce the bias-independent components of an effective field theory model for the redshift-space galaxy power spectrum monopole and quadrupole, collectively called the EFTEMU. Training used 8,000 of 10,000 Latin-hypercube cosmologies computed with PyBird at three redshifts over 0.001 h/Mpc to 0.19 h/Mpc, with the remaining 2,000 held out for testing. On the held-out set the emulator agreed with PyBird to better than 1% at the 1-sigma level for the bias-parameter sets tested, and mock full shape MCMC analyses recovered the input cosmology within 1 sigma at each redshift and for mock volumes up to (5000 Mpc/h)^3. Posteriors obtained with the emulator differed from importance-sampled PyBird posteriors by at most about 0.6 sigma in median value, with 68% credible interval widths agreeing to about 10%.
How AI was used
Ten thousand samples of five LCDM parameters were drawn by Latin hypercube from ranges set by the Aemulus and AbacusSummit simulation suites, and for each sample the bias-independent Pn,l components of the EFTofLSS galaxy power spectrum were computed with PyBird, using CLASS for the linear matter power spectrum, at z=0.38, 0.51 and 0.61. Targets and inputs were rescaled to [0,1] and scales where the components vanished for all training samples were removed. The 21 components per multipole were grouped into linear, loop and counterterm sets, and one fully connected TensorFlow network with two ReLU hidden layers was trained per group per multipole (200 nodes per layer for the linear and counterterm groups, 400 for the loop group), giving six component emulators, using mean squared error loss, an Adam optimiser, batch size 100, an initial learning rate of 0.013 with plateau-triggered reduction and early stopping, and a maximum of 10,000 epochs; hyper-parameters were tuned manually. Predictions were formed by combining the network outputs with bias parameters analytically. The trained emulator was then run over the held-out cosmologies with random and best-fit bias parameters and compared with PyBird, and was used as the likelihood model in mock full shape MCMC analyses of PyBird-generated mock multipoles with Gaussian covariances for several survey volumes, sampled with zeus; PyBird posteriors for comparison were obtained by importance sampling the emulator chains.
The shape of the work
Structural · the record, drawn
no AI
Sample cosmological parameter space
Obtaining raw data, whether by measurement, download or retrieval.
We concatenate their shared Λ CDM parameters and generate 10,000 Latin-hypercube samples in the region covered by the simulation samples.where the paper describes this · verbatim
no AI
Compute bias-independent power spectrum components
Numerical or physics simulation, including where a learned surrogate replaces it.
we use PyBird to calculate all Pn,l components and CLASS to calculate the linear matter power spectrumwhere the paper describes this · verbatim
no AI
Preprocess training data
Cleaning, filtering, normalising or labelling data already obtained.
the preprocessing involves rescaling all target functions and input variables such that they lie within the range [0,1]where the paper describes this · verbatim
AI
Train component neural networks
Fitting model parameters, including fine-tuning an existing model. The AI stood in for simulation.
We train the NNs for a maximum of 10,000 epochs with a batch size of 100.where the paper describes this · verbatim
AI
Predict multipoles for held-out cosmologies
Running a trained model over new data to predict, classify or score. The AI stood in for simulation.
We test the prediction accuracy of the multipoles using the unseen test set.where the paper describes this · verbatim
no AI
Quantify power-spectrum-level prediction error
Testing outputs against ground truth.
We assess the prediction accuracy by examining the ratio of the EFTEMU predictions to the PyBird predictions.where the paper describes this · verbatim
AI
Run mock full shape MCMC analyses
Running a trained model over new data to predict, classify or score. The AI stood in for simulation.
We calculate posterior distributions on cosmological and bias parameters via Markov Chain Monte Carlo (MCMC).where the paper describes this · verbatim
no AI
Compare emulator posteriors with PyBird posteriors
Testing outputs against ground truth.
Our target distribution is the PyBird posterior, and our proposal is the EFTEMU posterior.where the paper describes this · verbatim
What the record says
Technical · every part carries its own basis
+ in the paper~ our reading− not reported
How to read the quotations. A quotation shows where the paper describes something. It does not quote every value beside it: one passage locates a part of the work, and values without their own quotation are our reading of that passage.
The trained emulator (EFTEMU) is the object the paper presents and all reported power-spectrum predictions and emulator posteriors come from it
All the NNs are built with TensorFlow. All the NNs are shallow, each only having two fully-connected hidden layers.where the paper describes this · verbatim
Only 8,000 were used for training; the other 2,000 were used to test the prediction accuracy of the multipoleswhere the paper describes this · verbatim
We make available all training and test data generated for this work in a repositorywhere the paper describes this · verbatim
What this paper did not report
Technical · absence is published deliberately
- Version of EFTEMU (six component emulators within matryoshka)Which version of the model was used is not stated.
About this article
Record aix-00047, version 2, checked by a person on 2026-10-08. The record describes the paper; it does not assess whether the paper's findings are right. The paper is published under CC-BY; quotations are at most 25 words. How we work · Report an error