ATLAS Offline Software
Loading...
Searching...
No Matches
python.LArCalib_HVCorrConfig Namespace Reference

Functions

 HVCorrConfig (flags, outputName="hvcorr", runOut=0, lbOut=0, voltages=[], currents=[])

Variables

 parser = argparse.ArgumentParser(description="Recalculate HV corrections based on DCS values")
 help
 type
 int
 nargs
 default
 str
 action
 args = parser.parse_args()
 ts = strptime(args.datestamp+'/UTC','%Y-%m-%d:%H:%M:%S/%Z')
 TimeStamp = int(timegm(ts))
int TimeStamp_ns = TimeStamp*1000000000
 rlb = TimeStampToRunLumi(TimeStamp_ns)
 timediff = int(time()-TimeStamp)
 days
 remainder
 hours
 seconds
 voltage
 current
 outputName = args.output
 ConfigFlags = initConfigFlags()
 GlobalTag
 RunNumbers
 LumiBlockNumbers
 TimeStamps
 Files
 DatabaseInstance
 DBConnection
 AtlasVersion
 OutputLevel
 cfg = MainEvgenServicesCfg(ConfigFlags)
 FirstLB

Function Documentation

◆ HVCorrConfig()

python.LArCalib_HVCorrConfig.HVCorrConfig ( flags,
outputName = "hvcorr",
runOut = 0,
lbOut = 0,
voltages = [],
currents = [] )

Definition at line 8 of file LArCalib_HVCorrConfig.py.

8def HVCorrConfig(flags,outputName="hvcorr",runOut=0, lbOut=0, voltages=[], currents=[]):
9
10 from LArGeoAlgsNV.LArGMConfig import LArGMCfg
11 result=LArGMCfg(flags)
12
13 #Use the standard LArHVScaleCfg and adjust properties afterwards as needed
14 from LArCalibUtils.LArHVScaleConfig import LArHVScaleCfg
15
16 result.merge(LArHVScaleCfg(flags))
17 alg = result.getCondAlgo("LArHVCondAlg")
18 alg.UndoOnlineHVCorr=False
19 alg.keyOutputCorr="NewLArHVScaleCorr"
20 alg.fixCurrent = currents
21 alg.fixHV = voltages
22
23 from LArCabling.LArCablingConfig import LArOnOffIdMappingSCCfg
24 result.merge(LArOnOffIdMappingSCCfg(flags))
25 result.addEventAlgo(CompFactory.LArHVCorrToSCHVCorr(ContainerKey="NewLArHVScaleCorr",OutputKey="NewSCLArHVScaleCorr",
26 OutputFolder="/LAR/ElecCalibFlatSC/HVScaleCorrNew",
27 IsHeavyIons=False, PatchInHeavyIons=1.0,
28 PhysicsWeights="TrigT1CaloCalibUtils/HVcorrPhysicsWeights.txt"))
29
30 #The LArHVCorrMaker creates a flat blob in a CondAttrListCollection
31 #Input: The HV Scale Correction computed by the LArHVCondAlg based on the DCS HV values
32 result.addEventAlgo(CompFactory.LArHVCorrMaker(LArHVScaleCorr="NewLArHVScaleCorr",folderName="/LAR/ElecCalibFlat/HVScaleCorrNew"))
33
36
37 #Ntuple writing ...
38 from LArCalibTools.LArCalib_HVScale2NtupleConfig import LArHVScaleCorr2NtupleCfg
39 result.merge(LArHVScaleCorr2NtupleCfg(flags,rootfile=outputName+'_ntuple.root',addSC=True))
40 result.getEventAlgo("LArHVScaleCorr2Ntuple").ContainerKey="NewLArHVScaleCorr"
41 result.getEventAlgo("LArSCHVScaleCorr2Ntuple").ContainerKey="NewSCLArHVScaleCorr"
42 result.getEventAlgo("LArSCHVScaleCorr2Ntuple").NtuplePath="/NTUPLES/FILE1/HVSCALESC"
43
44 #sqlite writing ...
45 from RegistrationServices.OutputConditionsAlgConfig import OutputConditionsAlgCfg
46 result.merge(OutputConditionsAlgCfg(flags,
47 outputFile="dummy.root",
48 ObjectList=["CondAttrListCollection#/LAR/ElecCalibFlat/HVScaleCorrNew#/LAR/ElecCalibFlat/HVScaleCorr",
49 "CondAttrListCollection#/LAR/ElecCalibFlatSC/HVScaleCorrNew#/LAR/ElecCalibFlatSC/HVScaleCorr",],
50 Run1=runOut,
51 LB1=lbOut
52 ))
53
54
55
56 #RegistrationSvc
57 result.addService(CompFactory.IOVRegistrationSvc(RecreateFolders = True,
58 SVFolder=True,
59 OverrideNames = ["HVScaleCorr"],
60 OverrideTypes = ["Blob16M"],
61 ))
62
63 result.getService("IOVDbSvc").DBInstance=""
64 return result
65
66

Variable Documentation

◆ action

python.LArCalib_HVCorrConfig.action

Definition at line 81 of file LArCalib_HVCorrConfig.py.

◆ args

python.LArCalib_HVCorrConfig.args = parser.parse_args()

Definition at line 85 of file LArCalib_HVCorrConfig.py.

◆ AtlasVersion

python.LArCalib_HVCorrConfig.AtlasVersion

Definition at line 135 of file LArCalib_HVCorrConfig.py.

◆ cfg

python.LArCalib_HVCorrConfig.cfg = MainEvgenServicesCfg(ConfigFlags)

Definition at line 138 of file LArCalib_HVCorrConfig.py.

◆ ConfigFlags

python.LArCalib_HVCorrConfig.ConfigFlags = initConfigFlags()

Definition at line 124 of file LArCalib_HVCorrConfig.py.

◆ current

python.LArCalib_HVCorrConfig.current

Definition at line 115 of file LArCalib_HVCorrConfig.py.

◆ DatabaseInstance

python.LArCalib_HVCorrConfig.DatabaseInstance

Definition at line 133 of file LArCalib_HVCorrConfig.py.

◆ days

python.LArCalib_HVCorrConfig.days

Definition at line 108 of file LArCalib_HVCorrConfig.py.

◆ DBConnection

python.LArCalib_HVCorrConfig.DBConnection

Definition at line 134 of file LArCalib_HVCorrConfig.py.

◆ default

python.LArCalib_HVCorrConfig.default

Definition at line 76 of file LArCalib_HVCorrConfig.py.

◆ Files

python.LArCalib_HVCorrConfig.Files

Definition at line 132 of file LArCalib_HVCorrConfig.py.

◆ FirstLB

python.LArCalib_HVCorrConfig.FirstLB

Definition at line 140 of file LArCalib_HVCorrConfig.py.

◆ GlobalTag

python.LArCalib_HVCorrConfig.GlobalTag

Definition at line 127 of file LArCalib_HVCorrConfig.py.

◆ help

python.LArCalib_HVCorrConfig.help

Definition at line 75 of file LArCalib_HVCorrConfig.py.

◆ hours

python.LArCalib_HVCorrConfig.hours

Definition at line 109 of file LArCalib_HVCorrConfig.py.

◆ int

python.LArCalib_HVCorrConfig.int

Definition at line 76 of file LArCalib_HVCorrConfig.py.

◆ LumiBlockNumbers

python.LArCalib_HVCorrConfig.LumiBlockNumbers

Definition at line 130 of file LArCalib_HVCorrConfig.py.

◆ nargs

python.LArCalib_HVCorrConfig.nargs

Definition at line 76 of file LArCalib_HVCorrConfig.py.

◆ OutputLevel

python.LArCalib_HVCorrConfig.OutputLevel

Definition at line 136 of file LArCalib_HVCorrConfig.py.

◆ outputName

python.LArCalib_HVCorrConfig.outputName = args.output

Definition at line 120 of file LArCalib_HVCorrConfig.py.

◆ parser

python.LArCalib_HVCorrConfig.parser = argparse.ArgumentParser(description="Recalculate HV corrections based on DCS values")

Definition at line 74 of file LArCalib_HVCorrConfig.py.

◆ remainder

python.LArCalib_HVCorrConfig.remainder

Definition at line 108 of file LArCalib_HVCorrConfig.py.

◆ rlb

list python.LArCalib_HVCorrConfig.rlb = TimeStampToRunLumi(TimeStamp_ns)

Definition at line 97 of file LArCalib_HVCorrConfig.py.

◆ RunNumbers

python.LArCalib_HVCorrConfig.RunNumbers

Definition at line 129 of file LArCalib_HVCorrConfig.py.

◆ seconds

python.LArCalib_HVCorrConfig.seconds

Definition at line 109 of file LArCalib_HVCorrConfig.py.

◆ str

python.LArCalib_HVCorrConfig.str

Definition at line 78 of file LArCalib_HVCorrConfig.py.

◆ timediff

python.LArCalib_HVCorrConfig.timediff = int(time()-TimeStamp)

Definition at line 104 of file LArCalib_HVCorrConfig.py.

◆ TimeStamp

python.LArCalib_HVCorrConfig.TimeStamp = int(timegm(ts))

Definition at line 88 of file LArCalib_HVCorrConfig.py.

◆ TimeStamp_ns

int python.LArCalib_HVCorrConfig.TimeStamp_ns = TimeStamp*1000000000

Definition at line 89 of file LArCalib_HVCorrConfig.py.

◆ TimeStamps

python.LArCalib_HVCorrConfig.TimeStamps

Definition at line 131 of file LArCalib_HVCorrConfig.py.

◆ ts

python.LArCalib_HVCorrConfig.ts = strptime(args.datestamp+'/UTC','%Y-%m-%d:%H:%M:%S/%Z')

Definition at line 87 of file LArCalib_HVCorrConfig.py.

◆ type

python.LArCalib_HVCorrConfig.type

Definition at line 76 of file LArCalib_HVCorrConfig.py.

◆ voltage

python.LArCalib_HVCorrConfig.voltage

Definition at line 114 of file LArCalib_HVCorrConfig.py.