Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
mantidproject
mantid
Commits
715cb8fe
Unverified
Commit
715cb8fe
authored
Mar 04, 2021
by
Jose Borreguero
Committed by
GitHub
Mar 04, 2021
Browse files
Merge pull request #30767 from mantidproject/30675_tubedatabasedir_property
Remove property from corelli calibration algorithm
parents
8ae31082
55665af0
Changes
3
Hide whitespace changes
Inline
Side-by-side
Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/CorelliPowderCalibrationCreate.py
View file @
715cb8fe
...
...
@@ -116,10 +116,7 @@ class CorelliPowderCalibrationCreate(DataProcessorAlgorithm):
)
self
.
declareProperty
(
name
=
'OutputWorkspacesPrefix'
,
defaultValue
=
'pdcal_'
,
direction
=
Direction
.
Input
,
doc
=
"Prefix to be added to output workspaces"
)
# Tube Calibration properties
self
.
declareProperty
(
name
=
'TubeDatabaseDir'
,
defaultValue
=
'/SNS/CORELLI/shared/calibration/tube'
,
direction
=
Direction
.
Input
,
doc
=
'path to database containing detector heights'
)
# PDCalibration properties exposed, grouped
property_names
=
[
'TofBinning'
,
'PeakFunction'
,
'PeakPositions'
]
self
.
copyProperties
(
'PDCalibration'
,
property_names
)
...
...
Framework/PythonInterface/test/python/plugins/algorithms/WorkflowAlgorithms/CorelliPowderCalibrationCreateTest.py
View file @
715cb8fe
...
...
@@ -35,7 +35,7 @@ class CorelliPowderCalibrationCreateTest(unittest.TestCase):
# Both FixSource=True, AdjustSource=True can't be True
try
:
CorelliPowderCalibrationCreate
(
InputWorkspace
=
'test_workspace'
,
OutputWorkspacesPrefix
=
'cal_'
,
TubeDatabaseDir
=
'/tmp'
,
InputWorkspace
=
'test_workspace'
,
OutputWorkspacesPrefix
=
'cal_'
,
TofBinning
=
[
300
,
1.0
,
16666.7
],
PeakPositions
=
spacings_reference
,
FixSource
=
True
,
AdjustSource
=
True
,
ComponentList
=
'bank1'
,
ComponentMaxTranslation
=
0.2
,
ComponentMaxRotation
=
10
)
except
RuntimeError
as
error
:
...
...
@@ -44,7 +44,7 @@ class CorelliPowderCalibrationCreateTest(unittest.TestCase):
# Both FixSource=True, AdjustSource=True can't be False
try
:
CorelliPowderCalibrationCreate
(
InputWorkspace
=
'test_workspace'
,
OutputWorkspacesPrefix
=
'cal_'
,
TubeDatabaseDir
=
'/tmp'
,
InputWorkspace
=
'test_workspace'
,
OutputWorkspacesPrefix
=
'cal_'
,
TofBinning
=
[
300
,
1.0
,
16666.7
],
PeakPositions
=
spacings_reference
,
FixSource
=
False
,
AdjustSource
=
False
,
ComponentList
=
'bank1'
,
ComponentMaxTranslation
=
0.2
,
ComponentMaxRotation
=
10
)
except
RuntimeError
as
error
:
...
...
@@ -55,7 +55,7 @@ class CorelliPowderCalibrationCreateTest(unittest.TestCase):
# a result, the final position and orientation is not exactly perpendicular to the X-axis and positioned
# five meters away from the sample.
CorelliPowderCalibrationCreate
(
InputWorkspace
=
'test_workspace'
,
OutputWorkspacesPrefix
=
'cal_'
,
TubeDatabaseDir
=
'/tmp'
,
InputWorkspace
=
'test_workspace'
,
OutputWorkspacesPrefix
=
'cal_'
,
TofBinning
=
[
300
,
1.0
,
16666.7
],
PeakPositions
=
spacings_reference
,
SourceToSampleDistance
=
10.0
,
ComponentList
=
'bank1'
,
ComponentMaxTranslation
=
0.2
,
ComponentMaxRotation
=
10
)
# Check source position
...
...
Testing/SystemTests/tests/framework/CorelliPowderCalibrationTest.py
View file @
715cb8fe
...
...
@@ -31,7 +31,6 @@ class CorelliPowderCalibrationCreateTest(MantidSystemTest):
CorelliPowderCalibrationCreate
(
InputWorkspace
=
'LaB6'
,
OutputWorkspacesPrefix
=
'LaB6_'
,
SourceToSampleDistance
=
19.991
,
TubeDatabaseDir
=
'/tmp'
,
TofBinning
=
[
3000
,
-
0.001
,
16660
],
PeakFunction
=
'Gaussian'
,
PeakPositions
=
[
1.3143
,
1.3854
,
1.6967
,
1.8587
,
2.0781
,
2.3995
,
2.9388
,
4.1561
],
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment