MAJIS ITL reader and exporter#
from majis import read_itl, save_itl
Juice instrument timeline files (ITL) come with two flavors, one in plain text file (a.k.a. EPS) and one in JSON format. Both files should contains the same logic, a description on of the observation blocks, however they are not strictly the same.
In this package we try to simplify as much as possible the reader and writer of these files.
Load absolute time ITL as EventsDict#
Load of an ITL file (either EPS or JSON) will regenerate a EventsDict object that will group the observations based on their name:
itl_abs = read_itl('ITL_absolute_time.json')
itl_abs
| event | # | t_start | t_stop | |
|---|---|---|---|---|
| 0 | MAJ_JUP_DISK_SCAN | 2 | 2032-09-23 | 2032-09-23 |
itl_abs['MAJ_JUP_DISK_SCAN']
| OBS_KEY | OBS_NAME | INSTRUMENT | TYPE | OBSERVATION_TYPE | TARGET | POINTING | POINTING_DESIGNER | t_start | t_end | SCENARIO | CU_TREP | CU_FRAME | BINNING | PPE | START_ROW_VIS | MIRROR_FLAG | START_ANGLE | STOP_ANGLE | TICK_FREQ | SYNCHRONOUS | START_SCAN_SPEED | STOP_SCAN_SPEED | PRIME | ITL | COMMENTS | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | MAJ_JUP_DISK_SCAN | MAJ_JUP_DISK_SCAN_001 | MAJIS | OBSERVATION | PRIME | JUPITER | MAJIS | True | 2032-09-23T05:15:45.000Z | 2032-09-23T05:26:15.000Z | S007_01 | 500 | 300 | 1 | 400 | 100 | ENABLE | -1.31051 | 0.10202 | 1MHz | 0 | 0.0022421078 | 0.0022421078 | True | ITL_absolute_time.json | This comment will be included in the exported ITL file. |
| 1 | MAJ_JUP_DISK_SCAN | MAJ_JUP_DISK_SCAN_002 | MAJIS | OBSERVATION | RIDER | JUPITER | False | 2032-09-23T06:09:45.000Z | 2032-09-23T06:20:15.000Z | S007_01 | 2100 | 300 | 2 | 400 | 372 | ENABLE | 1.32935 | -0.08318 | 8MHz | 3 | -0.0022421078 | -0.0022421078 | False | ITL_absolute_time.json |
It is also possible to load the same file in text/EPS format:
itl_abs_eps = read_itl('absolute_time.itl')
itl_abs_eps
| event | # | t_start | t_stop | |
|---|---|---|---|---|
| 0 | MAJ_JUP_DISK_SCAN | 2 | 2032-09-23 | 2032-09-23 |
itl_abs_eps['MAJ_JUP_DISK_SCAN']
| t_start | t_end | INSTRUMENT | SCENARIO | OBS_NAME | TARGET | CU_TREP | CU_FRAME | BINNING | PPE | START_ROW_VIS | START_ANGLE | STOP_ANGLE | SYNCHRONOUS | START_SCAN_SPEED | STOP_SCAN_SPEED | PRIME | COMMENTS | ITL | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | 2032-09-23T05:15:45 | 2032-09-23T05:26:15 | MAJIS | S007_01 | MAJ_JUP_DISK_SCAN_001 | JUPITER | 500ms | 300 | 1 | 400 | 100 | -1.31051 | +0.10202 | 0 | +0.0022421078 | +0.0022421078 | True | MULTI WORDS COMMENT with , and ; / MULTI LINES COMMENT | absolute_time.itl |
| 1 | 2032-09-23T06:09:45 | 2032-09-23T06:20:15 | MAJIS | S007_01 | MAJ_JUP_DISK_SCAN_002 | JUPITER | 2100ms | 300 | 2 | 400 | 372 | +1.32935 | -0.08318 | +3 | -0.0022421078 | -0.0022421078 | True | absolute_time.itl |
Load relative time ITL as EventsList (as a flat list)#
Note
At the moment, only EPS file supports relative time input.
itl_rel = read_itl('relative_time.itl', refs='events.evf', flat=True)
itl_rel
| t_start | t_end | INSTRUMENT | SCENARIO | OBS_NAME | TARGET | CU_TREP | CU_FRAME | BINNING | PPE | START_ROW_VIS | START_ANGLE | STOP_ANGLE | SYNCHRONOUS | START_SCAN_SPEED | STOP_SCAN_SPEED | PRIME | COMMENTS | ITL | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | 2032-09-23T02:58:11.000 | 2032-09-23T03:01:59.900 | MAJIS | S007_01 | MAJ_JUP_DISK_SCAN_101 | JUPITER | 100ms | 109 | 1 | 64 | 436 | -0.27937 | +0.23385 | +3 | +0.0022421078 | +0.0022421078 | False | relative_time.itl | |
| 1 | 2032-09-23T03:04:34.000 | 2032-09-23T03:08:22.900 | MAJIS | S007_01 | MAJ_JUP_DISK_SCAN_102 | JUPITER | 200ms | 109 | 4 | 64 | 802 | -0.37981 | +0.13341 | +3 | +0.0022421078 | +0.0022421078 | False | relative_time.itl |
Concatenate ITL files into a single file#
save_itl('output.itl', itl_abs, itl_rel)
# MAJIS - SCENARIO=S007_01 OBS_NAME=MAJ_JUP_DISK_SCAN_101 TARGET=JUPITER CU_TREP=100ms
# MAJIS - CU_FRAME=109 BINNING=1 PPE=64 START_ROW_VIS=436 START_ANGLE=-0.27937
# MAJIS - STOP_ANGLE=+0.23385 SYNCHRONOUS=+3 START_SCAN_SPEED=+0.0022421078
# MAJIS - STOP_SCAN_SPEED=+0.0022421078
2032-09-23T02:58:11Z MAJIS OBS_START MAJ_JUP_DISK_SCAN
2032-09-23T03:01:59.900Z MAJIS OBS_END MAJ_JUP_DISK_SCAN
# MAJIS - SCENARIO=S007_01 OBS_NAME=MAJ_JUP_DISK_SCAN_102 TARGET=JUPITER CU_TREP=200ms
# MAJIS - CU_FRAME=109 BINNING=4 PPE=64 START_ROW_VIS=802 START_ANGLE=-0.37981
# MAJIS - STOP_ANGLE=+0.13341 SYNCHRONOUS=+3 START_SCAN_SPEED=+0.0022421078
# MAJIS - STOP_SCAN_SPEED=+0.0022421078
2032-09-23T03:04:34Z MAJIS OBS_START MAJ_JUP_DISK_SCAN
2032-09-23T03:08:22.900Z MAJIS OBS_END MAJ_JUP_DISK_SCAN
# MAJIS - OBS_KEY=MAJ_JUP_DISK_SCAN OBS_NAME=MAJ_JUP_DISK_SCAN_001 TYPE=OBSERVATION
# MAJIS - OBSERVATION_TYPE=PRIME TARGET=JUPITER POINTING=MAJIS POINTING_DESIGNER=True
# MAJIS - SCENARIO=S007_01 CU_TREP=500 CU_FRAME=300 BINNING=1 PPE=400 START_ROW_VIS=100
# MAJIS - MIRROR_FLAG=ENABLE START_ANGLE=-1.31051 STOP_ANGLE=0.10202 TICK_FREQ=1MHz
# MAJIS - SYNCHRONOUS=0 START_SCAN_SPEED=0.0022421078 STOP_SCAN_SPEED=0.0022421078
# MAJIS - COMMENT: This comment will be included in the exported ITL file.
2032-09-23T05:15:45Z MAJIS OBS_START MAJ_JUP_DISK_SCAN (PRIME=TRUE)
2032-09-23T05:26:15Z MAJIS OBS_END MAJ_JUP_DISK_SCAN
# MAJIS - OBS_KEY=MAJ_JUP_DISK_SCAN OBS_NAME=MAJ_JUP_DISK_SCAN_002 TYPE=OBSERVATION
# MAJIS - OBSERVATION_TYPE=RIDER TARGET=JUPITER POINTING=None POINTING_DESIGNER=False
# MAJIS - SCENARIO=S007_01 CU_TREP=2100 CU_FRAME=300 BINNING=2 PPE=400 START_ROW_VIS=372
# MAJIS - MIRROR_FLAG=ENABLE START_ANGLE=1.32935 STOP_ANGLE=-0.08318 TICK_FREQ=8MHz
# MAJIS - SYNCHRONOUS=3 START_SCAN_SPEED=-0.0022421078 STOP_SCAN_SPEED=-0.0022421078
2032-09-23T06:09:45Z MAJIS OBS_START MAJ_JUP_DISK_SCAN
2032-09-23T06:20:15Z MAJIS OBS_END MAJ_JUP_DISK_SCAN
Note
When multiple ITL are provided, they will be concatenate and ordered by increasing time.
Absolute and relative ITL are compatible.
Observation block must not overlap (can be by-pass with
overlap=True)If no relative reference is provided, the output will be in absolute time (see below for relative time).
Export ITL in JSON format#
save_itl('ITL_output.json', itl_abs)
{
"header": {
"filename": "ITL_output.json",
"creation_date": "2026-04-29T16:29:52.481Z",
"author": "docs"
},
"timeline": [
{
"name": "MAJ_JUP_DISK_SCAN",
"unique_id": "MAJ_JUP_DISK_SCAN_001",
"instrument": "MAJIS",
"type": "OBSERVATION",
"observation_type": "PRIME",
"target": "JUPITER",
"pointing": "MAJIS",
"pointing_designer": true,
"start_time": "2032-09-23T05:15:45Z",
"end_time": "2032-09-23T05:26:15Z",
"parameters": {
"scenario_id": "S007_01",
"cu_trep_ms": 500,
"nb_cu_frames_tot": 300,
"spatial_binning": 1,
"ppe": 400,
"start_row_vi": 100,
"mirror_flag": "ENABLE",
"start_angle": -1.31051,
"stop_angle": 0.10202,
"tick_freq": "1MHz",
"scanner_step_per_frame": 0,
"start_scan_speed": 0.0022421078,
"stop_scan_speed": 0.0022421078
},
"comment": "This comment will be included in the exported ITL file."
},
{
"name": "MAJ_JUP_DISK_SCAN",
"unique_id": "MAJ_JUP_DISK_SCAN_002",
"instrument": "MAJIS",
"type": "OBSERVATION",
"observation_type": "RIDER",
"target": "JUPITER",
"pointing": null,
"pointing_designer": false,
"start_time": "2032-09-23T06:09:45Z",
"end_time": "2032-09-23T06:20:15Z",
"parameters": {
"scenario_id": "S007_01",
"cu_trep_ms": 2100,
"nb_cu_frames_tot": 300,
"spatial_binning": 2,
"ppe": 400,
"start_row_vi": 372,
"mirror_flag": "ENABLE",
"start_angle": 1.32935,
"stop_angle": -0.08318,
"tick_freq": "8MHz",
"scanner_step_per_frame": 3,
"start_scan_speed": -0.0022421078,
"stop_scan_speed": -0.0022421078
},
"comment": ""
}
]
}
In the case of JSON export, the content of the ITL is checked against the SOC and MAJIS ITL schemas. For example, here, the itl_rel is missing the MIRROR_FLAG required parameter to be exported as a JSON ITL:
save_itl('ITL_output.json', itl_rel)
---------------------------------------------------------------------------
ValidationError Traceback (most recent call last)
Cell In[11], line 1
----> 1 save_itl('ITL_output.json', itl_rel)
File ~/checkouts/readthedocs.org/user_builds/majis-ops/envs/stable/lib/python3.10/site-packages/majis/itl/export.py:40, in save_itl(fout, ref, overlap, *events, **kwargs)
32 return save_itl_eps(
33 fout,
34 *events,
(...)
37 **kwargs,
38 )
39 case '.json':
---> 40 return save_itl_json(
41 fout,
42 *events,
43 ref=ref,
44 overlap=overlap,
45 **kwargs,
46 )
47 case '.csv':
48 return save_itl_csv(
49 fout,
50 *events,
(...)
53 **kwargs,
54 )
File ~/checkouts/readthedocs.org/user_builds/majis-ops/envs/stable/lib/python3.10/site-packages/majis/misc/events.py:85, in flatten_events.<locals>.wrapper(fout, overlap, *events, **kwargs)
83 """Concatenate events blocks before the calling the main function."""
84 blocks = concatenate(*events, flat=True, overlap=overlap)
---> 85 return func(fout, *blocks, **kwargs)
File ~/checkouts/readthedocs.org/user_builds/majis-ops/envs/stable/lib/python3.10/site-packages/majis/itl/json/export.py:41, in save_itl_json(fout, ref, overlap, fmt, *events)
35 content = {
36 'header': get_header(fout, fmt=fmt),
37 'timeline': [fmt_json(event) for event in events],
38 }
40 for schema in MAJIS_SCHEMAS[fmt]:
---> 41 schema.validate(content)
43 return save_file(fout, content, suffix='.json')
File ~/checkouts/readthedocs.org/user_builds/majis-ops/envs/stable/lib/python3.10/site-packages/majis/schema/schema.py:67, in JsonSchema.validate(self, content, raises_error)
65 except ValidationError as err:
66 if raises_error:
---> 67 raise err from None
69 warn(f'{self}: {err}', category=ValidationWarning, stacklevel=2)
File ~/checkouts/readthedocs.org/user_builds/majis-ops/envs/stable/lib/python3.10/site-packages/majis/schema/schema.py:64, in JsonSchema.validate(self, content, raises_error)
58 """Validate content against the JSON schema.
59
60 If ``raises_error`` is set to ``False``, a ``ValidationWarning``
61 can be reported instead of a ``ValidationError``.
62 """
63 try:
---> 64 validate(instance=content, schema=self.data)
65 except ValidationError as err:
66 if raises_error:
File ~/checkouts/readthedocs.org/user_builds/majis-ops/envs/stable/lib/python3.10/site-packages/jsonschema/validators.py:1332, in validate(instance, schema, cls, *args, **kwargs)
1330 error = exceptions.best_match(validator.iter_errors(instance))
1331 if error is not None:
-> 1332 raise error
ValidationError: 'mirror_flag' is a required property
Failed validating 'required' in schema['properties']['timeline']['items']['properties']['parameters']:
{'type': 'object',
'required': ['scenario_id',
'cu_trep_ms',
'nb_cu_frames_tot',
'spatial_binning',
'ppe',
'start_row_vi',
'mirror_flag',
'start_angle',
'stop_angle',
'tick_freq',
'scanner_step_per_frame',
'start_scan_speed',
'stop_scan_speed'],
'properties': {'mission_phase': {'type': 'string',
'description': 'JUICE mission phase '
'name (TODO: ask SOC '
'to provide '
'allowed/standard '
'names)'},
'scenario_id': {'type': 'string',
'description': 'New: scenario_id or '
"mtp, eg: 'S008_01' or "
"'ORB17' (TODO: ask SOC "
'if that will be '
'standardised)'},
'mirror_flag': {'type': 'string',
'enum': ['ENABLE', 'DISABLE'],
'description': 'If mirror '
"flag='DISABLE' (i.e. "
'no scan movement) then '
'please indicate the '
'requested fixed mirror '
'position in '
'start_angle parameter '
'(0° corresponds to '
'boresight). All other '
'scan parameters shall '
'be 0.'},
'start_angle': {'type': 'number',
'description': 'Start angle in '
'degrees'},
'start_scan_speed': {'type': 'number',
'description': ''},
'stop_scan_speed': {'type': 'number',
'description': ''},
'stop_angle': {'type': 'number',
'description': 'Stop angle in degrees'},
'tick_freq': {'type': 'string',
'enum': ['8MHz', '1MHz'],
'description': ''},
'scanner_step_per_frame': {'type': 'integer',
'enum': [-3, 0, 3],
'description': 'Scanner '
'step per '
'frame '
'(synchronous '
'flag).'},
'scanner_timetot': {'type': 'number',
'description': 'Scanner total '
'time'},
'first_cu_frame_start_rel_ca': {'type': 'string',
'description': 'First '
'CU_frame '
'start '
'wrt '
'C/A. '
'(-/+)hh:mm:ss,000. '
'Scientific '
'need '
'wrt '
'C/A. '
'Parameter '
'only '
'required '
'in '
'case '
'of '
'continuous '
'acquisition '
'(nb_cu_frames_tot=65535). '
'Note: '
'use '
'the '
'decimal '
'separator '
'(either '
"',' or "
"'.') "
'defined '
'in '
'your '
'Excel '
'for '
'the '
'milliseconds.'},
'last_cu_frame_stop_rel_ca': {'type': 'string',
'description': 'First '
'CU_frame '
'stop wrt '
'C/A. '
'(-/+)hh:mm:ss,000. '
'Scientific '
'need wrt '
'C/A. '
'Parameter '
'only '
'required '
'in case '
'of '
'continuous '
'acquisition '
'(nb_cu_frames_tot=65535). '
'Note: '
'use the '
'decimal '
'separator '
'(either '
"',' or "
"'.') "
'defined '
'in your '
'Excel '
'for the '
'milliseconds.'},
'first_cu_frame_start_utc': {'type': 'string',
'description': 'First '
'CU_frame '
'start UTC '
'time.'},
'last_cu_frame_stop_utc': {'type': 'string',
'description': 'First '
'CU_frame '
'start UTC '
'stop.'},
'cu_trep_ms': {'type': 'number', 'description': ''},
'spatial_binning': {'type': 'integer',
'enum': [1, 2, 4],
'description': 'Spatial binning '
'for the CU frame: '
'1, 2 or 4.'},
'obs_duration': {'type': 'number',
'description': 'Observation duration '
'in seconds.'},
'nb_cu_frames_tot': {'type': 'integer',
'minimum': 1,
'description': 'The number of '
'Frame is '
'automatically '
're-computed by '
"'timeline2config' "
'when the Scanner '
'is used in '
'asynchronous mode '
'(Mirror '
'Flag=ENABLE and '
'Scanner step per '
'frame=0). Here '
"'nb_cu_frames_tot' "
'is used to '
'compute the data '
"volume in the 'DV "
"(Mbits)' column. "
"Put '65535' for "
'continuous '
'acquisition '
'mode.'},
'nb_cu_frames_totcomp': {'type': 'integer',
'minimum': 1,
'description': 'Re-computed '
'value as '
"'timeline2config' "
'will do in '
'case of '
'Scanner used '
'in '
'asynchronous '
'mode. Shall '
'be equal to '
"'nb_cu_frames_tot' "
'for checking '
'purpose.'},
'ppe': {'type': 'integer',
'minimum': 1,
'description': 'Pixels Per Element'},
'spectral_mapping': {'type': 'string',
'description': ' the spectral '
'mask is a part of '
'a database that '
'contains spectral '
'masks associated '
'to each type of '
'MAJIS '
'observations, '
'comment '
'récupère-t-on ce '
'fichier ? '},
'data_volume_mbits': {'type': 'number',
'minimum': 0,
'description': 'Data volume in '
'Mbits '
'(Mbits=1024*1024bits)'},
'data_rate_bit_per_sec': {'type': 'number',
'minimum': 0,
'description': 'Data rate in '
'bits per '
'second'},
'nb_binned_spectels': {'type': 'integer',
'minimum': 1,
'description': 'Number of '
'binned spectral '
'elements'},
'nb_binned_spectels_after_comp': {'type': 'integer',
'minimum': 1,
'description': 'Equivalent '
'compression '
'factor '
'for '
'all '
'the '
'bands'},
'browse_parameters': {'type': 'string',
'description': 'Browse '
'parameters file '
'name. This file '
'is a part of a '
'database that '
'contains browse '
'parameters '
'associated to '
'each type of '
'MAJIS '
'observations, '
'comment '
'récupère-t-on ce '
'fichier.'},
'image_mode': {'type': 'string',
'enum': ['Nominal', 'No process'],
'description': 'Nominal or No process'},
'dark_strategy': {'type': 'integer',
'enum': [0, 1, 2, 3],
'description': 'Dark Strategy; 0:No '
'Dark, 1: Dark '
'Before, 2: Dark '
'After, 3: Dark '
'Before + After'},
'dark_subtraction': {'type': 'string',
'enum': ['Subtracted',
'Not Subtracted'],
'description': 'Dark Subtraction; '
'Subtracted, Not '
'Subtracted'},
'cds_flag': {'type': 'string',
'enum': ['ReadReset'],
'description': 'CDS flag; ReadReset'},
'vi_flag': {'type': 'string',
'enum': ['ON', 'OFF'],
'description': 'VI flag; ON,OFF'},
'ir_flag': {'type': 'string',
'enum': ['ON', 'OFF'],
'description': 'IR flag; ON,OFF'},
'ir_readout': {'type': 'string',
'enum': ['1MHz', '100kHz'],
'description': 'IR Readout; '
'1MHz,100kHz'},
'start_row_vi': {'type': 'integer',
'default': 100,
'description': 'Start Row VI; Nominal '
'values (in physical '
'pixels): 100 for VI '
'from calibration '
'data'},
'start_row_ir': {'type': 'integer',
'default': 87,
'description': 'Start Row IR; Nominal '
'values (in physical '
'pixels): 87 for IR '
'from calibration '
'data'},
'vi_despiking_m': {'type': 'integer',
'minimum': 1,
'maximum': 12,
'description': 'Despiking strategy '
'VI (M),integer '
'between 1 and 12'},
'vi_despiking_k': {'type': 'string',
'enum': ['Lowest', 'Low'],
'description': 'VI Despiking K; '
'Despiking strategy '
'VI (K) with '
'K=Lowest or Low'},
'vi_despiking_n': {'type': 'integer',
'minimum': 1,
'maximum': 8,
'description': 'IR Despiking N; '
'Despiking strategy '
'VI (N sub), integer '
'between 1 and 8'},
'vi_tint': {'type': 'number',
'minimum': 0,
'description': 'VI Tint; VI integration '
'time (ms)'},
'vi_gain': {'type': 'integer',
'minimum': 8,
'maximum': 13,
'default': 10,
'description': 'VI Gain; VI '
'preamplification Gain, '
'Default value 10, Value '
'between 8 and 13'},
'vi_offset': {'type': 'integer',
'minimum': 0,
'maximum': 3,
'default': 1,
'description': 'VI Offset; VI detector '
'reference voltage '
'offset, Default value 1, '
'value between 0 and 3'},
'vi_npe': {'type': 'integer',
'minimum': 1,
'maximum': 16,
'description': 'VI NPE; VI PE Frame '
'binning, value between 1 '
'and 16'},
'ir_despiking_n': {'type': 'integer',
'minimum': 1,
'maximum': 8,
'description': 'IR Despiking N; '
'Despiking strategy '
'VI (N sub), integer '
'between 1 and 8'},
'ir_despiking_m': {'type': 'integer',
'minimum': 1,
'maximum': 12,
'description': 'IR Despiking M; '
'Despiking strategy '
'VI (M),integer '
'between 1 and 12'},
'ir_despiking_k': {'type': 'string',
'enum': ['Lowest', 'Low'],
'description': 'IR Despiking K; '
'Despiking strategy '
'VI (K) with '
'K=Lowest or Low'},
'ir_tint': {'type': 'number',
'minimum': 0,
'description': 'IR Tint; VI integration '
'time (ms)'},
'ir_gain': {'type': 'integer',
'minimum': 8,
'maximum': 13,
'default': 10,
'description': 'IR Gain; VI '
'preamplification Gain, '
'Default value 10, Value '
'between 8 and 13'},
'ir_offset': {'type': 'integer',
'minimum': 0,
'maximum': 3,
'default': 1,
'description': 'IR Offset; VI detector '
'reference voltage '
'offset, Default value 1, '
'value between 0 and 3'},
'ir_npe': {'type': 'integer',
'minimum': 1,
'maximum': 16,
'description': 'IR NPE; VI PE Frame '
'binning, value between 1 '
'and 16'}}}
On instance['timeline'][1]['parameters']:
{'scenario_id': 'S007_01',
'cu_trep_ms': 200,
'nb_cu_frames_tot': 109,
'spatial_binning': 4,
'ppe': 64,
'start_row_vi': 802,
'start_angle': -0.37981,
'stop_angle': 0.13341,
'scanner_step_per_frame': 3,
'start_scan_speed': 0.0022421078,
'stop_scan_speed': 0.0022421078}
Export ITL with repesct to a relative time reference:#
save_itl(
'output.itl', itl_abs, itl_rel, ref='23-SEP-2032_00:00:02 EVENT_NAME (COUNT = 1)'
)
# Relative time reference:
# 2032-09-23T00:00:02 EVENT_NAME (COUNT = 1)
# MAJIS - SCENARIO=S007_01 OBS_NAME=MAJ_JUP_DISK_SCAN_101 TARGET=JUPITER CU_TREP=100ms
# MAJIS - CU_FRAME=109 BINNING=1 PPE=64 START_ROW_VIS=436 START_ANGLE=-0.27937
# MAJIS - STOP_ANGLE=+0.23385 SYNCHRONOUS=+3 START_SCAN_SPEED=+0.0022421078
# MAJIS - STOP_SCAN_SPEED=+0.0022421078
EVENT_NAME (COUNT = 1) +000.02:58:09.000 MAJIS OBS_START MAJ_JUP_DISK_SCAN
EVENT_NAME (COUNT = 1) +000.03:01:57.900 MAJIS OBS_END MAJ_JUP_DISK_SCAN
# MAJIS - SCENARIO=S007_01 OBS_NAME=MAJ_JUP_DISK_SCAN_102 TARGET=JUPITER CU_TREP=200ms
# MAJIS - CU_FRAME=109 BINNING=4 PPE=64 START_ROW_VIS=802 START_ANGLE=-0.37981
# MAJIS - STOP_ANGLE=+0.13341 SYNCHRONOUS=+3 START_SCAN_SPEED=+0.0022421078
# MAJIS - STOP_SCAN_SPEED=+0.0022421078
EVENT_NAME (COUNT = 1) +000.03:04:32.000 MAJIS OBS_START MAJ_JUP_DISK_SCAN
EVENT_NAME (COUNT = 1) +000.03:08:20.900 MAJIS OBS_END MAJ_JUP_DISK_SCAN
# MAJIS - OBS_KEY=MAJ_JUP_DISK_SCAN OBS_NAME=MAJ_JUP_DISK_SCAN_001 TYPE=OBSERVATION
# MAJIS - OBSERVATION_TYPE=PRIME TARGET=JUPITER POINTING=MAJIS POINTING_DESIGNER=True
# MAJIS - SCENARIO=S007_01 CU_TREP=500 CU_FRAME=300 BINNING=1 PPE=400 START_ROW_VIS=100
# MAJIS - MIRROR_FLAG=ENABLE START_ANGLE=-1.31051 STOP_ANGLE=0.10202 TICK_FREQ=1MHz
# MAJIS - SYNCHRONOUS=0 START_SCAN_SPEED=0.0022421078 STOP_SCAN_SPEED=0.0022421078
# MAJIS - COMMENT: This comment will be included in the exported ITL file.
EVENT_NAME (COUNT = 1) +000.05:15:43.000 MAJIS OBS_START MAJ_JUP_DISK_SCAN (PRIME=TRUE)
EVENT_NAME (COUNT = 1) +000.05:26:13.000 MAJIS OBS_END MAJ_JUP_DISK_SCAN
# MAJIS - OBS_KEY=MAJ_JUP_DISK_SCAN OBS_NAME=MAJ_JUP_DISK_SCAN_002 TYPE=OBSERVATION
# MAJIS - OBSERVATION_TYPE=RIDER TARGET=JUPITER POINTING=None POINTING_DESIGNER=False
# MAJIS - SCENARIO=S007_01 CU_TREP=2100 CU_FRAME=300 BINNING=2 PPE=400 START_ROW_VIS=372
# MAJIS - MIRROR_FLAG=ENABLE START_ANGLE=1.32935 STOP_ANGLE=-0.08318 TICK_FREQ=8MHz
# MAJIS - SYNCHRONOUS=3 START_SCAN_SPEED=-0.0022421078 STOP_SCAN_SPEED=-0.0022421078
EVENT_NAME (COUNT = 1) +000.06:09:43.000 MAJIS OBS_START MAJ_JUP_DISK_SCAN
EVENT_NAME (COUNT = 1) +000.06:20:13.000 MAJIS OBS_END MAJ_JUP_DISK_SCAN
Export ITL to CSV#
save_itl('output.csv', itl_abs)
#OBS_NAME;OBS_START;OBS_END;OBS_KEY;INSTRUMENT;TYPE;OBSERVATION_TYPE;TARGET;POINTING;POINTING_DESIGNER;SCENARIO;CU_TREP;CU_FRAME;BINNING;PPE;START_ROW_VIS;MIRROR_FLAG;START_ANGLE;STOP_ANGLE;TICK_FREQ;SYNCHRONOUS;START_SCAN_SPEED;STOP_SCAN_SPEED;PRIME;ITL;COMMENTS
MAJ_JUP_DISK_SCAN_001;2032-09-23T05:15:45Z;2032-09-23T05:26:15Z;MAJ_JUP_DISK_SCAN;MAJIS;OBSERVATION;PRIME;JUPITER;MAJIS;True;S007_01;500;300;1;400;100;ENABLE;-1.31051;0.10202;1MHz;0;0.0022421078;0.0022421078;True;ITL_absolute_time.json;"This comment will be included in the exported ITL file."
MAJ_JUP_DISK_SCAN_002;2032-09-23T06:09:45Z;2032-09-23T06:20:15Z;MAJ_JUP_DISK_SCAN;MAJIS;OBSERVATION;RIDER;JUPITER;None;False;S007_01;2100;300;2;400;372;ENABLE;1.32935;-0.08318;8MHz;3;-0.0022421078;-0.0022421078;False;ITL_absolute_time.json;""
Export ITL to XLSM timeline#
save_itl('output.xlsm', itl_abs, ref='23-SEP-2032_00:00:02 CA_REF (COUNT = 1)')
| Event Name | Phase | block | Comments | OBS_NAME | start_time_relative_ca | stop_time_relative_ca | start_time_utc | stop_time_utc | pointing desc | MAJIS resol | prime | MAJIS ODF name | ITL name | Mirror Flag | start_angle | start_scan_speed | stop_scan_speed | Scanner step per frame | stop_angle | tick_freq | scanner_timetot (ms) | First CU_frame start wrt C/A | Last CU_frame stop wrt C/A | First CU_frame start (UTC) | Last CU_frame stop (UTC) | cu_trep_ms | spatial_binning | obs durat (sec) (w/o borders) | nb_cu_frames_tot | nb_cu_frames_tot (computed) | ppe | Spectral Mapping | Number of spectels after spectral binning | Nb of bits per spectel after compression | datarate (bits/s) | DV (Mbits) | Browse Parameters | Number of browse spectels | Nb of bits per browse spectel after compression | browse datarate (bits/s) | browse DV (Mbits) | Image Mode | Dark Strategy | Dark Subtraction | CDS flag | VI flag | IR flag | VI Readout | IR Readout | Start Row VI | Start Row IR | VI Despiking N | VI Despiking M | VI Despiking K | VI Tint | VI Gain | VI Offset | VI NPE | IR Despiking N | IR Despiking M | IR Despiking K | IR Tint | IR Gain | IR Offset | IR NPE | Power (W) | Science mode (for power estimation) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| This comment will be included in the exported ITL file. | MAJ_JUP_DISK_SCAN_001 | MAJIS | ITL_absolute_time.json | ENABLE | -1.31051 | 0.0022421078 | 0.0022421078 | 0 | 0.10202 | =IF(AND(Mirror_Flag="ENABLE",ABS(Scanner_step_per_frame)<>3), IF(start_scan_speed=stop_scan_speed, ABS( (stop_angle - start_angle) / start_scan_speed ) *1000, ABS( (stop_angle - start_angle) / (stop_scan_speed - start_scan_speed) * LN( stop_scan_speed / start_scan_speed ) ) * 1000), "N/A") | +000.05:15:43.000 | +000.05:26:13.000 | 2032-09-23T05:15:45Z | 2032-09-23T05:26:15Z | 500 | No Binning | 300 | =IF(AND(Mirror_Flag="ENABLE",ABS(Scanner_step_per_frame)<>3), INT( (scanner_timetot__ms / cu_trep_ms) + 0.5), "N/A") | 400 | =(VI_flag="ON") * VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,2,FALSE) + (IR_flag="ON") * VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,4,FALSE) | =((VI_flag="ON") * (VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,3,FALSE)*VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,2,FALSE)) + (IR_flag="ON") * (VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,5,FALSE)*VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,4,FALSE)) ) / Number_of_spectels_after_spectral_binning | =DV__Mbits/cu_trep_ms/ IF(nb_cu_frames_tot=65535, DIFF_TIME_CA_ms(First_CU_frame_start_wrt_C_A, Last_CU_frame_stop_wrt_C_A)/cu_trep_ms,nb_cu_frames_tot)*(1024*1024) | =IF(AND(nb_cu_frames_tot__computed<>"N/A",nb_cu_frames_tot<>nb_cu_frames_tot__computed), "ERROR: nb_cu_frames_tot and nb_cu_frames_tot (computed) are not equal", IF(nb_cu_frames_tot=65535, DIFF_TIME_CA_ms(First_CU_frame_start_wrt_C_A,Last_CU_frame_stop_wrt_C_A)/cu_trep_ms, nb_cu_frames_tot) * ( ppe / 2^(IF(spatial_binning="No Binning",0,IF(spatial_binning="Binning x2",1,IF(spatial_binning="Binning x4",2,"N/A")))) ) * Number_of_spectels_after_spectral_binning * Nb_of_bits_per_spectel_after_compression / (1024*1024) ) | =(VI_flag="ON") * VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,2,FALSE) + (IR_flag="ON") * VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,4,FALSE) | =IF(Number_of_browse_spectels=0,0, ((VI_flag="ON") * (VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,3,FALSE)*VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,2,FALSE)) + (IR_flag="ON") * (VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,5,FALSE)*VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,4,FALSE)) ) / Number_of_browse_spectels) | =browse_DV__Mbits / cu_trep_ms / nb_cu_frames_tot * (1024*1024) | =IF(AND(nb_cu_frames_tot__computed<>"N/A",nb_cu_frames_tot<>nb_cu_frames_tot__computed), "ERROR: nb_cu_frames_tot and nb_cu_frames_tot (computed) are not equal", IF(nb_cu_frames_tot=65535, DIFF_TIME_CA_ms(First_CU_frame_start_wrt_C_A,Last_CU_frame_stop_wrt_C_A)/cu_trep_ms, nb_cu_frames_tot) * ( ppe / 2^(IF(spatial_binning="No Binning",0,IF(spatial_binning="Binning x2",1,IF(spatial_binning="Binning x4",2,"N/A")))) ) * Number_of_browse_spectels * Nb_of_bits_per_browse_spectel_after_compression / (1024*1024) ) | 100 | =IF(AND(VI_flag="ON",IR_flag="ON"), IF( Mirror_Flag = "ENABLE", power_2ch_science_scanning, power_2ch_science_pointing), IF(OR(VI_flag="ON",IR_flag="ON"), IF( Mirror_Flag = "ENABLE", power_1ch_science_scanning, power_1ch_science_pointing), "N/A")) | =IF(AND(VI_flag="ON",IR_flag="ON"), IF( Mirror_Flag = "ENABLE", power_2ch_science_scanning_description, power_2ch_science_pointing_description), IF(AND(VI_flag="ON",IR_flag="ON"), IF( Mirror_Flag = "ENABLE", power_1ch_science_scanning_description, power_1ch_science_pointing_description), "N/A")) | |||||||||||||||||||||||||||||||||||||
| MAJ_JUP_DISK_SCAN_002 | other | ITL_absolute_time.json | ENABLE | 1.32935 | -0.0022421078 | -0.0022421078 | 3 | -0.08318 | =IF(AND(Mirror_Flag="ENABLE",ABS(Scanner_step_per_frame)<>3), IF(start_scan_speed=stop_scan_speed, ABS( (stop_angle - start_angle) / start_scan_speed ) *1000, ABS( (stop_angle - start_angle) / (stop_scan_speed - start_scan_speed) * LN( stop_scan_speed / start_scan_speed ) ) * 1000), "N/A") | +000.06:09:43.000 | +000.06:20:13.000 | 2032-09-23T06:09:45Z | 2032-09-23T06:20:15Z | 2100 | Binning x2 | 300 | =IF(AND(Mirror_Flag="ENABLE",ABS(Scanner_step_per_frame)<>3), INT( (scanner_timetot__ms / cu_trep_ms) + 0.5), "N/A") | 400 | =(VI_flag="ON") * VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,2,FALSE) + (IR_flag="ON") * VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,4,FALSE) | =((VI_flag="ON") * (VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,3,FALSE)*VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,2,FALSE)) + (IR_flag="ON") * (VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,5,FALSE)*VLOOKUP(SPECTRAL_MASK,list_of_spectral_masks,4,FALSE)) ) / Number_of_spectels_after_spectral_binning | =DV__Mbits/cu_trep_ms/ IF(nb_cu_frames_tot=65535, DIFF_TIME_CA_ms(First_CU_frame_start_wrt_C_A, Last_CU_frame_stop_wrt_C_A)/cu_trep_ms,nb_cu_frames_tot)*(1024*1024) | =IF(AND(nb_cu_frames_tot__computed<>"N/A",nb_cu_frames_tot<>nb_cu_frames_tot__computed), "ERROR: nb_cu_frames_tot and nb_cu_frames_tot (computed) are not equal", IF(nb_cu_frames_tot=65535, DIFF_TIME_CA_ms(First_CU_frame_start_wrt_C_A,Last_CU_frame_stop_wrt_C_A)/cu_trep_ms, nb_cu_frames_tot) * ( ppe / 2^(IF(spatial_binning="No Binning",0,IF(spatial_binning="Binning x2",1,IF(spatial_binning="Binning x4",2,"N/A")))) ) * Number_of_spectels_after_spectral_binning * Nb_of_bits_per_spectel_after_compression / (1024*1024) ) | =(VI_flag="ON") * VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,2,FALSE) + (IR_flag="ON") * VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,4,FALSE) | =IF(Number_of_browse_spectels=0,0, ((VI_flag="ON") * (VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,3,FALSE)*VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,2,FALSE)) + (IR_flag="ON") * (VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,5,FALSE)*VLOOKUP(BROWSE_PARAMETERS,list_of_browse_parameters,4,FALSE)) ) / Number_of_browse_spectels) | =browse_DV__Mbits / cu_trep_ms / nb_cu_frames_tot * (1024*1024) | =IF(AND(nb_cu_frames_tot__computed<>"N/A",nb_cu_frames_tot<>nb_cu_frames_tot__computed), "ERROR: nb_cu_frames_tot and nb_cu_frames_tot (computed) are not equal", IF(nb_cu_frames_tot=65535, DIFF_TIME_CA_ms(First_CU_frame_start_wrt_C_A,Last_CU_frame_stop_wrt_C_A)/cu_trep_ms, nb_cu_frames_tot) * ( ppe / 2^(IF(spatial_binning="No Binning",0,IF(spatial_binning="Binning x2",1,IF(spatial_binning="Binning x4",2,"N/A")))) ) * Number_of_browse_spectels * Nb_of_bits_per_browse_spectel_after_compression / (1024*1024) ) | 372 | =IF(AND(VI_flag="ON",IR_flag="ON"), IF( Mirror_Flag = "ENABLE", power_2ch_science_scanning, power_2ch_science_pointing), IF(OR(VI_flag="ON",IR_flag="ON"), IF( Mirror_Flag = "ENABLE", power_1ch_science_scanning, power_1ch_science_pointing), "N/A")) | =IF(AND(VI_flag="ON",IR_flag="ON"), IF( Mirror_Flag = "ENABLE", power_2ch_science_scanning_description, power_2ch_science_pointing_description), IF(AND(VI_flag="ON",IR_flag="ON"), IF( Mirror_Flag = "ENABLE", power_1ch_science_scanning_description, power_1ch_science_pointing_description), "N/A")) |