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
70888b3a
Commit
70888b3a
authored
6 years ago
by
Matthew Andrew
Browse files
Options
Downloads
Patches
Plain Diff
Removed unused functions Re #23642
parent
7404fc93
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
scripts/Muon/GUI/Common/load_run_widget/model.py
+0
-20
0 additions, 20 deletions
scripts/Muon/GUI/Common/load_run_widget/model.py
scripts/Muon/GUI/Common/utilities/muon_test_helpers.py
+1
-1
1 addition, 1 deletion
scripts/Muon/GUI/Common/utilities/muon_test_helpers.py
with
1 addition
and
21 deletions
scripts/Muon/GUI/Common/load_run_widget/model.py
+
0
−
20
View file @
70888b3a
...
...
@@ -5,30 +5,10 @@
# & Institut Laue - Langevin
# SPDX - License - Identifier: GPL - 3.0 +
from
__future__
import
(
absolute_import
,
division
,
print_function
)
from
mantid.api
import
WorkspaceGroup
from
Muon.GUI.Common.muon_load_data
import
MuonLoadData
import
Muon.GUI.Common.utilities.load_utils
as
load_utils
def
is_workspace_group
(
workspace
):
return
isinstance
(
workspace
,
WorkspaceGroup
)
def
get_run_from_multi_period_data
(
workspace_list
):
"""
Checks if multi-period data has a single consistent
run number and returns it, otherwise raises ValueError.
"""
runs
=
[
ws
.
getRunNumber
()
for
ws
in
workspace_list
]
unique_runs
=
list
(
set
(
runs
))
if
len
(
unique_runs
)
!=
1
:
raise
ValueError
(
"
Multi-period data contains >1 unique run number.
"
)
else
:
return
unique_runs
[
0
]
def
exception_message_for_failed_files
(
failed_file_list
):
return
"
Could not load the following files :
\n
-
"
+
"
\n
-
"
.
join
(
failed_file_list
)
...
...
This diff is collapsed.
Click to expand it.
scripts/Muon/GUI/Common/utilities/muon_test_helpers.py
+
1
−
1
View file @
70888b3a
...
...
@@ -24,4 +24,4 @@ class IteratorWithException:
return
next
(
self
.
iterable
)
# python 3 compatibility
next
=
__next__
\ No newline at end of file
next
=
__next__
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