lstosa 0.10.12__tar.gz → 0.10.14__tar.gz

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.
Files changed (128) hide show
  1. {lstosa-0.10.12 → lstosa-0.10.14}/PKG-INFO +1 -1
  2. lstosa-0.10.14/crontab/crontab.txt +101 -0
  3. {lstosa-0.10.12 → lstosa-0.10.14}/src/lstosa.egg-info/PKG-INFO +1 -1
  4. {lstosa-0.10.12 → lstosa-0.10.14}/src/lstosa.egg-info/SOURCES.txt +1 -0
  5. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/_version.py +2 -2
  6. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/gain_selection.py +41 -16
  7. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/reprocessing.py +7 -2
  8. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/sequencer_webmaker.py +5 -2
  9. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/utils/cliopts.py +6 -0
  10. {lstosa-0.10.12 → lstosa-0.10.14}/.coveragerc +0 -0
  11. {lstosa-0.10.12 → lstosa-0.10.14}/.gitignore +0 -0
  12. {lstosa-0.10.12 → lstosa-0.10.14}/.mailmap +0 -0
  13. {lstosa-0.10.12 → lstosa-0.10.14}/.pre-commit-config.yaml +0 -0
  14. {lstosa-0.10.12 → lstosa-0.10.14}/.readthedocs.yml +0 -0
  15. {lstosa-0.10.12 → lstosa-0.10.14}/LICENSE +0 -0
  16. {lstosa-0.10.12 → lstosa-0.10.14}/MANIFEST.in +0 -0
  17. {lstosa-0.10.12 → lstosa-0.10.14}/README.md +0 -0
  18. {lstosa-0.10.12 → lstosa-0.10.14}/codemeta.json +0 -0
  19. {lstosa-0.10.12 → lstosa-0.10.14}/dev/mysql.py +0 -0
  20. {lstosa-0.10.12 → lstosa-0.10.14}/docs/Makefile +0 -0
  21. {lstosa-0.10.12 → lstosa-0.10.14}/docs/_static/logo_lstosa.png +0 -0
  22. {lstosa-0.10.12 → lstosa-0.10.14}/docs/authors.rst +0 -0
  23. {lstosa-0.10.12 → lstosa-0.10.14}/docs/components/index.rst +0 -0
  24. {lstosa-0.10.12 → lstosa-0.10.14}/docs/conf.py +0 -0
  25. {lstosa-0.10.12 → lstosa-0.10.14}/docs/configuration.rst +0 -0
  26. {lstosa-0.10.12 → lstosa-0.10.14}/docs/contribute.rst +0 -0
  27. {lstosa-0.10.12 → lstosa-0.10.14}/docs/documents/index.rst +0 -0
  28. {lstosa-0.10.12 → lstosa-0.10.14}/docs/howto/index.rst +0 -0
  29. {lstosa-0.10.12 → lstosa-0.10.14}/docs/index.rst +0 -0
  30. {lstosa-0.10.12 → lstosa-0.10.14}/docs/introduction/index.rst +0 -0
  31. {lstosa-0.10.12 → lstosa-0.10.14}/docs/introduction/reduction_steps_lstchain.png +0 -0
  32. {lstosa-0.10.12 → lstosa-0.10.14}/docs/jobs.rst +0 -0
  33. {lstosa-0.10.12 → lstosa-0.10.14}/docs/make.bat +0 -0
  34. {lstosa-0.10.12 → lstosa-0.10.14}/docs/nightsummary.rst +0 -0
  35. {lstosa-0.10.12 → lstosa-0.10.14}/docs/provenance.rst +0 -0
  36. {lstosa-0.10.12 → lstosa-0.10.14}/docs/references.rst +0 -0
  37. {lstosa-0.10.12 → lstosa-0.10.14}/docs/reports.rst +0 -0
  38. {lstosa-0.10.12 → lstosa-0.10.14}/docs/scripts/index.rst +0 -0
  39. {lstosa-0.10.12 → lstosa-0.10.14}/docs/troubleshooting/index.rst +0 -0
  40. {lstosa-0.10.12 → lstosa-0.10.14}/docs/utils.rst +0 -0
  41. {lstosa-0.10.12 → lstosa-0.10.14}/docs/veto.rst +0 -0
  42. {lstosa-0.10.12 → lstosa-0.10.14}/docs/workflow/LSTOSA_flow.png +0 -0
  43. {lstosa-0.10.12 → lstosa-0.10.14}/docs/workflow/index.rst +0 -0
  44. {lstosa-0.10.12 → lstosa-0.10.14}/environment.yml +0 -0
  45. {lstosa-0.10.12 → lstosa-0.10.14}/extra/example_sequencer.txt +0 -0
  46. {lstosa-0.10.12 → lstosa-0.10.14}/extra/history_files/sequence_LST1_04183.history +0 -0
  47. {lstosa-0.10.12 → lstosa-0.10.14}/extra/history_files/sequence_LST1_04183_failed.history +0 -0
  48. {lstosa-0.10.12 → lstosa-0.10.14}/extra/history_files/sequence_LST1_04183_oneline.history +0 -0
  49. {lstosa-0.10.12 → lstosa-0.10.14}/extra/history_files/sequence_LST1_04185.0010.history +0 -0
  50. {lstosa-0.10.12 → lstosa-0.10.14}/extra/sacct_output.csv +0 -0
  51. {lstosa-0.10.12 → lstosa-0.10.14}/extra/squeue_output.csv +0 -0
  52. {lstosa-0.10.12 → lstosa-0.10.14}/pyproject.toml +0 -0
  53. {lstosa-0.10.12 → lstosa-0.10.14}/setup.cfg +0 -0
  54. {lstosa-0.10.12 → lstosa-0.10.14}/src/lstosa.egg-info/dependency_links.txt +0 -0
  55. {lstosa-0.10.12 → lstosa-0.10.14}/src/lstosa.egg-info/entry_points.txt +0 -0
  56. {lstosa-0.10.12 → lstosa-0.10.14}/src/lstosa.egg-info/requires.txt +0 -0
  57. {lstosa-0.10.12 → lstosa-0.10.14}/src/lstosa.egg-info/top_level.txt +0 -0
  58. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/__init__.py +0 -0
  59. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/configs/__init__.py +0 -0
  60. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/configs/config.py +0 -0
  61. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/configs/datamodel.py +0 -0
  62. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/configs/options.py +0 -0
  63. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/configs/sequencer.cfg +0 -0
  64. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/conftest.py +0 -0
  65. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/high_level/__init__.py +0 -0
  66. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/high_level/selection_cuts.toml +0 -0
  67. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/high_level/significance.py +0 -0
  68. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/high_level/tests/test_significance.py +0 -0
  69. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/job.py +0 -0
  70. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/nightsummary/__init__.py +0 -0
  71. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/nightsummary/database.py +0 -0
  72. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/nightsummary/extract.py +0 -0
  73. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/nightsummary/nightsummary.py +0 -0
  74. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/nightsummary/set_source_coordinates.py +0 -0
  75. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/nightsummary/tests/test_database.py +0 -0
  76. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/nightsummary/tests/test_extract.py +0 -0
  77. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/nightsummary/tests/test_nightsummary.py +0 -0
  78. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/nightsummary/tests/test_source_coordinates.py +0 -0
  79. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/osadb.py +0 -0
  80. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/paths.py +0 -0
  81. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/provenance/__init__.py +0 -0
  82. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/provenance/capture.py +0 -0
  83. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/provenance/config/definition.yaml +0 -0
  84. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/provenance/config/environment.yaml +0 -0
  85. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/provenance/config/logger.yaml +0 -0
  86. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/provenance/io.py +0 -0
  87. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/provenance/utils.py +0 -0
  88. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/raw.py +0 -0
  89. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/report.py +0 -0
  90. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/__init__.py +0 -0
  91. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/autocloser.py +0 -0
  92. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/calibration_pipeline.py +0 -0
  93. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/closer.py +0 -0
  94. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/copy_datacheck.py +0 -0
  95. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/datasequence.py +0 -0
  96. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/provprocess.py +0 -0
  97. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/reprocess_longterm.py +0 -0
  98. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/sequencer.py +0 -0
  99. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/show_run_summary.py +0 -0
  100. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/simulate_processing.py +0 -0
  101. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/tests/__init__.py +0 -0
  102. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/tests/test_osa_scripts.py +0 -0
  103. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/scripts/update_source_catalog.py +0 -0
  104. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/tests/__init__.py +0 -0
  105. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/tests/test_jobs.py +0 -0
  106. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/tests/test_osa.py +0 -0
  107. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/tests/test_osadb.py +0 -0
  108. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/tests/test_paths.py +0 -0
  109. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/tests/test_raw.py +0 -0
  110. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/tests/test_report.py +0 -0
  111. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/tests/test_veto.py +0 -0
  112. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/utils/__init__.py +0 -0
  113. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/utils/iofile.py +0 -0
  114. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/utils/logging.py +0 -0
  115. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/utils/mail.py +0 -0
  116. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/utils/register.py +0 -0
  117. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/utils/tests/test_iofile.py +0 -0
  118. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/utils/tests/test_utils.py +0 -0
  119. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/utils/utils.py +0 -0
  120. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/version.py +0 -0
  121. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/veto.py +0 -0
  122. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/webserver/__init__.py +0 -0
  123. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/webserver/utils.py +0 -0
  124. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/workflow/__init__.py +0 -0
  125. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/workflow/dl3.py +0 -0
  126. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/workflow/stages.py +0 -0
  127. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/workflow/tests/test_dl3.py +0 -0
  128. {lstosa-0.10.12 → lstosa-0.10.14}/src/osa/workflow/tests/test_stages.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: lstosa
3
- Version: 0.10.12
3
+ Version: 0.10.14
4
4
  Summary: Onsite analysis pipeline for the CTA LST-1
5
5
  Author: María Láinez, José Enrique Ruiz, Lab Saha, Andrés Baquero, José Luis Contreras, Maximilian Linhoff
6
6
  Author-email: Daniel Morcuende <dmorcuen@ucm.es>
@@ -0,0 +1,101 @@
1
+ #SHELL=/usr/bin/bash
2
+ #BASH_ENV="/local/home/lstanalyzer/.bashrc"
3
+ #
4
+ #-Datacheck jobs
5
+ #
6
+ #30 5 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Data_Check_daily_script_v2.sh
7
+ #05 00-07 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_v7.sh
8
+ #05 00-07 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_close_night_v7.sh
9
+ #05 00-07 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_v9.sh
10
+ # EDIT Daniel Morcuende 2023-01-30: Running the data check during the night might be causing busy states of the camera during
11
+ # data taking. I modified the cron above to launch only during the day.
12
+ 05 08-13 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_v9.sh
13
+ #00 08 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_close_night_v7.sh
14
+ #00 09 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_close_night_v7.sh
15
+ 00 08 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_close_night_v9.sh
16
+ #05 12 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_close_night_v7.sh
17
+ #05 12 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_close_night_no_nightsummary_v7.sh
18
+ 05 12 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_close_night_no_nightsummary_v9.sh
19
+ #05 12 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_close_night_v9.sh
20
+ #00 14,16,18,20,21,22,23 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_v8.sh
21
+ #00 14,16,18,20,21,22,23 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_close_night_v8.sh
22
+ #00 14,16,18,20,21,22,23 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_v10.sh
23
+ # EDIT Daniel Morcuende 2023-01-30: Running the data check during the night might be causing busy states of the camera during
24
+ # data taking. I modified the cron above to launch only during the day up to 18:00 UTC.
25
+ 00 14,16,18 * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/Process_Run_incremental_script_v10.sh
26
+ #40 * * * * /usr/bin/bash /fefs/onsite/pipeline/data-check/test_cron.sh
27
+
28
+
29
+ SHELL=/usr/bin/bash
30
+ BASH_ENV="/local/home/lstanalyzer/.bashrc"
31
+ CRON_TZ=UTC
32
+ # Update astropy auxiliary data (e.g. IERS) every week
33
+ 0 0 * * SUN source /fefs/aswg/lstosa/utils/osa-conda; python /fefs/aswg/data/aux/astropy/get_iers_data.py > /dev/null 2>&1
34
+ #
35
+ # lstosa jobs
36
+ #
37
+ # [COPY OBS OVERVIEW] Copy observations overview and daily camera checks to lst1 datacheck webserver
38
+ #
39
+ 00 09 * * * /usr/bin/bash /fefs/aswg/lstosa/misc/copy_camera_daily_check_to_www.sh >/dev/null 2>&1
40
+ #
41
+ # [RUN SUMMARY] Produce the run summary file at the end of the observations to make sure it contains all the runs taken
42
+ #
43
+ 05 07 * * * obsdate=`date +\%Y\%m\%d -d yesterday`; export obsdate; source /fefs/aswg/lstosa/utils/osa-conda; lstchain_create_run_summary -d $obsdate --overwrite > /dev/null 2>&1
44
+ #
45
+ # [MERGED RUN SUMMARY] Produce the merged run summary file containing all the runs taken by the LST.
46
+ # This only appends the runs of the given date.
47
+ #
48
+ 15 07 * * * obsdate=`date +\%Y\%m\%d -d yesterday`; source /fefs/aswg/lstosa/utils/osa-conda; lstchain_merge_run_summaries -d $obsdate /fefs/aswg/data/real/OSA/Catalog/merged_RunSummary.ecsv > /dev/null 2>&1
49
+ #
50
+ # [GAIN SELECTION]
51
+ #
52
+ #50 07 * * * obsdate=`date +\%Y\%m\%d -d yesterday`; export obsdate; conda activate /fefs/aswg/software/conda/envs/osa-dev; gain_selection --no-queue-check -c /fefs/aswg/lstosa/cfg/sequencer_v0.10.cfg -d $obsdate -o /fefs/aswg/data/real/R0G -s 7 >> /fefs/aswg/data/real/OSA/GainSel_log/${obsdate}_LST1.log 2>&1
53
+ #
54
+ # [GAIN SELECTION CHECK]
55
+ #
56
+ #20 08 * * * obsdate=`date +\%Y\%m\%d -d yesterday`; export obsdate; conda activate /fefs/aswg/software/conda/envs/osa-dev; gain_selection --check -c /fefs/aswg/lstosa/cfg/sequencer_v0.10.cfg -d $obsdate -o /fefs/aswg/data/real/R0G -s 7 >> /fefs/aswg/data/real/OSA/GainSel_log/${obsdate}_check_LST1.log 2>&1
57
+ #
58
+ # [SIMULATED SEQUENCER] Launch sequencer once in the morning simulated. It also produces the run summary file if not found.
59
+ #
60
+ 10 08 * * * obsdate=`date +\%Y-\%m-\%d -d yesterday`; export obsdate; source /fefs/aswg/lstosa/utils/osa-conda; sequencer -c /fefs/aswg/lstosa/cfg/sequencer_v0.10.cfg -s -d $obsdate LST1 >> /fefs/aswg/data/real/OSA/Sequencer_log/${obsdate}_LST1.log 2>&1
61
+ #
62
+ # [SEQUENCER] Launch sequencer once in the morning
63
+ #
64
+ 50 07 * * * obsdate=`date +\%Y-\%m-\%d -d yesterday`; export obsdate; source /fefs/aswg/lstosa/utils/osa-conda; sequencer -c /fefs/aswg/lstosa/cfg/sequencer_v0.10.cfg -d $obsdate --no-gainsel --no-dl2 LST1 > /dev/null 2>&1
65
+ #
66
+ # [WEB SEQUENCER] Make sequencer xhtml table and copy it to the lst1 webserver
67
+ #
68
+ */15 08-18 * * * obsdate=`date +\%Y\%m\%d -d yesterday`; export obsdate; source /fefs/aswg/lstosa/utils/osa-conda; sequencer_webmaker -c /fefs/aswg/lstosa/cfg/sequencer_v0.10.cfg; if [ $? = 0 ]; then scp /fefs/aswg/data/real/OSA/SequencerWeb/osa_status_$obsdate.html datacheck:/home/www/html/datacheck/lstosa/sequencer.xhtml; fi > /dev/null 2>&1
69
+ #
70
+ # [AUTOCLOSER] Launch the closer without forcing it (no -f option).
71
+ #
72
+ 0 10-18/2 * * * obsdate=`date +\%Y-\%m-\%d -d yesterday`; export obsdate; source /fefs/aswg/lstosa/utils/osa-conda; autocloser -c /fefs/aswg/lstosa/cfg/sequencer_v0.10.cfg -d $obsdate --no-gainsel --no-dl2 LST1 >> /fefs/aswg/data/real/OSA/Autocloser_log/${obsdate}_LST1.log 2>&1
73
+ #
74
+ # [COPY DATACHECK] Copy the available calibration and DL1 datacheck to the LST1 webserver.
75
+ #
76
+ 05,20,40 08-18 * * * obsdate=`date +\%Y-\%m-\%d -d yesterday`; export obsdate; source /fefs/aswg/lstosa/utils/osa-conda; copy_datacheck -c /fefs/aswg/lstosa/cfg/sequencer_v0.10.cfg -d $obsdate LST1 > /dev/null 2>&1
77
+ #
78
+ # [SOURCE CATALOG]
79
+ #
80
+ 00 11-19 * * * obsdate=`date +\%Y-\%m-\%d -d yesterday`; export obsdate; source /fefs/aswg/lstosa/utils/osa-conda; update_source_catalog $obsdate > /dev/null 2>&1
81
+ #
82
+ # [COPY CUMULATIVE LST-1 OBSERVATION TIME]
83
+ # (added by Daniel Morcuende on 2024-04-05)
84
+ #
85
+ 0 11 * * FRI /usr/bin/bash /fefs/aswg/lstosa/misc/update_cumulative_obs_time.sh >/dev/null 2>&1
86
+
87
+
88
+ # Daniel Morcuende (2023-11-08) periodically remove leftover jobs kept in the SLURM as pending after job dependency not satisfied because of failure (Reason in squeue: 'DependencyNeverSatisfied').
89
+ # It does only look for lstosa jobs launched by sequencer with the prefix "LST1_" and also the merging jobs launched by autocloser like "longterm_dl1_datacheck".
90
+ */30 * * * * /local/home/lstanalyzer/remove_dependency_never_satisfied_jobs.sh > /dev/null 2>&1
91
+
92
+
93
+
94
+
95
+ SHELL=/usr/bin/bash
96
+ BASH_ENV="/local/home/lstanalyzer/.bashrc"
97
+ CRON_TZ=UTC
98
+ #
99
+ # Restart camera processing of calibration runs in realtime in case it was killed for whatever reason
100
+ #
101
+ 04 * * * * cd /local/home/lstanalyzer/camera/lst-camera-watchers;./lst1_watcher_restarter
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: lstosa
3
- Version: 0.10.12
3
+ Version: 0.10.14
4
4
  Summary: Onsite analysis pipeline for the CTA LST-1
5
5
  Author: María Láinez, José Enrique Ruiz, Lab Saha, Andrés Baquero, José Luis Contreras, Maximilian Linhoff
6
6
  Author-email: Daniel Morcuende <dmorcuen@ucm.es>
@@ -9,6 +9,7 @@ README.md
9
9
  codemeta.json
10
10
  environment.yml
11
11
  pyproject.toml
12
+ crontab/crontab.txt
12
13
  dev/mysql.py
13
14
  docs/Makefile
14
15
  docs/authors.rst
@@ -12,5 +12,5 @@ __version__: str
12
12
  __version_tuple__: VERSION_TUPLE
13
13
  version_tuple: VERSION_TUPLE
14
14
 
15
- __version__ = version = '0.10.12'
16
- __version_tuple__ = version_tuple = (0, 10, 12)
15
+ __version__ = version = '0.10.14'
16
+ __version_tuple__ = version_tuple = (0, 10, 14)
@@ -24,7 +24,7 @@ log = myLogger(logging.getLogger(__name__))
24
24
 
25
25
  PATH = "PATH=/fefs/aswg/software/offline_dvr/bin:$PATH"
26
26
 
27
- parser = argparse.ArgumentParser(add_help=False)
27
+ parser = argparse.ArgumentParser()
28
28
  parser.add_argument(
29
29
  "--check",
30
30
  action="store_true",
@@ -50,13 +50,14 @@ parser.add_argument(
50
50
  "--date",
51
51
  default=None,
52
52
  type=str,
53
- help="Night to apply the gain selection",
53
+ help="Night to apply the gain selection in YYYYMMDD format",
54
54
  )
55
55
  parser.add_argument(
56
56
  "-l",
57
57
  "--dates-file",
58
58
  default=None,
59
- help="List of dates to apply the gain selection",
59
+ help="List of dates to apply the gain selection. The input file should list"
60
+ "the dates in the format YYYYMMDD, one date per line.",
60
61
  )
61
62
  parser.add_argument(
62
63
  "-o",
@@ -79,12 +80,20 @@ parser.add_argument(
79
80
  default=18,
80
81
  help="Time to stop gain selection in HH format. Default is 18.",
81
82
  )
83
+ parser.add_argument(
84
+ "-t",
85
+ "--tool",
86
+ type=str,
87
+ default=None,
88
+ help="Choose tool to apply the gain selection regardless the date. Possible options are: lst_dvr (by default used for dates "
89
+ "previous to 20231205) and lstchain_r0_to_r0g (by default used for dates later than 20231205).",
90
+ )
82
91
 
83
92
  def get_sbatch_script(
84
- run_id, subrun, input_file, output_dir, log_dir, log_file, ref_time, ref_counter, module, ref_source, script
93
+ run_id, subrun, input_file, output_dir, log_dir, log_file, ref_time, ref_counter, module, ref_source, tool
85
94
  ):
86
95
  """Build the sbatch job pilot script for running the gain selection."""
87
- if script=="old":
96
+ if tool == "lst_dvr":
88
97
  return dedent(
89
98
  f"""\
90
99
  #!/bin/bash
@@ -98,7 +107,7 @@ def get_sbatch_script(
98
107
  lst_dvr {input_file} {output_dir} {ref_time} {ref_counter} {module} {ref_source}
99
108
  """
100
109
  )
101
- elif script=="new":
110
+ elif tool == "lstchain_r0_to_r0g":
102
111
  return dedent(
103
112
  f"""\
104
113
  #!/bin/bash
@@ -113,16 +122,17 @@ def get_sbatch_script(
113
122
  """
114
123
  )
115
124
 
116
- def apply_gain_selection(date: str, start: int, end: int, output_basedir: Path = None, no_queue_check: bool = False):
125
+ def apply_gain_selection(date: str, start: int, end: int, output_basedir: Path = None, tool: str = None, no_queue_check: bool = False):
117
126
  """
118
127
  Submit the jobs to apply the gain selection to the data for a given date
119
128
  on a subrun-by-subrun basis.
120
129
  """
121
130
 
122
- if date < "20231205":
123
- script = "old"
124
- else:
125
- script = "new"
131
+ if not tool:
132
+ if date < "20231205":
133
+ tool = "lst_dvr"
134
+ else:
135
+ tool = "lstchain_r0_to_r0g"
126
136
 
127
137
  run_summary_dir = Path("/fefs/aswg/data/real/monitoring/RunSummary")
128
138
  run_summary_file = run_summary_dir / f"RunSummary_{date}.ecsv"
@@ -156,7 +166,7 @@ def apply_gain_selection(date: str, start: int, end: int, output_basedir: Path =
156
166
  subrun_numbers = [int(file[-12:-8]) for file in files]
157
167
  input_files = []
158
168
 
159
- if date < "20231205" and ref_source not in ["UCTS", "TIB"]:
169
+ if tool == "lst_dvr" and ref_source not in ["UCTS", "TIB"]:
160
170
  input_files = r0_dir.glob(f"LST-1.?.Run{run_id:05d}.????.fits.fz")
161
171
  log.info(
162
172
  f"Run {run_id} does not have UCTS or TIB info, so gain selection cannot"
@@ -199,7 +209,7 @@ def apply_gain_selection(date: str, start: int, end: int, output_basedir: Path =
199
209
  ref_counter,
200
210
  module,
201
211
  ref_source,
202
- script,
212
+ tool,
203
213
  )
204
214
  )
205
215
  sp.run(["sbatch", job_file], check=True)
@@ -208,7 +218,8 @@ def apply_gain_selection(date: str, start: int, end: int, output_basedir: Path =
208
218
  log.info(f"Found {len(calib_runs)} NO-DATA runs")
209
219
 
210
220
  for run in calib_runs:
211
- log.info(f"Copying R0 files corresponding to run {run} directly to {output_dir}")
221
+ run_id = run["run_id"]
222
+ log.info(f"Copying R0 files corresponding to run {run_id} directly to {output_dir}")
212
223
  # Avoid copying files while it is still night time
213
224
  wait_for_daytime(start, end)
214
225
 
@@ -327,7 +338,14 @@ def main():
327
338
  check_failed_jobs(args.date, args.output_basedir)
328
339
  else:
329
340
  log.info(f"Applying gain selection to date {args.date}")
330
- apply_gain_selection(args.date, args.start_time, args.end_time, args.output_basedir, no_queue_check=args.no_queue_check)
341
+ apply_gain_selection(
342
+ args.date,
343
+ args.start_time,
344
+ args.end_time,
345
+ args.output_basedir,
346
+ args.tool,
347
+ no_queue_check=args.no_queue_check,
348
+ )
331
349
 
332
350
 
333
351
  elif args.dates_file:
@@ -341,7 +359,14 @@ def main():
341
359
  else:
342
360
  for date in list_of_dates:
343
361
  log.info(f"Applying gain selection to date {date}")
344
- apply_gain_selection(date, args.start_time, args.end_time, args.output_basedir, no_queue_check=args.no_queue_check)
362
+ apply_gain_selection(
363
+ date,
364
+ args.start_time,
365
+ args.end_time,
366
+ args.output_basedir,
367
+ args.tool,
368
+ no_queue_check=args.no_queue_check,
369
+ )
345
370
  log.info("Done! No more dates to process.")
346
371
 
347
372
 
@@ -22,7 +22,7 @@ def number_of_pending_jobs():
22
22
 
23
23
 
24
24
  def run_script(
25
- script: str, date, config: Path, no_dl2: bool, no_calib: bool, simulate: bool, force: bool
25
+ script: str, date, config: Path, no_dl2: bool, no_gainsel: bool, no_calib: bool, simulate: bool, force: bool
26
26
  ):
27
27
  """Run the sequencer for a given date."""
28
28
  osa_config = Path(config).resolve()
@@ -32,6 +32,9 @@ def run_script(
32
32
  if no_dl2:
33
33
  cmd.append("--no-dl2")
34
34
 
35
+ if no_gainsel:
36
+ cmd.append("--no-gainsel")
37
+
35
38
  if no_calib:
36
39
  cmd.append("--no-calib")
37
40
 
@@ -64,6 +67,7 @@ def get_list_of_dates(dates_file):
64
67
 
65
68
  @click.command()
66
69
  @click.option("--no-dl2", is_flag=True, help="Do not run the DL2 step.")
70
+ @click.option("--no-gainsel", is_flag=True, help="Do not require gain selection to be finished.")
67
71
  @click.option("--no-calib", is_flag=True, help="Do not run the calibration step.")
68
72
  @click.option("-s", "--simulate", is_flag=True, help="Activate simulation mode.")
69
73
  @click.option("-f", "--force", is_flag=True, help="Force the autocloser to close the day.")
@@ -83,6 +87,7 @@ def main(
83
87
  dates_file: Path = None,
84
88
  config: Path = DEFAULT_CFG,
85
89
  no_dl2: bool = False,
90
+ no_gainsel: bool = False,
86
91
  no_calib: bool = False,
87
92
  simulate: bool = False,
88
93
  force: bool = False,
@@ -102,7 +107,7 @@ def main(
102
107
  # Avoid running jobs while it is still night time
103
108
  wait_for_daytime()
104
109
 
105
- run_script(script, date, config, no_dl2, no_calib, simulate, force)
110
+ run_script(script, date, config, no_dl2, no_gainsel, no_calib, simulate, force)
106
111
  log.info("Waiting 1 minute to launch the process for the next date...\n")
107
112
  time.sleep(60)
108
113
 
@@ -55,7 +55,7 @@ def html_content(body: str, date: str) -> str:
55
55
  )
56
56
 
57
57
 
58
- def get_sequencer_output(date: str, config: str, test=False) -> list:
58
+ def get_sequencer_output(date: str, config: str, test=False, no_gainsel=False) -> list:
59
59
  """Call sequencer to get table with the sequencer status report.
60
60
 
61
61
  Parameters
@@ -82,6 +82,9 @@ def get_sequencer_output(date: str, config: str, test=False) -> list:
82
82
  options.tel_id,
83
83
  ]
84
84
 
85
+ if no_gainsel:
86
+ commandargs.insert(1, "--no-gainsel")
87
+
85
88
  if test:
86
89
  commandargs.insert(-1, "-t")
87
90
 
@@ -144,7 +147,7 @@ def main():
144
147
  sys.exit(1)
145
148
 
146
149
  # Get the table with the sequencer status report:
147
- lines = get_sequencer_output(date, args.config, args.test)
150
+ lines = get_sequencer_output(date, args.config, test=args.test, no_gainsel=args.no_gainsel)
148
151
 
149
152
  # Build the html sequencer table that will be place in the body of the HTML file
150
153
  matrix = lines_to_matrix(lines)
@@ -447,6 +447,12 @@ def sequencer_webmaker_argparser():
447
447
  parser = ArgumentParser(
448
448
  description="Script to make an xhtml from LSTOSA sequencer output", parents=[common_parser]
449
449
  )
450
+ parser.add_argument(
451
+ "--no-gainsel",
452
+ action="store_true",
453
+ default=False,
454
+ help="Do not check if the gain selection finished correctly (default False)",
455
+ )
450
456
  options.tel_id = "LST1"
451
457
  options.prod_id = get_prod_id()
452
458
 
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes