{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/connect-a-neural-network-based-framework-for","title":"CONNECT: A neural network based framework for emulating cosmological observables and cosmological parameter inference","arxiv_id":"2205.15726","date":"2022-05-30","proceeding":null,"authors":["Andreas Nygaard","Emil Brinch Holm","Steen Hannestad","Thomas Tram"],"abstract":"Bayesian parameter inference is an essential tool in modern cosmology, and typically requires the calculation of $10^5$--$10^6$ theoretical models for each inference of model parameters for a given dataset combination. Computing these models by solving the linearised Einstein-Boltzmann system usually takes tens of CPU core-seconds per model, making the entire process very computationally expensive. In this paper we present \\textsc{connect}, a neural network framework emulating \\textsc{class} computations as an easy-to-use plug-in for the popular sampler \\textsc{MontePython}. \\textsc{connect} uses an iteratively trained neural network which emulates the observables usually computed by \\textsc{class}. The training data is generated using \\textsc{class}, but using a novel algorithm for generating favourable points in parameter space for training data, the required number of \\textsc{class}-evaluations can be reduced by two orders of magnitude compared to a traditional inference run. Once \\textsc{connect} has been trained for a given model, no additional training is required for different dataset combinations, making \\textsc{connect} many orders of magnitude faster than \\textsc{class} (and making the inference process entirely dominated by the speed of the likelihood calculation). For the models investigated in this paper we find that cosmological parameter inference run with \\textsc{connect} produces posteriors which differ from the posteriors derived using \\textsc{class} by typically less than $0.01$--$0.1$ standard deviations for all parameters. We also stress that the training data can be produced in parallel, making efficient use of all available compute resources. The \\textsc{connect} code is publicly available for download at \\url{https://github.com/AarhusCosmology}.","url_abs":"https://arxiv.org/abs/2205.15726v2","url_pdf":"https://arxiv.org/pdf/2205.15726v2.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"links_only","authors_date_abstract":"arXiv metadata, CC0 1.0 (https://info.arxiv.org/help/license), from the Kaggle arXiv metadata snapshot of 2026-09-12"},"code_links":[{"paper_slug":"connect-a-neural-network-based-framework-for","repo_url":"https://github.com/aarhuscosmology/connect_public","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"tf","reach":null}],"tasks":[],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"syntology_url":null,"atlas_url":null,"mcp":null,"developers":"https://syntology.ai/developers"},"arxiv_metadata":null,"syntology_extracted_results":null}