#include <PileupInformation.h>
Private Types | |
typedef std::map < EncodedEventId, unsigned int > | EncodedEventIdToIndex |
typedef std::map< int, int > | myindex |
Private Member Functions | |
void | produce (edm::Event &, const edm::EventSetup &) |
Private Attributes | |
edm::ParameterSet | conf_ |
double | distanceCut_ |
myindex | event_index_ |
bool | LookAtTrackingTruth_ |
std::string | MessageCategory_ |
std::vector< int > | ntrks_highpT |
std::vector< int > | ntrks_lowpT |
edm::EDGetTokenT < PileupMixingContent > | PileupInfoLabel_ |
double | pTcut_1_ |
double | pTcut_2_ |
std::vector< float > | sumpT_highpT |
std::vector< float > | sumpT_lowpT |
edm::EDGetTokenT < TrackingParticleCollection > | trackingTruthT_ |
edm::EDGetTokenT < TrackingVertexCollection > | trackingTruthV_ |
double | volumeRadius_ |
double | volumeZ_ |
std::vector< float > | zpositions |
Additional Inherited Members | |
Public Types inherited from edm::EDProducer | |
typedef EDProducer | ModuleType |
Public Types inherited from edm::ProducerBase | |
typedef ProductRegistryHelper::TypeLabelList | TypeLabelList |
Static Public Member Functions inherited from edm::EDProducer | |
static const std::string & | baseType () |
static void | fillDescriptions (ConfigurationDescriptions &descriptions) |
static void | prevalidate (ConfigurationDescriptions &descriptions) |
Protected Member Functions inherited from edm::ProducerBase | |
void | callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func) |
Protected Member Functions inherited from edm::EDConsumerBase | |
template<typename ProductType , BranchType B = InEvent> | |
EDGetTokenT< ProductType > | consumes (edm::InputTag const &tag) |
EDGetToken | consumes (const TypeToGet &id, edm::InputTag const &tag) |
template<BranchType B> | |
EDGetToken | consumes (TypeToGet const &id, edm::InputTag const &tag) |
ConsumesCollector | consumesCollector () |
Use a ConsumesCollector to gather consumes information from helper functions. More... | |
template<typename ProductType , BranchType B = InEvent> | |
void | consumesMany () |
void | consumesMany (const TypeToGet &id) |
template<BranchType B> | |
void | consumesMany (const TypeToGet &id) |
template<typename ProductType , BranchType B = InEvent> | |
EDGetTokenT< ProductType > | mayConsume (edm::InputTag const &tag) |
EDGetToken | mayConsume (const TypeToGet &id, edm::InputTag const &tag) |
template<BranchType B> | |
EDGetToken | mayConsume (const TypeToGet &id, edm::InputTag const &tag) |
Definition at line 30 of file PileupInformation.h.
|
private |
Definition at line 43 of file PileupInformation.h.
|
private |
Definition at line 44 of file PileupInformation.h.
|
explicit |
Definition at line 21 of file PileupInformation.cc.
References distanceCut_, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), LookAtTrackingTruth_, MessageCategory_, PileupInfoLabel_, pTcut_1_, pTcut_2_, trackingTruthT_, trackingTruthV_, volumeRadius_, and volumeZ_.
|
privatevirtual |
The following code is not valid when there are no Crossing Frames, since all of the vertices will not be in memory at the same time
Collect all the simvertex from the crossing frame edm::Handle<CrossingFrame<SimVertex> > cfSimVertexes; if( event.getByToken(simHitToken_, cfSimVertexes) ) {
Create a mix collection from one simvertex collection simVertexes_ = std::auto_ptr<MixCollection<SimVertex> >( new MixCollection<SimVertex>(cfSimVertexes.product()) );
int index = 0; Solution to the problem of not having vertexId bool FirstL = true; EncodedEventIdToIndex vertexId; EncodedEventId oldEventId; int oldBX = -1000;
std::vector<int> BunchCrossings2; std::list<int> Interactions_Xing2;
Loop for finding repeated vertexId (vertexId problem hack) for (MixCollection<SimVertex>::MixItr iterator = simVertexes_->begin(); iterator != simVertexes_->end(); ++iterator, ++index) { std::cout << " SimVtx eventid, vertexid " << iterator->eventId().event() << " " << iterator->eventId().bunchCrossing() << std::endl; if (!index || iterator->eventId() != oldEventId) { if(iterator->eventId().bunchCrossing()==0 && iterator->eventId().event()==0){ continue; } if(iterator->eventId().bunchCrossing() != oldBX) { BunchCrossings2.push_back(iterator->eventId().bunchCrossing()); Interactions_Xing2.push_back(iterator->eventId().event()); oldBX = iterator->eventId().bunchCrossing(); } else { Interactions_Xing2.pop_back(); Interactions_Xing2.push_back(iterator->eventId().event()); }
oldEventId = iterator->eventId(); continue; } } std::vector<int>::iterator viter; std::list<int>::iterator liter = Interactions_Xing2.begin(); for(viter = BunchCrossings2.begin(); viter != BunchCrossings2.end(); ++viter, ++liter){
std::cout << " bcr, nint from VTX " << (*viter) << " " << (*liter) << std::endl; BunchCrossings.push_back((*viter)); Interactions_Xing.push_back((*liter)); TrueInteractions_Xing.push_back(-1.); // no idea what the true number is }
} // end of "did we find vertices?" end of look at SimVertices
Implements edm::EDProducer.
Definition at line 55 of file PileupInformation.cc.
References event_index_, edm::hlt::Exception, edm::Event::getByToken(), PileupMixingContent::getMix_bunchCrossing(), PileupMixingContent::getMix_Ninteractions(), PileupMixingContent::getMix_TrueInteractions(), cuy::ib, LookAtTrackingTruth_, ntrks_highpT, ntrks_lowpT, PileupInfoLabel_, edm::Handle< T >::product(), pTcut_1_, pTcut_2_, mathSSE::sqrt(), sumpT_highpT, sumpT_lowpT, trackingTruthT_, trackingTruthV_, and zpositions.
|
private |
Definition at line 41 of file PileupInformation.h.
|
private |
Definition at line 54 of file PileupInformation.h.
Referenced by PileupInformation().
|
private |
Definition at line 45 of file PileupInformation.h.
Referenced by produce().
|
private |
Definition at line 64 of file PileupInformation.h.
Referenced by PileupInformation(), and produce().
|
private |
Definition at line 66 of file PileupInformation.h.
Referenced by PileupInformation().
|
private |
Definition at line 51 of file PileupInformation.h.
Referenced by produce().
|
private |
Definition at line 50 of file PileupInformation.h.
Referenced by produce().
|
private |
Definition at line 62 of file PileupInformation.h.
Referenced by PileupInformation(), and produce().
|
private |
Definition at line 57 of file PileupInformation.h.
Referenced by PileupInformation(), and produce().
|
private |
Definition at line 58 of file PileupInformation.h.
Referenced by PileupInformation(), and produce().
|
private |
Definition at line 49 of file PileupInformation.h.
Referenced by produce().
|
private |
Definition at line 48 of file PileupInformation.h.
Referenced by produce().
|
private |
Definition at line 60 of file PileupInformation.h.
Referenced by PileupInformation(), and produce().
|
private |
Definition at line 61 of file PileupInformation.h.
Referenced by PileupInformation(), and produce().
|
private |
Definition at line 55 of file PileupInformation.h.
Referenced by PileupInformation().
|
private |
Definition at line 56 of file PileupInformation.h.
Referenced by PileupInformation().
|
private |
Definition at line 47 of file PileupInformation.h.
Referenced by produce().