48 nameProcess_( iConfig.getParameter< std::string >(
"processName" ) ),
49 autoProcessName_( nameProcess_ ==
"*" ),
50 onlyStandAlone_( iConfig.getParameter< bool >(
"onlyStandAlone" ) ),
54 tagL1GlobalTriggerObjectMaps_(
"l1L1GtObjectMap" ),
63 autoProcessNameL1ExtraMu_(
false ),
64 autoProcessNameL1ExtraNoIsoEG_(
false ),
65 autoProcessNameL1ExtraIsoEG_(
false ),
66 autoProcessNameL1ExtraCenJet_(
false ),
67 autoProcessNameL1ExtraForJet_(
false ),
68 autoProcessNameL1ExtraTauJet_(
false ),
69 autoProcessNameL1ExtraETM_(
false ),
70 autoProcessNameL1ExtraHTM_(
false ),
74 hltConfigInit_(
false ),
76 tagTriggerResults_(
"TriggerResults" ),
77 tagTriggerEvent_(
"hltTriggerSummaryAOD" ),
79 labelHltPrescaleTable_(),
80 hltPrescaleTableRun_(),
81 hltPrescaleTableLumi_(),
82 addPathModuleLabels_(
false )
88 if ( iConfig.
exists(
"l1ExtraMu" ) ) {
95 if ( iConfig.
exists(
"l1ExtraNoIsoEG" ) ) {
102 if ( iConfig.
exists(
"l1ExtraIsoEG" ) ) {
109 if ( iConfig.
exists(
"l1ExtraCenJet" ) ) {
116 if ( iConfig.
exists(
"l1ExtraForJet" ) ) {
123 if ( iConfig.
exists(
"l1ExtraTauJet" ) ) {
130 if ( iConfig.
exists(
"l1ExtraETM" ) ) {
137 if ( iConfig.
exists(
"l1ExtraHTM" ) ) {
157 produces< TriggerAlgorithmCollection >();
158 produces< TriggerConditionCollection >();
159 produces< TriggerPathCollection >();
160 produces< TriggerFilterCollection >();
161 produces< TriggerObjectCollection >();
163 produces< TriggerObjectStandAloneCollection >();
186 if ( processHistory.getConfigurationForProcess( iHist->processName(), processConfiguration ) &&
196 LogError(
"autoProcessName" ) <<
"trigger::TriggerEvent product with label '" <<
tagTriggerEvent_.
label() <<
"' not produced according to process history of input data\n"
197 <<
"No trigger information produced";
200 LogInfo(
"autoProcessName" ) <<
"HLT process name' " <<
nameProcess_ <<
"' used for PAT trigger information";
223 bool changed(
true );
225 LogError(
"hltConfig" ) <<
"HLT config extraction error with process name '" <<
nameProcess_ <<
"'";
227 LogError(
"hltConfig" ) <<
"HLT config size error";
241 if ( handleHltPrescaleTable.
isValid() ) {
264 if ( handleHltPrescaleTable.
isValid() ) {
291 if( ! handleTriggerResults.
isValid() ) {
293 <<
"No HLT information produced";
295 }
else if ( ! handleTriggerEvent.
isValid() ) {
297 <<
"No HLT information produced";
313 if ( handleHltPrescaleTable.
isValid() ) {
314 hltPrescaleTable =
trigger::HLTPrescaleTable( handleHltPrescaleTable->set(), handleHltPrescaleTable->labels(), handleHltPrescaleTable->table() );
318 if ( hltPrescaleTable.size() == 0 ) {
321 <<
"Using default from event setup";
326 LogDebug(
"hltPrescaleTable" ) <<
"HLT prescale table found in event setup";
328 LogWarning(
"hltPrescaleSet" ) <<
"HLTPrescaleTable from event setup has error";
332 unsigned set( hltPrescaleTable.set() );
333 if ( hltPrescaleTable.size() > 0 ) {
335 bool foundPrescaleLabel(
false );
336 for (
unsigned iLabel = 0; iLabel < hltPrescaleTable.labels().size(); ++iLabel ) {
339 foundPrescaleLabel =
true;
343 if ( ! foundPrescaleLabel ) {
350 LogError(
"hltPrescaleTable" ) <<
"No HLT prescale table found\n"
351 <<
"Using default empty table with all prescales 1";
356 const unsigned sizeFilters( handleTriggerEvent->sizeFilters() );
357 const unsigned sizeObjects( handleTriggerEvent->sizeObjects() );
359 std::map< std::string, int > moduleStates;
363 triggerPaths->reserve( sizePaths );
365 for (
size_t indexPath = 0; indexPath < sizePaths; ++indexPath ) {
366 const std::string & namePath = pathNames.at( indexPath );
367 unsigned indexLastFilterPathModules( handleTriggerResults->index( indexPath ) + 1 );
368 unsigned indexLastFilterFilters( sizeFilters );
369 while ( indexLastFilterPathModules > 0 ) {
370 --indexLastFilterPathModules;
371 const std::string & labelLastFilterPathModules(
hltConfig_.
moduleLabel( indexPath, indexLastFilterPathModules ) );
372 indexLastFilterFilters = handleTriggerEvent->filterIndex(
InputTag( labelLastFilterPathModules,
"",
nameProcess_ ) );
373 if ( indexLastFilterFilters < sizeFilters ) {
381 assert( indexLastFilterPathModules < sizeModulesPath );
382 std::map< unsigned, std::string > indicesModules;
383 for (
size_t iM = 0; iM < sizeModulesPath; ++iM ) {
386 triggerPath.addModule( nameModule );
388 const unsigned indexFilter( handleTriggerEvent->filterIndex(
InputTag( nameModule,
"",
nameProcess_ ) ) );
389 if ( indexFilter < sizeFilters ) {
390 triggerPath.addFilterIndex( indexFilter );
393 indicesModules.insert( std::pair< unsigned, std::string >( slotModule, nameModule ) );
397 for ( L1SeedCollection::const_iterator iSeed = l1Seeds.begin(); iSeed != l1Seeds.end(); ++iSeed ) {
398 triggerPath.addL1Seed( *iSeed );
401 triggerPaths->push_back( triggerPath );
403 for ( std::map< unsigned, std::string >::const_iterator iM = indicesModules.begin(); iM != indicesModules.end(); ++iM ) {
404 if ( iM->first < indexLastFilterPathModules ) {
405 moduleStates[ iM->second ] = 1;
406 }
else if ( iM->first == indexLastFilterPathModules ) {
407 moduleStates[ iM->second ] = handleTriggerResults->accept( indexPath );
408 }
else if ( moduleStates.find( iM->second ) == moduleStates.end() ) {
409 moduleStates[ iM->second ] = -1;
414 iEvent.
put( triggerPaths );
420 std::multimap< trigger::size_type, int > objectTypes;
421 std::multimap< trigger::size_type, std::string > filterLabels;
423 for (
size_t iF = 0; iF < sizeFilters; ++iF ) {
424 const std::string nameFilter( handleTriggerEvent->filterLabel( iF ) );
426 const trigger::Vids & types = handleTriggerEvent->filterIds( iF );
427 assert( types.size() == keys.size() );
428 for (
size_t iK = 0; iK < keys.size(); ++iK ) {
429 filterLabels.insert( std::pair< trigger::size_type, std::string >( keys[ iK ], nameFilter ) );
430 objectTypes.insert( std::pair< trigger::size_type, int >( keys[ iK ], types[ iK ] ) );
437 triggerObjectsStandAlone->reserve( sizeObjects );
439 const trigger::Keys & collectionKeys( handleTriggerEvent->collectionKeys() );
440 std::map< trigger::size_type, trigger::size_type > newObjectKeys;
441 for (
size_t iO = 0, iC = 0, nC = handleTriggerEvent->sizeCollections(); iO < sizeObjects && iC < nC; ++iO ) {
445 while ( iO >= collectionKeys[ iC ] ) ++iC;
446 triggerObject.
setCollection( handleTriggerEvent->collectionTagEncoded( iC ) );
448 typedef std::multimap< trigger::size_type, int >::const_iterator it_type;
449 for (std::pair<it_type,it_type> trange = objectTypes.equal_range(iO);
450 trange.first != trange.second; ++trange.first) {
451 triggerObject.addTriggerObjectType( trange.first->second );
457 bool excluded(
false );
465 if ( excluded )
continue;
466 typedef std::multimap< trigger::size_type, std::string >::const_iterator it_fl;
467 for (std::pair<it_fl,it_fl> frange = filterLabels.equal_range(iO); frange.first != frange.second; ++frange.first) {
470 for (std::vector<ModuleLabelToPathAndFlags::PathAndFlags>::const_iterator iP = paths.begin(); iP != paths.end(); ++iP) {
471 bool pathFired = handleTriggerResults->wasrun( iP->pathIndex ) && handleTriggerResults->accept( iP->pathIndex );
472 triggerObjectStandAlone.
addPathName( iP->pathName, pathFired && iP->lastFilter, pathFired && iP->l3Filter );
476 triggerObjectsStandAlone->push_back( triggerObjectStandAlone );
478 triggerObjects->push_back( triggerObject );
486 triggerFilters->reserve( sizeFilters );
487 for (
size_t iF = 0; iF < sizeFilters; ++iF ) {
488 const std::string nameFilter( handleTriggerEvent->filterTag( iF ).label() );
490 const trigger::Vids & types = handleTriggerEvent->filterIds( iF );
494 triggerFilter.
setType( typeFilter );
497 for (
size_t iK = 0; iK < keys.size(); ++iK ) {
499 if ( newObjectKeys.find( keys.at( iK ) ) != newObjectKeys.end() ) {
500 if ( newObjectKeys[ keys.at( iK ) ] == sizeObjects )
continue;
501 triggerFilter.
addObjectKey( newObjectKeys[ keys.at( iK ) ] );
504 LogWarning(
"triggerObjectKey" ) <<
"TriggerFilter '" << nameFilter <<
"' requests non-existing TriggerObject key " << keys.at( iK ) <<
"\n"
505 <<
"Skipping object assignment";
509 std::map< std::string, int >::iterator iS( moduleStates.find( nameFilter ) );
510 if ( iS != moduleStates.end() ) {
511 if ( ! triggerFilter.
setStatus( iS->second ) ) {
518 triggerFilters->push_back( triggerFilter );
521 iEvent.
put( triggerFilters );
530 std::map< L1GtObject, std::vector< unsigned > > l1ObjectTypeMap;
534 if ( handleL1ExtraMu.
isValid() ) {
535 std::vector< unsigned > muKeys;
536 for (
size_t l1Mu = 0; l1Mu < handleL1ExtraMu->size(); ++l1Mu ) {
537 if (
mainBxOnly_ && handleL1ExtraMu->at( l1Mu ).bx() != 0 )
continue;
543 const reco::LeafCandidate leafCandidate( *( handleL1ExtraMu->at( l1Mu ).reco::LeafCandidate::clone() ) );
550 triggerObjectsStandAlone->push_back( triggerObjectStandAlone );
551 if ( handleL1ExtraMu->at( l1Mu ).bx() == 0 ) muKeys.push_back( triggerObjectsStandAlone->size() - 1 );
553 l1ObjectTypeMap.insert( std::make_pair(
Mu, muKeys ) );
554 }
else LogError(
"l1ExtraValid" ) <<
"l1extra::L1MuonParticleCollection product with InputTag '" <<
tagL1ExtraMu_.
encode() <<
"' not in event";
559 if ( handleL1ExtraNoIsoEG.
isValid() ) {
560 std::vector< unsigned > noIsoEGKeys;
561 for (
size_t l1NoIsoEG = 0; l1NoIsoEG < handleL1ExtraNoIsoEG->size(); ++l1NoIsoEG ) {
562 if (
mainBxOnly_ && handleL1ExtraNoIsoEG->at( l1NoIsoEG ).bx() != 0 )
continue;
568 const reco::LeafCandidate leafCandidate( *( handleL1ExtraNoIsoEG->at( l1NoIsoEG ).reco::LeafCandidate::clone() ) );
575 triggerObjectsStandAlone->push_back( triggerObjectStandAlone );
576 if ( handleL1ExtraNoIsoEG->at( l1NoIsoEG ).bx() == 0 ) noIsoEGKeys.push_back( triggerObjectsStandAlone->size() - 1 );
578 l1ObjectTypeMap.insert( std::make_pair(
NoIsoEG, noIsoEGKeys ) );
584 if ( handleL1ExtraIsoEG.
isValid() ) {
585 std::vector< unsigned > isoEGKeys;
586 for (
size_t l1IsoEG = 0; l1IsoEG < handleL1ExtraIsoEG->size(); ++l1IsoEG ) {
587 if (
mainBxOnly_ && handleL1ExtraIsoEG->at( l1IsoEG ).bx() != 0 )
continue;
593 const reco::LeafCandidate leafCandidate( *( handleL1ExtraIsoEG->at( l1IsoEG ).reco::LeafCandidate::clone() ) );
600 triggerObjectsStandAlone->push_back( triggerObjectStandAlone );
601 if ( handleL1ExtraIsoEG->at( l1IsoEG ).bx() == 0 ) isoEGKeys.push_back( triggerObjectsStandAlone->size() - 1 );
603 l1ObjectTypeMap.insert( std::make_pair(
IsoEG, isoEGKeys ) );
609 if ( handleL1ExtraCenJet.
isValid() ) {
610 std::vector< unsigned > cenJetKeys;
611 for (
size_t l1CenJet = 0; l1CenJet < handleL1ExtraCenJet->size(); ++l1CenJet ) {
612 if (
mainBxOnly_ && handleL1ExtraCenJet->at( l1CenJet ).bx() != 0 )
continue;
618 const reco::LeafCandidate leafCandidate( *( handleL1ExtraCenJet->at( l1CenJet ).reco::LeafCandidate::clone() ) );
625 triggerObjectsStandAlone->push_back( triggerObjectStandAlone );
626 if ( handleL1ExtraCenJet->at( l1CenJet ).bx() == 0 ) cenJetKeys.push_back( triggerObjectsStandAlone->size() - 1 );
628 l1ObjectTypeMap.insert( std::make_pair(
CenJet, cenJetKeys ) );
634 if ( handleL1ExtraForJet.
isValid() ) {
635 std::vector< unsigned > forJetKeys;
636 for (
size_t l1ForJet = 0; l1ForJet < handleL1ExtraForJet->size(); ++l1ForJet ) {
637 if (
mainBxOnly_ && handleL1ExtraForJet->at( l1ForJet ).bx() != 0 )
continue;
643 const reco::LeafCandidate leafCandidate( *( handleL1ExtraForJet->at( l1ForJet ).reco::LeafCandidate::clone() ) );
650 triggerObjectsStandAlone->push_back( triggerObjectStandAlone );
651 if ( handleL1ExtraForJet->at( l1ForJet ).bx() == 0 ) forJetKeys.push_back( triggerObjectsStandAlone->size() - 1 );
653 l1ObjectTypeMap.insert( std::make_pair(
ForJet, forJetKeys ) );
659 if ( handleL1ExtraTauJet.
isValid() ) {
660 std::vector< unsigned > tauJetKeys;
661 for (
size_t l1TauJet = 0; l1TauJet < handleL1ExtraTauJet->size(); ++l1TauJet ) {
662 if (
mainBxOnly_ && handleL1ExtraTauJet->at( l1TauJet ).bx() != 0 )
continue;
668 const reco::LeafCandidate leafCandidate( *( handleL1ExtraTauJet->at( l1TauJet ).reco::LeafCandidate::clone() ) );
675 triggerObjectsStandAlone->push_back( triggerObjectStandAlone );
676 if ( handleL1ExtraTauJet->at( l1TauJet ).bx() == 0 ) tauJetKeys.push_back( triggerObjectsStandAlone->size() - 1 );
678 l1ObjectTypeMap.insert( std::make_pair(
TauJet, tauJetKeys ) );
684 if ( handleL1ExtraETM.
isValid() ) {
685 std::vector< unsigned > etmKeys;
686 for (
size_t l1ETM = 0; l1ETM < handleL1ExtraETM->size(); ++l1ETM ) {
687 if (
mainBxOnly_ && handleL1ExtraETM->at( l1ETM ).bx() != 0 )
continue;
693 const reco::LeafCandidate leafCandidate( *( handleL1ExtraETM->at( l1ETM ).reco::LeafCandidate::clone() ) );
700 triggerObjectsStandAlone->push_back( triggerObjectStandAlone );
701 if ( handleL1ExtraETM->at( l1ETM ).bx() == 0 ) etmKeys.push_back( triggerObjectsStandAlone->size() - 1 );
703 l1ObjectTypeMap.insert( std::make_pair(
ETM, etmKeys ) );
704 }
else LogError(
"l1ExtraValid" ) <<
"l1extra::L1EtMissParticleCollection product with InputTag '" <<
tagL1ExtraETM_.
encode() <<
"' not in event";
709 if ( handleL1ExtraHTM.
isValid() ) {
710 std::vector< unsigned > htmKeys;
711 for (
size_t l1HTM = 0; l1HTM < handleL1ExtraHTM->size(); ++l1HTM ) {
712 if (
mainBxOnly_ && handleL1ExtraHTM->at( l1HTM ).bx() != 0 )
continue;
718 const reco::LeafCandidate leafCandidate( *( handleL1ExtraHTM->at( l1HTM ).reco::LeafCandidate::clone() ) );
725 triggerObjectsStandAlone->push_back( triggerObjectStandAlone );
726 if ( handleL1ExtraHTM->at( l1HTM ).bx() == 0 ) htmKeys.push_back( triggerObjectsStandAlone->size() - 1 );
728 l1ObjectTypeMap.insert( std::make_pair(
HTM, htmKeys ) );
729 }
else LogError(
"l1ExtraValid" ) <<
"l1extra::L1EtMissParticleCollection product with InputTag '" <<
tagL1ExtraHTM_.
encode() <<
"' not in event";
741 std::map< L1GtObject, trigger::TriggerObjectType > mapObjectTypes;
758 const std::vector< ConditionMap > l1GtConditionsVector( l1GtTriggerMenu.
gtConditionMap() );
761 for (
size_t iCv = 0; iCv < l1GtConditionsVector.size(); ++iCv ) {
762 l1GtConditions.insert( l1GtConditionsVector.at( iCv ).begin(), l1GtConditionsVector.at( iCv ).end() );
764 triggerAlgos->reserve( l1GtAlgorithms.size() + l1GtTechTriggers.size() );
767 if( ! handleL1GlobalTriggerObjectMaps.
isValid() ) {
769 <<
"No L1 objects and GTL results available for physics algorithms";
771 handleL1GlobalTriggerObjectMaps->consistencyCheck();
775 LogError(
"l1ObjectMap" ) <<
"ParameterSet registry not available\n"
776 <<
"Skipping conditions for all L1 physics algorithm names in this run";
780 LogInfo(
"l1ObjectMap" ) <<
"ParameterSet registry not available\n"
781 <<
"Skipping conditions for all L1 physics algorithm names in this event";
785 for (
CItAlgo iAlgo = l1GtAlgorithms.begin(); iAlgo != l1GtAlgorithms.end(); ++iAlgo ) {
786 const std::string & algoName( iAlgo->second.algoName() );
795 LogError(
"l1Algo" ) <<
"L1 physics algorithm '" << algoName <<
"' not found in the L1 menu\n"
800 LogError(
"l1Algo" ) <<
"L1 physics algorithm '" << algoName <<
"' does not have category 'AlgorithmTrigger' from 'L1GtUtils'\n"
804 bool decisionBeforeMask;
805 bool decisionAfterMask;
810 LogError(
"l1Algo" ) <<
"L1 physics algorithm '" << algoName <<
"' decision has error code " <<
error <<
" from 'L1GtUtils'\n"
817 if( ! handleL1GlobalTriggerObjectMaps.
isValid() ) {
818 triggerAlgos->push_back( triggerAlgo );
821 if ( ! handleL1GlobalTriggerObjectMaps->algorithmExists(bit)) {
822 LogError(
"l1ObjectMap" ) <<
"L1 physics algorithm '" << algoName <<
"' is missing in L1GlobalTriggerObjectMaps\n"
823 <<
"Skipping conditions and GTL result";
824 triggerAlgos->push_back( triggerAlgo );
827 bool algorithmResult = handleL1GlobalTriggerObjectMaps->algorithmResult(bit);
829 if ( ( algorithmResult != decisionBeforeMask ) && ( decisionBeforeMask ==
true ) ) {
830 LogInfo(
"l1ObjectMap" ) <<
"L1 physics algorithm '" << algoName <<
"' with different decisions in\n"
831 <<
"L1GlobalTriggerObjectMaps (GTL result) : " << algorithmResult <<
"\n"
832 <<
"L1GlobalTriggerReadoutRecord (decision before mask): " << decisionBeforeMask;
838 triggerAlgos->push_back( triggerAlgo );
843 LogError(
"l1ObjectMap" ) <<
"L1 physics algorithm name '" << algoName <<
"' not available in ParameterSet registry\n"
844 <<
"Skipping conditions for this algorithm in this run";
846 LogInfo(
"l1ObjectMap" ) <<
"L1 physics algorithm name '" << algoName <<
"' not available in ParameterSet registry\n"
847 <<
"Skipping conditions for this algorithm in this event";
849 triggerAlgos->push_back( triggerAlgo );
852 std::vector<std::string> conditionNames(
l1PSet_->
getParameter<std::vector<std::string> >(algoName) );
854 for (
unsigned iT = 0; iT < conditionNames.size(); ++iT ) {
855 size_t key( triggerConditions->size() );
856 for (
size_t iC = 0; iC < triggerConditions->size(); ++iC ) {
857 if ( conditionNames.at(iT) == triggerConditions->at( iC ).name() ) {
862 if (
key == triggerConditions->size() ) {
864 LogError(
"l1CondMap" ) <<
"More condition names from ParameterSet registry than the " << conditions.
nConditions() <<
" conditions in L1GlobalTriggerObjectMaps\n"
865 <<
"Skipping condition " << conditionNames.at(iT) <<
" in algorithm " << algoName;
869 if ( l1GtConditions.find( triggerCond.name() ) != l1GtConditions.end() ) {
870 triggerCond.
setCategory( l1GtConditions[ triggerCond.name() ]->condCategory() );
871 triggerCond.setType( l1GtConditions[ triggerCond.name() ]->condType() );
872 const std::vector< L1GtObject > l1ObjectTypes( l1GtConditions[ triggerCond.name() ]->objectType() );
873 for (
size_t iType = 0 ; iType < l1ObjectTypes.size(); ++iType ) {
874 triggerCond.addTriggerObjectType( mapObjectTypes[ l1ObjectTypes.at( iType ) ] );
878 for (
size_t iVV = 0; iVV < combinations.
nCombinations(); ++iVV ) {
882 if ( iV >= l1ObjectTypes.size() ) {
883 LogError(
"l1CondMap" ) <<
"Index " << iV <<
" in combinations vector overshoots size " << l1ObjectTypes.size() <<
" of types vector in conditions map\n"
884 <<
"Skipping object key in condition " << triggerCond.name();
885 }
else if ( l1ObjectTypeMap.find( l1ObjectTypes.at( iV ) ) != l1ObjectTypeMap.end() ) {
886 if ( objectIndex >= l1ObjectTypeMap[ l1ObjectTypes.at( iV ) ].size() ) {
887 LogError(
"l1CondMap" ) <<
"Index " << objectIndex <<
" in combination overshoots number " << l1ObjectTypeMap[ l1ObjectTypes.at( iV ) ].size() <<
"of according trigger objects\n"
888 <<
"Skipping object key in condition " << triggerCond.name();
890 const unsigned objectKey( l1ObjectTypeMap[ l1ObjectTypes.at( iV ) ].at( objectIndex ) );
891 triggerCond.addObjectKey( objectKey );
893 triggerObjectsStandAlone->at( objectKey ).addAlgorithmName( triggerAlgo.
name(), ( triggerAlgo.
decision() && triggerCond.wasAccept() ) );
894 triggerObjectsStandAlone->at( objectKey ).addConditionName( triggerCond.name() );
899 LogWarning(
"l1CondMap" ) <<
"L1 conditions '" << triggerCond.name() <<
"' not found in the L1 menu\n"
900 <<
"Remains incomplete";
902 triggerConditions->push_back( triggerCond );
906 triggerAlgos->push_back( triggerAlgo );
909 for (
CItAlgo iAlgo = l1GtTechTriggers.begin(); iAlgo != l1GtTechTriggers.end(); ++iAlgo ) {
910 const std::string & algoName( iAlgo->second.algoName() );
919 LogError(
"l1Algo" ) <<
"L1 technical trigger '" << algoName <<
"' not found in the L1 menu\n"
924 LogError(
"l1Algo" ) <<
"L1 technical trigger '" << algoName <<
"' does not have category 'TechnicalTrigger' from 'L1GtUtils'\n"
928 bool decisionBeforeMask;
929 bool decisionAfterMask;
934 LogError(
"l1Algo" ) <<
"L1 technical trigger '" << algoName <<
"' decision has error code " <<
error <<
" from 'L1GtUtils'\n"
940 triggerAlgos->push_back( triggerAlgo );
945 iEvent.
put( triggerAlgos );
946 iEvent.
put( triggerConditions );
950 iEvent.
put( triggerObjectsStandAlone );
958 const std::vector<std::string> & pathNames = hltConfig_.
triggerNames();
959 unsigned int sizePaths = pathNames.size();
960 for (
unsigned int indexPath = 0; indexPath < sizePaths; ++indexPath ) {
961 const std::string & namePath = pathNames[indexPath];
963 const std::vector<std::string> & nameModules = hltConfig_.
moduleLabels(indexPath);
964 unsigned int sizeModulesPath = nameModules.size();
965 bool lastFilter =
true;
966 unsigned int iM = sizeModulesPath;
968 const std::string & nameFilter = nameModules[--iM];
969 if (hltConfig_.
moduleEDMType(nameFilter) !=
"EDFilter")
continue;
970 if (hltConfig_.
moduleType(nameFilter) ==
"HLTBool")
continue;
972 insert( nameFilter, namePath, indexPath, lastFilter, saveTags );
973 if (saveTags) lastFilter =
false;
unsigned int set() const
low-level const accessors for data members
unsigned int size() const
number of trigger paths in trigger table
collection_type::const_iterator const_iterator
T getParameter(std::string const &) const
bool getByLabel(std::string const &label, Handle< PROD > &result) const
unsigned char getObjectIndex(unsigned combination, unsigned object) const
bool saveTags(const std::string &module) const
Is module an L3 filter (ie, tracked saveTags=true)
Analysis-level L1 trigger algorithm class.
const int l1Results(const edm::Event &iEvent, const edm::InputTag &l1GtRecordInputTag, const edm::InputTag &l1GtReadoutRecordInputTag, const std::string &nameAlgoTechTrig, bool &decisionBeforeMask, bool &decisionAfterMask, int &prescaleFactor, int &triggerMask) const
virtual void produce(edm::Event &iEvent, const edm::EventSetup &iSetup)
edm::InputTag tagL1ExtraForJet_
const std::string moduleType(const std::string &module) const
C++ class name of module.
bool autoProcessNameL1ExtraHTM_
virtual void beginLuminosityBlock(edm::LuminosityBlock &iLuminosityBlock, const edm::EventSetup &iSetup)
static const bool useL1EventSetup(true)
bool autoProcessNameL1ExtraIsoEG_
edm::InputTag tagTriggerEvent_
PATTriggerProducer(const edm::ParameterSet &iConfig)
HLTConfigProvider hltConfig_
bool setStatus(int status)
static PFTauRenderPlugin instance
enum start value shifted to 81 so as to avoid clashes with PDG codes
bool autoProcessNameL1ExtraTauJet_
virtual bool hasCollection(const std::string &collName) const
Checks, if a certain label of original collection is assigned (method overrides)
#define DEFINE_FWK_MODULE(type)
edm::InputTag tagTriggerResults_
const bool l1AlgoTechTrigBitNumber(const std::string &nameAlgoTechTrig, TriggerCategory &trigCategory, int &bitNumber) const
static const unsigned int NumberTechnicalTriggers
const std::vector< std::vector< std::pair< bool, std::string > > > & hltL1GTSeeds() const
const std::vector< std::string > & triggerNames() const
names of trigger paths
The single EDProduct containing the HLT Prescale Table.
void setGtlResult(bool gtlResult)
Set L1 algorithm GTL result.
unsigned short nObjectsPerCombination() const
bool exists(std::string const ¶meterName) const
checks if a parameter exists
void insert(const std::string &filter, const std::string &path, unsigned int pathIndex, bool lastFilter, bool l3Filter)
const std::string moduleEDMType(const std::string &module) const
C++ base class name of module.
edm::InputTag tagL1ExtraETM_
void addTriggerObjectType(trigger::TriggerObjectType triggerObjectType)
Add a new trigger object type identifier.
std::string hltPrescaleLabel_
std::vector< TriggerObjectStandAlone > TriggerObjectStandAloneCollection
Collection of TriggerObjectStandAlone.
void addObjectKey(unsigned objectKey)
Add a new trigger object collection index.
bool getByLabel(std::string const &label, Handle< PROD > &result) const
const std::map< std::string, std::vector< unsigned int > > & prescaleTable() const
Analysis-level trigger object class.
const std::map< std::string, std::vector< unsigned int > > & table() const
bool autoProcessNameL1ExtraMu_
void addFilterLabel(const std::string &filterLabel)
Methods.
bool autoProcessNameL1ExtraCenJet_
const std::string & moduleLabel(unsigned int trigger, unsigned int module) const
const std::vector< std::string > & saveTagsModules(unsigned int trigger) const
Single trigger physics object (e.g., an isolated muon)
std::vector< TriggerAlgorithm > TriggerAlgorithmCollection
Collection of TriggerAlgorithm.
void addPathName(const std::string &pathName, bool pathLastFilterAccepted=true, bool pathL3FilterAccepted=true)
Adds a new HLT path name.
bool addPathModuleLabels_
Analysis-level HLTrigger filter class.
Produces the full or stand-alone PAT trigger information collections.
unsigned int prescaleValue(unsigned int set, const std::string &trigger) const
HLT prescale value in specific prescale set for a specific trigger path.
unsigned int moduleIndex(unsigned int trigger, const std::string &module) const
slot position of module on trigger path (0 to size-1)
edm::InputTag tagL1ExtraIsoEG_
void setCollection(const std::string &collName)
Methods.
Analysis-level L1 trigger condition class.
Analysis-level HLTrigger path class.
static const unsigned int NumberPhysTriggersExtended
OrphanHandle< PROD > put(std::auto_ptr< PROD > product)
Put a new product.
const std::vector< std::string > & labels() const
trigger::HLTPrescaleTable hltPrescaleTableLumi_
const std::string & name() const
Get L1 algorithm name.
ProcessHistory const & processHistory() const
static const unsigned int NumberPhysTriggers
void setSaveTags(bool saveTags)
Set the L3 status.
void setLogicalExpression(const std::string &expression)
Set L1 algorithm logical expression.
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
unsigned nConditions() const
const std::vector< std::string > & moduleLabels(unsigned int trigger) const
label(s) of module(s) on a trigger path
virtual void beginRun(edm::Run &iRun, const edm::EventSetup &iSetup)
edm::InputTag tagL1GlobalTriggerObjectMaps_
static const bool useL1GtTriggerMenuLite(false)
std::vector< TriggerFilter > TriggerFilterCollection
Collection of TriggerFilter.
void getL1GtRunCache(const edm::Run &, const edm::EventSetup &, const bool, const bool, const edm::InputTag &)
get all the run-constant quantities for L1 trigger and cache them
edm::InputTag tagL1ExtraMu_
ModuleLabelToPathAndFlags moduleLabelToPathAndFlags_
void setCategory(L1GtConditionCategory category)
Set the condition category.
unsigned nCombinations() const
int prescaleSet(const edm::Event &iEvent, const edm::EventSetup &iSetup) const
std::vector< size_type > Keys
bool init(const edm::Run &iRun, const edm::EventSetup &iSetup, const std::string &processName, bool &changed)
d'tor
bool autoProcessNameL1ExtraForJet_
const std::vector< std::string > & prescaleLabels() const
low-level data member access
void addConditionKey(unsigned conditionKey)
Add a new trigger condition collection index.
void setType(const std::string &type)
Set the filter module type.
edm::InputTag tagL1ExtraTauJet_
std::vector< TriggerObject > TriggerObjectCollection
Collection of TriggerObject.
math::PtEtaPhiMLorentzVector PolarLorentzVector
Lorentz vector.
unsigned int prescaleSize() const
trigger::HLTPrescaleTable hltPrescaleTableRun_
bool getConditionResult(unsigned condition) const
std::vector< TriggerCondition > TriggerConditionCollection
Collection of TriggerCondition.
void init(const HLTConfigProvider &conf)
bool autoProcessNameL1ExtraETM_
std::vector< std::string > exludeCollections_
bool autoProcessNameL1ExtraNoIsoEG_
std::vector< L1Seed > L1SeedCollection
Collection of L1Seed.
void addTriggerObjectType(trigger::TriggerObjectType triggerObjectType)
Add a new trigger object type identifier.
std::vector< TriggerPath > TriggerPathCollection
Collection of TriggerPath.
edm::InputTag tagL1ExtraNoIsoEG_
edm::InputTag tagL1ExtraCenJet_
Analysis-level trigger object class (stand-alone)
edm::InputTag tagL1ExtraHTM_
edm::ParameterSet * l1PSet_
std::string labelHltPrescaleTable_
void set(const std::string &name, int value)
set the flag, with a run-time name