Skip to content

Commit

Permalink
Add QA mode 2 to E-by-E T0 code (#486)
Browse files Browse the repository at this point in the history
Small change to help QA calibrations.
  • Loading branch information
genevb authored Jan 28, 2023
1 parent 01e1e34 commit f464ae7
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion StRoot/StEventUtilities/StEbyET0.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,13 @@ double StEbyET0::getTime(StEvent* event, int mode) {

mRunId = event->runId();
mEventId = event->id();
mTime = 0.; // default event time should always be zero, not correcting for some other global T0

// check for calibration mode
// fill tree without mTime subtracted
if (mode == 1) fillTree(event);

// determine event time
mTime = 0.; // default should always be zero, not correcting for some other global T0
double info[12];
St_EbyET0C* ebyeTable = St_EbyET0C::instance();
for (int row = 0; row < ebyeTable->GetNRows(); row++) {
Expand Down Expand Up @@ -95,6 +96,10 @@ double StEbyET0::getTime(StEvent* event, int mode) {
break;
}

// check for QA mode
// fill tree with mTime added
if (mode == 2) fillTree(event);

return mTime;
}
//_____________________________________________________________________________
Expand Down Expand Up @@ -217,6 +222,9 @@ void StEbyET0::getTpcInfo(StEvent* event, double* info) {
// because constant shifts aren't relavant for the EbyET0 calibration
double time = coorS.position().z() / (StTpcDb::instance()->DriftVelocity()*1e-6);
// apply the EbyE T0 time correction (if it is already determined)
time += mTime;
if (innerRow) {
if (tb < innerMaxTB && tb > innerMinTB) { // use only prompt hit candidates
if (sector <= 12) {
Expand Down

0 comments on commit f464ae7

Please sign in to comment.