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
0fd85705
Commit
0fd85705
authored
5 years ago
by
Karim Ahmed
Browse files
Options
Downloads
Patches
Plain Diff
change args out-folder with out-path
parent
6b94c16f
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!217
FIX/Include run number in out -folder path if missing
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
xfel_calibrate/calibrate.py
+5
-10
5 additions, 10 deletions
xfel_calibrate/calibrate.py
with
5 additions
and
10 deletions
xfel_calibrate/calibrate.py
+
5
−
10
View file @
0fd85705
...
...
@@ -769,17 +769,12 @@ def run():
caltype
.
upper
(),
datetime
.
now
().
isoformat
())
if
try_report_to_output
:
if
"
out_folder
"
in
args
:
out_path
=
os
.
path
.
abspath
(
args
[
"
out_folder
"
])
if
"
run
"
in
args
:
if
"
run
"
in
args
and
str
(
args
[
"
run
"
])
not
in
args
[
"
out_folder
"
]:
rr
=
args
[
"
run
"
]
# Only put run, when it is not in the folder path
# (e.g. out-folder from webservice conf)
if
"
r{:04d}/
"
.
format
(
rr
)
not
in
out_path
and
\
"
{}
"
.
format
(
rr
)
not
in
out_path
:
if
isinstance
(
rr
,
int
):
out_path
=
"
{}/r{:04d}/
"
.
format
(
out_path
,
rr
)
else
:
out_path
=
"
{}/{}/
"
.
format
(
out_path
,
rr
)
# Only put run, when it is not in the out_folder
if
isinstance
(
rr
,
int
):
args
[
"
out_folder
"
]
=
"
{}/{}/
"
.
format
(
args
[
"
out_folder
"
],
rr
)
out_path
=
os
.
path
.
abspath
(
args
[
"
out_folder
"
])
else
:
print
(
"
No
'
out_folder
'
defined as argument, outputting to
'
{}
'
instead.
"
.
format
(
out_path
))
...
...
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