Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
pybind11
Commits
fccb6d9d
Commit
fccb6d9d
authored
Feb 21, 2021
by
Ralf W. Grosse-Kunstleve
Browse files
Also scaling performance data to PyCLIF.
[skip ci]
parent
d1ee33f6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
+13
-0
ubench/holder_comparison_extract_sheet_data.py
ubench/holder_comparison_extract_sheet_data.py
+13
-0
No files found.
ubench/holder_comparison_extract_sheet_data.py
View file @
fccb6d9d
...
@@ -18,6 +18,7 @@ def run(args):
...
@@ -18,6 +18,7 @@ def run(args):
header
=
None
header
=
None
header_row
=
None
header_row
=
None
data_row
=
None
data_row
=
None
data_row_buffer
=
[]
def
show
():
def
show
():
if
header_row
:
if
header_row
:
...
@@ -27,6 +28,7 @@ def run(args):
...
@@ -27,6 +28,7 @@ def run(args):
assert
header
==
header_row
assert
header
==
header_row
if
data_row
is
not
None
:
if
data_row
is
not
None
:
print
(
","
.
join
(
data_row
))
print
(
","
.
join
(
data_row
))
data_row_buffer
.
append
(
data_row
)
return
header_row
return
header_row
for
line
in
log_lines
:
for
line
in
log_lines
:
...
@@ -41,6 +43,8 @@ def run(args):
...
@@ -41,6 +43,8 @@ def run(args):
assert
len
(
flds
)
==
2
assert
len
(
flds
)
==
2
header_row
.
append
(
"calls"
)
header_row
.
append
(
"calls"
)
data_row
.
append
(
flds
[
0
])
data_row
.
append
(
flds
[
0
])
header_row
.
append
(
"up"
)
data_row
.
append
(
"1.000"
)
elif
line
[
2
:].
startswith
(
ratx
):
elif
line
[
2
:].
startswith
(
ratx
):
flds
=
line
.
split
()
flds
=
line
.
split
()
assert
len
(
flds
)
==
4
assert
len
(
flds
)
==
4
...
@@ -48,6 +52,15 @@ def run(args):
...
@@ -48,6 +52,15 @@ def run(args):
data_row
.
append
(
flds
[
2
])
data_row
.
append
(
flds
[
2
])
show
()
show
()
print
(
"Scaled to last column:"
)
print
(
","
.
join
(
header_row
))
for
data_row
in
data_row_buffer
:
data_row_rescaled
=
data_row
[:
2
]
unit
=
float
(
data_row
[
-
1
])
for
fld
in
data_row
[
2
:]:
data_row_rescaled
.
append
(
"%.3f"
%
(
float
(
fld
)
/
unit
))
print
(
","
.
join
(
data_row_rescaled
))
if
__name__
==
"__main__"
:
if
__name__
==
"__main__"
:
run
(
args
=
sys
.
argv
[
1
:])
run
(
args
=
sys
.
argv
[
1
:])
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