sdss / lvmdatasimulator

Simulator of LVM data for testing DRP and DAP
BSD 3-Clause "New" or "Revised" License
6 stars 0 forks source link

lvmdatasimulator

Versions Documentation Status Travis (.org) codecov

Simulator of LVM data for testing DRP and DAP. It can be used also as an advanced exposure time calculator for LVM.

In the current, early, version only reduced data with a very simplified instrument setup can be simulated.

Instalation and configuration

To install the package, please run

git clone --recursive https://github.com/sdss/lvmdatasimulator

Don't forget to download all necessary files with the pre-computed grids of models. The details are given in this notebook and in this section

N.B.: We have been notified that there are problems installing the package with the M1 MacBook. The solution seems to be installing the hdf5 package. Including this package in the requirements, however, creates issues with the installation on other platforms (e.g. Ubuntu). So, if you are trying to install this package on a new Mac, please first do pip install hdf5.

How to use the code

Shortly, the current version of the code can be divided three main sections:

The detailed documentation of these blocks will be added later to this readme. At the moment, we prepared two tutorials for users on how to use the code.

Major limitations of the current version:

Known bugs or missing features that will be fixed soon

Desrciption of the required and generated files

There are some data that the simulator needs to work properly that are too large for github for storage and they have to be downloaded from the SAS. To download the data, you can run in an ipython session the following commands:

from lvmdatasimulator import download_data
download_data()

The data will be automatically downloaded and positioned in the correct location within the package directory structures. Run this command after installing the simulator, and every once in a while, in case these data changed.

Finally, the Starburst99 models are useful to produce the continuum. They are already in the data directory (LVM_continuum_models.fits)

Adopted format of the pre-generated Cloudy models.

In lvmdatasimulator we use the specific format of the Cloudy models that is described below. If someone wants to run simulations using their own model grids, they can save such grids in the same format and rewrite the path to the model grid in the config file

Produced fits-files with information on the ISM:

The ISM components generated by the lvmdatasimulator (source field) is saved to a multi-extensions fits file. It is possible to externally modify the file before running simulator. Every nebula in this file has their own ID.

The following extension can be included in the file:

The primary extension contains the following important fields:

The headers of each other extension can contain the following fields: