ATLAS Offline Software
Functions
python.LArCalibConfigFlags Namespace Reference

Functions

def addLArCalibFlags (flags, isSC=False)
 
def _getInputFiles (prevFlags)
 
def LArCalibFolderTag (folder, tag)
 

Function Documentation

◆ _getInputFiles()

def python.LArCalibConfigFlags._getInputFiles (   prevFlags)
private

Definition at line 89 of file LArCalibConfigFlags.py.

89 def _getInputFiles(prevFlags):
90  from LArCalibProcessing.GetInputFiles import GetInputFiles
91  allFiles=[]
92  for rn in prevFlags.LArCalib.Input.RunNumbers:
93  pattern="data.*%(rn)07d.%(type)s.*" % {'rn' : rn,'type' : prevFlags.LArCalib.Input.Type }
94  allFiles+=GetInputFiles(prevFlags.LArCalib.Input.Dir,pattern)
95 
96  return allFiles
97 

◆ addLArCalibFlags()

def python.LArCalibConfigFlags.addLArCalibFlags (   flags,
  isSC = False 
)

Definition at line 3 of file LArCalibConfigFlags.py.

3 def addLArCalibFlags(flags, isSC=False):
4 
5  flags.Input.isMC=False
6  flags.addFlag("LArCalib.isSC",isSC)
7  flags.addFlag("LArCalib.BadChannelDB","LAR_OFL")
8  flags.addFlag("LArCalib.BadChannelTag","-RUN2-UPD3-00")
9  flags.addFlag("LArCalib.BadChannelTagSC","-RUN3-UPD3-00")
10 
11  #Folders:
12  def _prefix(prevFlags):
13  if prevFlags.LArCalib.isSC:
14  return "/LAR/ElecCalibOflSC/"
15  else:
16  return "/LAR/ElecCalibOfl/"
17 
18  flags.addFlag("LArCalib.Pedestal.Folder", lambda prevFlags: _prefix(prevFlags)+"Pedestals/Pedestal")
19  flags.addFlag("LArCalib.AutoCorr.Folder", lambda prevFlags: _prefix(prevFlags)+"AutoCorrs/AutoCorr")
20  flags.addFlag("LArCalib.PhysAutoCorr.Folder", lambda prevFlags: _prefix(prevFlags)+"AutoCorrs/PhysicsAutoCorr")
21  flags.addFlag("LArCalib.CaliWave.Folder", lambda prevFlags: _prefix(prevFlags)+"CaliWaves/CaliWave")
22  flags.addFlag("LArCalib.OFCCali.Folder", lambda prevFlags: _prefix(prevFlags)+"OFC/CaliWave")
23  flags.addFlag("LArCalib.PhysWave.Folder", lambda prevFlags: _prefix(prevFlags)+"PhysWaves/RTM")
24  flags.addFlag("LArCalib.Ramp.Folder", lambda prevFlags: _prefix(prevFlags)+"Ramps/RampLinea")
25  flags.addFlag("LArCalib.OFCPhys.Folder", lambda prevFlags: _prefix(prevFlags)+"OFC/PhysWave/RTM/")
26  flags.addFlag("LArCalib.Shape.Folder", lambda prevFlags: _prefix(prevFlags)+"Shape/RTM/")
27  flags.addFlag("LArCalib.MphysOverMcal.Folder", lambda prevFlags: _prefix(prevFlags)+"MphysOverMcal/RTM")
28  flags.addFlag("LArCalib.PhysCaliTdiff.Folder",lambda prevFlags: _prefix(prevFlags)+"PhysCaliTdiff")
29  flags.addFlag("LArCalib.CaliPulseParams.Folder", lambda prevFlags: _prefix(prevFlags)+"CaliPulseParams/RTM")
30  flags.addFlag("LArCalib.DetCellParams.Folder", lambda prevFlags: _prefix(prevFlags)+"DetCellParams/RTM")
31 
32  flags.addFlag("LArCalib.FCALPhysWave.Folder", "/LAR/ElecCalibOfl/PhysWaves/FCALFromTB")
33 
34  flags.addFlag("LArCalib.GroupingType",lambda prevFlags: "SuperCells" if prevFlags.LArCalib.isSC else "ExtendedSubDetector")
35  flags.addFlag("LArCalib.Output.POOLFile","ouput.pool.root")
36  flags.addFlag("LArCalib.Output.ROOTFile","")
37  flags.addFlag("LArCalib.Output.POOLFile2","ouput2.pool.root")
38  flags.addFlag("LArCalib.Output.ROOTFile2","")
39  flags.addFlag("LArCalib.Output.SaveAverages",True)
40 
41  flags.addFlag("LArCalib.Gain",0)
42 
43  flags.addFlag("LArCalib.doValidation",True)
44 
45  flags.addFlag("LArCalib.CorrectBadChannels",True)
46 
47  #Flags to find the input files/databases
48  flags.addFlag("LArCalib.Input.Dir",".")
49  flags.addFlag("LArCalib.Input.RunNumbers",[])
50  flags.addFlag("LArCalib.Input.Type","calibration_LArElec-Pedestal")
51  flags.addFlag("LArCalib.Input.Files",_getInputFiles)
52  flags.addFlag("LArCalib.Input.SubDet","") #EM, HEC or FCAL
53  flags.addFlag("LArCalib.Input.isRawData",False)
54  flags.addFlag("LArCalib.Input.paramsFile","parameters.dat")
55 
56  flags.addFlag("LArCalib.Input.Database","LAR_OFL") #In practice, a sqlite file
57  flags.addFlag("LArCalib.Input.Database2","LAR_OFL") #In practice, a sqlite file, sometimes we need 2 of them
58 
59  flags.addFlag("LArCalib.Input.ChannelSelection","") #Read only a subset of COOL channels. Format like '3,4,5:10'
60 
61  flags.addFlag("LArCalib.IOVStart", lambda pF: min(pF.LArCalib.Input.RunNumbers) if len(pF.LArCalib.Input.RunNumbers)>0 else 0) #Output IOV start (runnumber)
62  flags.addFlag("LArCalib.IOVEnd", 0x7FFFFFFF) #Output IOV end (runnumber)
63 
64 
65 
66  flags.addFlag("LArCalib.Preselection.Side",[])
67  flags.addFlag("LArCalib.Preselection.BEC",[])
68  flags.addFlag("LArCalib.Preselection.FT",[])
69  flags.addFlag("LArCalib.Preselection.Slot",[])
70 
71  flags.addFlag("LArCalib.SCIgnoreBarrelChannels",False)
72  flags.addFlag("LArCalib.SCIgnoreEndcapChannels",False)
73 
74  flags.addFlag("LArCalib.RTM.ExtractAll",True) # False = extract only tauR
75  flags.addFlag("LArCalib.RTM.DumpOmegaScan",False)
76  flags.addFlag("LArCalib.RTM.DumpResOscill",False)
77 
78 
79 
80  flags.addFlag("LArCalib.OFC.Ncoll",0)
81  flags.addFlag("LArCalib.OFC.UsePhysCalibTDiff",True)
82  flags.addFlag("LArCalib.OFC.Normalize",True)
83  flags.addFlag("LArCalib.OFC.useDelta",False)
84  flags.addFlag("LArCalib.OFC.Nsamples",4)
85  flags.addFlag("LArCalib.OFC.ShapeCorrection",False)
86 
87  flags.addFlag("LArCalib.PhysACuseHG",False)
88 

◆ LArCalibFolderTag()

def python.LArCalibConfigFlags.LArCalibFolderTag (   folder,
  tag 
)

Definition at line 98 of file LArCalibConfigFlags.py.

98 def LArCalibFolderTag(folder,tag):
99  return ''.join(folder.split('/')) + tag
python.LArCalibConfigFlags._getInputFiles
def _getInputFiles(prevFlags)
Definition: LArCalibConfigFlags.py:89
python.GetInputFiles.GetInputFiles
def GetInputFiles(inputPath, filePattern)
Definition: GetInputFiles.py:5
min
#define min(a, b)
Definition: cfImp.cxx:40
python.LArCalibConfigFlags.LArCalibFolderTag
def LArCalibFolderTag(folder, tag)
Definition: LArCalibConfigFlags.py:98
TCS::join
std::string join(const std::vector< std::string > &v, const char c=',')
Definition: Trigger/TrigT1/L1Topo/L1TopoCommon/Root/StringUtils.cxx:10
python.LArCalibConfigFlags.addLArCalibFlags
def addLArCalibFlags(flags, isSC=False)
Definition: LArCalibConfigFlags.py:3