/
githubmirror
/
cmssw
Обзор
Документация
Войти
/
githubmirror
/
cmssw
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
GeneratorInterface/Pythia6Interface/plugins/Pythia6Gun.h
82 строки
2 KB
Christopher Jones
Modernize pythia6 related modules
14 окт 2021, 00:28
14 окт 2021, 00:28
063acb1
Код
Авторство
О чём код?
#ifndef gen_Pythia6Gun_h #define gen_Pythia6Gun_h /** \class Pythia6Gun * * Generates single particle gun in HepMC format * Julia Yarba 02/2009 ***************************************/ #include <string> #include <vector> //#include "HepPDT/defs.h" //#include "HepPDT/TableBuilder.hh" //#include "HepPDT/ParticleDataTable.hh" #include "HepMC/GenEvent.h" // #include "FWCore/Framework/interface/ESHandle.h" #include "FWCore/Framework/interface/one/EDProducer.h" #include "GeneratorInterface/Pythia6Interface/interface/Pythia6Service.h" #include "GeneratorInterface/Pythia6Interface/interface/Pythia6Declarations.h" #include "HepPID/ParticleIDTranslations.hh" namespace CLHEP { class HepRandomEngine; } namespace edm { class EventSetup; class LuminosityBlock; } // namespace edm namespace gen { // class Pythia6Service; class Pythia6Gun : public edm::one::EDProducer<edm::one::WatchLuminosityBlocks, edm::one::WatchRuns, edm::one::SharedResources> { public: Pythia6Gun(const edm::ParameterSet&); ~Pythia6Gun() override; void beginJob() override; void beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) override; void endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) final; void beginRun(edm::Run const&, edm::EventSetup const&) override; void endRun(edm::Run const&, edm::EventSetup const&) override; void produce(edm::Event&, const edm::EventSetup&) override; protected: void attachPy6DecaysToGenEvent(); void loadEvent(edm::Event&); virtual void generateEvent(CLHEP::HepRandomEngine*) = 0; HepMC::GenParticle* addAntiParticle(int&, int&, double&, double&, double&); Pythia6Service* fPy6Service; // gun particle(s) characteristics // std::vector<int> fPartIDs; double fMinPhi; double fMaxPhi; // the event format itself // HepMC::GenEvent* fEvt; // HepMC/HepPDT related things // (for particle/event construction) // // edm::ESHandle<HepPDT::ParticleDataTable> fPDGTable ; bool fHepMCVerbosity; int fPylistVerbosity; int fMaxEventsToPrint; }; } // namespace gen #endif