Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:07:19

0001 #ifndef DQM_EcalMonitorTasks_PiZeroTask_H
0002 #define DQM_EcalMonitorTasks_PiZeroTask_H
0003 
0004 #include "DQM/EcalMonitorTasks/interface/DQWorkerTask.h"
0005 #include "DQM/EcalCommon/interface/EcalDQMCommonUtils.h"
0006 
0007 #include "DataFormats/EcalRawData/interface/EcalDCCHeaderBlock.h"
0008 #include "DataFormats/EcalRecHit/interface/EcalRecHitCollections.h"
0009 #include "Geometry/CaloTopology/interface/CaloSubdetectorTopology.h"
0010 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0011 #include "RecoEcal/EgammaCoreTools/interface/PositionCalc.h"
0012 
0013 #include "TVector3.h"
0014 
0015 namespace ecaldqm {
0016 
0017   class PiZeroTask : public DQWorkerTask {
0018   public:
0019     PiZeroTask();
0020     ~PiZeroTask() override = default;
0021 
0022     bool filterRunType(short const*) override;
0023     bool analyze(void const*, Collections) override;
0024     void runOnEBRecHits(EcalRecHitCollection const&);
0025 
0026   private:
0027     void setParams(edm::ParameterSet const&) override;
0028 
0029     static const int MAXCLUS = 2000;
0030     static const int MAXPI0S = 200;
0031 
0032     // Parameters needed for pi0 finding
0033     double seleXtalMinEnergy_;
0034 
0035     double clusSeedThr_;
0036     int clusEtaSize_;
0037     int clusPhiSize_;
0038 
0039     double selePtGammaOne_;
0040     double selePtGammaTwo_;
0041     double seleS4S9GammaOne_;
0042     double seleS4S9GammaTwo_;
0043     double selePtPi0_;
0044     double selePi0Iso_;
0045     double selePi0BeltDR_;
0046     double selePi0BeltDeta_;
0047     double seleMinvMaxPi0_;
0048     double seleMinvMinPi0_;
0049 
0050     edm::ParameterSet posCalcParameters_;
0051   };
0052 
0053   inline bool PiZeroTask::analyze(void const* collection_data, Collections collection) {
0054     switch (collection) {
0055       case kEBRecHit:
0056         if (collection_data)
0057           runOnEBRecHits(*static_cast<EcalRecHitCollection const*>(collection_data));
0058         return true;
0059       case kEERecHit:  // This module does not run on EERecHits
0060         break;
0061       default:
0062         break;
0063     }
0064 
0065     return false;
0066   }
0067 
0068 }  // namespace ecaldqm
0069 
0070 #endif