ATLAS Offline Software
Loading...
Searching...
No Matches
ParseActsStatDump Namespace Reference

Functions

 GetCustomAthArgs ()
 main (str fileName)

Variables

 MyArgs = GetCustomAthArgs()

Function Documentation

◆ GetCustomAthArgs()

ParseActsStatDump.GetCustomAthArgs ( )

Definition at line 4 of file ParseActsStatDump.py.

4def GetCustomAthArgs():
5 from argparse import ArgumentParser
6 parser = ArgumentParser(description='Parser for dumping ACTS statistics after reco')
7 parser.add_argument("--inputFile", help='Name of the input log file', required=True)
8 return parser.parse_args()
9

◆ main()

ParseActsStatDump.main ( str fileName)

Definition at line 10 of file ParseActsStatDump.py.

10def main(fileName: str):
11 assert isinstance(fileName ,str)
12
13 import re
14 with open(fileName, 'r') as inFile:
15 for line in inFile:
16 # Check stat report statement
17 match = re.findall(r'(Acts\S+\s+INFO.*statistics)', line)
18 if match:
19 print(match[0])
20
21 match = re.findall(r'(Acts\S+\s+INFO.*Ratios)', line)
22 if match:
23 print(match[0])
24
25 # print table
26 match = re.findall(r'\d{2}:\d{2}:\d{2}\s(\|[A-Za-z0-9. +/-]+\|[^a-df-z]+\|$)', line)
27 if match:
28 print(match[0])
29
void print(char *figname, TCanvas *c1)
int main()
Definition hello.cxx:18

Variable Documentation

◆ MyArgs

ParseActsStatDump.MyArgs = GetCustomAthArgs()

Definition at line 32 of file ParseActsStatDump.py.