Skip to content

Commit

Permalink
Merge pull request #958 in B2/basf2 from bugfix/BII-9318-exclude-bad-…
Browse files Browse the repository at this point in the history
…tdc-in-calculating-the-mean-of-edges-r61 to release/06-01

* commit '4be67cac4b4f1b8d53562fd8a25a4714089aa6c3':
  exclude bad tdc in calculating the mean of edges
  • Loading branch information
GiacomoXT committed Apr 23, 2022
2 parents f822e8d + 4be67ca commit f3d744b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dqm/analysis/modules/src/DQMHistAnalysisCDCMonObj.cc
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ void DQMHistAnalysisCDCMonObjModule::endRun()
}
// TDC related
B2DEBUG(20, "tdc related");
int nDeadTDC = 1; // bid 0 always empty
int nDeadTDC = -1; // bid 0 always empty
TH1F* hTDCEdge = new TH1F("hTDCEdge", "TDC edge;board;tdc edge [nsec]", 300, 0, 300);
TH1F* hTDCSlope = new TH1F("hTDCSlope", "TDC slope;board;tdc slope [nsec]", 300, 0, 300);
std::vector<float> tdcEdges = {};
Expand Down Expand Up @@ -435,7 +435,7 @@ void DQMHistAnalysisCDCMonObjModule::endRun()
m_monObj->setVariable("adcMean", std::accumulate(means.begin(), means.end(), 0.0) / means.size());
m_monObj->setVariable("nDeadADC", nDeadADC);
m_monObj->setVariable("nBadADC", nBadADC); //???? n_0/n_tot>0.9
m_monObj->setVariable("tdcEdge", std::accumulate(tdcEdges.begin(), tdcEdges.end(), 0.0) / tdcEdges.size());
m_monObj->setVariable("tdcEdge", std::accumulate(tdcEdges.begin(), tdcEdges.end(), 0.0) / (tdcEdges.size() - 1 - nDeadTDC));
m_monObj->setVariable("nDeadTDC", nDeadTDC);
m_monObj->setVariable("tdcSlope", std::accumulate(tdcSlopes.begin(), tdcSlopes.end(), 0.0) / tdcSlopes.size());

Expand Down

0 comments on commit f3d744b

Please sign in to comment.