Skip to content
Snippets Groups Projects
Commit a4a08463 authored by Dominik Smith's avatar Dominik Smith
Browse files

Improved QA output for event builder and seed finder.

parent de1ceba4
No related branches found
Tags dev_2021_45
1 merge request!563Improved QA output for event builder and seed finder.
Pipeline #13749 passed
......@@ -229,6 +229,7 @@ void run_reco(TString input = "", Int_t nTimeSlices = -1, Int_t firstTimeSlice =
//evBuildRaw->SetReferenceDetector(kRawEventBuilderDetUndef);
//evBuildRaw->AddSeedTimeFillerToList(kRawEventBuilderDetSts);
//evBuildRaw->SetSlidingWindowSeedFinder(1000, 500, 500);
//evBuildRaw->SetSeedFinderQa(true); // optional QA information for seed finder
evBuildRaw->SetTsParameters(0.0, 1.e7, 0.0);
......
......@@ -98,15 +98,19 @@ InitStatus CbmBuildEventsQa::Init()
// --- Init histograms
histFolder = fOutFolder.AddFolder("hist", "Histogramms");
fhCorrectDigiRatioAll = new TH1F("fhCorrectDigiRatioAll", "\% correct digis per event", 1001, 0., 100.1);
fhFoundDigiRatioAll = new TH1F("fhFoundDigiRatioAll", "\% found digis per event", 1001, 0., 100.1);
fhCorrectDigiRatioAll = new TH1F("fhCorrectDigiRatioAll", "Correct digis per event [pct]", 402, -0.25, 100.25);
fhFoundDigiRatioAll = new TH1F("fhFoundDigiRatioAll", "Found digis per event [pct]", 402, -0.25, 100.25);
histFolder->Add(fhCorrectDigiRatioAll);
histFolder->Add(fhFoundDigiRatioAll);
for (ECbmModuleId& system : fSystems) {
TString h1name = "fhCorrectDigiRatio" + CbmModuleList::GetModuleNameCaps(system);
TString h2name = "fhFoundDigiRatio" + CbmModuleList::GetModuleNameCaps(system);
fhMapSystemsCorrectDigi[system] = new TH1F(h1name, "\% correct digis per event", 1001, 0., 100.1);
fhMapSystemsFoundDigi[system] = new TH1F(h2name, "\% found digis per event", 1001, 0., 100.1);
TString h1name = "fhCorrectDigiRatio" + CbmModuleList::GetModuleNameCaps(system);
TString h2name = "fhFoundDigiRatio" + CbmModuleList::GetModuleNameCaps(system);
fhMapSystemsCorrectDigi[system] =
new TH1F(h1name, Form("Correct digis per event, %s [pct]", (CbmModuleList::GetModuleNameCaps(system)).Data()),
402, -0.25, 100.25);
fhMapSystemsFoundDigi[system] =
new TH1F(h2name, Form("Found digis per event, %s [pct]", (CbmModuleList::GetModuleNameCaps(system)).Data()), 402,
-0.25, 100.25);
histFolder->Add(fhMapSystemsCorrectDigi[system]);
histFolder->Add(fhMapSystemsFoundDigi[system]);
}
......
......@@ -87,6 +87,11 @@ void CbmSeedFinderSlidingWindow::FillSeedTimes(const std::vector<inType>* vIn, c
winStartT = GetTime(vIn, j);
}
}
if (vDigiMatch && fvEventMatches) { // QA mode
std::cout << "CbmSeedFinderSlidingWindow::FillSeedTimes(): Found " << GetNofSeeds() << " seeds for this timeslice."
<< std::endl;
}
}
template void CbmSeedFinderSlidingWindow::FillSeedTimes(const std::vector<CbmMuchBeamTimeDigi>*,
const std::vector<CbmMatch>*);
......
......@@ -24,6 +24,7 @@
#include <vector>
#include <stdint.h>
#include <stdio.h>
class CbmMatch;
......@@ -61,6 +62,9 @@ public:
template<class inType>
void FillSeedTimes(const std::vector<inType>* vIn, const std::vector<CbmMatch>* vDigiMatch = nullptr);
/** @brief Returns number of seed times currently stored in buffer. */
size_t GetNofSeeds() { return fvSeedTimes->size(); }
private:
/** @brief Output of the algorithm. Stores seed times for current time slice. */
std::vector<double>* fvSeedTimes = nullptr;
......@@ -96,4 +100,4 @@ private:
*/
void FillEventMatch(int32_t WinStart, int32_t WinEnd, const std::vector<CbmMatch>* vDigiMatch);
};
#endif //CbmSeedFinderSlidingWindow_tmpl
#endif //CbmSeedFinderSlidingWindow_h
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment