Skip to content

Commit 7f83266

Browse files
jokonigshahor02
authored andcommitted
[EMCAL-798] Add input subspecification to offline calib workflow
- During reconstruction, the offline calibrator needs to get uncalibrated cells. Therefore it needs to listen to subspecification 1 instead of 0 - Additionally changed the makeCellIDTimeEnergy default argument to false, as it is a bool and cannot be set to false in the workflow options
1 parent 969fa57 commit 7f83266

4 files changed

Lines changed: 12 additions & 7 deletions

File tree

Detectors/EMCAL/workflow/include/EMCALWorkflow/OfflineCalibSpec.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ class OfflineCalibSpec : public framework::Task
7070
/// \brief Creating offline calib spec
7171
/// \ingroup EMCALworkflow
7272
///
73-
o2::framework::DataProcessorSpec getEmcalOfflineCalibSpec(bool makeCellIDTimeEnergy, bool rejectCalibTriggers);
73+
o2::framework::DataProcessorSpec getEmcalOfflineCalibSpec(bool makeCellIDTimeEnergy, bool rejectCalibTriggers, uint32_t inputsubspec);
7474

7575
} // namespace emcal
7676

Detectors/EMCAL/workflow/src/OfflineCalibSpec.cxx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,11 +108,11 @@ void OfflineCalibSpec::endOfStream(o2::framework::EndOfStreamContext& ec)
108108
outputFile->Close();
109109
}
110110

111-
o2::framework::DataProcessorSpec o2::emcal::getEmcalOfflineCalibSpec(bool makeCellIDTimeEnergy, bool rejectCalibTriggers)
111+
o2::framework::DataProcessorSpec o2::emcal::getEmcalOfflineCalibSpec(bool makeCellIDTimeEnergy, bool rejectCalibTriggers, uint32_t inputsubspec)
112112
{
113113
return o2::framework::DataProcessorSpec{"EMCALOfflineCalib",
114-
{{"cells", o2::header::gDataOriginEMC, "CELLS", 0, o2::framework::Lifetime::Timeframe},
115-
{"triggerrecord", o2::header::gDataOriginEMC, "CELLSTRGR", 0, o2::framework::Lifetime::Timeframe}},
114+
{{"cells", o2::header::gDataOriginEMC, "CELLS", inputsubspec, o2::framework::Lifetime::Timeframe},
115+
{"triggerrecord", o2::header::gDataOriginEMC, "CELLSTRGR", inputsubspec, o2::framework::Lifetime::Timeframe}},
116116
{},
117117
o2::framework::adaptFromTask<o2::emcal::OfflineCalibSpec>(makeCellIDTimeEnergy, rejectCalibTriggers)};
118118
}

Detectors/EMCAL/workflow/src/emc-offline-calib-workflow.cxx

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,9 @@ using namespace o2::framework;
2121
void customize(std::vector<o2::framework::ConfigParamSpec>& workflowOptions)
2222
{
2323
// option allowing to set parameters
24-
std::vector<ConfigParamSpec> options{{"makeCellIDTimeEnergy", VariantType::Bool, true, {"list whether or not to make the cell ID, time, energy THnSparse"}},
24+
std::vector<ConfigParamSpec> options{{"makeCellIDTimeEnergy", VariantType::Bool, false, {"list whether or not to make the cell ID, time, energy THnSparse"}},
2525
{"no-rejectCalibTrigg", VariantType::Bool, false, {"if set to true, all events, including calibration triggered events, will be accepted"}},
26+
{"input-subspec", VariantType::UInt32, 0U, {"Subspecification for input objects"}},
2627
{"configKeyValues", VariantType::String, "", {"Semicolon separated key=value strings"}}};
2728
workflowOptions.insert(workflowOptions.end(), options.begin(), options.end());
2829
}
@@ -37,7 +38,11 @@ WorkflowSpec defineDataProcessing(ConfigContext const& cfgc)
3738
// Update the (declared) parameters if changed from the command line
3839
bool makeCellIDTimeEnergy = cfgc.options().get<bool>("makeCellIDTimeEnergy");
3940
bool rejectCalibTrigg = !cfgc.options().get<bool>("no-rejectCalibTrigg");
41+
42+
// subpsecs for input
43+
auto inputsubspec = cfgc.options().get<uint32_t>("input-subspec");
44+
4045
o2::conf::ConfigurableParam::updateFromString(cfgc.options().get<std::string>("configKeyValues"));
41-
wf.emplace_back(o2::emcal::getEmcalOfflineCalibSpec(makeCellIDTimeEnergy, rejectCalibTrigg));
46+
wf.emplace_back(o2::emcal::getEmcalOfflineCalibSpec(makeCellIDTimeEnergy, rejectCalibTrigg, inputsubspec));
4247
return wf;
4348
}

prodtests/full-system-test/calib-workflow.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ if [[ $CALIB_TPC_RESPADGAIN == 1 ]]; then add_W o2-tpc-calib-gainmap-tracks "--p
2727
if [[ $CALIB_ZDC_TDC == 1 ]]; then add_W o2-zdc-tdccalib-epn-workflow "" "" 0; fi
2828
if [[ $CALIB_FT0_TIMEOFFSET == 1 ]]; then add_W o2-calibration-ft0-time-spectra-processor; fi
2929
# for async calibrations
30-
if [[ $CALIB_EMC_ASYNC_RECALIB == 1 ]]; then add_W o2-emcal-emc-offline-calib-workflow; fi
30+
if [[ $CALIB_EMC_ASYNC_RECALIB == 1 ]]; then add_W o2-emcal-emc-offline-calib-workflow --input-subspec 1; fi
3131

3232
# output-proxy for aggregator
3333
if workflow_has_parameter CALIB_PROXIES; then

0 commit comments

Comments
 (0)