Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pycalibration
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Model registry
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
calibration
pycalibration
Commits
f0aeec49
Commit
f0aeec49
authored
5 years ago
by
Mikhail Karnevskiy
Browse files
Options
Downloads
Patches
Plain Diff
Order modules in the report
parent
ae731083
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!67
Feat: Remove extra information from report
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
cal_tools/cal_tools/tools.py
+19
-0
19 additions, 0 deletions
cal_tools/cal_tools/tools.py
with
19 additions
and
0 deletions
cal_tools/cal_tools/tools.py
+
19
−
0
View file @
f0aeec49
...
...
@@ -15,10 +15,29 @@ import time
from
uuid
import
uuid4
def
atoi
(
text
):
'''
Convert string to integer is possible
:param text: string to be converted
:return: integer value or input string
'''
return
int
(
text
)
if
text
.
isdigit
()
else
text
def
natural_keys
(
text
):
'''
Decompose string to list of integers and sub-strings
'''
return
[
atoi
(
c
)
for
c
in
re
.
split
(
r
'
(\d+)
'
,
text
)
]
def
combine_report
(
run_path
,
calibration
):
sphinx_path
=
"
{}/sphinx_rep
"
.
format
(
os
.
path
.
abspath
(
run_path
))
os
.
makedirs
(
sphinx_path
)
direntries
=
os
.
listdir
(
run_path
)
direntries
.
sort
(
key
=
natural_keys
)
for
entry
in
direntries
:
...
...
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