CMS 3D CMS Logo

Functions
L1TCommon Namespace Reference

Functions

def generateEfficiencyStrings (variables, plots)
 

Function Documentation

◆ generateEfficiencyStrings()

def L1TCommon.generateEfficiencyStrings (   variables,
  plots 
)

Definition at line 2 of file L1TCommon.py.

2 def generateEfficiencyStrings(variables, plots):
3  stringTemplate = "{plot} " + \
4  "'{var} efficiency; Offline E_{{T}}^{{miss}} (GeV); {var} efficiency'" + \
5  " {num_path} {den_path}"
6  for variable, thresholds in variables.items():
7  for plot in plots[variable]:
8  for threshold in thresholds:
9  plotName = '{0}_threshold_{1}'.format(plot, threshold)
10  varName = plot.replace('efficiency', '')
11  yield stringTemplate.format(
12  var=varName,
13  plot=plotName,
14  num_path='efficiency_raw/' + plotName + '_Num',
15  den_path='efficiency_raw/' + plotName + '_Den',
16  )
17 
def generateEfficiencyStrings(variables, plots)
Definition: L1TCommon.py:2