generate_array_config

generate_array_config#

Generate sim_telarray config files for a given array.

All the input required has to be given as a yaml file by the command line argument array_config.

The required entries in the array_config file are:

‘site’: South or North

‘layout_name’: name of an array layout.

‘model_version’: model version.

‘default’: telescope model names to be assigned to each telescope size by default.

As optional data, specific telescope models can be assigned to individual telescopes. This is done by the entries with the name of the telescope (as used by the layout definition, ex. LSTN-01, MSTN-05, SSTS-10).

Each telescope model can be set in two ways.

a) A single str with the name of telescope model Ex. ‘MSTN-05’: ‘NectarCam-D’

b) A dict containing a ‘name’ key with the name of the telescope model and further keys with model parameters to be changed from the original model. Ex.:

'MSTN-05': {
        'name': 'design',
        'fadc_pulse_shape': 'Pulse_template_nectarCam_17042020-noshift.dat',
        'discriminator_pulse_shape': 'Pulse_template_nectarCam_17042020-noshift.dat'
    }

This is an example of the content of an array_config file.

site: North,
layout_name: Prod5
model_version: Prod5
default:
    LST: 'D234'  # Design model for the LSTs
    MST: FlashCam-D  # Design model for the MST-FlashCam
LST-01: '1'  # Model of LST-01 in the LaPalma site.
MST-05:
    name: NectarCam-D
    # Parameters to be changed
    fadc_pulse_shape: Pulse_template_nectarCam_17042020-noshift.dat
    discriminator_pulse_shape: Pulse_template_nectarCam_17042020-noshift.dat

Command line arguments#

label (str, optional)

Label to identify the output files/directories.

array_config (str, required)

Path to a yaml file with the array config data.

verbosity (str, optional)

Log level to print.

Example#

North - Prod5, simple example

Get the array configuration from DB:

simtools-db-get-file-from-db --file_name array_config_test.yml

Run the application. Runtime < 1 min.

simtools-generate-array-config --label test --array_config array_config_test.yml

The output is saved in simtools-output/test/model.