ATLAS Offline Software
Functions | Variables
python.evaluateDiffRoot Namespace Reference

Functions

def getResults (infile, test_dict)
 
def getTests (infile, selected_test)
 
def reportOverview (test_dict)
 
def reportDiffs (test_dict)
 
def printDict (test_dict)
 

Variables

 parser
 
 usage
 
 type
 
 dest
 
 default
 
 help
 
 None
 
 action
 
 False
 
 options
 
 args
 
 debugmode
 
 infile_name
 
 selected_tests
 
 test_dict
 

Function Documentation

◆ getResults()

def python.evaluateDiffRoot.getResults (   infile,
  test_dict 
)

Definition at line 14 of file evaluateDiffRoot.py.

14 def getResults(infile, test_dict):
15  global debugmode
16  for test in test_dict.keys():
17  for ftype in ['ESD','AOD']:
18  linenr = 0
19  f = open(infile, 'r')
20  doRead = False
21  for line in f:
22  linenr += 1
23  if line.startswith('Py:diff-root INFO old:') and test in line and ftype in line:
24  doRead = True
25  if line.startswith('Py:Acmd'):
26  doRead = False
27  if doRead and ("leaves differ" in line or "WARNING" in line):
28  if line.split('\n')[0] not in test_dict[test][ftype]:
29  test_dict[test][ftype].append(line.split('\n')[0])
30 
31  if debugmode and doRead:
32  print ("DEBUG: %s: %s" %(linenr,line.split('\n')[0]))
33 
34  return test_dict
35 
36 """
37  create initial dict including all tests which have been probed
38 """

◆ getTests()

def python.evaluateDiffRoot.getTests (   infile,
  selected_test 
)

Definition at line 39 of file evaluateDiffRoot.py.

39 def getTests(infile, selected_test):
40  test_dict = {}
41  f = open(infile, 'r')
42  for line in f:
43  if "CHANGED" in line or "IDENTICAL" in line:
44  test = line.split()[0]
45  if selected_test and test not in selected_test:
46  continue
47  test_dict[test] = { 'ESD' : [],
48  'AOD' : [],
49  'status' : line.split()[1]}
50  f.close()
51  return test_dict
52 
53 
54 """
55  prints sorted summary of tests
56 """

◆ printDict()

def python.evaluateDiffRoot.printDict (   test_dict)

Definition at line 84 of file evaluateDiffRoot.py.

84 def printDict(test_dict):
85  print ("Overview:")
86  print ("==========")
87  reportOverview(test_dict)
88  print()
89  print()
90  print()
91  print ("Details")
92  print ("========")
93  reportDiffs(test_dict)
94 
95 
96 
97 
98 """
99  Main function here
100 """

◆ reportDiffs()

def python.evaluateDiffRoot.reportDiffs (   test_dict)

Definition at line 67 of file evaluateDiffRoot.py.

67 def reportDiffs(test_dict):
68  list_sorted = sorted(test_dict.keys())
69  for test in list_sorted:
70  if test_dict[test]['status'] == 'IDENTICAL':
71  continue
72  print (test, test_dict[test]['status'])
73  for item in ['ESD','AOD']:
74  print (item)
75  for line in test_dict[test][item]:
76  print (line)
77  print()
78  print()
79 
80 
81 """
82  print all
83 """

◆ reportOverview()

def python.evaluateDiffRoot.reportOverview (   test_dict)

Definition at line 57 of file evaluateDiffRoot.py.

57 def reportOverview(test_dict):
58  list_sorted = sorted(test_dict.keys())
59  for test in list_sorted:
60  #print ("%20s %s" %(test, test_dict[test]['status']))
61  print ('{0:50} {1:10}'.format(test, test_dict[test]['status']))
62 
63 
64 """
65  prints detailed diff on screen
66 """

Variable Documentation

◆ action

python.evaluateDiffRoot.action

Definition at line 106 of file evaluateDiffRoot.py.

◆ args

python.evaluateDiffRoot.args

Definition at line 107 of file evaluateDiffRoot.py.

◆ debugmode

python.evaluateDiffRoot.debugmode

Definition at line 109 of file evaluateDiffRoot.py.

◆ default

python.evaluateDiffRoot.default

Definition at line 103 of file evaluateDiffRoot.py.

◆ dest

python.evaluateDiffRoot.dest

Definition at line 103 of file evaluateDiffRoot.py.

◆ False

python.evaluateDiffRoot.False

Definition at line 106 of file evaluateDiffRoot.py.

◆ help

python.evaluateDiffRoot.help

Definition at line 103 of file evaluateDiffRoot.py.

◆ infile_name

python.evaluateDiffRoot.infile_name

Definition at line 111 of file evaluateDiffRoot.py.

◆ None

python.evaluateDiffRoot.None

Definition at line 104 of file evaluateDiffRoot.py.

◆ options

python.evaluateDiffRoot.options

Definition at line 107 of file evaluateDiffRoot.py.

◆ parser

python.evaluateDiffRoot.parser

Definition at line 102 of file evaluateDiffRoot.py.

◆ selected_tests

python.evaluateDiffRoot.selected_tests

Definition at line 113 of file evaluateDiffRoot.py.

◆ test_dict

python.evaluateDiffRoot.test_dict

Definition at line 118 of file evaluateDiffRoot.py.

◆ type

python.evaluateDiffRoot.type

Definition at line 103 of file evaluateDiffRoot.py.

◆ usage

python.evaluateDiffRoot.usage

Definition at line 102 of file evaluateDiffRoot.py.

python.evaluateDiffRoot.reportDiffs
def reportDiffs(test_dict)
Definition: evaluateDiffRoot.py:67
python.evaluateDiffRoot.getTests
def getTests(infile, selected_test)
Definition: evaluateDiffRoot.py:39
vtune_athena.format
format
Definition: vtune_athena.py:14
dumpHVPathFromNtuple.append
bool append
Definition: dumpHVPathFromNtuple.py:91
python.evaluateDiffRoot.getResults
def getResults(infile, test_dict)
Definition: evaluateDiffRoot.py:14
DerivationFramework::TriggerMatchingUtils::sorted
std::vector< typename T::value_type > sorted(T begin, T end)
Helper function to create a sorted vector from an unsorted one.
Trk::open
@ open
Definition: BinningType.h:40
python.evaluateDiffRoot.printDict
def printDict(test_dict)
Definition: evaluateDiffRoot.py:84
Muon::print
std::string print(const MuPatSegment &)
Definition: MuonTrackSteering.cxx:28
python.evaluateDiffRoot.reportOverview
def reportOverview(test_dict)
Definition: evaluateDiffRoot.py:57