This repository contains the code for neural network emulation of stellar population synsthesis (SPS) models for galaxy spectra, originally published in Alsing et. al (2020). If you use this code, kindly cite that paper. The parent fork at justinalsing/speculator is the home for the original tensorflow version of the codebase.
You can install the code with pip: pip install git+https://github.com/justinalsing/speculator.git
The code is in python3 and has the following dependencies:
tensorflow (>2.0)
scikit-learn
numpy
A basic demo of loading and calling a pre-trained model (Prospector-alpha) can be found in examples/speculator_demo.ipynb. For training your own model, you can use the template given in examples/speculator_training_demo.ipynb.
This tensorflow version of the code is no longer being actively maintained, but will remain here for those still using it. The torch version developed in the torch branch of justinalsing/speculator will continue to be developed as the default branch of Cosmo-Pop/speculator.
- J. Alsing et al. (2020). ApJS 249, 5. arXiv:1911.11778