13 #pragma GCC diagnostic push
14 #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
15 #include <HepMC/GenEvent.h>
16 #include <HepMC/GenParticle.h>
17 #include <HepMC/GenVertex.h>
18 #include <HepMC/SimpleVector.h>
19 #pragma GCC diagnostic pop
39 PHHepMCGenEventMap *genevtmap = findNode::getClass<PHHepMCGenEventMap>(topNode,
"PHHepMCGenEventMap");
40 for (
auto &iter : *genevtmap)
43 HepMC::GenEvent *evt = genevt->
getEvent();
56 for (
auto v = event->vertices_begin();
v !=
event->vertices_end(); ++
v)
58 HepMC::FourVector
position = (*v)->position();
60 position.setZ(-position.z());
61 position.setX(-position.x());
63 (*v)->set_position(position);
66 for (
auto p = event->particles_begin();
p !=
event->particles_end(); ++
p)
68 HepMC::FourVector
momentum = (*p)->momentum();
70 momentum.setPz(-momentum.pz());
71 momentum.setPx(-momentum.px());
73 (*p)->set_momentum(momentum);