ATLAS Offline Software
Loading...
Searching...
No Matches
TrigMuonHypoConfig Namespace Reference

Classes

class  TrigmuCombHypoConfig
class  TrigMufastHypoToolConfig

Functions

 getThresholdsFromDict (chainDict)
 TrigMufastHypoAlgCfg (flags, name="UNSPECIFIED", **kwargs)
 TrigMufastHypoToolFromDict (flags, chainDict)
 TrigmuCombHypoAlgCfg (flags, name="UNSPECIFIED", **kwargs)
 TrigmuCombHypoToolFromDict (flags, chainDict)
 TrigmuCombHypoToolwORFromDict (flags, chainDict)
 Trigl2IOHypoToolwORFromDict (flags, chainDict)
 Trigl2mtCBHypoToolwORFromDict (flags, chainDict)
 TrigMuonEFHypoAlgCfg (flags, name="UNSPECIFIED", **kwargs)
 TrigMuonEFMSonlyHypoToolFromDict (flags, chainDict)
 TrigMuonEFMSonlyHypoToolFromName (flags, chainDict)
 TrigMuonEFHypoToolCfg (name, thresholds, doSA=False, **kwargs)
 TrigMuonEFCombinerHypoToolFromDict (flags, chainDict)
 TrigMuonEFCombinerHypoToolFromName (flags, chainDict)
 TrigMuonEFTrackIsolationHypoToolFromDict (flags, chainDict)
 TrigMuonEFTrackIsolationHypoCfg (flags, name, isoCut, **kwargs)
 TrigMuonEFTrackIsolationHypoAlgCfg (flags, name="TrigMuonEFTrackIsolationHypoAlg", **kwargs)
 TrigMuonEFInvMassHypoToolFromDict (flags, chainDict)
 TrigMuonEFInvMassHypoCfg (flags, toolName, thresholds, **kwargs)
 TrigMuonEFIdtpHypoToolFromDict (flags, chainDict)
 TrigMuonEFIdtpHypoCfg (name, thresholds, **kwargs)
 TrigMuonEFIdtpInvMassHypoToolFromDict (flags, chainDict)
 TrigMuonEFIdtpInvMassHypoCfg (name, thresholds, **kwargs)
 TrigMuonEFIdtpHypoAlgCfg (flags, name="TrigMuonEFIdtpHypoAlg", **kwargs)
 TrigMuonLateMuRoIHypoAlgCfg (flags, name="TrigMuRoIHypoAlg", **kwargs)
 TrigMuonLateMuRoIHypoToolFromDict (flags, chainDict)
 TrigMuonLateMuRoIHypoCfg (flags, name="TrigMuRoIHypoTool")

Variables

bool monitorAll = False
 log = logging.getLogger('TrigMuonHypoConfig')
dict muFastThresholds
dict muCombThresholds
dict trigMuonEFSAThresholds
dict efCombinerThresholds
dict muFastThresholdsForECWeakBRegion
dict trigMuonEFTrkIsoThresholds
dict trigMuonLrtd0Cut
dict trigMuonEFInvMassThresholds
list muonHypoMonGroups = ['muonMon:online']
list idHypoMonGroups = ['idMon:t0','idMon:shifter']

Function Documentation

◆ getThresholdsFromDict()

TrigMuonHypoConfig.getThresholdsFromDict ( chainDict)

Definition at line 280 of file TrigMuonHypoConfig.py.

280def getThresholdsFromDict( chainDict ):
281 cparts = [i for i in chainDict['chainParts'] if i['signature']=='Muon' or i['signature']=='Bphysics']
282 return sum( [ [part['threshold']]*int(part['multiplicity']) for part in cparts ], [])
283
284

◆ Trigl2IOHypoToolwORFromDict()

TrigMuonHypoConfig.Trigl2IOHypoToolwORFromDict ( flags,
chainDict )

Definition at line 574 of file TrigMuonHypoConfig.py.

574def Trigl2IOHypoToolwORFromDict( flags, chainDict ):
575
576 thresholds = getThresholdsFromDict( chainDict )
577 if chainDict['chainParts'][0]['multiplicity']=="0":
578 thresholds = [chainDict['chainParts'][0]['threshold']]
579
580 config = TrigmuCombHypoConfig()
581
582 tight = False # can be probably decoded from some of the proprties of the chain, expert work
583
584 acceptAll = False
585 domuCombTag=False
586
587 tool=config.ConfigurationHypoTool( chainDict['chainName'], thresholds, tight, acceptAll, domuCombTag )
588
589 # Overlap Removal
590 tool.ApplyOR = True
591 tool.RequireDR = True
592 tool.RequireMufastDR = False
593 tool.RequireMass = True
594 tool.RequireSameSign = True
595 tool.EtaBins = [0, 0.9, 1.1, 1.9, 2.1, 9.9]
596 tool.DRThres = [0.002, 0.001, 0.002, 0.002, 0.002]
597 tool.MufastDRThres = [0]
598 tool.MassThres = [0.004, 0.002, 0.006, 0.006, 0.006]
599
600 return tool
601
602
603# muComb Hypo for L2 multi-track SA mode

◆ Trigl2mtCBHypoToolwORFromDict()

TrigMuonHypoConfig.Trigl2mtCBHypoToolwORFromDict ( flags,
chainDict )

Definition at line 604 of file TrigMuonHypoConfig.py.

604def Trigl2mtCBHypoToolwORFromDict( flags, chainDict ):
605
606 if 'idperf' in chainDict['chainParts'][0]['addInfo'] or 'idtp' in chainDict['chainParts'][0]['addInfo'] :
607 thresholds = ['passthrough']
608 elif chainDict['chainParts'][0]['multiplicity']=="0":
609 thresholds = [chainDict['chainParts'][0]['threshold']]
610 else:
611 thresholds = getThresholdsFromDict( chainDict )
612
613 config = TrigmuCombHypoConfig()
614
615 tight = False # can be probably decoded from some of the proprties of the chain, expert work
616
617 acceptAll = False
618 domuCombTag = False
619
620 tool=config.ConfigurationHypoTool( chainDict['chainName'], thresholds, tight, acceptAll, domuCombTag )
621
622 # Overlap Removal
623 tool.ApplyOR = True
624 tool.RequireDR = True
625 tool.RequireMufastDR = True
626 tool.RequireMass = True
627 tool.RequireSameSign = True
628 tool.EtaBins = [0, 0.9, 1.1, 1.9, 2.1, 9.9]
629 tool.DRThres = [0.002, 0.001, 0.002, 0.002, 0.002]
630 tool.MufastDRThres = [0.4, 0.4, 0.4, 0.4, 0.4]
631 tool.MassThres = [0.004, 0.002, 0.006, 0.006, 0.006]
632
633 return tool
634
635

◆ TrigmuCombHypoAlgCfg()

TrigMuonHypoConfig.TrigmuCombHypoAlgCfg ( flags,
name = "UNSPECIFIED",
** kwargs )

Definition at line 486 of file TrigMuonHypoConfig.py.

486def TrigmuCombHypoAlgCfg(flags, name="UNSPECIFIED", **kwargs):
487 return CompFactory.TrigmuCombHypoAlg(name, **kwargs)
488

◆ TrigmuCombHypoToolFromDict()

TrigMuonHypoConfig.TrigmuCombHypoToolFromDict ( flags,
chainDict )

Definition at line 489 of file TrigMuonHypoConfig.py.

489def TrigmuCombHypoToolFromDict( flags, chainDict ):
490
491 if 'idperf' in chainDict['chainParts'][0]['addInfo'] or 'idtp' in chainDict['chainParts'][0]['addInfo'] :
492 thresholds = ['passthrough']
493 elif chainDict['chainParts'][0]['multiplicity']=="0":
494 thresholds = [chainDict['chainParts'][0]['threshold']]
495 else:
496 thresholds = getThresholdsFromDict( chainDict )
497
498 config = TrigmuCombHypoConfig()
499
500 tight = False # can be probably decoded from some of the proprties of the chain, expert work
501
502 acceptAll = False
503
504 if 'mucombTag' in chainDict['chainParts'][0]['extra']:
505 domuCombTag = True
506 else:
507 domuCombTag = False
508
509 if chainDict['chainParts'][0]['signature'] == 'Bphysics':
510 acceptAll = True
511
512 tool = config.ConfigurationHypoTool( chainDict['chainName'], thresholds, tight, acceptAll, domuCombTag )
513
514 if monitorAll:
515 tool.MonTool = TrigmuCombHypoMonitoring(flags, "TrigmuCombHypoTool/"+chainDict['chainName'])
516 else:
517 if any(group in muonHypoMonGroups for group in chainDict['monGroups']):
518 tool.MonTool = TrigmuCombHypoMonitoring(flags, "TrigmuCombHypoTool/"+chainDict['chainName'])
519
520 d0cut=0.
521 if 'd0loose' in chainDict['chainParts'][0]['lrtInfo']:
522 d0cut=trigMuonLrtd0Cut['d0loose']
523 elif 'd0medium' in chainDict['chainParts'][0]['lrtInfo']:
524 d0cut=trigMuonLrtd0Cut['d0medium']
525 elif 'd0tight' in chainDict['chainParts'][0]['lrtInfo']:
526 d0cut=trigMuonLrtd0Cut['d0tight']
527 tool.MinimumD0=d0cut
528
529 return tool
530
531

◆ TrigmuCombHypoToolwORFromDict()

TrigMuonHypoConfig.TrigmuCombHypoToolwORFromDict ( flags,
chainDict )

Definition at line 532 of file TrigMuonHypoConfig.py.

532def TrigmuCombHypoToolwORFromDict( flags, chainDict ):
533
534 if 'idperf' in chainDict['chainParts'][0]['addInfo'] or 'idtp' in chainDict['chainParts'][0]['addInfo'] :
535 thresholds = ['passthrough']
536 elif chainDict['chainParts'][0]['multiplicity']=="0":
537 thresholds = [chainDict['chainParts'][0]['threshold']]
538 else:
539 thresholds = getThresholdsFromDict( chainDict )
540
541 config = TrigmuCombHypoConfig()
542
543 tight = False # can be probably decoded from some of the proprties of the chain, expert work
544
545 acceptAll = False
546 if 'mucombTag' in chainDict['chainParts'][0]['extra']:
547 domuCombTag = True
548 else:
549 domuCombTag = False
550
551 tool = config.ConfigurationHypoTool( chainDict['chainName'], thresholds, tight, acceptAll, domuCombTag )
552
553 if monitorAll:
554 tool.MonTool = TrigL2MuonOverlapRemoverMonitoringMucomb(flags, "TrigmuCombHypoTool/"+chainDict['chainName'])
555 else:
556 if any(group in muonHypoMonGroups for group in chainDict['monGroups']):
557 tool.MonTool = TrigL2MuonOverlapRemoverMonitoringMucomb(flags, "TrigmuCombHypoTool/"+chainDict['chainName'])
558
559 # Overlap Removal
560 tool.ApplyOR = True
561 tool.RequireDR = True
562 tool.RequireMufastDR = True
563 tool.RequireMass = True
564 tool.RequireSameSign = True
565 tool.EtaBins = [0, 0.9, 1.1, 1.9, 2.1, 9.9]
566 tool.DRThres = [0.002, 0.001, 0.002, 0.002, 0.002]
567 tool.MufastDRThres = [0.4, 0.4, 0.4, 0.4, 0.4]
568 tool.MassThres = [0.004, 0.002, 0.006, 0.006, 0.006]
569
570 return tool
571
572
573# muComb Hypo for L2 inside-out

◆ TrigMufastHypoAlgCfg()

TrigMuonHypoConfig.TrigMufastHypoAlgCfg ( flags,
name = "UNSPECIFIED",
** kwargs )

Definition at line 285 of file TrigMuonHypoConfig.py.

285def TrigMufastHypoAlgCfg(flags, name="UNSPECIFIED", **kwargs):
286 return CompFactory.TrigMufastHypoAlg(name, **kwargs)
287

◆ TrigMufastHypoToolFromDict()

TrigMuonHypoConfig.TrigMufastHypoToolFromDict ( flags,
chainDict )

Definition at line 288 of file TrigMuonHypoConfig.py.

288def TrigMufastHypoToolFromDict(flags, chainDict):
289
290 chainPart = chainDict['chainParts'][0]
291
292 doOverlapRemoval = False
293 if chainPart['signature'] == 'Bphysics' or 'l2io' in chainPart['l2AlgInfo']:
294 doOverlapRemoval = False
295 elif int(chainPart['multiplicity']) > 1:
296 doOverlapRemoval = True
297 elif len(chainDict['signatures']) > 1 and not chainPart['extra']:
298 doOverlapRemoval = True
299
300 doMonitoring = monitorAll or any(group in muonHypoMonGroups for group in chainDict['monGroups'])
301
302 config = TrigMufastHypoToolConfig(chainDict['chainName'], chainPart, chainDict['eventBuildType'], doOverlapRemoval, doMonitoring)
303 config.compile(flags)
304 return config.tool()
305
306

◆ TrigMuonEFCombinerHypoToolFromDict()

TrigMuonHypoConfig.TrigMuonEFCombinerHypoToolFromDict ( flags,
chainDict )

Definition at line 829 of file TrigMuonHypoConfig.py.

829def TrigMuonEFCombinerHypoToolFromDict( flags, chainDict ) :
830 if 'idperf' in chainDict['chainParts'][0]['addInfo'] or 'idtp' in chainDict['chainParts'][0]['addInfo']:
831 thresholds = ['passthrough']
832 elif chainDict['chainParts'][0]['multiplicity']=="0":
833 thresholds = [chainDict['chainParts'][0]['threshold']]
834 else:
835 thresholds = getThresholdsFromDict( chainDict )
836
837 if 'muonqual' in chainDict['chainParts'][0]['addInfo']:
838 muonquality = True
839 else:
840 muonquality = False
841
842 if 'nscan10' in chainDict['chainParts'][0]['addInfo']:
843 conesize = 0.1
844 narrowscan = True
845 elif 'nscan20' in chainDict['chainParts'][0]['addInfo']:
846 conesize = 0.2
847 narrowscan = True
848 elif 'nscan30' in chainDict['chainParts'][0]['addInfo']:
849 conesize = 0.3
850 narrowscan = True
851 elif 'nscan40' in chainDict['chainParts'][0]['addInfo']:
852 conesize = 0.4
853 narrowscan = True
854 elif 'nscan' in chainDict['chainParts'][0]['addInfo']:
855 conesize = 0.5
856 narrowscan = True
857 else:
858 narrowscan = False
859 conesize = 0.0
860
861 if 'noL1' not in chainDict['chainParts'][0]['extra']:
862 overlap=True
863 else:
864 overlap=False
865
866 monTool=None
867 if monitorAll:
868 monTool = TrigMuonEFHypoMonitoring(flags, "TrigMuonEFCombinerHypoTool/"+chainDict['chainName'])
869 else:
870 if any(group in muonHypoMonGroups for group in chainDict['monGroups']):
871 monTool = TrigMuonEFHypoMonitoring(flags, "TrigMuonEFCombinerHypoTool/"+chainDict['chainName'])
872
873 d0cut=0.
874 if 'd0loose' in chainDict['chainParts'][0]['lrtInfo']:
875 d0cut=trigMuonLrtd0Cut['d0loose']
876 elif 'd0medium' in chainDict['chainParts'][0]['lrtInfo']:
877 d0cut=trigMuonLrtd0Cut['d0medium']
878 elif 'd0tight' in chainDict['chainParts'][0]['lrtInfo']:
879 d0cut=trigMuonLrtd0Cut['d0tight']
880
881
882 tool = TrigMuonEFHypoToolCfg(chainDict['chainName'], thresholds, doSA=False, MuonQualityCut=muonquality, MonTool=monTool,
883 NarrowScan=narrowscan, RemoveOverlaps=overlap, ConeSize=conesize, MinimumD0=d0cut)
884
885 return tool
886

◆ TrigMuonEFCombinerHypoToolFromName()

TrigMuonHypoConfig.TrigMuonEFCombinerHypoToolFromName ( flags,
chainDict )

Definition at line 887 of file TrigMuonHypoConfig.py.

887def TrigMuonEFCombinerHypoToolFromName( flags, chainDict ):
888 #For full scan chains, we need to configure the thresholds based on all muons
889 #in the chain to get the counting correct. Currently a bit convoluted as
890 #the chain dict is (improperly) overwritten when merging for FS chains.
891 #Can probably improve this once serial merging is officially implemented
892 thresholds=[]
893 chainName = chainDict["chainName"]
894 hltChainName = chainName.rsplit("_L1",1)[0]
895 cparts = hltChainName.split("_")
896 if 'HLT' in hltChainName:
897 cparts.remove('HLT')
898 for part in cparts:
899 if 'mu' in part:
900 thrPart = part.split('mu')
901 if not thrPart[0] or thrPart[0] == "0":
902 mult = 1
903 else:
904 mult=thrPart[0]
905 thr = thrPart[1]
906 if 'noL1' in part:
907 thr =thr.replace('noL1','')
908 for i in range(1,int(mult)+1):
909 thresholds.append(thr)
910 if 'nscan10' in chainDict['chainParts'][0]['addInfo']:
911 conesize = 0.1
912 narrowscan = True
913 elif 'nscan20' in chainDict['chainParts'][0]['addInfo']:
914 conesize = 0.2
915 narrowscan = True
916 elif 'nscan30' in chainDict['chainParts'][0]['addInfo']:
917 conesize = 0.3
918 narrowscan = True
919 elif 'nscan40' in chainDict['chainParts'][0]['addInfo']:
920 conesize = 0.4
921 narrowscan = True
922 if 'nscan' in chainDict['chainParts'][0]['addInfo']:
923 conesize = 0.5
924 narrowscan = True
925 else:
926 narrowscan = False
927 conesize = 0.0
928
929 if 'muonqual' in chainDict['chainParts'][0]['addInfo']:
930 muonquality = True
931 else:
932 muonquality = False
933
934 monTool=None
935 if monitorAll:
936 monTool = TrigMuonEFHypoMonitoring(flags, "TrigMuonEFCombinerHypoTool/"+chainDict['chainName'])
937 else:
938 if any(group in muonHypoMonGroups for group in chainDict['monGroups']):
939 monTool = TrigMuonEFHypoMonitoring(flags, "TrigMuonEFCombinerHypoTool/"+chainDict['chainName'])
940
941 tool = TrigMuonEFHypoToolCfg(chainDict['chainName'], thresholds, doSA=False, MuonQualityCut=muonquality, MonTool=monTool,
942 NarrowScan=narrowscan, ConeSize=conesize)
943
944 return tool
945
946
947

◆ TrigMuonEFHypoAlgCfg()

TrigMuonHypoConfig.TrigMuonEFHypoAlgCfg ( flags,
name = "UNSPECIFIED",
** kwargs )

Definition at line 683 of file TrigMuonHypoConfig.py.

683def TrigMuonEFHypoAlgCfg(flags, name="UNSPECIFIED", **kwargs):
684 return CompFactory.TrigMuonEFHypoAlg(name, **kwargs)
685
686

◆ TrigMuonEFHypoToolCfg()

TrigMuonHypoConfig.TrigMuonEFHypoToolCfg ( name,
thresholds,
doSA = False,
** kwargs )

Definition at line 787 of file TrigMuonHypoConfig.py.

787def TrigMuonEFHypoToolCfg(name, thresholds, doSA=False, **kwargs):
788
789
790 log = logging.getLogger(name)
791
792 nt = len(thresholds)
793 log.debug('Set %d thresholds', nt)
794 PtBins = [ [ 0.0, 2.5 ] ] * nt
795 PtThresholds = [ [ 5.49 * GeV ] ] * nt
796 passthrough=False
797 for th, thvalue in enumerate(thresholds):
798 if (thvalue=='passthrough'):
799 passthrough = True
800 PtBins[th] = [-10000.,10000.]
801 PtThresholds[th] = [ -1. * GeV ]
802 else:
803 if "0eta105" in name:
804 thvaluename = thvalue+ "GeV_barrelOnly"
805 else:
806 if int(thvalue)==3:
807 thvaluename = thvalue + 'GeV_v22a'
808 else:
809 if doSA:
810 thvaluename = thvalue + 'GeV'
811 else:
812 thvaluename = thvalue + 'GeV_v15a'
813 log.debug('Number of threshold = %d, Value of threshold = %s', th, thvaluename)
814
815 if doSA:
816 values = trigMuonEFSAThresholds[thvaluename]
817 else:
818 values = efCombinerThresholds[thvaluename]
819 PtBins[th] = values[0]
820 PtThresholds[th] = [ x * GeV for x in values[1] ]
821
822
823 kwargs.setdefault("AcceptAll", passthrough)
824 kwargs.setdefault("PtBins", PtBins)
825 kwargs.setdefault("PtThresholds", PtThresholds)
826 return CompFactory.TrigMuonEFHypoTool(name, **kwargs)
827
828

◆ TrigMuonEFIdtpHypoAlgCfg()

TrigMuonHypoConfig.TrigMuonEFIdtpHypoAlgCfg ( flags,
name = "TrigMuonEFIdtpHypoAlg",
** kwargs )

Definition at line 1097 of file TrigMuonHypoConfig.py.

1097def TrigMuonEFIdtpHypoAlgCfg(flags, name="TrigMuonEFIdtpHypoAlg", **kwargs):
1098 return CompFactory.TrigMuonEFIdtpHypoAlg(name, **kwargs)
1099

◆ TrigMuonEFIdtpHypoCfg()

TrigMuonHypoConfig.TrigMuonEFIdtpHypoCfg ( name,
thresholds,
** kwargs )

Definition at line 1037 of file TrigMuonHypoConfig.py.

1037def TrigMuonEFIdtpHypoCfg(name, thresholds, **kwargs):
1038
1039 log = logging.getLogger(name)
1040
1041 nt = len(thresholds)
1042 log.debug('Set %d thresholds', nt)
1043 ptBins = [ [ 0, 2.5 ] ] * nt
1044 ptThresholds = [ [ 5.49 * GeV ] ] * nt
1045 for th, thvalue in enumerate(thresholds):
1046 thvaluename = thvalue + 'GeV'
1047 if int(thvalue)==3:
1048 thvaluename = thvalue + 'GeV_v22a'
1049 log.debug('Number of threshold = %d, Value of threshold = %s', th, thvaluename)
1050 if (thvalue=='passthrough'):
1051 ptBins[th] = [-10000.,10000.]
1052 ptThresholds[th] = [ -1. * GeV ]
1053 else:
1054 values = trigMuonEFSAThresholds[thvaluename]
1055 ptBins[th] = values[0]
1056 ptThresholds[th] = [ x * GeV for x in values[1] ]
1057
1058
1059 if (thvalue=='passthrough'):
1060 kwargs.setdefault("AcceptAll", True)
1061 else:
1062 kwargs.setdefault("AcceptAll", False)
1063
1064 kwargs.setdefault("PtBins", ptBins)
1065 kwargs.setdefault("PtThresholds", ptThresholds)
1066
1067
1068 return CompFactory.TrigMuonEFIdtpHypoTool( name, **kwargs )
1069

◆ TrigMuonEFIdtpHypoToolFromDict()

TrigMuonHypoConfig.TrigMuonEFIdtpHypoToolFromDict ( flags,
chainDict )

Definition at line 1028 of file TrigMuonHypoConfig.py.

1028def TrigMuonEFIdtpHypoToolFromDict( flags, chainDict ) :
1029 thresholds = getThresholdsFromDict( chainDict )
1030 monTool=None
1031 if any(group in idHypoMonGroups for group in chainDict['monGroups']):
1032 monTool = TrigMuonEFIdtpHypoMonitoring(flags, "TrigMuonEFIdtpHypoTool/"+chainDict['chainName'])
1033 tool = TrigMuonEFIdtpHypoCfg( chainDict['chainName'], thresholds, MonTool=monTool )
1034 return tool
1035
1036

◆ TrigMuonEFIdtpInvMassHypoCfg()

TrigMuonHypoConfig.TrigMuonEFIdtpInvMassHypoCfg ( name,
thresholds,
** kwargs )

Definition at line 1087 of file TrigMuonHypoConfig.py.

1087def TrigMuonEFIdtpInvMassHypoCfg(name, thresholds, **kwargs) :
1088
1089 massWindow = trigMuonEFInvMassThresholds[thresholds]
1090 kwargs.setdefault("InvMassLow", massWindow[0])
1091 kwargs.setdefault("InvMassHigh", massWindow[1])
1092 kwargs.setdefault("AcceptAll", False)
1093
1094 return CompFactory.TrigMuonEFIdtpInvMassHypoTool(name, **kwargs)
1095
1096

◆ TrigMuonEFIdtpInvMassHypoToolFromDict()

TrigMuonHypoConfig.TrigMuonEFIdtpInvMassHypoToolFromDict ( flags,
chainDict )

Definition at line 1070 of file TrigMuonHypoConfig.py.

1070def TrigMuonEFIdtpInvMassHypoToolFromDict(flags, chainDict) :
1071 cname = chainDict['chainName']
1072 if 'idZmumu' in cname :
1073 thresholds = 'idZmumu'
1074 elif 'idJpsimumu' in cname :
1075 thresholds = 'idJpsimumu'
1076 else :
1077 log.warning("unknown chain name for IdtpInvmassHypo, chain name= %s, setting threshold of Z mass",cname)
1078 thresholds = 'idZmumu'
1079
1080 tool = TrigMuonEFIdtpInvMassHypoCfg( chainDict['chainName'], thresholds )
1081
1082 if any(group in idHypoMonGroups for group in chainDict['monGroups']):
1083 tool.MonTool = TrigMuonEFIdtpInvMassHypoMonitoring(flags, "TrigMuonEFIdtpInvMassHypoTool/"+chainDict['chainName'])
1084
1085 return tool
1086

◆ TrigMuonEFInvMassHypoCfg()

TrigMuonHypoConfig.TrigMuonEFInvMassHypoCfg ( flags,
toolName,
thresholds,
** kwargs )

Definition at line 1017 of file TrigMuonHypoConfig.py.

1017def TrigMuonEFInvMassHypoCfg(flags, toolName, thresholds, **kwargs):
1018
1019 massWindow = trigMuonEFInvMassThresholds[thresholds]
1020
1021 kwargs.setdefault("InvMassLow", massWindow[0])
1022 kwargs.setdefault("InvMassHigh", massWindow[1])
1023 kwargs.setdefault("AcceptAll", False)
1024
1025 tool = CompFactory.TrigMuonEFInvMassHypoTool(toolName, **kwargs)
1026 return tool
1027

◆ TrigMuonEFInvMassHypoToolFromDict()

TrigMuonHypoConfig.TrigMuonEFInvMassHypoToolFromDict ( flags,
chainDict )

Definition at line 998 of file TrigMuonHypoConfig.py.

998def TrigMuonEFInvMassHypoToolFromDict( flags, chainDict ) :
999 cparts = [i for i in chainDict['chainParts'] if i['signature']=='Muon']
1000 #The invariant mass is specified at end of chain, so only shows up in the last chainPart
1001 thresholds = cparts[-1]['invMassInfo']
1002 if "os" in cparts[-1]['addInfo']:
1003 osCut=True
1004 else:
1005 osCut = False
1006
1007 tool = TrigMuonEFInvMassHypoCfg( flags, chainDict['chainName'], thresholds, SelectOppositeSign=osCut )
1008
1009 if monitorAll:
1010 tool.MonTool = TrigMuonEFInvMassHypoMonitoring(flags, "TrigMuonEFInvMassHypoTool/"+chainDict['chainName'])
1011 else:
1012 if any(group in muonHypoMonGroups for group in chainDict['monGroups']):
1013 tool.MonTool = TrigMuonEFInvMassHypoMonitoring(flags, "TrigMuonEFInvMassHypoTool/"+chainDict['chainName'])
1014
1015 return tool
1016

◆ TrigMuonEFMSonlyHypoToolFromDict()

TrigMuonHypoConfig.TrigMuonEFMSonlyHypoToolFromDict ( flags,
chainDict )

Definition at line 687 of file TrigMuonHypoConfig.py.

687def TrigMuonEFMSonlyHypoToolFromDict( flags, chainDict ) :
688 thresholds = getThresholdsFromDict( chainDict )
689 if chainDict['chainParts'][0]['multiplicity']=="0":
690 thresholds = [chainDict['chainParts'][0]['threshold']]
691 kwargs={}
692 kwargs.setdefault("RequireSAMuons",True)
693 if 'msonly' in chainDict['chainParts'][0]['msonlyInfo'] and 'noL1' not in chainDict['chainParts'][0]['extra']:
694 kwargs.setdefault("RemoveOverlaps",True)
695
696
697 if monitorAll:
698 monTool = TrigMuonEFHypoMonitoring(flags, "TrigMuonEFMSonlyHypoTool/"+chainDict['chainName'])
699 kwargs.setdefault("MonTool", monTool)
700 else:
701 if any(group in muonHypoMonGroups for group in chainDict['monGroups']):
702 monTool = TrigMuonEFHypoMonitoring(flags, "TrigMuonEFMSonlyHypoTool/"+chainDict['chainName'])
703 kwargs.setdefault("MonTool", monTool)
704 if '3layersEC' in chainDict['chainParts'][0]['addInfo']:
705 kwargs.setdefault("RequireThreeStations", True)
706 muonflags = flags.cloneAndReplace('Muon', 'Trigger.Offline.SA.Muon')
707 if muonflags.Muon.runCommissioningChain:
708 kwargs.setdefault("RunCommissioningChain",True)
709
710
711 if 'nscan10' in chainDict['chainParts'][0]['addInfo']:
712 conesize = 0.1
713 narrowscan = True
714 elif 'nscan20' in chainDict['chainParts'][0]['addInfo']:
715 conesize = 0.2
716 narrowscan = True
717 elif 'nscan30' in chainDict['chainParts'][0]['addInfo']:
718 conesize = 0.3
719 narrowscan = True
720 elif 'nscan40' in chainDict['chainParts'][0]['addInfo']:
721 conesize = 0.4
722 narrowscan = True
723 elif 'nscan' in chainDict['chainParts'][0]['addInfo']:
724 conesize = 0.5
725 narrowscan = True
726 else:
727 narrowscan = False
728 conesize = 0.0
729
730 kwargs.setdefault("ConeSize", conesize)
731 kwargs.setdefault("NarrowScan", narrowscan)
732
733 return TrigMuonEFHypoToolCfg( chainDict['chainName'], thresholds, doSA=True, **kwargs )
734

◆ TrigMuonEFMSonlyHypoToolFromName()

TrigMuonHypoConfig.TrigMuonEFMSonlyHypoToolFromName ( flags,
chainDict )

Definition at line 735 of file TrigMuonHypoConfig.py.

735def TrigMuonEFMSonlyHypoToolFromName( flags, chainDict):
736 #For full scan chains, we need to configure the thresholds based on all muons
737 #in the chain to get the counting correct.
738 thresholds=[]
739 chainName = chainDict["chainName"]
740 hltChainName = chainName.rsplit("_L1",1)[0]
741 cparts = hltChainName.split("_")
742
743 if 'HLT' in hltChainName:
744 cparts.remove('HLT')
745 for part in cparts:
746 if 'mu' in part:
747 thrPart = part.split('mu')
748 if not thrPart[0] or thrPart[0] == "0":
749 mult = 1
750 else:
751 mult=thrPart[0]
752 thr = thrPart[1]
753 if 'noL1' in part:
754 thr =thr.replace('noL1','')
755 for i in range(1,int(mult)+1):
756 thresholds.append(thr)
757
758 monTool=None
759 if monitorAll:
760 monTool = TrigMuonEFHypoMonitoring(flags, "TrigMuonEFMSonlyHypoTool/"+chainDict['chainName'])
761 else:
762 if any(group in muonHypoMonGroups for group in chainDict['monGroups']):
763 monTool = TrigMuonEFHypoMonitoring(flags, "TrigMuonEFMSonlyHypoTool/"+chainDict['chainName'])
764
765 if 'nscan10' in chainDict['chainParts'][0]['addInfo']:
766 conesize = 0.1
767 narrowscan = True
768 elif 'nscan20' in chainDict['chainParts'][0]['addInfo']:
769 conesize = 0.2
770 narrowscan = True
771 elif 'nscan30' in chainDict['chainParts'][0]['addInfo']:
772 conesize = 0.3
773 narrowscan = True
774 elif 'nscan40' in chainDict['chainParts'][0]['addInfo']:
775 conesize = 0.4
776 narrowscan = True
777 elif 'nscan' in chainDict['chainParts'][0]['addInfo']:
778 conesize = 0.5
779 narrowscan = True
780 else:
781 narrowscan = False
782 conesize = 0.0
783
784
785 return TrigMuonEFHypoToolCfg( chainDict['chainName'], thresholds, doSA=True, MonTool=monTool, RequireSAMuons=True, NarrowScan=narrowscan, ConeSize=conesize)
786

◆ TrigMuonEFTrackIsolationHypoAlgCfg()

TrigMuonHypoConfig.TrigMuonEFTrackIsolationHypoAlgCfg ( flags,
name = "TrigMuonEFTrackIsolationHypoAlg",
** kwargs )

Definition at line 995 of file TrigMuonHypoConfig.py.

995def TrigMuonEFTrackIsolationHypoAlgCfg(flags, name="TrigMuonEFTrackIsolationHypoAlg", **kwargs):
996 return CompFactory.TrigMuonEFTrackIsolationHypoAlg(name, **kwargs)
997

◆ TrigMuonEFTrackIsolationHypoCfg()

TrigMuonHypoConfig.TrigMuonEFTrackIsolationHypoCfg ( flags,
name,
isoCut,
** kwargs )

Definition at line 966 of file TrigMuonHypoConfig.py.

966def TrigMuonEFTrackIsolationHypoCfg(flags, name, isoCut, **kwargs) :
967
968
969 if(isoCut=='passthrough') :
970 kwargs.setdefault("AcceptAll", True)
971
972 else:
973 ptcone03 = trigMuonEFTrkIsoThresholds[ isoCut ]
974
975 kwargs.setdefault("PtCone02Cut", 0.0)
976 kwargs.setdefault("PtCone03Cut", ptcone03)
977 kwargs.setdefault("AcceptAll", False)
978
979 if 'ms' in isoCut:
980 kwargs.setdefault("RequireCombinedMuon", False)
981 kwargs.setdefault("DoAbsCut", True)
982 else:
983 kwargs.setdefault("RequireCombinedMuon", True)
984 kwargs.setdefault("DoAbsCut", False)
985
986
987 if 'var' in isoCut :
988 kwargs.setdefault("useVarIso", True)
989 else :
990 kwargs.setdefault("useVarIso", False)
991
992 tool = CompFactory.TrigMuonEFTrackIsolationHypoTool(name, **kwargs)
993 return tool
994
if(febId1==febId2)

◆ TrigMuonEFTrackIsolationHypoToolFromDict()

TrigMuonHypoConfig.TrigMuonEFTrackIsolationHypoToolFromDict ( flags,
chainDict )

Definition at line 948 of file TrigMuonHypoConfig.py.

948def TrigMuonEFTrackIsolationHypoToolFromDict( flags, chainDict ) :
949 cparts = [i for i in chainDict['chainParts'] if i['signature']=='Muon']
950 if 'ivarperf' in chainDict['chainParts'][0]['isoInfo']:
951 thresholds = 'passthrough'
952 else:
953 thresholds = cparts[0]['isoInfo']
954
955 tool = TrigMuonEFTrackIsolationHypoCfg(flags, chainDict['chainName'], thresholds)
956
957
958 if monitorAll:
959 tool.MonTool = TrigMuonEFTrackIsolationMonitoring(flags, 'TrigMuonEFTrackIsolationHypoTool/'+chainDict['chainName'])
960 else:
961 if any(group in muonHypoMonGroups for group in chainDict['monGroups']):
962 tool.MonTool = TrigMuonEFTrackIsolationMonitoring(flags, 'TrigMuonEFTrackIsolationHypoTool/'+chainDict['chainName'])
963
964 return tool
965

◆ TrigMuonLateMuRoIHypoAlgCfg()

TrigMuonHypoConfig.TrigMuonLateMuRoIHypoAlgCfg ( flags,
name = "TrigMuRoIHypoAlg",
** kwargs )

Definition at line 1100 of file TrigMuonHypoConfig.py.

1100def TrigMuonLateMuRoIHypoAlgCfg(flags, name="TrigMuRoIHypoAlg", **kwargs):
1101 return CompFactory.TrigMuonLateMuRoIHypoAlg(name, **kwargs)
1102

◆ TrigMuonLateMuRoIHypoCfg()

TrigMuonHypoConfig.TrigMuonLateMuRoIHypoCfg ( flags,
name = "TrigMuRoIHypoTool" )

Definition at line 1107 of file TrigMuonHypoConfig.py.

1107def TrigMuonLateMuRoIHypoCfg(flags, name="TrigMuRoIHypoTool") :
1108
1109 tool = CompFactory.TrigMuonLateMuRoIHypoTool(name, AcceptAll=False)
1110 return tool

◆ TrigMuonLateMuRoIHypoToolFromDict()

TrigMuonHypoConfig.TrigMuonLateMuRoIHypoToolFromDict ( flags,
chainDict )

Definition at line 1103 of file TrigMuonHypoConfig.py.

1103def TrigMuonLateMuRoIHypoToolFromDict(flags, chainDict ) :
1104 tool = TrigMuonLateMuRoIHypoCfg(flags, chainDict['chainName'])
1105 return tool
1106

Variable Documentation

◆ efCombinerThresholds

dict TrigMuonHypoConfig.efCombinerThresholds

Definition at line 164 of file TrigMuonHypoConfig.py.

◆ idHypoMonGroups

list TrigMuonHypoConfig.idHypoMonGroups = ['idMon:t0','idMon:shifter']

Definition at line 278 of file TrigMuonHypoConfig.py.

◆ log

TrigMuonHypoConfig.log = logging.getLogger('TrigMuonHypoConfig')

Definition at line 24 of file TrigMuonHypoConfig.py.

◆ monitorAll

bool TrigMuonHypoConfig.monitorAll = False

Definition at line 18 of file TrigMuonHypoConfig.py.

◆ muCombThresholds

dict TrigMuonHypoConfig.muCombThresholds

Definition at line 64 of file TrigMuonHypoConfig.py.

◆ muFastThresholds

dict TrigMuonHypoConfig.muFastThresholds

Definition at line 26 of file TrigMuonHypoConfig.py.

◆ muFastThresholdsForECWeakBRegion

dict TrigMuonHypoConfig.muFastThresholdsForECWeakBRegion

Definition at line 208 of file TrigMuonHypoConfig.py.

◆ muonHypoMonGroups

list TrigMuonHypoConfig.muonHypoMonGroups = ['muonMon:online']

Definition at line 277 of file TrigMuonHypoConfig.py.

◆ trigMuonEFInvMassThresholds

dict TrigMuonHypoConfig.trigMuonEFInvMassThresholds
Initial value:
1= {
2 'invmJPsiOS' : [2.5, 4.3],
3 'invmDimu' : [1.5, 14.],
4 'idZmumu' : [50., 130.],
5 'idJpsimumu' : [1., 5.],
6}

Definition at line 269 of file TrigMuonHypoConfig.py.

◆ trigMuonEFSAThresholds

dict TrigMuonHypoConfig.trigMuonEFSAThresholds

Definition at line 118 of file TrigMuonHypoConfig.py.

◆ trigMuonEFTrkIsoThresholds

dict TrigMuonHypoConfig.trigMuonEFTrkIsoThresholds
Initial value:
1= {
2 'ivarloose' : 0.16, #ivarloose
3 'ivarmedium' : 0.07, #ivarmedium
4 'ivartight' : 0.06, #ivartight
5 'ivarverytight' : 0.04, #ivarverytight
6 'iloosems' : 3000.0 #ms-only iso
7 }

Definition at line 252 of file TrigMuonHypoConfig.py.

◆ trigMuonLrtd0Cut

dict TrigMuonHypoConfig.trigMuonLrtd0Cut
Initial value:
1= {
2 'd0loose' : 2.0,
3 'd0medium' : 3.0,
4 'd0tight' : 5.0
5 }

Definition at line 260 of file TrigMuonHypoConfig.py.