Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 11:57:35

0001 #ifndef ROOT_TEcnaHeader
0002 #define ROOT_TEcnaHeader
0003 
0004 //////////////////////////////////////////////////////////////////////////
0005 //                                                                      //
0006 // TEcnaHeader   Header of CNA ROOT file                                 //
0007 //                                                                      //
0008 //                                                                      //
0009 //                                                                      //
0010 //////////////////////////////////////////////////////////////////////////
0011 #include "TROOT.h"
0012 #include "TObject.h"
0013 #include "TString.h"
0014 #include "TNamed.h"
0015 #include "Riostream.h"
0016 #include <ctime>
0017 #include <TMath.h>
0018 
0019 #include "CalibCalorimetry/EcalCorrelatedNoiseAnalysisAlgos/interface/TEcnaObject.h"
0020 
0021 ///-----------------------------------------------------------
0022 ///   TEcnaHeader.h
0023 ///   Update: 05/05/2012
0024 ///   Authors:   FX Gentit, B.Fabbro (bernard.fabbro@cea.fr)
0025 ///              DSM/IRFU/SPP CEA-Saclay
0026 ///   Copyright: Those valid for CEA sofware
0027 ///
0028 ///   ECNA web page:
0029 ///     http://cms-fabbro.web.cern.ch/cms-fabbro/
0030 ///     cna_new/Correlated_Noise_Analysis/ECNA_main_page.htm
0031 ///-----------------------------------------------------------
0032 ///
0033 ///   Header of ECNA result file (.root file)
0034 ///
0035 
0036 class TEcnaHeader : public TNamed {
0037 protected:
0038   void Init();
0039 
0040 public:
0041   Int_t fCnew;
0042   Int_t fCdelete;
0043 
0044   Int_t fgMaxCar;  // Max nb of caracters for char*
0045 
0046   //....... Header parameters
0047   TString fTypAna;           // name of the analysis (default = "std")
0048   Int_t fNbOfSamples;        // Number of samples for calculations
0049   Int_t fRunNumber;          // Run number
0050   Int_t fFirstReqEvtNumber;  // First requested event number
0051   Int_t fLastReqEvtNumber;   // Number of taken evts
0052   Int_t fReqNbOfEvts;        // Requested number of events
0053   Int_t fStex;               // Stex number
0054 
0055   time_t fStartTime;   // Start time
0056   time_t fStopTime;    // Stop time
0057   TString fStartDate;  // Start date
0058   TString fStopDate;   // Stop date
0059 
0060   Int_t fRunType;  // run type
0061 
0062   //....... Header counters
0063   Int_t fStinNumbersCalc;  // Nb of entries of type StinNumbers
0064   Int_t fNbOfEvtsCalc;     // Nb of entries of type NbOfEvts
0065 
0066   Int_t fAdcEvtCalc;  // *Nb of entries of type SampTime
0067   Int_t fMSpCalc;     // *Nb of entries of type Ev
0068   Int_t fSSpCalc;     // *Nb of entries of type Var
0069   Int_t fAvTnoCalc;   // *Nb of entries of type AvTotn
0070   Int_t fAvLfnCalc;   // *Nb of entries of type AvLfn
0071   Int_t fAvHfnCalc;   // *Nb of entries of type AvHfn
0072 
0073   Int_t fCovCssCalc;       // *Nb of entries of type CovCss
0074   Int_t fCorCssCalc;       // *Nb of entries of type CorCss
0075   Int_t fHfCovCalc;        // *Nb of entries of type HfCov
0076   Int_t fHfCorCalc;        // *Nb of entries of type HfCor
0077   Int_t fLfCovCalc;        // *Nb of entries of type LfCov
0078   Int_t fLfCorCalc;        // *Nb of entries of type LfCor
0079   Int_t fLFccMoStinsCalc;  // *Nb of entries of type LFccMoStins
0080   Int_t fHFccMoStinsCalc;  // *Nb of entries of type HFccMoStins
0081   Int_t fPedCalc;          // *Nb of entries of type Ped
0082   Int_t fTnoCalc;          // *Nb of entries of type Tno
0083   Int_t fMeanCorssCalc;    // *Nb of entries of type EvCorCss
0084   Int_t fLfnCalc;          // *Nb of entries of type Lfn
0085   Int_t fHfnCalc;          // *Nb of entries of type Hfn
0086   Int_t fSigCorssCalc;     // *Nb of entries of type SigCorCss
0087 
0088   Int_t fAvPedCalc;        // *Nb of entries of type AvPed
0089   Int_t fAvMeanCorssCalc;  // *Nb of entries of type AvEvCorss
0090   Int_t fAvSigCorssCalc;   // *Nb of entries of type AvSigCorss
0091 
0092   //------------------------------- methods
0093   TEcnaHeader();
0094   TEcnaHeader(TEcnaObject*, const Text_t*, const Text_t*);
0095   //TEcnaHeader(const Text_t*, const Text_t*);
0096   ~TEcnaHeader() override;
0097 
0098   //  void HeaderParameters(Text_t*, Text_t*, const TString&,      const Int_t&,
0099   //              const Int_t&,     const Int_t&, const Int_t&, const Int_t&,
0100   //                const  Int_t&);
0101   //  void HeaderParameters(Text_t*,  Text_t*, const TString&,    const Int_t&,
0102   //            const Int_t&,    const Int_t&, const Int_t&, const Int_t&);
0103 
0104   void HeaderParameters(
0105       const TString&, const Int_t&, const Int_t&, const Int_t&, const Int_t&, const Int_t&, const Int_t&);
0106   void HeaderParameters(
0107       const TString&, const Int_t&, const Int_t&, const Int_t&, const Int_t&, const Int_t&, const Int_t&, const Int_t&);
0108 
0109   using TNamed::Print;
0110   void Print();
0111   ClassDefOverride(TEcnaHeader, 1)  //Header of CNA ROOT file
0112 };
0113 #endif