You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Configurable<bool> mFatalOnPassNotAvailable{"fatalOnPassNotAvailable", true, "Flag to throw a fatal if the pass is not available in the retrieved CCDB object"};
70
70
Configurable<bool> mEnableTimeDependentResponse{"enableTimeDependentResponse", false, "Flag to use the collision timestamp to fetch the PID Response"};
constauto& bc = coll.bc_as<aod::BCsWithTimestamps>();
162
+
constauto& bc = coll.templatebc_as<aod::BCsWithTimestamps>();
162
163
163
164
// First we check if this run number was already processed
164
165
if (mLastRunNumber == bc.runNumber()) {
@@ -237,11 +238,14 @@ struct tofSignal {
237
238
LOG(info) << "No table or process is enabled. Disabling task";
238
239
return;
239
240
}
240
-
if (metadataInfo.isFullyDefined() && !doprocessRun2 && !doprocessRun3) { // Check if the metadata is initialized (only if not forced from the workflow configuration)
241
-
if (metadataInfo.isRun3()) {
242
-
doprocessRun3.value = true;
243
-
} else {
244
-
doprocessRun2.value = false;
241
+
if (mTOFCalibConfig.mAutoSetProcessFunctions) {
242
+
LOG(info) << "Autodetecting process functions";
243
+
if (metadataInfo.isFullyDefined() && !doprocessRun2 && !doprocessRun3) { // Check if the metadata is initialized (only if not forced from the workflow configuration)
244
+
if (metadataInfo.isRun3()) {
245
+
doprocessRun3.value = true;
246
+
} else {
247
+
doprocessRun2.value = false;
248
+
}
245
249
}
246
250
}
247
251
@@ -391,8 +395,24 @@ struct tofEventTime {
391
395
return;
392
396
}
393
397
394
-
if (metadataInfo.isFullyDefined() && metadataInfo.isRun3() && doprocessRun2) {
395
-
LOG(fatal) << "Run2 process function is enabled but the metadata says it is Run3";
398
+
if (mTOFCalibConfig.mAutoSetProcessFunctions) {
399
+
LOG(info) << "Autodetecting process functions";
400
+
if (metadataInfo.isFullyDefined()) {
401
+
if (metadataInfo.isRun3()) {
402
+
doprocessRun3.value = true;
403
+
} else {
404
+
doprocessRun2.value = true;
405
+
}
406
+
}
407
+
}
408
+
409
+
if (metadataInfo.isFullyDefined()) {
410
+
if (metadataInfo.isRun3() && doprocessRun2) {
411
+
LOG(fatal) << "Run2 process function is enabled but the metadata says it is Run3";
412
+
}
413
+
if (!metadataInfo.isRun3() && doprocessRun3) {
414
+
LOG(fatal) << "Run3 process function is enabled but the metadata says it is Run2";
LOG(fatal) << "Collision system " << mTOFCalibConfig.mCollisionSystem.value << "" << CollisionSystemType::getCollisionSystemName(mTOFCalibConfig.mCollisionSystem) << " not supported for TOF event time computation";
506
+
break;
500
507
}
501
508
502
509
if (mComputeEvTimeWithTOF == 1 && mComputeEvTimeWithFT0 == 1) {
@@ -646,7 +653,7 @@ struct tofEventTime {
646
653
LOG(fatal) << "Invalid configuration for TOF event time computation";
647
654
}
648
655
}
649
-
PROCESS_SWITCH(tofEventTime, processRun3, "Process the Run3 data", false);
656
+
PROCESS_SWITCH(tofEventTime, processRun3, "Process the Run3 data", true);
650
657
};
651
658
652
659
// Part 3 Nsigma computation
@@ -1114,11 +1121,15 @@ struct tofPidBeta {
1114
1121
LOG(info) << "No table or process is enabled. Disabling task";
1115
1122
return;
1116
1123
}
1117
-
if (metadataInfo.isFullyDefined()) {
1118
-
if (metadataInfo.isRun3()) {
1119
-
doprocessRun3.value = true;
1120
-
} else {
1121
-
doprocessRun2.value = true;
1124
+
1125
+
if (mTOFCalibConfig.mAutoSetProcessFunctions) {
1126
+
LOG(info) << "Autodetecting process functions";
1127
+
if (metadataInfo.isFullyDefined()) {
1128
+
if (metadataInfo.isRun3()) {
1129
+
doprocessRun3.value = true;
1130
+
} else {
1131
+
doprocessRun2.value = true;
1132
+
}
1122
1133
}
1123
1134
}
1124
1135
@@ -1153,7 +1164,7 @@ struct tofPidBeta {
1153
1164
}
1154
1165
}
1155
1166
}
1156
-
PROCESS_SWITCH(tofPidBeta, processRun2, "Process Run3 data i.e. input is TrackIU. If false, taken from metadata automatically", false);
1167
+
PROCESS_SWITCH(tofPidBeta, processRun2, "Process Run3 data i.e. input is TrackIU. If false, taken from metadata automatically", true);
0 commit comments