gammasimtools 0.8.2__py3-none-any.whl → 0.10.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {gammasimtools-0.8.2.dist-info → gammasimtools-0.10.0.dist-info}/METADATA +4 -4
- {gammasimtools-0.8.2.dist-info → gammasimtools-0.10.0.dist-info}/RECORD +119 -105
- {gammasimtools-0.8.2.dist-info → gammasimtools-0.10.0.dist-info}/WHEEL +1 -1
- {gammasimtools-0.8.2.dist-info → gammasimtools-0.10.0.dist-info}/entry_points.txt +4 -1
- simtools/_version.py +2 -2
- simtools/applications/calculate_trigger_rate.py +15 -38
- simtools/applications/convert_all_model_parameters_from_simtel.py +9 -28
- simtools/applications/convert_geo_coordinates_of_array_elements.py +54 -53
- simtools/applications/convert_model_parameter_from_simtel.py +2 -2
- simtools/applications/db_add_file_to_db.py +1 -2
- simtools/applications/db_add_simulation_model_from_repository_to_db.py +110 -0
- simtools/applications/db_add_value_from_json_to_db.py +2 -11
- simtools/applications/db_development_tools/write_array_elements_positions_to_repository.py +6 -6
- simtools/applications/db_get_array_layouts_from_db.py +3 -1
- simtools/applications/db_get_file_from_db.py +11 -12
- simtools/applications/db_get_parameter_from_db.py +44 -32
- simtools/applications/derive_mirror_rnda.py +10 -1
- simtools/applications/derive_photon_electron_spectrum.py +99 -0
- simtools/applications/derive_psf_parameters.py +1 -1
- simtools/applications/generate_array_config.py +18 -22
- simtools/applications/generate_regular_arrays.py +24 -21
- simtools/applications/generate_simtel_array_histograms.py +11 -48
- simtools/applications/plot_array_layout.py +3 -1
- simtools/applications/plot_tabular_data.py +84 -0
- simtools/applications/production_generate_simulation_config.py +25 -7
- simtools/applications/production_scale_events.py +3 -4
- simtools/applications/simulate_light_emission.py +2 -2
- simtools/applications/simulate_prod.py +25 -60
- simtools/applications/simulate_prod_htcondor_generator.py +95 -0
- simtools/applications/submit_data_from_external.py +12 -4
- simtools/applications/submit_model_parameter_from_external.py +8 -6
- simtools/applications/validate_camera_efficiency.py +3 -3
- simtools/applications/validate_camera_fov.py +3 -7
- simtools/applications/validate_cumulative_psf.py +3 -7
- simtools/applications/validate_file_using_schema.py +38 -24
- simtools/applications/validate_optics.py +3 -4
- simtools/{camera_efficiency.py → camera/camera_efficiency.py} +1 -4
- simtools/camera/single_photon_electron_spectrum.py +168 -0
- simtools/configuration/commandline_parser.py +14 -13
- simtools/configuration/configurator.py +6 -19
- simtools/constants.py +10 -3
- simtools/corsika/corsika_config.py +8 -7
- simtools/corsika/corsika_histograms.py +1 -1
- simtools/data_model/data_reader.py +0 -3
- simtools/data_model/metadata_collector.py +21 -4
- simtools/data_model/metadata_model.py +8 -111
- simtools/data_model/model_data_writer.py +18 -64
- simtools/data_model/schema.py +213 -0
- simtools/data_model/validate_data.py +73 -51
- simtools/db/db_handler.py +395 -790
- simtools/db/db_model_upload.py +139 -0
- simtools/io_operations/hdf5_handler.py +54 -24
- simtools/io_operations/legacy_data_handler.py +61 -0
- simtools/job_execution/htcondor_script_generator.py +133 -0
- simtools/job_execution/job_manager.py +77 -50
- simtools/layout/array_layout.py +33 -28
- simtools/model/array_model.py +13 -7
- simtools/model/camera.py +4 -2
- simtools/model/model_parameter.py +61 -63
- simtools/model/site_model.py +3 -3
- simtools/production_configuration/calculate_statistical_errors_grid_point.py +119 -144
- simtools/production_configuration/event_scaler.py +7 -17
- simtools/production_configuration/generate_simulation_config.py +5 -32
- simtools/production_configuration/interpolation_handler.py +8 -11
- simtools/ray_tracing/mirror_panel_psf.py +47 -27
- simtools/runners/corsika_runner.py +14 -3
- simtools/runners/corsika_simtel_runner.py +3 -1
- simtools/runners/runner_services.py +3 -3
- simtools/runners/simtel_runner.py +27 -8
- simtools/schemas/input/MST_mirror_2f_measurements.schema.yml +39 -0
- simtools/schemas/input/single_pe_spectrum.schema.yml +38 -0
- simtools/schemas/integration_tests_config.metaschema.yml +23 -3
- simtools/schemas/model_parameter.metaschema.yml +95 -2
- simtools/schemas/model_parameter_and_data_schema.metaschema.yml +2 -0
- simtools/schemas/model_parameters/array_element_position_utm.schema.yml +1 -1
- simtools/schemas/model_parameters/array_window.schema.yml +37 -0
- simtools/schemas/model_parameters/asum_clipping.schema.yml +0 -4
- simtools/schemas/model_parameters/channels_per_chip.schema.yml +1 -1
- simtools/schemas/model_parameters/corsika_iact_io_buffer.schema.yml +2 -2
- simtools/schemas/model_parameters/dsum_clipping.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_ignore_below.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_offset.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_pedsub.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_pre_clipping.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_prescale.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_presum_max.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_presum_shift.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_shaping.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_shaping_renormalize.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_threshold.schema.yml +0 -2
- simtools/schemas/model_parameters/dsum_zero_clip.schema.yml +0 -2
- simtools/schemas/model_parameters/effective_focal_length.schema.yml +31 -1
- simtools/schemas/model_parameters/fadc_compensate_pedestal.schema.yml +1 -1
- simtools/schemas/model_parameters/fadc_lg_compensate_pedestal.schema.yml +1 -1
- simtools/schemas/model_parameters/fadc_noise.schema.yml +3 -3
- simtools/schemas/model_parameters/fake_mirror_list.schema.yml +33 -0
- simtools/schemas/model_parameters/laser_photons.schema.yml +2 -2
- simtools/schemas/model_parameters/secondary_mirror_degraded_reflection.schema.yml +1 -1
- simtools/schemas/production_configuration_metrics.schema.yml +68 -0
- simtools/schemas/production_tables.schema.yml +41 -0
- simtools/simtel/simtel_config_writer.py +5 -6
- simtools/simtel/simtel_io_histogram.py +32 -67
- simtools/simtel/simtel_io_histograms.py +15 -30
- simtools/simtel/simtel_table_reader.py +410 -0
- simtools/simtel/simulator_array.py +2 -1
- simtools/simtel/simulator_camera_efficiency.py +11 -4
- simtools/simtel/simulator_light_emission.py +5 -3
- simtools/simtel/simulator_ray_tracing.py +2 -2
- simtools/simulator.py +80 -33
- simtools/testing/configuration.py +12 -8
- simtools/testing/helpers.py +9 -16
- simtools/testing/validate_output.py +152 -68
- simtools/utils/general.py +149 -12
- simtools/utils/names.py +25 -21
- simtools/utils/value_conversion.py +9 -1
- simtools/visualization/plot_tables.py +106 -0
- simtools/visualization/visualize.py +43 -5
- simtools/applications/db_add_model_parameters_from_repository_to_db.py +0 -184
- simtools/db/db_array_elements.py +0 -130
- simtools/db/db_from_repo_handler.py +0 -106
- {gammasimtools-0.8.2.dist-info → gammasimtools-0.10.0.dist-info}/LICENSE +0 -0
- {gammasimtools-0.8.2.dist-info → gammasimtools-0.10.0.dist-info}/top_level.txt +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"""Generate run scripts and directories for CORSIKA simulations."""
|
|
2
2
|
|
|
3
3
|
import logging
|
|
4
|
-
import
|
|
4
|
+
import stat
|
|
5
5
|
from pathlib import Path
|
|
6
6
|
|
|
7
7
|
from simtools.io_operations import io_handler
|
|
@@ -99,6 +99,15 @@ class CorsikaRunner:
|
|
|
99
99
|
file_type="config_tmp", run_number=self.corsika_config.run_number
|
|
100
100
|
)
|
|
101
101
|
corsika_input_tmp_file = self._directory["inputs"].joinpath(corsika_input_tmp_name)
|
|
102
|
+
# CORSIKA log file naming (temporary and final)
|
|
103
|
+
corsika_log_tmp_file = (
|
|
104
|
+
self._directory["data"]
|
|
105
|
+
.joinpath(f"run{self.corsika_config.run_number:06}")
|
|
106
|
+
.joinpath(f"run{self.corsika_config.run_number}.log")
|
|
107
|
+
)
|
|
108
|
+
corsika_log_file = self.get_file_name(
|
|
109
|
+
file_type="corsika_log", run_number=self.corsika_config.run_number
|
|
110
|
+
)
|
|
102
111
|
|
|
103
112
|
if use_pfp:
|
|
104
113
|
pfp_command = self._get_pfp_command(corsika_input_tmp_file, corsika_input_file)
|
|
@@ -138,11 +147,13 @@ class CorsikaRunner:
|
|
|
138
147
|
file.write(f"cp {corsika_input_file} {corsika_input_tmp_file}")
|
|
139
148
|
file.write("\n# Running corsika_autoinputs\n")
|
|
140
149
|
file.write(autoinputs_command)
|
|
150
|
+
file.write("\n# Moving log files to the corsika log directory\n")
|
|
151
|
+
file.write(f"gzip {corsika_log_tmp_file}\n")
|
|
152
|
+
file.write(f"mv -v {corsika_log_tmp_file}.gz {corsika_log_file}\n")
|
|
141
153
|
|
|
142
154
|
file.write('\necho "RUNTIME: $SECONDS"\n')
|
|
143
155
|
|
|
144
|
-
|
|
145
|
-
|
|
156
|
+
script_file_path.chmod(script_file_path.stat().st_mode | stat.S_IXUSR | stat.S_IXGRP)
|
|
146
157
|
return script_file_path
|
|
147
158
|
|
|
148
159
|
def get_resources(self, run_number=None):
|
|
@@ -6,6 +6,7 @@ from pathlib import Path
|
|
|
6
6
|
|
|
7
7
|
from simtools.runners.corsika_runner import CorsikaRunner
|
|
8
8
|
from simtools.simtel.simulator_array import SimulatorArray
|
|
9
|
+
from simtools.utils.general import clear_default_sim_telarray_cfg_directories
|
|
9
10
|
|
|
10
11
|
__all__ = ["CorsikaSimtelRunner"]
|
|
11
12
|
|
|
@@ -197,7 +198,8 @@ class CorsikaSimtelRunner:
|
|
|
197
198
|
)
|
|
198
199
|
command += f" | gzip > {_log_file} 2>&1 || exit"
|
|
199
200
|
|
|
200
|
-
|
|
201
|
+
# Remove the default sim_telarray configuration directories
|
|
202
|
+
return clear_default_sim_telarray_cfg_directories(command)
|
|
201
203
|
|
|
202
204
|
def get_file_name(self, simulation_software=None, file_type=None, run_number=None, mode=None):
|
|
203
205
|
"""
|
|
@@ -163,6 +163,7 @@ class RunnerServices:
|
|
|
163
163
|
log_suffixes = {
|
|
164
164
|
"log": ".log.gz",
|
|
165
165
|
"histogram": ".hdata.zst",
|
|
166
|
+
"corsika_log": ".corsika.log.gz",
|
|
166
167
|
}
|
|
167
168
|
return self.directory["logs"].joinpath(f"{file_name}{log_suffixes[file_type]}")
|
|
168
169
|
|
|
@@ -187,7 +188,6 @@ class RunnerServices:
|
|
|
187
188
|
data_suffixes = {
|
|
188
189
|
"output": ".zst",
|
|
189
190
|
"corsika_output": ".zst",
|
|
190
|
-
"corsika_log": ".log",
|
|
191
191
|
"simtel_output": ".simtel.zst",
|
|
192
192
|
}
|
|
193
193
|
run_dir = self._get_run_number_string(run_number)
|
|
@@ -245,10 +245,10 @@ class RunnerServices:
|
|
|
245
245
|
"""
|
|
246
246
|
file_name = self._get_file_basename(run_number)
|
|
247
247
|
|
|
248
|
-
if file_type in ["log", "histogram"]:
|
|
248
|
+
if file_type in ["log", "histogram", "corsika_log"]:
|
|
249
249
|
return self._get_log_file_path(file_type, file_name)
|
|
250
250
|
|
|
251
|
-
if file_type in ["output", "corsika_output", "
|
|
251
|
+
if file_type in ["output", "corsika_output", "simtel_output"]:
|
|
252
252
|
return self._get_data_file_path(file_type, file_name, run_number)
|
|
253
253
|
|
|
254
254
|
if file_type in ("sub_log", "sub_script"):
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
"""Base class for running sim_telarray simulations."""
|
|
2
2
|
|
|
3
3
|
import logging
|
|
4
|
-
import
|
|
4
|
+
import stat
|
|
5
|
+
import subprocess
|
|
5
6
|
from pathlib import Path
|
|
6
7
|
|
|
7
8
|
import simtools.utils.general as gen
|
|
@@ -96,7 +97,7 @@ class SimtelRunner:
|
|
|
96
97
|
|
|
97
98
|
file.write('\necho "RUNTIME: $SECONDS"\n')
|
|
98
99
|
|
|
99
|
-
|
|
100
|
+
script_file_path.chmod(script_file_path.stat().st_mode | stat.S_IXUSR | stat.S_IXGRP)
|
|
100
101
|
return script_file_path
|
|
101
102
|
|
|
102
103
|
def run(self, test=False, input_file=None, run_number=None):
|
|
@@ -114,15 +115,17 @@ class SimtelRunner:
|
|
|
114
115
|
"""
|
|
115
116
|
self._logger.debug("Running sim_telarray")
|
|
116
117
|
|
|
117
|
-
command = self._make_run_command(
|
|
118
|
+
command, stdout_file, stderr_file = self._make_run_command(
|
|
119
|
+
run_number=run_number, input_file=input_file
|
|
120
|
+
)
|
|
118
121
|
|
|
119
122
|
if test:
|
|
120
123
|
self._logger.info(f"Running (test) with command: {command}")
|
|
121
|
-
self._run_simtel_and_check_output(command)
|
|
124
|
+
self._run_simtel_and_check_output(command, stdout_file, stderr_file)
|
|
122
125
|
else:
|
|
123
126
|
self._logger.debug(f"Running ({self.runs_per_set}x) with command: {command}")
|
|
124
127
|
for _ in range(self.runs_per_set):
|
|
125
|
-
self._run_simtel_and_check_output(command)
|
|
128
|
+
self._run_simtel_and_check_output(command, stdout_file, stderr_file)
|
|
126
129
|
|
|
127
130
|
self._check_run_result(run_number=run_number)
|
|
128
131
|
|
|
@@ -148,7 +151,7 @@ class SimtelRunner:
|
|
|
148
151
|
self._logger.error(msg)
|
|
149
152
|
raise SimtelExecutionError(msg)
|
|
150
153
|
|
|
151
|
-
def _run_simtel_and_check_output(self, command):
|
|
154
|
+
def _run_simtel_and_check_output(self, command, stdout_file, stderr_file):
|
|
152
155
|
"""
|
|
153
156
|
Run the sim_telarray command and check the exit code.
|
|
154
157
|
|
|
@@ -157,8 +160,24 @@ class SimtelRunner:
|
|
|
157
160
|
SimtelExecutionError
|
|
158
161
|
if run was not successful.
|
|
159
162
|
"""
|
|
160
|
-
if
|
|
163
|
+
stdout_file = stdout_file if stdout_file else "/dev/null"
|
|
164
|
+
stderr_file = stderr_file if stderr_file else "/dev/null"
|
|
165
|
+
with (
|
|
166
|
+
open(f"{stdout_file}", "w", encoding="utf-8") as stdout,
|
|
167
|
+
open(f"{stderr_file}", "w", encoding="utf-8") as stderr,
|
|
168
|
+
):
|
|
169
|
+
result = subprocess.run(
|
|
170
|
+
command,
|
|
171
|
+
shell=True,
|
|
172
|
+
text=True,
|
|
173
|
+
stdout=stdout,
|
|
174
|
+
stderr=stderr,
|
|
175
|
+
)
|
|
176
|
+
|
|
177
|
+
if result.returncode != 0:
|
|
178
|
+
self._logger.error(result.stderr)
|
|
161
179
|
self._raise_simtel_error()
|
|
180
|
+
return result.returncode
|
|
162
181
|
|
|
163
182
|
def _make_run_command(self, run_number=None, input_file=None):
|
|
164
183
|
self._logger.debug(
|
|
@@ -167,7 +186,7 @@ class SimtelRunner:
|
|
|
167
186
|
)
|
|
168
187
|
input_file = input_file if input_file else "nofile"
|
|
169
188
|
run_number = run_number if run_number else 1
|
|
170
|
-
return f"{input_file}-{run_number}"
|
|
189
|
+
return f"{input_file}-{run_number}", None, None
|
|
171
190
|
|
|
172
191
|
@staticmethod
|
|
173
192
|
def get_config_option(par, value=None, weak_option=False):
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
%YAML 1.2
|
|
2
|
+
---
|
|
3
|
+
title: Schema for mirror panel 2F measurements
|
|
4
|
+
version: 0.1.0
|
|
5
|
+
meta_schema: simpipe-schema
|
|
6
|
+
meta_schema_url: https://raw.githubusercontent.com/gammasim/simtools/main/src/simtools/schemas/model_parameter_and_data_schema.metaschema.yml
|
|
7
|
+
meta_schema_version: 0.1.0
|
|
8
|
+
name: mirror_2f_measurement
|
|
9
|
+
description: |-
|
|
10
|
+
Mirror panel 2F measurements determining
|
|
11
|
+
panel radius and panel PSF.
|
|
12
|
+
data:
|
|
13
|
+
- type: data_table
|
|
14
|
+
table_columns:
|
|
15
|
+
- name: mirror_panel_id
|
|
16
|
+
description: |-
|
|
17
|
+
Mirror panel ID.
|
|
18
|
+
required: true
|
|
19
|
+
unit: dimensionless
|
|
20
|
+
type: string
|
|
21
|
+
- name: mirror_curvature_radius
|
|
22
|
+
description: |-
|
|
23
|
+
Mirror panel curvature radius.
|
|
24
|
+
required: true
|
|
25
|
+
unit: cm
|
|
26
|
+
type: float64
|
|
27
|
+
- name: psf
|
|
28
|
+
description: |-
|
|
29
|
+
Spot size of mirror panel PSF at nominal distance.
|
|
30
|
+
required: true
|
|
31
|
+
unit: cm
|
|
32
|
+
type: float64
|
|
33
|
+
- name: psf_opt
|
|
34
|
+
description: |-
|
|
35
|
+
Spot size of mirror panel PSF
|
|
36
|
+
(best value, not at nominal distance).
|
|
37
|
+
required: false
|
|
38
|
+
unit: cm
|
|
39
|
+
type: float64
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
%YAML 1.2
|
|
2
|
+
---
|
|
3
|
+
title: Schema for single photon electron spectrum
|
|
4
|
+
version: 0.1.0
|
|
5
|
+
meta_schema: simpipe-schema
|
|
6
|
+
meta_schema_url: https://raw.githubusercontent.com/gammasim/simtools/main/src/simtools/schemas/model_parameter_and_data_schema.metaschema.yml
|
|
7
|
+
meta_schema_version: 0.1.0
|
|
8
|
+
name: single_pe_spectrum
|
|
9
|
+
description: |-
|
|
10
|
+
Single photo-electron response as a function of signal amplitude.
|
|
11
|
+
May include prompt, prompt plus afterpulse, or afterpulse response.
|
|
12
|
+
data:
|
|
13
|
+
- type: data_table
|
|
14
|
+
table_columns:
|
|
15
|
+
- name: amplitude
|
|
16
|
+
description: |-
|
|
17
|
+
Signal amplitude (p.e.)
|
|
18
|
+
required: true
|
|
19
|
+
unit: dimensionless
|
|
20
|
+
type: float64
|
|
21
|
+
- name: frequency (prompt)
|
|
22
|
+
description: |-
|
|
23
|
+
Single photo-electron response (prompt)
|
|
24
|
+
required: false
|
|
25
|
+
unit: dimensionless
|
|
26
|
+
type: float64
|
|
27
|
+
- name: frequency (afterpulsing)
|
|
28
|
+
description: |-
|
|
29
|
+
Single photo-electron response (afterpulsing)
|
|
30
|
+
required: false
|
|
31
|
+
unit: dimensionless
|
|
32
|
+
type: float64
|
|
33
|
+
- name: frequency (prompt+afterpulsing)
|
|
34
|
+
description: |-
|
|
35
|
+
Single photo-electron response (prompt+afterpulsing)
|
|
36
|
+
required: false
|
|
37
|
+
unit: dimensionless
|
|
38
|
+
type: float64
|
|
@@ -3,7 +3,7 @@ $schema: http://json-schema.org/draft-06/schema#
|
|
|
3
3
|
$ref: '#/definitions/SimtoolsIntegrationTestConfiguration'
|
|
4
4
|
title: SimPipe integration test configuration metaschema
|
|
5
5
|
description: YAML representation of integration test configuration metaschema
|
|
6
|
-
version: 0.
|
|
6
|
+
version: 0.2.0
|
|
7
7
|
name: integration_tests_config.metaschema
|
|
8
8
|
type: object
|
|
9
9
|
additionalProperties: false
|
|
@@ -60,6 +60,20 @@ definitions:
|
|
|
60
60
|
description: |
|
|
61
61
|
"Path of output file tested to be generated by integration test."
|
|
62
62
|
type: string
|
|
63
|
+
TEST_OUTPUT_FILES:
|
|
64
|
+
type: array
|
|
65
|
+
items:
|
|
66
|
+
type: object
|
|
67
|
+
properties:
|
|
68
|
+
PATH_DESCRIPTOR:
|
|
69
|
+
type: string
|
|
70
|
+
FILE:
|
|
71
|
+
type: string
|
|
72
|
+
EXPECTED_OUTPUT:
|
|
73
|
+
description: |
|
|
74
|
+
"Expected output of integration test."
|
|
75
|
+
type: object
|
|
76
|
+
required: ["PATH_DESCRIPTOR", "FILE"]
|
|
63
77
|
FILE_TYPE:
|
|
64
78
|
description: |
|
|
65
79
|
"Expected file type of output file generated by integration test."
|
|
@@ -68,10 +82,16 @@ definitions:
|
|
|
68
82
|
description: |
|
|
69
83
|
"Reference file used for comparison."
|
|
70
84
|
type: string
|
|
71
|
-
|
|
85
|
+
TEST_SIMTEL_CFG_FILES:
|
|
72
86
|
description: |
|
|
73
|
-
"
|
|
87
|
+
"Reference file used for comparison of sim_telarray configuration files."
|
|
74
88
|
type: object
|
|
89
|
+
additionalProperties: false
|
|
90
|
+
patternProperties:
|
|
91
|
+
"^[0-9]+\\.[0-9]+\\.[0-9]+$": # Semantic versioning pattern (e.g., "5.0.0", "6.0.0")
|
|
92
|
+
type: string
|
|
93
|
+
description: Path to the configuration file for the given version.
|
|
94
|
+
minProperties: 1
|
|
75
95
|
TOLERANCE:
|
|
76
96
|
description: "Allowed tolerance for floating point comparison."
|
|
77
97
|
type: number
|
|
@@ -2,12 +2,104 @@
|
|
|
2
2
|
$schema: http://json-schema.org/draft-06/schema#
|
|
3
3
|
$ref: '#/definitions/SimtoolsModelParameters'
|
|
4
4
|
title: SimPipe DB Model Parameter Metaschema
|
|
5
|
-
description:
|
|
6
|
-
|
|
5
|
+
description: |
|
|
6
|
+
YAML representation of db model parameter metaschema
|
|
7
|
+
(based on simulation model DB).
|
|
8
|
+
version: 0.2.0
|
|
7
9
|
name: modelparameter.metaschema
|
|
8
10
|
type: object
|
|
9
11
|
additionalProperties: false
|
|
10
12
|
|
|
13
|
+
definitions:
|
|
14
|
+
SimtoolsModelParameters:
|
|
15
|
+
description: ""
|
|
16
|
+
type: object
|
|
17
|
+
properties:
|
|
18
|
+
_id:
|
|
19
|
+
type: string
|
|
20
|
+
description: "DB unique identifier."
|
|
21
|
+
entry_date:
|
|
22
|
+
type: string
|
|
23
|
+
description: "Value entry date."
|
|
24
|
+
file:
|
|
25
|
+
type: boolean
|
|
26
|
+
description: "This parameter is a file."
|
|
27
|
+
instrument:
|
|
28
|
+
type:
|
|
29
|
+
- string
|
|
30
|
+
- "null"
|
|
31
|
+
description: "Associated instrument."
|
|
32
|
+
site:
|
|
33
|
+
type:
|
|
34
|
+
- string
|
|
35
|
+
- "null"
|
|
36
|
+
description: "Associated CTAO site."
|
|
37
|
+
enum:
|
|
38
|
+
- North
|
|
39
|
+
- South
|
|
40
|
+
- null
|
|
41
|
+
type:
|
|
42
|
+
type: string
|
|
43
|
+
description: "Data type"
|
|
44
|
+
enum:
|
|
45
|
+
- boolean
|
|
46
|
+
- dict
|
|
47
|
+
- double
|
|
48
|
+
- file
|
|
49
|
+
- float64
|
|
50
|
+
- int
|
|
51
|
+
- int64
|
|
52
|
+
- string
|
|
53
|
+
- uint
|
|
54
|
+
- uint32
|
|
55
|
+
- uint64
|
|
56
|
+
unit:
|
|
57
|
+
anyOf:
|
|
58
|
+
- type: string
|
|
59
|
+
- type: "null"
|
|
60
|
+
description: "Unit of the parameter."
|
|
61
|
+
value:
|
|
62
|
+
anyOf:
|
|
63
|
+
- type: boolean
|
|
64
|
+
- type: number
|
|
65
|
+
- type: string
|
|
66
|
+
- type: "null"
|
|
67
|
+
- type: array
|
|
68
|
+
description: "Value of the parameter."
|
|
69
|
+
parameter_version:
|
|
70
|
+
anyOf:
|
|
71
|
+
- type: string
|
|
72
|
+
description: "Parameter version."
|
|
73
|
+
schema_version:
|
|
74
|
+
anyOf:
|
|
75
|
+
- type: string
|
|
76
|
+
description: "Metaschema version."
|
|
77
|
+
unique_id:
|
|
78
|
+
anyOf:
|
|
79
|
+
- type: string
|
|
80
|
+
- type: "null"
|
|
81
|
+
description: "Unique ID of parameter definition."
|
|
82
|
+
required:
|
|
83
|
+
- file
|
|
84
|
+
- instrument
|
|
85
|
+
- parameter_version
|
|
86
|
+
- schema_version
|
|
87
|
+
- site
|
|
88
|
+
- type
|
|
89
|
+
- unit
|
|
90
|
+
- value
|
|
91
|
+
...
|
|
92
|
+
---
|
|
93
|
+
$schema: http://json-schema.org/draft-06/schema#
|
|
94
|
+
$ref: '#/definitions/SimtoolsModelParameters'
|
|
95
|
+
title: SimPipe DB Model Parameter Metaschema
|
|
96
|
+
description: |
|
|
97
|
+
YAML representation of db model parameter metaschema
|
|
98
|
+
(based on model_parameters DB).
|
|
99
|
+
version: 0.1.0
|
|
100
|
+
name: modelparameter.metaschema
|
|
101
|
+
type: object
|
|
102
|
+
additionalProperties: false
|
|
11
103
|
|
|
12
104
|
definitions:
|
|
13
105
|
SimtoolsModelParameters:
|
|
@@ -48,6 +140,7 @@ definitions:
|
|
|
48
140
|
- boolean
|
|
49
141
|
- double
|
|
50
142
|
- int
|
|
143
|
+
- int64
|
|
51
144
|
- string
|
|
52
145
|
- uint
|
|
53
146
|
- file
|
|
@@ -25,6 +25,7 @@ definitions:
|
|
|
25
25
|
description: "name of meta schema (e.g. simpipe-schema)"
|
|
26
26
|
meta_schema_url:
|
|
27
27
|
type: string
|
|
28
|
+
format: uri
|
|
28
29
|
description: "url to meta schema definition"
|
|
29
30
|
meta_schema_version:
|
|
30
31
|
type: string
|
|
@@ -322,6 +323,7 @@ definitions:
|
|
|
322
323
|
- ValidateArrayElementCoordinates
|
|
323
324
|
- ValidateAtmosphericModel
|
|
324
325
|
- ValidateCameraChargeResponse
|
|
326
|
+
- ValidateCameraEfficiency
|
|
325
327
|
- ValidateCameraGainsAndEfficiency
|
|
326
328
|
- ValidateCameraGeometry
|
|
327
329
|
- ValidateCameraLinearity
|
|
@@ -7,7 +7,7 @@ meta_schema_url: https://raw.githubusercontent.com/gammasim/simtools/main/src/si
|
|
|
7
7
|
meta_schema_version: 0.1.0
|
|
8
8
|
name: array_element_position_utm
|
|
9
9
|
description: |-
|
|
10
|
-
Position and
|
|
10
|
+
Position and altitude of an array element (e.g., a telescope) in UTM coordinates.
|
|
11
11
|
short_description: UTM coordinate position of an array element.
|
|
12
12
|
data:
|
|
13
13
|
- type: double
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
%YAML 1.2
|
|
2
|
+
---
|
|
3
|
+
title: Schema for array_window model parameter
|
|
4
|
+
version: 0.1.0
|
|
5
|
+
meta_schema: simpipe-schema
|
|
6
|
+
meta_schema_url: https://raw.githubusercontent.com/gammasim/simtools/main/src/simtools/schemas/model_parameter_and_data_schema.metaschema.yml
|
|
7
|
+
meta_schema_version: 0.1.0
|
|
8
|
+
name: array_window
|
|
9
|
+
description: |-
|
|
10
|
+
Length of a coincidence window of the default stereo trigger,
|
|
11
|
+
after correction of fixed (cable length, focal length, etc.)
|
|
12
|
+
and variable (view direction) delays.
|
|
13
|
+
short_description: |-
|
|
14
|
+
Length of a coincidence window of the default stereo trigger.
|
|
15
|
+
data:
|
|
16
|
+
- type: double
|
|
17
|
+
unit: ns
|
|
18
|
+
default: 1000.
|
|
19
|
+
instrument:
|
|
20
|
+
class: Camera
|
|
21
|
+
type:
|
|
22
|
+
- LSTN
|
|
23
|
+
- LSTS
|
|
24
|
+
- MSTN
|
|
25
|
+
- MSTS
|
|
26
|
+
- SSTS
|
|
27
|
+
- SCTS
|
|
28
|
+
activity:
|
|
29
|
+
setting:
|
|
30
|
+
- SetParameterFromExternal
|
|
31
|
+
validation:
|
|
32
|
+
- ValidateParameterByExpert
|
|
33
|
+
- ValidateTriggerPerformance
|
|
34
|
+
source:
|
|
35
|
+
- Initial instrument setup
|
|
36
|
+
simulation_software:
|
|
37
|
+
- name: sim_telarray
|
|
@@ -8,7 +8,7 @@ meta_schema_version: 0.1.0
|
|
|
8
8
|
name: channels_per_chip
|
|
9
9
|
description: |-
|
|
10
10
|
Number of channels per readout chip.
|
|
11
|
-
Potentially useful for
|
|
11
|
+
Potentially useful for cross-talk calculations.
|
|
12
12
|
short_description: Number of channels per readout chip.
|
|
13
13
|
data:
|
|
14
14
|
- type: uint
|
|
@@ -33,12 +33,42 @@ short_description: |-
|
|
|
33
33
|
Effective focal length.
|
|
34
34
|
Only to be used for image analysis, has no effect on the simulation.
|
|
35
35
|
data:
|
|
36
|
-
-
|
|
36
|
+
- description: |-
|
|
37
|
+
Mean effective length for all directions of incidence.
|
|
38
|
+
type: double
|
|
37
39
|
unit: cm
|
|
38
40
|
default: 0.0
|
|
39
41
|
allowed_range:
|
|
40
42
|
min: 0.0
|
|
41
43
|
max: 10000.0
|
|
44
|
+
- description: |-
|
|
45
|
+
Effective length for incidence directions in mirror/camera x-z plane
|
|
46
|
+
(if non-zero).
|
|
47
|
+
type: double
|
|
48
|
+
unit: cm
|
|
49
|
+
default: 0.0
|
|
50
|
+
allowed_range:
|
|
51
|
+
min: 0.0
|
|
52
|
+
max: 10000.0
|
|
53
|
+
- description: |-
|
|
54
|
+
Effective length for incidence directions in mirror/camera y-z plane
|
|
55
|
+
(if non-zero).
|
|
56
|
+
type: double
|
|
57
|
+
unit: cm
|
|
58
|
+
default: 0.0
|
|
59
|
+
allowed_range:
|
|
60
|
+
min: 0.0
|
|
61
|
+
max: 10000.0
|
|
62
|
+
- description: |-
|
|
63
|
+
Any displacement along x in the focal plane from asymmetric PSF behavior.
|
|
64
|
+
type: double
|
|
65
|
+
unit: cm
|
|
66
|
+
default: 0.0
|
|
67
|
+
- description: |-
|
|
68
|
+
Any displacement along y in the focal plane from asymmetric PSF behavior.
|
|
69
|
+
type: double
|
|
70
|
+
unit: cm
|
|
71
|
+
default: 0.0
|
|
42
72
|
instrument:
|
|
43
73
|
class: Structure
|
|
44
74
|
type:
|