Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
mantid
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review 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
mantidproject
mantid
Commits
cf8c4faa
Commit
cf8c4faa
authored
6 years ago
by
Alex Buts
Browse files
Options
Downloads
Patches
Plain Diff
Re #22307 This should fix it.
parent
6842774c
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
scripts/Inelastic/Direct/ISISDirecInelasticConfig.py
+8
-3
8 additions, 3 deletions
scripts/Inelastic/Direct/ISISDirecInelasticConfig.py
with
8 additions
and
3 deletions
scripts/Inelastic/Direct/ISISDirecInelasticConfig.py
+
8
−
3
View file @
cf8c4faa
...
...
@@ -82,7 +82,8 @@ class UserProperties(object):
self
.
_rb_exist
[
recent_date_id
]
=
rb_exist
# a data which define the cycle ID e.g 2014_3 or something
self
.
_cycle_IDs
[
recent_date_id
]
=
(
str
(
cycle
[
5
:
9
]),
str
(
cycle
[
9
:
10
]))
self
.
_cycle_IDs
[
recent_date_id
]
=
(
str
(
cycle
[
5
:
9
]),
str
(
cycle
[
9
:]))
self
.
_instrument
[
recent_date_id
]
=
str
(
instrument
).
upper
()
self
.
_rb_dirs
[
recent_date_id
]
=
rb_folder_or_id
if
self
.
_recent_dateID
:
...
...
@@ -277,7 +278,9 @@ class UserProperties(object):
if
isinstance
(
cycle
,
int
):
cycle
=
convert_cycle_int
(
cycle
)
if
isinstance
(
cycle
,
str
):
if
len
(
cycle
)
!=
10
:
if
len
(
cycle
)
==
11
:
cycle
=
cycle
.
upper
();
elif
len
(
cycle
)
<
10
:
cycle
=
cycle
.
replace
(
'
_
'
,
''
)
try
:
cycle
=
int
(
cycle
)
...
...
@@ -682,11 +685,13 @@ class MantidConfigDirectInelastic(object):
(cycle ID)
The agreement on the naming as currently in ISIS:
e.g: /archive/NDXMERLIN/Instrument/data/cycle_08_1
Note: will fail if cycle numbers ever become a 2-digit numbers e.g. cycle_22_10
"""
# cycle folder have short form without leading numbers
cycle_fold_n
=
int
(
cycle_ID
[
0
])
-
2000
folder
=
os
.
path
.
join
(
self
.
_root_data_folder
,
'
NDX
'
+
instr
.
upper
(),
"
Instrument/data/cycle_{0:02}_{1}
"
.
format
(
cycle_fold_n
,
str
(
cycle_ID
[
1
])))
"
Instrument/data/cycle_{0:02}_{1}
"
.
format
(
cycle_fold_n
,
str
(
cycle_ID
[
1
]
[
0
]
)))
return
folder
def
is_inelastic
(
self
,
instr_name
):
...
...
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