Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Iris
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Simcha van Collem
Iris
Commits
500176fd
Commit
500176fd
authored
9 years ago
by
Ralf Jung
Browse files
Options
Downloads
Patches
Plain Diff
make the visualizer visual
parent
66bb3579
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
benchmark/visualize.py
+15
-4
15 additions, 4 deletions
benchmark/visualize.py
with
15 additions
and
4 deletions
benchmark/visualize.py
+
15
−
4
View file @
500176fd
#!/usr/bin/env python3
import
argparse
,
sys
,
pprint
import
matplotlib.pyplot
as
plt
import
parse_log
# read command-line arguments
...
...
@@ -14,7 +15,17 @@ args = parser.parse_args()
pp
=
pprint
.
PrettyPrinter
()
log_file
=
sys
.
stdin
if
args
.
file
==
"
-
"
else
open
(
args
.
file
,
"
r
"
)
for
result
in
parse_log
.
parse
(
log_file
,
args
.
timings
):
pp
.
pprint
(
result
.
commit
)
pp
.
pprint
(
result
.
times
)
print
()
results
=
list
(
parse_log
.
parse
(
log_file
,
args
.
timings
))
for
timing
in
args
.
timings
:
plt
.
plot
(
list
(
map
(
lambda
r
:
r
.
times
[
timing
],
results
)))
plt
.
legend
(
args
.
timings
)
plt
.
xticks
(
range
(
len
(
results
)),
list
(
map
(
lambda
r
:
r
.
commit
[:
7
],
results
)),
rotation
=
70
)
plt
.
subplots_adjust
(
bottom
=
0.2
)
# more space for the commit labels
plt
.
xlabel
(
'
Commit
'
)
plt
.
ylabel
(
'
Time (s)
'
)
plt
.
title
(
'
Time to compile files
'
)
plt
.
grid
(
True
)
plt
.
show
()
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment