File indexing completed on 2024-11-25 02:29:03
0001
0002
0003
0004
0005
0006 class PlotData:
0007 """ Hold information about XYZ
0008 """
0009
0010 def __init__(self, mode):
0011 self.numberOfBins = [0, 0, 0]
0012 self.maxShift = [0, 0, 0]
0013 self.minShift = [0, 0, 0]
0014 self.maxBinShift = [0, 0, 0]
0015
0016 self.binShift = [0, 0, 0]
0017 self.hiddenEntries = [0, 0, 0]
0018 self.binPosition = [1, 1, 1]
0019 self.usedRange = [0, 0, 0]
0020 self.histo = []
0021 self.histoAxis = []
0022
0023 self.title = 0
0024 self.text = 0
0025 self.label = ""
0026 self.objid = 0
0027
0028 if (mode == "xyz"):
0029 self.xyz = {0: "X", 1: "Y", 2: "Z"}
0030 self.data = [0, 1, 2]
0031 self.unit = "#mum"
0032 if (mode == "rot"):
0033 self.xyz = {0: "#alpha", 1: "#beta", 2: "#gamma"}
0034 self.data = [3, 4, 5]
0035 self.unit = "mrad"
0036 if (mode == "dist"):
0037 self.xyz = {0: "A", 1: "B", 2: "C"}
0038 self.data = [6, 7, 8]
0039 self.unit = ""
0040
0041
0042 class PedeDumpData:
0043 """ information out of the pede.dump.gz file
0044 """
0045
0046 def __init__(self):
0047 self.sumValue = 0
0048 self.sumWValue = 0
0049 self.sumSteps = ""
0050 self.correction = 0
0051 self.memory = 0
0052 self.time = []
0053 self.warning = []
0054
0055 self.nrec = 0
0056
0057 self.ntgb = 0
0058
0059 self.nvgb = 0
0060
0061 def printLog(self):
0062 if (self.sumValue != 0):
0063 print("Sum(Chi^2)/Sum(Ndf) = {0} = {1}".format(self.sumSteps, self.sumValue))
0064 else:
0065 print("Sum(W*Chi^2)/Sum(Ndf)/<W> = {0} = {1}".format(self.sumSteps, self.sumWValue))
0066 print("with correction for down-weighting: {0}".format(self.correction))
0067 print("Peak dynamic memory allocation: {0} GB".format(self.memory))
0068 print("Total time: {0} h {1} m {2} s".format(self.time[0], self.time[1], self.time[2]))
0069 print("Number of records: {0}".format(self.nrec))
0070 print("Total number of parameters: {0}".format(self.ntgb))
0071 print("Number of variable parameters: {0}".format(self.nvgb))
0072 print("Warning:")
0073 for line in self.warning:
0074 print(line)
0075
0076
0077 class MonitorData:
0078 """ information out of the monitor root files
0079 """
0080 monitors = []
0081
0082 def __init__(self, name, ntracks, weight = None):
0083 self.name = name
0084 self.ntracks = ntracks
0085 self.weight = weight
0086 self.monitors.append(self)
0087
0088
0089 class OutputData:
0090 """ stores the information about the data which should be part of the Output
0091 """
0092
0093 def __init__(self, plottype="", name="", number="", parameter="", filename=""):
0094 self.plottype = plottype
0095 self.name = name
0096 self.number = number
0097 self.parameter = parameter
0098 self.filename = filename