CMS 3D CMS Logo

Classes | Functions
dataLoader Namespace Reference

Classes

class  DataLoader
 

Functions

def get_data (filename)
 
def get_data_csv (csv_data)
 

Function Documentation

def dataLoader.get_data (   filename)

Definition at line 191 of file dataLoader.py.

References get_data_csv(), and edm.print().

Referenced by generateFlavCfromFlavB.main(), and checkBTagCalibrationConsistency.run_check().

191 def get_data(filename):
192  with open(filename) as f:
193  csv_data = f.readlines()
194  if not (csv_data and "OperatingPoint" in csv_data[0]):
195  print("Data file does not contain typical header: %s. Exit" % filename)
196  return False
197  csv_data.pop(0) # remove header
198  return get_data_csv(csv_data)
199 
S & print(S &os, JobReport::InputFile const &f)
Definition: JobReport.cc:66
def get_data_csv(csv_data)
Definition: dataLoader.py:158
def get_data(filename)
Definition: dataLoader.py:191
def dataLoader.get_data_csv (   csv_data)

Definition at line 158 of file dataLoader.py.

References createfilelist.int, list(), and digitizers_cfi.strip.

Referenced by get_data(), and checkBTagCalibrationConsistency.run_check_csv().

158 def get_data_csv(csv_data):
159  # grab measurement types
160  meas_types = set(
161  l.split(',')[1].strip()
162  for l in csv_data
163  if len(l.split()) == 11
164  )
165 
166  # grab operating points
167  ops = set(
168  int(l.split(',')[0])
169  for l in csv_data
170  if len(l.split()) == 11
171  ) if separate_by_op else ['all']
172 
173  # grab flavors
174  flavs = set(
175  int(l.split(',')[3])
176  for l in csv_data
177  if len(l.split()) == 11
178  ) if separate_by_flav else ['all']
179 
180  # make loaders and filter empty ones
181  lds = list(
182  DataLoader(csv_data, mt, op, fl)
183  for mt in meas_types
184  for op in ops
185  for fl in flavs
186  )
187  lds = [d for d in lds if d.entries]
188  return lds
189 
190 
def get_data_csv(csv_data)
Definition: dataLoader.py:158
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