1 #ifndef __KVFILTERGROUPRECONSTRUCTOR_H
2 #define __KVFILTERGROUPRECONSTRUCTOR_H
4 #include "KVGroupReconstructor.h"
5 #include "KVDataQualityAudit.h"
6 #include <unordered_map>
25 std::unique_ptr<KVEvent> fSimEvent;
26 std::unordered_map<std::string, int> hits;
27 std::unordered_map<KVReconstructedNucleus*, TList> part_correspond;
30 std::unordered_map<std::string, double> energy_loss;
31 std::unordered_map<std::string, int> number_uncalibrated;
32 std::unordered_map<std::string, int> number_unidentified;
36 void PerformSecondaryAnalysis();
43 bool audit_has_telescope_with_name(
const TString&
n)
const
47 bool has_audit()
const
49 return fDataQAudit!=
nullptr;
51 static std::unordered_map<std::string,bool> audit_id_extensions;
52 bool can_extend_identification_beyond_audit(
const std::string& id_label)
54 return audit_id_extensions[id_label];
63 ::Info(
"KVFilterGroupReconstructor::EnableIDExtensionBeyondAudit()",
"%s", idlab.
Data());
64 audit_id_extensions[idlab.
Data()]=
true;
65 audit_id_extensions[
"initialised"]=
true;
76 fSimEvent.reset(
static_cast<KVEvent*
>(
e->IsA()->New()));
86 n->Copy(*(nuc = fSimEvent->AddNucleus()));
93 KVString s_traj(
n->GetParameters()->GetStringValue(
"TRAJECTORY"));
100 int most_dets_on_traj = 0;
102 for(
auto _traj : *stop_det->GetNode()->GetTrajectories())
111 ndets+=traj->Contains(s_traj.
Next());
113 if(ndets>most_dets_on_traj)
115 most_dets_on_traj=ndets;
122 KVError::Error(
this,
"AddSimParticle",
"Could not find trajectory to suit this particle:");
138 while (
auto node = traj->GetNextNode()) {
140 ++number_unidentified[node->
GetName()];
145 de_tot +=
np->GetDouble();
156 part_correspond.clear();
158 number_uncalibrated.clear();
159 number_unidentified.clear();
#define ClassDefOverride(name, id)
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t np
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t g
Audit of experimental data identification and calibrations.
Bool_t HasTelescope(const TString &tel_name) const
Abstract base class container for multi-particle events.
Reconstruct particles in group of detectors after filtering simulated events.
void IdentifyParticle(KVReconstructedNucleus &PART) override
void Clear(Option_t *="") override
static void EnableIDExtensionBeyondAudit(const TString &idlab)
void AddSimParticle(const KVNucleus *n)
void ReconstructParticle(KVReconstructedNucleus *part, const KVGeoDNTrajectory *traj, const KVGeoDetectorNode *node) override
KVFilterGroupReconstructor(const KVGroup *g=nullptr)
void SetSimEvent(KVEvent *e)
void SetDataQualityAudit(const KVDataQualityAudit *DQA)
void CalibrateParticle(KVReconstructedNucleus *PART) override
Path taken by particles through multidetector geometry.
KVGeoDetectorNode * GetNode(const Char_t *name) const
Information on relative positions of detectors & particle trajectories.
const Char_t * GetName() const override
Name of node is same as name of associated detector.
void Print(Option_t *option="") const override
virtual KVDetector * GetDetector(const Char_t *name) const
Return detector in this structure with given name.
Base class for particle reconstruction in one group of a detector array.
KVGroup * GetGroup() const
Group of detectors which can be treated independently of all others in array.
const KVGeoDNTrajectory * FindReconTraj(const KVString &path)
const KVGeoDNTrajectory * GetTrajectoryForReconstruction(const KVGeoDNTrajectory *t, const KVGeoDetectorNode *n) const
Base class for all detectors or associations of detectors in array which can identify charged particl...
Full result of one attempted particle identification.
KVNamedParameter * FindParameter(const Char_t *name) const
return the parameter object with the asking name
A generic named parameter storing values of different types.
Description of properties and kinematics of atomic nuclei.
KVNameValueList * GetParameters() const
void SetParameter(const Char_t *name, ValType value) const
Path through detector array used to reconstruct detected particle.
Nuclei reconstructed from data measured by a detector array .
Extension of ROOT TString class which allows backwards compatibility with ROOT v3....
void Begin(TString delim) const
KVString Next(Bool_t strip_whitespace=kFALSE) const
const char * GetName() const override
virtual void Info(const char *method, const char *msgfmt,...) const
const char * Data() const
void Error(UserClass p, const char *location, const char *va_(fmt),...)