Looking into future cosmology

by M. Raveri, M. Martinelli, G.B. Zhao and Yuting Wang

Learn More


CosmicFish is a modern library for cosmological forecasts. The code can be used to obtain expected bounds on cosmological parameters for a wide range of models and observables.


Select the cosmological model that you want to study. Choose between all models in CAMB, EFTCAMB and MGCAMB to explore the standard cosmological model and extensions of that.


Run the code to produce the Fisher matrix.


Select the type of experiments that you want to study choosing within a wide range of possible cosmological observables. Then design the experimental specifications.


Perform statistical analyses of the Fisher matrices and plot results.


The core of the CosmicFish code consists of two libraries. The first one is a Fortran library that takes care of producing the Fisher matrices. The second part consists of a Python library designed to perform operations on Fisher matrices, once they are produced. This also contains a full set of plotting utilities.

Huge model coverage

Choose among all the models included in CAMB, EFTCAMB and MGCAMB. If that is not enough interface easily your own Boltzmann solver.

Many different observables

  • Cosmic Microwave Backround
  • Weak Lensing tomography
  • Galaxy Clustering
  • Supernovae
  • Redshift drift
  • ...more coming soon

Performance and accuracy

Both libraries constituting the CosmicFish code are based on state of the art, optimized, core algorithms including precise derivatives calculators, spectral protection of Fisher matrices against degenerate, unconstrained, parameters, to name a few.

Collaborative development

The CosmicFish source code is available on GitHub and we welcome contributions from everyone. Follow the link to access the latest features (mostly still to be validated) and improvement. Join the developers and include your favourite models or observables.

Easy To Customize

Thanks to an exaustive documentation and clean code the CosmicFish library is easy to customize. New applications can be easily developed following the already existing ones. A flexible package system allows for as much customization as possible. Produce your own analysis and plotting pipelines following the default python apps.

Clean Code

The two libraries tha constitute the CosmicFish code are clearly written and documented. The code comes with two unit testing suites that are responsible for checking all the building blocks of the two libraries. The two libraries are supplied with a thorough automatic documentation that explain the interfaces and the purposes of all the functions in both codes.


Get your hands on the CosmicFish code!
Please read the README for the installation procedure.

Developers version

  • Latest features and latest bugs. Updated very often.

Stable version

  • Validated and tested features. Updated on a regular long time scale.

Validation package

  • Package used to validate the code.

Information Gain package

  • Package used for the CosmicFish release paper:

Some papers using the CosmicFish code.

  • Information Gain in Cosmology:
    From the Discovery of Expansion to Future Surveys Marco Raveri, Matteo Martinelli, Gong-Bo Zhao and Yuting Wang, arxiv:1606.06273

    Facing the advent of the next generation cosmological surveys we present a method to forecast knowledge gain on cosmological models. We propose this as a well defined and general tool to quantify the performance of different experiments in relation to different theoretical models. In particular, the assessment of experimental performance will benefit enormously from the fact that this method is invariant under re-parametrization of the model. We apply this to future surveys and compare expected knowledge advancements to the most relevant experiments performed over the history of modern cosmology. When considering the standard cosmological model, we show that it will rapidly reach knowledge saturation in the near future and forthcoming improvements will not match the past ones. On the contrary, we find that new observations have the potential for unprecedented knowledge jumps when extensions of the standard scenario are considered.


The CosmicFish library is thoroughly documented.
Two automatic documentations are provided for both the Fortran and Python part of the code.
Click here for the documentation of the CosmicFish Fortran library.
Click here for the documentation of the CosmicFish Python library.
Also check out the Python Library example page or try it!


Questions and Answers.

For any other problem just contact us or ask some question in the CosmicFish discussion group!
Here we collect some of the most frequently asked questions.

Why there is no FAQ now?

Because the code has just been released!


If you use the CosmicFish package to produce some scientific results, please refer the papers:
Information Gain in Cosmology: From the Discovery of Expansion to Future Surveys
CosmicFish Implementation Notes V1.0

If the results were obtained with the CosmicFish code built with CAMB, EFTCAMB or MGCAMB in addition to the previous references please cite the standard references for these codes as well.


We are grateful to Ana AchĂșcarro, Carlo Baccigalupi, Erminia Calabrese, Stefano Camera, Luigi Danese, Giulio Fabbian, Noemi Frusciante, Bin Hu, Valeria Pettorino, Levon Pogosian, Giuseppe Puglisi and Alessandra Silvestri for useful and helpful discussions on the subject. We are indebted to Luca Heltai for help with numerical algorithms.