-
Notifications
You must be signed in to change notification settings - Fork 24
Closed
Labels
Ins: GLOWSRelated to the GLOWS instrumentRelated to the GLOWS instrumentLevel: L2Level 2 processingLevel 2 processingenhancementNew feature or requestNew feature or request
Milestone
Description
Description
Currently, when no good times are found in L1B data, the L2 processing continues and creates an output file with potentially invalid or meaningless data. The code should exit early or skip processing to avoid creating invalid output files.
Location
imap_processing/glows/l2/glows_l2.py:80-91
Current Implementation
if len(good_data["epoch"]) != 0:
var_outputs["start_time"] = good_data["epoch"].data[0]
var_outputs["end_time"] = good_data["epoch"].data[-1]
else:
# No good times in the file
var_outputs["start_time"] = l1b_dataset["imap_start_time"].data[0]
var_outputs["end_time"] = (
l1b_dataset["imap_start_time"].data[0]
+ l1b_dataset["imap_time_offset"].data[0]
)
# Processing continues regardless...Required Changes
- After detecting
len(good_data["epoch"]) == 0, add early return or raise appropriate exception - Log warning message about no good times found
- Decide appropriate behavior:
- Option A: Return None and skip file creation
- Option B: Raise exception with clear message
- Option C: Create file with special flag indicating no valid data
Related
Part of #1276 (GLOWS L2 follow up)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Ins: GLOWSRelated to the GLOWS instrumentRelated to the GLOWS instrumentLevel: L2Level 2 processingLevel 2 processingenhancementNew feature or requestNew feature or request
Type
Projects
Status
Done