Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Łukasz Nowak
erp5
Commits
d52ff480
Commit
d52ff480
authored
Dec 05, 2011
by
Arnaud Fontaine
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow to ignore benchmark result columns.
parent
286d955f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
erp5/util/benchmark/report.py
erp5/util/benchmark/report.py
+14
-0
No files found.
erp5/util/benchmark/report.py
View file @
d52ff480
...
@@ -61,6 +61,11 @@ def parseArguments():
...
@@ -61,6 +61,11 @@ def parseArguments():
default
=
False
,
default
=
False
,
help
=
'Merge identical labels (default: False)'
)
help
=
'Merge identical labels (default: False)'
)
parser
.
add_argument
(
'--ignore-labels-regex'
,
dest
=
'ignore_label_re'
,
type
=
re
.
compile
,
help
=
'Ignore labels with the specified regex'
)
parser
.
add_argument
(
'report_directory'
,
parser
.
add_argument
(
'report_directory'
,
help
=
'Reports directory'
)
help
=
'Reports directory'
)
...
@@ -75,6 +80,7 @@ from .result import BenchmarkResultStatistic
...
@@ -75,6 +80,7 @@ from .result import BenchmarkResultStatistic
def
computeStatisticFromFilenameList
(
argument_namespace
,
filename_list
):
def
computeStatisticFromFilenameList
(
argument_namespace
,
filename_list
):
reader_list
=
[]
reader_list
=
[]
ignore_result_set
=
set
()
stat_list
=
[]
stat_list
=
[]
use_case_suite_dict
=
collections
.
OrderedDict
()
use_case_suite_dict
=
collections
.
OrderedDict
()
row_use_case_mapping_dict
=
{}
row_use_case_mapping_dict
=
{}
...
@@ -93,6 +99,11 @@ def computeStatisticFromFilenameList(argument_namespace, filename_list):
...
@@ -93,6 +99,11 @@ def computeStatisticFromFilenameList(argument_namespace, filename_list):
label_list
=
row_list
label_list
=
row_list
label_merged_index
=
0
label_merged_index
=
0
for
index
,
label
in
enumerate
(
label_list
):
for
index
,
label
in
enumerate
(
label_list
):
if
(
argument_namespace
.
ignore_label_re
and
argument_namespace
.
ignore_label_re
.
match
(
label
)):
ignore_result_set
.
add
(
index
)
continue
try
:
try
:
suite_name
,
result_name
=
label
.
split
(
': '
,
1
)
suite_name
,
result_name
=
label
.
split
(
': '
,
1
)
except
ValueError
:
except
ValueError
:
...
@@ -121,6 +132,9 @@ def computeStatisticFromFilenameList(argument_namespace, filename_list):
...
@@ -121,6 +132,9 @@ def computeStatisticFromFilenameList(argument_namespace, filename_list):
for
row_list
in
reader
:
for
row_list
in
reader
:
row_iter
=
iter
(
enumerate
(
row_list
))
row_iter
=
iter
(
enumerate
(
row_list
))
for
idx
,
row
in
row_iter
:
for
idx
,
row
in
row_iter
:
if
idx
in
ignore_result_set
:
continue
use_case_suite
=
row_use_case_mapping_dict
.
get
(
idx
,
None
)
use_case_suite
=
row_use_case_mapping_dict
.
get
(
idx
,
None
)
if
use_case_suite
:
if
use_case_suite
:
try
:
try
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment