-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Application of Cat-B calibration (option1) #302
base: main
Are you sure you want to change the base?
Conversation
Co-authored-by: Daniel Morcuende <[email protected]>
log.info(f"Going to level {level}") | ||
else: | ||
level -= 2 | ||
log.info(f"No images stored in dl1ab. Producing DL2. Going to level {level}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
log.info(f"No images stored in dl1ab. Producing DL2. Going to level {level}") | |
log.info( | |
f"No images stored in dl1ab. Skipping datachecks and producing DL2. Going to level {level}" | |
) |
src/osa/scripts/datasequence.py
Outdated
if run_str[-4:] != "0000": | ||
log.debug(f"{run_str} is not the first subrun of the run, so the script " | ||
"onsite_create_cat_B_calibration_file will not be launched for this subrun.") | ||
|
||
catB_calibration_file = get_catB_calibration_filename(int(run_str[:5])) | ||
n = 0 | ||
n_max = 10 | ||
while not catB_calibration_file.exists() and n<=n_max: | ||
time.sleep(120) | ||
n += 1 | ||
return 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you need the sleep part here if you plan to do it in two steps?
src/osa/scripts/datasequence.py
Outdated
log.debug(f"{run_str} is not the first subrun of the run, so the script " | ||
"onsite_create_cat_B_calibration_file will not be launched for this subrun.") | ||
|
||
catB_calibration_file = get_catB_calibration_filename(int(run_str[:5])) | ||
n = 0 | ||
n_max = 10 | ||
while not catB_calibration_file.exists() and n<=n_max: | ||
time.sleep(120) | ||
n += 1 | ||
return 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I'd simply return if subrun is not 0
#elif program == cfg.get("lstchain", "catB_calibration"): | ||
# level = 3 if exit_status == 0 else 4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why is it commented? do you plan to include a new cat B calibration line in the history file?
The idea with this new scheme is that first one sequencer is launched with option --no-dl1ab. This sequencer will be launched once by the crontab. Then sequencer_catB_tailcuts will be launched several times. It has to be launched every x minutes to give time for the catB.closed files and the .json config files with the appropriate tailcuts to be created. Then, a second sequencer (without the option --no-dl1ab) is launched also every x minutes. This sequencer should start from step dl1ab and it should first check if the catB.closed files and the .json config files for the tailcuts exist for a given run. Once it has checked that these files exist, it will proceed with the dl1ab step and dl2 if option --no-dl2 is not given. |
In order to be able to process some nights "fast" with Cat-B calibration we have thought of this option. The idea is to launch first a sequencer with option --no-dl1ab, then the script onsite_create_cat_B_calibration "manually" and then another sequencer (without option --no-dl1ab). I have created a script that does all these steps by its own and it seems to be working. Tests are ongoing.