PandaRoot
BSEmcLocalMaxFindingProcess.h
Go to the documentation of this file.
1 //--------------------------------------------------------------------------
2 // Description:
3 // Class EmcERatioLocMaxMaxFinder./
4 // Searches for local maxima in a cluster based on the ratio
5 // between the energy of the maxima crystal and that of
6 // its neighbours
7 //
8 // Environment:
9 // Software developed for the BaBar Detector at the SLAC B-Factory.
10 //
11 // Adapted for the PANDA experiment at GSI
12 //
13 // Author List:
14 // Phil Strother
15 // Helmut Schmuecker Ruhr-Uni Bochum
16 //
17 // Copyright Information:
18 // Copyright (C) 1997 Imperial College
19 // Modified:
20 // M. Babai
21 //------------------------------------------------------------------------
22 //#pragma once
23 #ifndef BSEMCLOCALMAXFINDINGPROCESS_HH
24 #define BSEMCLOCALMAXFINDINGPROCESS_HH
25 #include <string>
26 #include <vector>
27 
28 #include "Rtypes.h"
29 #include "RtypesCore.h"
30 
31 #include "PndContainerI.h"
32 #include "PndParameterRegister.h"
33 #include "PndProcess.h"
34 
35 #include "BSEmcCluster.h"
36 
38 
39 class BSEmcClusteringPar;
40 class BSEmcDigi;
41 class FairParGenericSet;
42 class BSEmcCluster;
45 class TBuffer;
46 class TClass;
47 class TMemberInspector;
48 struct BSEmcClusteringData;
49 struct BSEmcDigiInfo_t;
50 template <class T>
51 class PndContainerI;
52 template <class T>
54 
67  public:
70  virtual void SetDetectorName(const std::string &t_detectorName) /*override*/;
71  virtual void SetupParameters(const PndParameterRegister *t_parameterRegister) /*override*/;
72  virtual void RequestDataContainer(PndContainerRegister *t_register) /*override*/;
73  virtual void GetDataContainer(PndContainerRegister *t_register) /*override*/;
74  virtual void Process() /*override*/;
75  void FindLocalMaxima(const std::vector<const BSEmcDigi *> &t_digiCont, const std::vector<BSEmcCluster *> &t_clusterCont);
76  void SetClusteringParName(const std::string &t_parName) { fClusteringParName = t_parName; }
77  void SetNeighbouringRelationParName(const std::string &t_parName) { fNeighbouringRelationParName = t_parName; }
78 
79  void SetDigiBranchName(const TString &t_branchname) { fDigiBranchname = t_branchname; }
80  void SetClusterBranchName(const TString &t_branchname) { fClusterBranchname = t_branchname; }
81 
82  protected:
83  Bool_t IsLocalMaximum(const BSEmcDigi *t_digi, const std::vector<const BSEmcDigi *> &t_neighbours) const;
84  std::vector<const BSEmcDigi *>
85  GetNeigboursOf(const std::vector<const BSEmcDigi *> &t_digiCont, const BSEmcDigiInfo_t &t_digi, const std::vector<BSEmcDigiInfo_t> &t_potentialneighbours) const;
86 
87  private:
88  std::string fClusteringParName{""};
89  std::string fNeighbouringRelationParName{""};
90 
91  TString fDigiBranchname{""};
92  TString fClusterBranchname{""};
93 
94  PndContainerI<BSEmcDigi> *fDigiArray{nullptr};
95  PndMutableContainerI<BSEmcCluster> *fClusterArray{nullptr};
96  Double_t fMaximumsEnergyThreshold{-1};
97  BSEmcGeoNeighbouringRelationPar *fNeighbouringRelationPar{nullptr};
98  ClassDef(BSEmcLocalMaxFindingProcess, 1);
99 };
100 
101 #endif /*BSEMCLOCALMAXFINDINGPROCESS_HH*/
virtual void Process()
The actual data transformation (digitizing, clustering, etc.) should be defined here.
Base Process class.
Definition: PndProcess.h:24
Container for clustering parameter.
std::vector< const BSEmcDigi * > GetNeigboursOf(const std::vector< const BSEmcDigi *> &t_digiCont, const BSEmcDigiInfo_t &t_digi, const std::vector< BSEmcDigiInfo_t > &t_potentialneighbours) const
virtual ~BSEmcLocalMaxFindingProcess()
Process to find all local maxima within a cluster.
virtual void SetDetectorName(const std::string &t_detectorName)
Set the Detector name. Important, as most EmcParameter need to know for which detector they need to b...
void SetClusteringParName(const std::string &t_parName)
void SetNeighbouringRelationParName(const std::string &t_parName)
virtual void RequestDataContainer(PndContainerRegister *t_register)
Pass the container register to the process, and get the processes container requirements.
void SetClusterBranchName(const TString &t_branchname)
a cluster (group of neighboring crystals) of hit emc crystals
Definition: BSEmcCluster.h:54
represents the reconstructed hit of one emc crystal
Definition: BSEmcDigi.h:47
virtual void SetupParameters(const PndParameterRegister *t_parameterRegister)
Fetch all parameters from the PndParameterRegister.
Interface to a datacontainer to be used in PandaROOT.
virtual void GetDataContainer(PndContainerRegister *t_register)
Pass the container register to the process, and set the processes container requirements.
Helper class to indirect the Parameter fetching via the FairRuntimeDb.
Neigbouring Relations based on a list of detectorIds.
void FindLocalMaxima(const std::vector< const BSEmcDigi *> &t_digiCont, const std::vector< BSEmcCluster *> &t_clusterCont)
void SetDigiBranchName(const TString &t_branchname)
simple Struct used in Cluster classes to index crystal. Includes the weight of the crystal on the cur...
Definition: BSEmcCluster.h:39
Bool_t IsLocalMaximum(const BSEmcDigi *t_digi, const std::vector< const BSEmcDigi *> &t_neighbours) const