def configureEarlyDataAlignment(fixQOverPBias=True): TAlignment().WriteCondSubDetList += ['Velo', 'TT', 'IT', 'OT', 'Muon'] # define the alignment elements elements = Alignables() elements.Velo("None") elements.VeloRight("Tx") elements.VeloLeft("Tx") elements.IT("None") elements.ITBoxes("TxTzRz") elements.ITLayers("TxTz") elements.OT("None") elements.OTCFrames("Tx") elements.OTCFrameLayers("Tz") elements.TT("None") elements.TTLayers("None") elements.TTModules("TxRz") elements.Tracker("None") TAlignment().ElementsToAlign = list(elements) # make sure that the velo stays where it was TAlignment().Constraints = constraints = [] constraints.append("VeloHalfAverage : Velo/Velo(Left|Right) : Tx ") # fix the q/p scale by not moving T in X. note that you do not # want to do this if you use D0 in the alignment if fixQOverPBias: constraints.append("OT3X : OT/T3X1U.Side : Tx") # tweak the survey a little bit to fix the z-scale to survey surveyconstraints = SurveyConstraints() surveyconstraints.All() # make sure we fix the z-scale surveyconstraints.XmlUncertainties += [ "OT/T3X1U : 0.5 0.5 0.00001 0.0001 0.0001 0.0001" ]
def configureTrackerAlignment(fixQOverPBias=False, surveyVer='latest'): TAlignment().WriteCondSubDetList += ['TT', 'IT', 'OT'] # define the alignment elements elements = Alignables() elements.Velo("None") elements.VeloRight("None") elements.VeloLeft("None") elements.IT("None") elements.ITBoxes("TxTzRz") elements.ITLayers("None") elements.OT("None") elements.OTCFrames("TxRz") elements.OTCFrameLayers("Tz") elements.OTModules("TxRz") elements.TT("None") elements.TTLayers("Tz") elements.TTModules("TxRz") elements.Tracker("None") TAlignment().ElementsToAlign = list(elements) # make sure that the velo stays where it was constraints = [] # fix the q/p scale by not moving T in X. note that you do not # want to do this if you use D0 in the alignment if fixQOverPBias: constraints.append("OT3X : OT/T3X1U.Side : Tx") TAlignment().Constraints = constraints if surveyVer == None: return # tweak the survey a little bit to fix the z-scale to survey surveyconstraints = SurveyConstraints() surveyconstraints.All(surveyVer) # make sure we fix the z-scale surveyconstraints.XmlUncertainties += [ "OT/T3X1U : 0.5 0.5 0.00001 0.0001 0.0001 0.0001" ]
elements = Alignables() elements.Velo("None") #elements.VeloRight("TxTyTzRxRy") #elements.VeloLeft("TxTyTzRxRy") elements.VeloLeft("None") elements.VeloRight("None") #elements.VeloModules("TxTyTzRz") #elements.VeloPhiSensors("TxTy") #elements.VeloRSensors("None") #elements.VeloRSensors("None") #elements.VeloPhiSensors("None") elements.VeloModules("None") elements.IT("None") elements.ITBoxes("TxTyTzRxRyRz") elements.ITLayers("TxTz") elements.ITLadders("TxRz") #elements.ITBoxes("Tx") elements.OT("None") elements.OTCFrames("Tx") elements.OTCFrameLayers("Tz") elements.OTModules("TxRz") elements.TT("None") elements.TTLayers("None") #elements.TTBoxes("Ry") #elements.TTHalfLayers("Tx") #elements.TTHalfModules("TxRz") elements.TTModules("TxRz")