Skip to content

Commit e7e5f54

Browse files
darxriggsfabienrenaud
authored andcommitted
Stick to Python naming conventions
1 parent e619766 commit e7e5f54

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

output/toCsv.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import 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):
4040
sheets = {}
4141
for 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'])

0 commit comments

Comments
 (0)