Skip to content

Commit dbf6d9b

Browse files
sawenzelclaude
andcommitted
Allow anchored MC to run the AnalysisQC
This adds an option to run the AnalysisQC in anchored MC and enables it in the 2-tag test. - ALIEN_JDL_RUNANALYSISQC=1 passes --include-analysis to the workflow creation and adds the analysis tasks to the targets. - The QCDB upload tasks of the AnalysisQC are not targeted. - The option is ignored with a message when O2Physics is not loaded. - The 2-tag test template sets it, so release checks fail when the AnalysisQC fails. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent cf554aa commit dbf6d9b

2 files changed

Lines changed: 16 additions & 0 deletions

File tree

‎MC/run/ANCHOR/anchorMC.sh‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ print_help()
6262
echo "ALIEN_O2DPG_FILEGRAPH=FILE, delete intermediate files early, using a FileIOGraph report"
6363
echo "ALIEN_O2DPG_RESOURCES=FILE, use resource estimates learned by a pilot run instead of sampling them"
6464
echo "DISABLE_QC, set this to disable QC, e.g. to 1"
65+
echo "ALIEN_JDL_RUNANALYSISQC=1, run the AnalysisQC on the produced AO2D (needs O2Physics in the environment)"
6566
echo "CYCLE, to set a cycle number different than 0"
6667
echo "NSIGEVENTS, to enforce a specific upper limit of events in a timeframe (not counting orbit-early) events"
6768
}
@@ -349,6 +350,15 @@ remainingargs="${remainingargs} -productionTag ${ALIEN_JDL_LPMPRODUCTIONTAG:-ali
349350
# prepend(!) ALIEN_JDL_ANCHOR_SIM_OPTIONS
350351
# since the last passed argument wins, e.g. -productionTag cannot be overwritten by the user
351352
remainingargs="${ALIEN_JDL_ANCHOR_SIM_OPTIONS} ${remainingargs} --anchor-config config-json.json"
353+
# AnalysisQC on the produced AO2D
354+
if [[ "${ALIEN_JDL_RUNANALYSISQC}" == "1" ]]; then
355+
if [[ -n "${O2PHYSICS_ROOT}" ]]; then
356+
remainingargs="${remainingargs} --include-analysis"
357+
else
358+
echo_info "ALIEN_JDL_RUNANALYSISQC=1 but O2Physics is not loaded, not running AnalysisQC"
359+
unset ALIEN_JDL_RUNANALYSISQC
360+
fi
361+
fi
352362
# apply software tagging choice
353363
# remainingargs="${remainingargs} ${ALIEN_JDL_O2DPG_ASYNC_RECO_TAG:+--alternative-reco-software ${ALIEN_JDL_O2DPG_ASYNC_RECO_TAG}}"
354364
ALIEN_JDL_O2DPG_ASYNC_RECO_FROMSTAGE=${ALIEN_JDL_O2DPG_ASYNC_RECO_FROMSTAGE:-RECO}
@@ -412,6 +422,10 @@ else
412422
targetString="${targetString} '^.*QC.*'" # QC tasks should have QC in the name
413423
fi
414424
fi
425+
# -) AnalysisQC tasks, without the QCDB upload tasks
426+
if [[ "${ALIEN_JDL_RUNANALYSISQC}" == "1" ]]; then
427+
targetString="${targetString} '^Analysis_(?!finalize_).*'"
428+
fi
415429
echo_info "Workflow will run with target specification ${targetString}"
416430

417431
# resource estimates learned by a pilot run (o2dpg_sim_metrics.py json-stat)

‎MC/run/ANCHOR/tests/test_anchor_2tag_template.sh‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ export ALIEN_JDL_ADDTIMESERIESINMC=0
4444
export DISABLE_QC=1
4545
export ALIEN_JDL_MC_ORBITS_PER_TF=10000:10000000:2 # puts just 2 orbit for large enough interaction rates
4646
export ALIEN_JDL_O2DPGWORKFLOWTARGET="aod"
47+
# run the AnalysisQC on the produced AO2D
48+
export ALIEN_JDL_RUNANALYSISQC=1
4749

4850
# select anchoring points
4951
export PRODSPLIT=${ALIEN_O2DPG_GRIDSUBMIT_PRODSPLIT:-100}

0 commit comments

Comments
 (0)