235 algo, rParam, btagDiscriminators, btagInfos, patJets, labelName, btagPrefix, postfix):
241 requiredTagInfos =
list(btagInfos)
242 for btagDiscr
in btagDiscriminators :
243 for tagInfoList
in supportedBtagDiscr[btagDiscr] :
244 for requiredTagInfo
in tagInfoList :
245 tagInfoCovered =
False 246 for tagInfo
in requiredTagInfos :
247 if requiredTagInfo == tagInfo :
248 tagInfoCovered =
True 250 if not tagInfoCovered :
251 requiredTagInfos.append(requiredTagInfo)
253 if hasattr( process,
'candidateJetProbabilityComputer' ) ==
False :
255 process.load(
"RecoBTag.ImpactParameter.impactParameter_cff")
256 task.add(process.impactParameterTask)
257 process.load(
"RecoBTag.SecondaryVertex.secondaryVertex_cff")
258 task.add(process.secondaryVertexTask)
259 process.load(
"RecoBTag.SoftLepton.softLepton_cff")
260 task.add(process.softLeptonTask)
261 process.load(
"RecoBTag.Combined.combinedMVA_cff")
262 task.add(process.combinedMVATask)
263 process.load(
"RecoBTag.CTagging.cTagging_cff")
264 task.add(process.cTaggingTask)
266 process.load(
"RecoBTag.ImpactParameter.impactParameter_EventSetup_cff")
267 process.load(
"RecoBTag.SecondaryVertex.secondaryVertex_EventSetup_cff")
268 process.load(
"RecoBTag.SoftLepton.softLepton_EventSetup_cff")
269 process.load(
"RecoBTag.Combined.combinedMVA_EventSetup_cff")
270 process.load(
"RecoBTag.CTagging.cTagging_EventSetup_cff")
276 sys.stderr.write(
"-------------------------------------------------------------------\n")
277 sys.stderr.write(
" Warning: For a complete switch to the legacy tight b-tag track\n")
278 sys.stderr.write(
" selection, please also enable the \'runIVF\' switch.\n")
279 sys.stderr.write(
"-------------------------------------------------------------------\n")
281 sys.stderr.write(
"-------------------------------------------------------------------\n")
282 sys.stderr.write(
" Warning: With the tight b-tag track selection enabled, it is\n")
283 sys.stderr.write(
" advisable to set \'btagPrefix\' to a non-empty string to\n")
284 sys.stderr.write(
" avoid unintentional modifications to the default\n")
285 sys.stderr.write(
" b tagging setup that might be loaded in the same job.\n")
286 sys.stderr.write(
"-------------------------------------------------------------------\n")
290 svSourceCvsL = copy.deepcopy(svSource)
291 svSourceCvsL.setModuleLabel(svSource.getModuleLabel()+
'CvsL')
294 runIVFforCTagOnly =
False 295 ivfcTagInfos = [
'pfInclusiveSecondaryVertexFinderCvsLTagInfos',
'pfInclusiveSecondaryVertexFinderNegativeCvsLTagInfos']
297 if pvSource.getModuleLabel() ==
'offlineSlimmedPrimaryVertices' and any(i
in requiredTagInfos
for i
in ivfcTagInfos)
and not runIVF:
298 runIVFforCTagOnly =
True 300 sys.stderr.write(
"-------------------------------------------------------------------\n")
301 sys.stderr.write(
" Info: To run c tagging on MiniAOD, c-tag-specific IVF secondary\n")
302 sys.stderr.write(
" vertices will be remade.\n")
303 sys.stderr.write(
"-------------------------------------------------------------------\n")
305 if runIVF
and btagPrefix !=
'':
306 if runIVFforCTagOnly:
307 svSourceCvsL.setModuleLabel(btagPrefix+svSourceCvsL.getModuleLabel())
309 svSource.setModuleLabel(btagPrefix+svSource.getModuleLabel())
310 svSourceCvsL.setModuleLabel(btagPrefix+svSourceCvsL.getModuleLabel())
315 acceptedTagInfos =
list()
316 for btagInfo
in requiredTagInfos:
317 if hasattr(btag,btagInfo):
318 if btagInfo ==
'pfImpactParameterTagInfos':
320 btag.pfImpactParameterTagInfos.clone(jets = jetSource,primaryVertex=pvSource,candidates=pfCandidates),
323 _btagInfo = getattr(process, btagPrefix+btagInfo+labelName+postfix)
324 _btagInfo.explicitJTA = cms.bool(explicitJTA)
326 _btagInfo = getattr(process, btagPrefix+btagInfo+labelName+postfix)
327 _btagInfo.minimumNumberOfPixelHits = cms.int32(2)
328 _btagInfo.minimumNumberOfHits = cms.int32(8)
329 if btagInfo ==
'pfImpactParameterAK8TagInfos':
331 btag.pfImpactParameterAK8TagInfos.clone(jets = jetSource,primaryVertex=pvSource,candidates=pfCandidates),
334 _btagInfo = getattr(process, btagPrefix+btagInfo+labelName+postfix)
335 _btagInfo.explicitJTA = cms.bool(explicitJTA)
337 _btagInfo = getattr(process, btagPrefix+btagInfo+labelName+postfix)
338 _btagInfo.minimumNumberOfPixelHits = cms.int32(2)
339 _btagInfo.minimumNumberOfHits = cms.int32(8)
340 if btagInfo ==
'pfImpactParameterCA15TagInfos':
342 btag.pfImpactParameterCA15TagInfos.clone(jets = jetSource,primaryVertex=pvSource,candidates=pfCandidates),
345 _btagInfo = getattr(process, btagPrefix+btagInfo+labelName+postfix)
346 _btagInfo.explicitJTA = cms.bool(explicitJTA)
348 _btagInfo = getattr(process, btagPrefix+btagInfo+labelName+postfix)
349 _btagInfo.minimumNumberOfPixelHits = cms.int32(2)
350 _btagInfo.minimumNumberOfHits = cms.int32(8)
351 if btagInfo ==
'pfSecondaryVertexTagInfos':
353 btag.pfSecondaryVertexTagInfos.clone(
354 trackIPTagInfos = cms.InputTag(btagPrefix+
'pfImpactParameterTagInfos'+labelName+postfix)),
357 _btagInfo = getattr(process, btagPrefix+btagInfo+labelName+postfix)
358 _btagInfo.trackSelection.pixelHitsMin = cms.uint32(2)
359 _btagInfo.trackSelection.totalHitsMin = cms.uint32(8)
360 if btagInfo ==
'pfDeepCSVTagInfos':
362 btag.pfDeepCSVTagInfos.clone(
363 svTagInfos = cms.InputTag(btagPrefix+
'pfInclusiveSecondaryVertexFinderTagInfos'+labelName+postfix)),
365 if svClustering
or fatJets != cms.InputTag(
''):
366 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
367 if btagInfo ==
'pfDeepCSVNegativeTagInfos':
369 btag.pfDeepCSVNegativeTagInfos.clone(
370 svTagInfos = cms.InputTag(btagPrefix+
'pfInclusiveSecondaryVertexFinderNegativeTagInfos'+labelName+postfix)),
372 if svClustering
or fatJets != cms.InputTag(
''):
373 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
374 if btagInfo ==
'pfDeepCSVPositiveTagInfos':
376 btag.pfDeepCSVPositiveTagInfos.clone(
377 svTagInfos = cms.InputTag(btagPrefix+
'pfInclusiveSecondaryVertexFinderTagInfos'+labelName+postfix)),
379 if svClustering
or fatJets != cms.InputTag(
''):
380 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
381 if btagInfo ==
'pfDeepCMVATagInfos':
383 btag.pfDeepCMVATagInfos.clone(
384 deepNNTagInfos = cms.InputTag(btagPrefix+
'pfDeepCSVTagInfos'+labelName+postfix),
385 ipInfoSrc = cms.InputTag(btagPrefix+
"pfImpactParameterTagInfos"+labelName+postfix),
386 muInfoSrc = cms.InputTag(btagPrefix+
"softPFMuonsTagInfos"+labelName+postfix),
387 elInfoSrc = cms.InputTag(btagPrefix+
"softPFElectronsTagInfos"+labelName+postfix)),
389 if svClustering
or fatJets != cms.InputTag(
''):
390 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
391 if btagInfo ==
'pfDeepCMVANegativeTagInfos':
393 btag.pfDeepCMVATagInfos.clone(
394 deepNNTagInfos = cms.InputTag(btagPrefix+
'pfDeepCSVTagInfos'+labelName+postfix),
395 ipInfoSrc = cms.InputTag(btagPrefix+
"pfImpactParameterTagInfos"+labelName+postfix),
396 muInfoSrc = cms.InputTag(btagPrefix+
"softPFMuonsTagInfos"+labelName+postfix),
397 elInfoSrc = cms.InputTag(btagPrefix+
"softPFElectronsTagInfos"+labelName+postfix)),
399 if svClustering
or fatJets != cms.InputTag(
''):
400 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
401 if btagInfo ==
'pfDeepCMVAPositiveTagInfos':
403 btag.pfDeepCMVATagInfos.clone(
404 deepNNTagInfos = cms.InputTag(btagPrefix+
'pfDeepCSVTagInfos'+labelName+postfix),
405 ipInfoSrc = cms.InputTag(btagPrefix+
"pfImpactParameterTagInfos"+labelName+postfix),
406 muInfoSrc = cms.InputTag(btagPrefix+
"softPFMuonsTagInfos"+labelName+postfix),
407 elInfoSrc = cms.InputTag(btagPrefix+
"softPFElectronsTagInfos"+labelName+postfix)),
409 if svClustering
or fatJets != cms.InputTag(
''):
410 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
411 if btagInfo ==
'pfInclusiveSecondaryVertexFinderTagInfos':
413 btag.pfInclusiveSecondaryVertexFinderTagInfos.clone(
414 trackIPTagInfos = cms.InputTag(btagPrefix+
'pfImpactParameterTagInfos'+labelName+postfix),
415 extSVCollection=svSource),
417 if svClustering
or fatJets != cms.InputTag(
''):
418 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
419 if btagInfo ==
'pfInclusiveSecondaryVertexFinderAK8TagInfos':
421 btag.pfInclusiveSecondaryVertexFinderAK8TagInfos.clone(
422 trackIPTagInfos = cms.InputTag(btagPrefix+
'pfImpactParameterAK8TagInfos'+labelName+postfix),
423 extSVCollection=svSource),
425 if svClustering
or fatJets != cms.InputTag(
''):
426 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
427 if btagInfo ==
'pfBoostedDoubleSVAK8TagInfos':
429 btag.pfBoostedDoubleSVAK8TagInfos.clone(
430 svTagInfos = cms.InputTag(btagPrefix+
'pfInclusiveSecondaryVertexFinderAK8TagInfos'+labelName+postfix)),
432 if btagInfo ==
'pfInclusiveSecondaryVertexFinderCA15TagInfos':
434 btag.pfInclusiveSecondaryVertexFinderCA15TagInfos.clone(
435 trackIPTagInfos = cms.InputTag(btagPrefix+
'pfImpactParameterCA15TagInfos'+labelName+postfix),
436 extSVCollection=svSource),
438 if svClustering
or fatJets != cms.InputTag(
''):
439 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
440 if btagInfo ==
'pfBoostedDoubleSVCA15TagInfos':
442 btag.pfBoostedDoubleSVCA15TagInfos.clone(
443 svTagInfos = cms.InputTag(btagPrefix+
'pfInclusiveSecondaryVertexFinderCA15TagInfos'+labelName+postfix)),
445 if btagInfo ==
'pfInclusiveSecondaryVertexFinderCvsLTagInfos':
447 btag.pfInclusiveSecondaryVertexFinderCvsLTagInfos.clone(
448 trackIPTagInfos = cms.InputTag(btagPrefix+
'pfImpactParameterTagInfos'+labelName+postfix),
449 extSVCollection=svSourceCvsL),
451 if svClustering
or fatJets != cms.InputTag(
''):
452 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
453 if btagInfo ==
'pfInclusiveSecondaryVertexFinderNegativeCvsLTagInfos':
455 btag.pfInclusiveSecondaryVertexFinderNegativeCvsLTagInfos.clone(
456 trackIPTagInfos = cms.InputTag(btagPrefix+
'pfImpactParameterTagInfos'+labelName+postfix),
457 extSVCollection=svSourceCvsL),
459 if svClustering
or fatJets != cms.InputTag(
''):
460 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
461 if btagInfo ==
'pfGhostTrackVertexTagInfos':
463 btag.pfGhostTrackVertexTagInfos.clone(
464 trackIPTagInfos = cms.InputTag(btagPrefix+
'pfImpactParameterTagInfos'+labelName+postfix)),
466 if btagInfo ==
'pfSecondaryVertexNegativeTagInfos':
468 btag.pfSecondaryVertexNegativeTagInfos.clone(
469 trackIPTagInfos = cms.InputTag(btagPrefix+
'pfImpactParameterTagInfos'+labelName+postfix)),
472 _btagInfo = getattr(process, btagPrefix+btagInfo+labelName+postfix)
473 _btagInfo.trackSelection.pixelHitsMin = cms.uint32(2)
474 _btagInfo.trackSelection.totalHitsMin = cms.uint32(8)
475 if btagInfo ==
'pfInclusiveSecondaryVertexFinderNegativeTagInfos':
477 btag.pfInclusiveSecondaryVertexFinderNegativeTagInfos.clone(
478 trackIPTagInfos = cms.InputTag(btagPrefix+
'pfImpactParameterTagInfos'+labelName+postfix),
479 extSVCollection=svSource),
481 if svClustering
or fatJets != cms.InputTag(
''):
482 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
483 if btagInfo ==
'impactParameterTagInfos':
485 btag.impactParameterTagInfos.clone(
486 jetTracks = cms.InputTag(
'jetTracksAssociatorAtVertex'+labelName+postfix),
487 primaryVertex=pvSource),
489 if btagInfo ==
'secondaryVertexTagInfos':
491 btag.secondaryVertexTagInfos.clone(
492 trackIPTagInfos = cms.InputTag(btagPrefix+
'impactParameterTagInfos'+labelName+postfix)),
494 if btagInfo ==
'inclusiveSecondaryVertexFinderTagInfos':
496 btag.inclusiveSecondaryVertexFinderTagInfos.clone(
497 trackIPTagInfos = cms.InputTag(btagPrefix+
'impactParameterTagInfos'+labelName+postfix)),
499 if svClustering
or fatJets != cms.InputTag(
''):
500 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
501 if btagInfo ==
'inclusiveSecondaryVertexFinderFilteredTagInfos':
503 btag.inclusiveSecondaryVertexFinderFilteredTagInfos.clone(
504 trackIPTagInfos = cms.InputTag(btagPrefix+
'impactParameterTagInfos'+labelName+postfix)),
506 if svClustering
or fatJets != cms.InputTag(
''):
507 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
508 if btagInfo ==
'secondaryVertexNegativeTagInfos':
510 btag.secondaryVertexNegativeTagInfos.clone(
511 trackIPTagInfos = cms.InputTag(btagPrefix+
'impactParameterTagInfos'+labelName+postfix)),
513 if btagInfo ==
'inclusiveSecondaryVertexFinderNegativeTagInfos':
515 btag.inclusiveSecondaryVertexFinderNegativeTagInfos.clone(
516 trackIPTagInfos = cms.InputTag(btagPrefix+
'impactParameterTagInfos'+labelName+postfix)),
518 if svClustering
or fatJets != cms.InputTag(
''):
519 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
520 if btagInfo ==
'inclusiveSecondaryVertexFinderFilteredNegativeTagInfos':
522 btag.inclusiveSecondaryVertexFinderFilteredNegativeTagInfos.clone(
523 trackIPTagInfos = cms.InputTag(btagPrefix+
'impactParameterTagInfos'+labelName+postfix)),
525 if svClustering
or fatJets != cms.InputTag(
''):
526 setupSVClustering(getattr(process, btagPrefix+btagInfo+labelName+postfix), svClustering, algo, rParam, fatJets, groomedFatJets)
527 if btagInfo ==
'softMuonTagInfos':
529 btag.softMuonTagInfos.clone(jets = jetSource, primaryVertex=pvSource),
531 if btagInfo ==
'softPFMuonsTagInfos':
533 btag.softPFMuonsTagInfos.clone(jets = jetSource, primaryVertex=pvSource, muons=muSource),
535 if btagInfo ==
'softPFElectronsTagInfos':
537 btag.softPFElectronsTagInfos.clone(jets = jetSource, primaryVertex=pvSource, electrons=elSource),
539 acceptedTagInfos.append(btagInfo)
540 elif hasattr(toptag, btagInfo) :
541 acceptedTagInfos.append(btagInfo)
543 print ' --> %s ignored, since not available via RecoBTag.Configuration.RecoBTag_cff!'%(btagInfo)
545 acceptedBtagDiscriminators =
list()
546 for discriminator_name
in btagDiscriminators :
547 btagDiscr = discriminator_name.split(
':')[0]
549 if hasattr(btag,btagDiscr):
550 newDiscr = btagPrefix+btagDiscr+labelName+postfix
551 if hasattr(process, newDiscr):
553 elif hasattr(getattr(btag, btagDiscr),
'tagInfos'):
556 getattr(btag, btagDiscr).
clone(
557 tagInfos = cms.VInputTag(
558 *[ cms.InputTag(btagPrefix+x+labelName+postfix) \
559 for x
in supportedBtagDiscr[discriminator_name][0] ]
565 elif hasattr(getattr(btag, btagDiscr),
'src'):
568 getattr(btag, btagDiscr).
clone(
569 src = cms.InputTag(btagPrefix+supportedBtagDiscr[discriminator_name][0][0]+labelName+postfix)
575 raise ValueError(
'I do not know how to update %s it does not have neither "tagInfos" nor "src" attributes' % btagDiscr)
576 acceptedBtagDiscriminators.append(discriminator_name)
578 print ' --> %s ignored, since not available via RecoBTag.Configuration.RecoBTag_cff!'%(btagDiscr)
580 patJets.tagInfoSources = cms.VInputTag( *[ cms.InputTag(btagPrefix+x+labelName+postfix)
for x
in acceptedTagInfos ] )
581 patJets.discriminatorSources = cms.VInputTag(*[
582 cms.InputTag(btagPrefix+x+labelName+postfix) \
583 if ':' not in x
else \
584 cms.InputTag(btagPrefix+x.split(
':')[0]+labelName+postfix+
':'+x.split(
':')[1]) \
585 for x
in acceptedBtagDiscriminators
587 if len(acceptedBtagDiscriminators) > 0 :
588 patJets.addBTagInfo =
True 591 if not tightBTagNTkHits:
592 if pvSource.getModuleLabel() ==
'offlineSlimmedPrimaryVertices':
597 ivfbTagInfos = [
'pfInclusiveSecondaryVertexFinderTagInfos',
'pfInclusiveSecondaryVertexFinderAK8TagInfos',
'pfInclusiveSecondaryVertexFinderCA15TagInfos']
598 if any(i
in acceptedTagInfos
for i
in ivfbTagInfos)
and not runIVFforCTagOnly:
599 if not hasattr( process, btagPrefix+
'inclusiveCandidateVertexFinder' ):
600 loadWithPrefix(process,
'RecoVertex.AdaptiveVertexFinder.inclusiveVertexing_cff', btagPrefix, task.label())
602 if hasattr( process, btagPrefix+
'inclusiveCandidateVertexFinder' ):
603 _temp = getattr(process, btagPrefix+
'inclusiveCandidateVertexFinder')
604 _temp.minHits = cms.uint32(8)
606 if pvSource.getModuleLabel() ==
'offlineSlimmedPrimaryVertices':
607 if hasattr( process, btagPrefix+
'inclusiveCandidateVertexFinder' ):
608 _temp = getattr(process, btagPrefix+
'inclusiveCandidateVertexFinder')
609 _temp.primaryVertices = pvSource
610 _temp.tracks = pfCandidates
611 if hasattr( process, btagPrefix+
'candidateVertexArbitrator' ):
612 _temp = getattr(process, btagPrefix+
'candidateVertexArbitrator')
613 _temp.primaryVertices = pvSource
614 _temp.tracks = pfCandidates
615 if hasattr( process, btagPrefix+
'inclusiveCandidateSecondaryVertices' )
and not hasattr( process, svSource.getModuleLabel() ):
617 getattr(process, btagPrefix+
'inclusiveCandidateSecondaryVertices').
clone(),
619 if any(i
in acceptedTagInfos
for i
in ivfcTagInfos):
620 if not hasattr( process, btagPrefix+
'inclusiveCandidateVertexFinderCvsL' ):
621 loadWithPrefix(process,
'RecoVertex.AdaptiveVertexFinder.inclusiveVertexing_cff', btagPrefix, task.label())
623 if hasattr( process, btagPrefix+
'inclusiveCandidateVertexFinderCvsL' ):
624 _temp = getattr(process, btagPrefix+
'inclusiveCandidateVertexFinderCvsL')
625 _temp.minHits = cms.uint32(8)
627 if pvSource.getModuleLabel() ==
'offlineSlimmedPrimaryVertices':
628 if hasattr( process, btagPrefix+
'inclusiveCandidateVertexFinderCvsL' ):
629 _temp = getattr(process, btagPrefix+
'inclusiveCandidateVertexFinderCvsL')
630 _temp.primaryVertices = pvSource
631 _temp.tracks = pfCandidates
632 if hasattr( process, btagPrefix+
'candidateVertexArbitratorCvsL' ):
633 _temp = getattr(process, btagPrefix+
'candidateVertexArbitratorCvsL')
634 _temp.primaryVertices = pvSource
635 _temp.tracks = pfCandidates
636 if hasattr( process, btagPrefix+
'inclusiveCandidateSecondaryVerticesCvsL' )
and not hasattr( process, svSourceCvsL.getModuleLabel() ):
638 getattr(process, btagPrefix+
'inclusiveCandidateSecondaryVerticesCvsL').
clone(),
640 if 'inclusiveSecondaryVertexFinderTagInfos' in acceptedTagInfos:
641 if not hasattr( process,
'inclusiveVertexing' ):
642 process.load(
'RecoVertex.AdaptiveVertexFinder.inclusiveVertexing_cff' )
643 task.add(process.inclusiveVertexingTask)
644 task.add(process.inclusiveCandidateVertexingTask)
645 task.add(process.inclusiveCandidateVertexingCvsLTask)
646 if 'inclusiveSecondaryVertexFinderFilteredTagInfos' in acceptedTagInfos:
647 if not hasattr( process,
'inclusiveVertexing' ):
648 process.load(
'RecoVertex.AdaptiveVertexFinder.inclusiveVertexing_cff' )
649 task.add(process.inclusiveVertexingTask)
650 task.add(process.inclusiveCandidateVertexingTask)
651 task.add(process.inclusiveCandidateVertexingCvsLTask)
652 if 'inclusiveSecondaryVertexFinderFilteredTagInfos' in acceptedTagInfos:
653 if not hasattr( process,
'inclusiveSecondaryVerticesFiltered' ):
654 process.load(
'RecoBTag.SecondaryVertex.inclusiveSecondaryVerticesFiltered_cfi' )
655 task.add(process.inclusiveSecondaryVerticesFiltered)
656 task.add(process.bVertexFilter)
657 if not hasattr( process,
'bToCharmDecayVertexMerged' ):
658 process.load(
'RecoBTag.SecondaryVertex.bToCharmDecayVertexMerger_cfi' )
659 task.add(process.bToCharmDecayVertexMerged)
660 if 'caTopTagInfos' in acceptedTagInfos :
661 patJets.addTagInfos =
True 662 if not hasattr( process,
'caTopTagInfos' )
and not hasattr( process,
'caTopTagInfosAK8' ):
663 process.load(
'RecoJets.JetProducers.caTopTaggers_cff' )
664 task.add(process.caTopTaggersTask)
bool any(const std::vector< T > &v, const T &what)
def addToProcessAndTask(label, module, process, task)
def loadWithPrefix(process, moduleName, prefix='', loadedProducersAndFilters=None)
TEveGeoShape * clone(const TEveElement *element, TEveElement *parent)
def getPatAlgosToolsTask(process)
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 list("!*","!HLTx*"if it matches 2 triggers or more) will accept the event if all the matching triggers are FAIL.It will reject the event if any of the triggers are PASS or EXCEPTION(this matches the behavior of"!*"before the partial wildcard feature was incorporated).Triggers which are in the READY state are completely ignored.(READY should never be returned since the trigger paths have been run