forked from cta-observatory/ctapipe
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstrument_info.py
More file actions
27 lines (21 loc) · 837 Bytes
/
Copy pathinstrument_info.py
File metadata and controls
27 lines (21 loc) · 837 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
"""
Example of showing some information about the instrumental description
"""
from ctapipe.io import event_source
from ctapipe.utils import get_dataset_path
if __name__ == '__main__':
# load up one event so that we get the instrument info
infile = get_dataset_path("gamma_test.simtel.gz")
with event_source(infile) as source:
gsource = (x for x in source)
event = next(gsource)
print("------ Input: ", infile)
subarray = event.inst.subarray
print("\n---------- Subarray Info: -----------")
subarray.info()
print("\n---------- Subarray Table:-----------")
print(subarray.to_table())
print("\n---------- Subarray Optics:----------")
print(subarray.to_table(kind='optics'))
print("\n---------- Mirror Area: -------------")
print(subarray.tel[1].optics.mirror_area)