Belle II Software  release-08-01-10
MillepedeCalibration Class Reference

Public Member Functions

def __init__ (self, components=None, tracks=None, particles=None, vertices=None, primary_vertices=None, path=None)
 
def set_components (self, components)
 
def set_command (self, cmd_name, command='')
 
def pre_algo (self, algorithm, iteration)
 
def create (self, name, input_files)
 
def get_param (self, param, module=None)
 
def set_param (self, value, param, module=None)
 
def get_module (self, module=None)
 
def __getstate__ (self)
 
def __setstate__ (self, state)
 
def fixGlobalParam (self, uid, element, param, value=0.)
 
def fixCDCLayerX (self, layer)
 
def fixCDCLayerY (self, layer)
 
def fixCDCLayerRot (self, layer)
 
def fixCDCTimeWalk (self, board_id)
 
def fixCDCTimeZero (self, wire_id)
 
def fixVXDid (self, layer, ladder, sensor, segment=0, parameters=[1, 2, 3, 4, 5, 6])
 
def fixPXDYing (self, parameters=UVWABC)
 
def fixPXDYang (self, parameters=UVWABC)
 
def fixSVDPat (self, parameters=UVWABC)
 
def fixSVDMat (self, parameters=UVWABC)
 
def fixEKLMSector (self, endcap, layer, sector, parameters=[1, 2, 6])
 
def fixEKLMSegment (self, endcap, layer, sector, plane, segment, parameters=[1, 2, 6])
 
def fixBKLMModule (self, sector, layer, forward, parameters=UVWABC)
 
def fixBKLM (self, sectors=range(1, 9), layers=range(1, 16), forbackwards=[0, 1])
 

Public Attributes

 algo
 the algorithm
 
 path
 pre-collector path
 
 collector
 the collector module
 
 parameters
 Parameter config at algo level (fixing)
 
 commands
 Commands for pede steering.
 
 components
 db objects for calibration
 

Detailed Description

 The generic Millepede calibration collector+algorithm 

Definition at line 49 of file __init__.py.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
  components = None,
  tracks = None,
  particles = None,
  vertices = None,
  primary_vertices = None,
  path = None 
)
components are the names of DB objects to calibrate (BeamSpot etc.)
tracks are collections of RecoTracks of fitted charged tracks (usually cosmic rays, no associated particle)
particles are names of ParticleLists with single charged particles
vertices are names ParticleLists with at least two body decays fitted with vertex constraint
primary_vertices are names of ParticleLists with at least two body decays fitted with beam+vertex constraint

Definition at line 52 of file __init__.py.

58  path=None):
59  """
60  components are the names of DB objects to calibrate (BeamSpot etc.)
61  tracks are collections of RecoTracks of fitted charged tracks (usually cosmic rays, no associated particle)
62  particles are names of ParticleLists with single charged particles
63  vertices are names ParticleLists with at least two body decays fitted with vertex constraint
64  primary_vertices are names of ParticleLists with at least two body decays fitted with beam+vertex constraint
65  """
66 
67  if components is None:
68  components = []
69 
70  # By default, at least the raw RecoTracks are fitted (let's specify its name explicitly here)
71  if (tracks is None) and (particles is None) and (vertices is None) and (primary_vertices is None):
72  tracks = ['RecoTracks']
73 
74  if particles is None:
75  particles = []
76 
77  if vertices is None:
78  vertices = []
79 
80  if primary_vertices is None:
81  primary_vertices = []
82 
83  if path is None:
84  path = b2.create_path()
85  path.add_module('Gearbox')
86  path.add_module('Geometry')
87  path.add_module('SetupGenfitExtrapolation', noiseBetheBloch=False, noiseCoulomb=False, noiseBrems=False)
88 
89 
90  self.algo = Belle2.MillepedeAlgorithm()
91 
92  self.path = path
93 
94  self.collector = b2.register_module('MillepedeCollector')
95 
96  self.parameters = OrderedDict()
97 
98  self.commands = OrderedDict()
99 
100  self.set_components(components)
101 
102  self.collector.param('tracks', tracks)
103  self.collector.param('particles', particles)
104  self.collector.param('vertices', vertices)
105  self.collector.param('primaryVertices', primary_vertices)
106  self.collector.param('minPValue', 0.)
107  self.collector.param('useGblTree', True)
108 
109  self.set_command('method diagonalization 3 0.1')
110  self.set_command('skipemptycons')
111  self.set_command('entries 10')
112  self.set_command('hugecut 50')
113  self.set_command('chiscut 30. 6.')
114  self.set_command('outlierdownweighting 3')
115  self.set_command('dwfractioncut 0.1')
116 
Class implementing Millepede calibration algorithm.

Member Function Documentation

◆ __getstate__()

def __getstate__ (   self)
 serialization 

Definition at line 204 of file __init__.py.

◆ __setstate__()

def __setstate__ (   self,
  state 
)
 de-serialization 

Definition at line 212 of file __init__.py.

◆ create()

def create (   self,
  name,
  input_files 
)
 Create the CAF Calibration object 

Definition at line 149 of file __init__.py.

◆ fixBKLM()

def fixBKLM (   self,
  sectors = range(1, 9),
  layers = range(1, 16),
  forbackwards = [0, 1] 
)
 Fix (all by default) BKLM modules 

Definition at line 308 of file __init__.py.

◆ fixBKLMModule()

def fixBKLMModule (   self,
  sector,
  layer,
  forward,
  parameters = UVWABC 
)
 Fix a BKLM module 

Definition at line 297 of file __init__.py.

◆ fixCDCLayerRot()

def fixCDCLayerRot (   self,
  layer 
)
 fix CDC layer Phi rotation 

Definition at line 236 of file __init__.py.

◆ fixCDCLayerX()

def fixCDCLayerX (   self,
  layer 
)
 fix CDC layer X-shift 

Definition at line 228 of file __init__.py.

◆ fixCDCLayerY()

def fixCDCLayerY (   self,
  layer 
)
 fix CDC layer Y-shift 

Definition at line 232 of file __init__.py.

◆ fixCDCTimeWalk()

def fixCDCTimeWalk (   self,
  board_id 
)
 fix CDC time walk parameter for given board 

Definition at line 240 of file __init__.py.

◆ fixCDCTimeZero()

def fixCDCTimeZero (   self,
  wire_id 
)
 fix CDC tie zero parameter for given wire 

Definition at line 244 of file __init__.py.

◆ fixEKLMSector()

def fixEKLMSector (   self,
  endcap,
  layer,
  sector,
  parameters = [1, 2, 6] 
)
 Fix EKLM sector parameters 

Definition at line 280 of file __init__.py.

◆ fixEKLMSegment()

def fixEKLMSegment (   self,
  endcap,
  layer,
  sector,
  plane,
  segment,
  parameters = [1, 2, 6] 
)
 Fix EKLM segment parameters 

Definition at line 288 of file __init__.py.

◆ fixGlobalParam()

def fixGlobalParam (   self,
  uid,
  element,
  param,
  value = 0. 
)
 Generic fcn to manipulate (fix to given value) parameters identified by db object id (uid),
    element and parameter number 

Definition at line 219 of file __init__.py.

◆ fixPXDYang()

def fixPXDYang (   self,
  parameters = UVWABC 
)
 fix PXD Yang half-shell 

Definition at line 266 of file __init__.py.

◆ fixPXDYing()

def fixPXDYing (   self,
  parameters = UVWABC 
)
 fix PXD Ying half-shell 

Definition at line 262 of file __init__.py.

◆ fixSVDMat()

def fixSVDMat (   self,
  parameters = UVWABC 
)
 fix SVD Mat half-shell 

Definition at line 274 of file __init__.py.

◆ fixSVDPat()

def fixSVDPat (   self,
  parameters = UVWABC 
)
 fix SVD Pat half-shell 

Definition at line 270 of file __init__.py.

◆ fixVXDid()

def fixVXDid (   self,
  layer,
  ladder,
  sensor,
  segment = 0,
  parameters = [1, 2, 3, 4, 5, 6] 
)
 Fix VXD element parameters by layer,ladder,sensor and segment number 

Definition at line 250 of file __init__.py.

◆ get_module()

def get_module (   self,
  module = None 
)
 Get collector module or any other module from path (given its name) 

Definition at line 191 of file __init__.py.

◆ get_param()

def get_param (   self,
  param,
  module = None 
)
 Get parameter of the collector module or any module in path (given its name) 

Definition at line 177 of file __init__.py.

◆ pre_algo()

def pre_algo (   self,
  algorithm,
  iteration 
)
 Fcn to execute before algorithm... 

Definition at line 145 of file __init__.py.

◆ set_command()

def set_command (   self,
  cmd_name,
  command = '' 
)
 Set command for Millepede steering 

Definition at line 131 of file __init__.py.

◆ set_components()

def set_components (   self,
  components 
)
 Select db objects for calibration from list of their names 

Definition at line 117 of file __init__.py.

◆ set_param()

def set_param (   self,
  value,
  param,
  module = None 
)
 Set parameter of the collector module or any module in path (given its name) 

Definition at line 185 of file __init__.py.


The documentation for this class was generated from the following file: