CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ShallowEventDataProducer.cc
Go to the documentation of this file.
4 
6  produces <unsigned int> ( "run" );
7  produces <unsigned int> ( "event" );
8  produces <unsigned int> ( "bx" );
9  produces <unsigned int> ( "lumi" );
10  produces <std::vector<bool> > ( "TrigTech" );
11  produces <std::vector<bool> > ( "TrigPh" );
12 }
13 
16 
17 
18  std::auto_ptr<unsigned int > run ( new unsigned int(iEvent.id().run() ) );
19  std::auto_ptr<unsigned int > event ( new unsigned int(iEvent.id().event() ) );
20  std::auto_ptr<unsigned int > bx ( new unsigned int(iEvent.bunchCrossing() ) );
21  std::auto_ptr<unsigned int > lumi ( new unsigned int(iEvent.luminosityBlock() ) );
22 
23 
25  iEvent.getByLabel( edm::InputTag("gtDigis"), gtRecord);
26 
27  std::vector<bool> TrigTech_(64,0);
28  std::vector<bool> TrigPh_(128,0);
29 
30  // Get dWord after masking disabled bits
31  DecisionWord dWord = gtRecord->decisionWord();
32  if ( ! dWord.empty() ) { // if board not there this is zero
33  // loop over dec. bit to get total rate (no overlap)
34  for ( int i = 0; i < 64; ++i ) {
35  TrigPh_[i]= dWord[i];
36  }
37  }
38 
39  TechnicalTriggerWord tw = gtRecord->technicalTriggerWord();
40  if ( ! tw.empty() ) {
41  // loop over dec. bit to get total rate (no overlap)
42  for ( int i = 0; i < 64; ++i ) {
43  TrigTech_[i]=tw[i];
44  }
45  }
46 
47  std::auto_ptr<std::vector<bool> > TrigTech(new std::vector<bool>(TrigTech_));
48  std::auto_ptr<std::vector<bool> > TrigPh(new std::vector<bool>(TrigPh_));
49 
50  iEvent.put( run, "run" );
51  iEvent.put( event, "event" );
52  iEvent.put( bx, "bx" );
53  iEvent.put( lumi, "lumi" );
54  iEvent.put( TrigTech, "TrigTech" );
55  iEvent.put( TrigPh, "TrigPh" );
56 }
RunNumber_t run() const
Definition: EventID.h:42
EventNumber_t event() const
Definition: EventID.h:44
int i
Definition: DBlmapReader.cc:9
tuple lumi
Definition: fjr2json.py:35
int bunchCrossing() const
Definition: EventBase.h:62
edm::LuminosityBlockNumber_t luminosityBlock() const
Definition: EventBase.h:59
int iEvent
Definition: GenABIO.cc:243
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
Definition: Event.h:94
std::vector< bool > DecisionWord
typedefs
std::vector< bool > TechnicalTriggerWord
technical trigger bits (64 bits)
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
Definition: Event.h:361
void produce(edm::Event &, const edm::EventSetup &)
edm::EventID id() const
Definition: EventBase.h:56
ShallowEventDataProducer(const edm::ParameterSet &)