Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

ReconstructedParticleHistogramMaker.h

Go to the documentation of this file.
00001 // ================================================
00002 //ReconstructedParticleHistogramMaker class description
00003 // ================================================
00004 //
00005 // THIS TEXT TO BE REPLACED BY ATLAS ReconstructedParticle FORMAT
00006 //
00007 //
00008 // This version....
00009 //
00010 //
00011 // Namespace Atlfast::
00012 //
00013 // class: ReconstructedParticleHistogramMaker
00014 //
00015 // Description: 
00016 //
00017 //  Algorithm which makes debug histograms for ReconstructedParticles
00018 //
00019 //
00020 // ................................................................
00021 //
00022 
00023 #ifndef ATLFAST_RECONSTRUCTEDPARTICLEHISTOGRAMMAKER_H
00024 #define ATLFAST_RECONSTRUCTEDPARTICLEHISTOGRAMMAKER_H
00025 
00026 // STL
00027 #include <vector>
00028 #include <string>
00029 
00030 // Gaudi 
00031 #include "GaudiKernel/ISvcLocator.h"
00032 #include "GaudiKernel/Algorithm.h"
00033 #include "GaudiKernel/MsgStream.h"
00034 #include "GaudiKernel/DataObject.h"
00035 
00036 class IHistogram1D;  // forward declaration
00037 
00038 // Other
00039 #include "CLHEP/Vector/LorentzVector.h"
00040 #include "HepMC/GenEvent.h"
00041 #include "HepMC/GenParticle.h"
00042 
00043 // Atlfast
00044 #include "AtlfastEvent/ReconstructedParticle.h"
00045 #include "AtlfastUtils/TesIO.h"
00046  
00047 namespace HepMC_helper{
00048   class IMCselector;
00049 }
00050 namespace Atlfast {
00051   using std::string;
00055   class ReconstructedParticleHistogramMaker : public Algorithm{
00056     
00057   public:
00058     
00059     //-------------------------
00060     // Constructors/Destructors
00061     //
00062     // Gaudi requires that the constructor takes certain arguments
00063     // (and passes them directly to the constructor of the base class)
00064     //-------------------------
00065     
00066     ReconstructedParticleHistogramMaker( const std::string& name, ISvcLocator* pSvcLocator ) ; 
00067     ~ReconstructedParticleHistogramMaker();
00068     
00069     
00070     //------------------------------------------------------
00071     // Methods used by Gaudi to run the algorithm
00072     //------------------------------------------------------
00073     
00074     StatusCode initialize() ;
00075     StatusCode execute() ;
00076     StatusCode finalize() ;
00077     
00078     
00079     
00080   private:
00081     TesIO* m_tesIO;
00082     
00083     //-------------------------------
00084     // Private methods
00085     //-------------------------------
00086     void book(
00087               std::vector<IHistogram1D*> & start, 
00088               const std::string title, 
00089               const int nbins, 
00090               const double xmin, 
00091               const double xmax,
00092               const double xminDiff,
00093               const double xmaxDiff
00094               );
00095     
00096     void fill(
00097               std::vector<IHistogram1D*> & start, 
00098               const double rec, 
00099               const double tru
00100               );
00101     
00102     // the following data members tell the
00103     // algorithm where to retrieve its input particles from
00104     // in the TES. These are written by the job Options service.
00105     
00106     std::string m_inputLocation ;
00107     std::string m_mcTruthLocation;
00108     
00109     
00110     
00111     // The following are the actual histograms
00112     // htp has added his own naming convention here
00113     // m_h_ means a histogram!
00114     
00115     // Each quantity to be histogrammed has a vector[4] of histograms
00116     // these correspond to
00117     // [0] = Rec = reconstructed
00118     // [1] = Tru = true
00119     // [2] = Dif = difference, true-rec
00120     // [3] = Res = residual, (true-rec)/true
00121     
00122     // Multiplicity
00123     std::vector<IHistogram1D*> m_h_multiplicity ;
00124     // Energy
00125     std::vector<IHistogram1D*> m_h_energy ;
00126     // Pt
00127     std::vector<IHistogram1D*> m_h_pt ; 
00128     // eta
00129     std::vector<IHistogram1D*> m_h_eta ;
00130     // phi
00131     std::vector<IHistogram1D*> m_h_phi ;
00132     // theta
00133     std::vector<IHistogram1D*> m_h_theta ;
00134     
00135     
00136     
00137     // histogram numbers, start at...
00138     int m_histStart;
00139     // and current count
00140     int m_nHist;
00141     
00142     // particle type to look at
00143     int m_particleType ;
00144     
00145     // prefix for histogram titles
00146     std::string m_histTitle ;
00147     
00148     
00149   //-----------------------------------------------------------------
00150   // Selector to select only those truth particles which are required
00151   //-----------------------------------------------------------------
00152     HepMC_helper::IMCselector*  m_ncutter ;
00153   };
00154   
00155 } // end of namespace bracket
00156 
00157 #endif

Generated on Tue Mar 18 11:18:24 2003 for AtlfastAlgs by doxygen1.3-rc1