File indexing completed on 2024-04-06 12:30:40
0001 #ifndef SimGeneral_PreMixingModule_PreMixingPileupCopy_h
0002 #define SimGeneral_PreMixingModule_PreMixingPileupCopy_h
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012 #include "FWCore/Framework/interface/Event.h"
0013 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0014 #include "FWCore/Framework/interface/ConsumesCollector.h"
0015 #include "FWCore/Framework/interface/ProducesCollector.h"
0016
0017 #include "DataFormats/Provenance/interface/ProductID.h"
0018 #include "DataFormats/Common/interface/Handle.h"
0019
0020 #include "SimDataFormats/PileupSummaryInfo/interface/PileupSummaryInfo.h"
0021 #include "SimDataFormats/CrossingFrame/interface/CrossingFramePlaybackInfoNew.h"
0022
0023 #include <vector>
0024 #include <string>
0025
0026 namespace reco {
0027 class GenParticle;
0028 }
0029 class PileUpEventPrincipal;
0030
0031 namespace edm {
0032 class ModuleCallingContext;
0033
0034 class PreMixingPileupCopy {
0035 public:
0036 PreMixingPileupCopy(const edm::ParameterSet& ps, edm::ProducesCollector, edm::ConsumesCollector&& iC);
0037 ~PreMixingPileupCopy() = default;
0038
0039 float getTrueNumInteractions(PileUpEventPrincipal const& pep) const;
0040
0041 void addPileupInfo(PileUpEventPrincipal const& pep);
0042 const std::vector<PileupSummaryInfo>& getPileupSummaryInfo() const { return pileupSummaryStorage_; }
0043 int getBunchSpacing() const { return bsStorage_; }
0044 void putPileupInfo(edm::Event& e);
0045
0046 private:
0047 edm::InputTag pileupInfoInputTag_;
0048 edm::InputTag bunchSpacingInputTag_;
0049 edm::InputTag cfPlaybackInputTag_;
0050
0051 std::vector<edm::InputTag> genPUProtonsInputTags_;
0052
0053
0054 CrossingFramePlaybackInfoNew crossingFramePlaybackStorage_;
0055 std::vector<PileupSummaryInfo> pileupSummaryStorage_;
0056 int bsStorage_;
0057
0058 std::vector<std::string> genPUProtons_labels_;
0059 std::vector<std::vector<reco::GenParticle> > genPUProtons_;
0060
0061 bool foundPlayback_;
0062 };
0063 }
0064
0065 #endif