14 filenamein = sys.argv[1]
18 file = TFile(filenamein)
19 detectortuple = file.Get(
"Detector_Artuple")
21 entries = detectortuple.GetEntries()
25 for i
in range(entries):
26 detectortuple.GetEntry(i)
27 if abs(detectortuple.det) == 2:
31 infoprev.res = detectortuple.res
32 infoprev.tres = detectortuple.tres
33 infoprev.resmean = detectortuple.resMean
34 infoprev.tresmean = detectortuple.tresMean
35 infoprev.hits = detectortuple.nhits
36 det = detectortuple.det
38 print (
"For detector part %d res = %s\n" %(det,infoprev.res))
39 print (
"For detector part %d tres = %s\n" %(det,infoprev.tres))
40 print (
"For detector part %d resmean = %s\n" %(det,infoprev.resmean))
41 print (
"For detector part %d tresmean = %s\n" %(det,infoprev.tresmean))
42 info[detectortuple.det, detectortuple.lay ] = infoprev
44 detectortuple = file.Get(
"Detectortuple")
45 entries = detectortuple.GetEntries()
48 for i
in range(entries):
49 detectortuple.GetEntry(i)
50 if abs(detectortuple.det) == 1:
54 infoprev.res = detectortuple.res
55 infoprev.tres = detectortuple.tres
56 infoprev.resmean = detectortuple.resMean
57 infoprev.tresmean = detectortuple.tresMean
58 infoprev.hits = detectortuple.nhits
59 det = detectortuple.det
61 print (
"For detector part %d res = %s\n" %(det,infoprev.res))
62 print (
"For detector part %d tres = %s\n" %(det,infoprev.tres))
63 print (
"For detector part %d resmean = %s\n" %(det,infoprev.resmean))
64 print (
"For detector part %d tresmean = %s\n" %(det,infoprev.tresmean))
65 info[detectortuple.det, detectortuple.lay ] = infoprev
67 print(
"Extracted data\n")