File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 55import re
66
77
8- def parseFileInfo (f ):
8+ def parse_file_info (f ):
99 words = f .replace ('.txt' , '' ).split ('-' )
1010 return {
1111 'datatype' : words [0 ],
@@ -15,7 +15,7 @@ def parseFileInfo(f):
1515 }
1616
1717
18- def extractScores (f ):
18+ def extract_scores (f ):
1919 result = {}
2020 with open (f ) as fh :
2121 lines = fh .readlines ()
@@ -27,7 +27,7 @@ def extractScores(f):
2727 elif complete :
2828 if benchmark :
2929 values = re .split ('\s+' , l )
30- if ( len (values ) > 3 ) :
30+ if len (values ) > 3 :
3131 name = values [0 ].split ('.' )[- 1 ]
3232 score = values [3 ]
3333 result [name ] = score
@@ -40,8 +40,8 @@ def extractScores(f):
4040sheets = {}
4141for f in os .listdir (cwd ):
4242 if os .path .isfile (f ) and f .endswith ('.txt' ):
43- fileInfo = parseFileInfo (f )
44- scores = extractScores (f )
43+ fileInfo = parse_file_info (f )
44+ scores = extract_scores (f )
4545
4646 sheetName = "{}-{}-{}" .format (fileInfo ['datatype' ],
4747 fileInfo ['command' ], fileInfo ['number' ])
You can’t perform that action at this time.
0 commit comments