From b9277f0663c7346e611d5b2002131803d69e8d7d Mon Sep 17 00:00:00 2001 From: Gemma Guest <gemma.guest@stfc.ac.uk> Date: Tue, 28 Jan 2020 14:39:27 +0000 Subject: [PATCH] Fix problems with output property lists When assigning to a list of outputs when calling the algorithm in python, the outputs must be specified in the order they are declared, even if they are optional outputs like IvsLam. This means that if we want to specify the transmission workspace output we must first specify IvsLam even if debug is false. Some of the algorithms always output IvsLam if the name was given whereas others did not. They now always output it if the name is given. Note that this means you may now get an error if you don't supply enough arguments whereas previously it was ok. It is ok if you just specify the IvsQ output(s) but beyond that we do not know whether the output should be IvsLam or the transmission, so we require all of them, hence the error. This is better than it assigning an unexpected output so I think is ok, and is the only way I can think to do this. Re #27633 --- Framework/Algorithms/CMakeLists.txt | 2 - .../ReflectometryReductionOne2.h | 4 +- .../ReflectometryReductionOneAuto3.h | 4 +- .../ReflectometryWorkflowBase2.h | 1 + .../ReflectometryWorkflowBase3.h | 31 ----------- .../src/ReflectometryReductionOne2.cpp | 9 +++- .../src/ReflectometryReductionOneAuto3.cpp | 7 ++- .../src/ReflectometryWorkflowBase2.cpp | 32 +++++++++++- .../src/ReflectometryWorkflowBase3.cpp | 51 ------------------- .../test/ReflectometryReductionOneAuto3Test.h | 2 +- .../ReflectometryISISLoadAndProcess.py | 6 +-- .../tests/analysis/INTERReductionTest.py | 10 +++- .../ISISReflectometryAutoreductionTest.py | 6 ++- .../ReflectometryReductionOne-v2.rst | 22 ++++---- .../ReflectometryReductionOneAuto-v3.rst | 2 +- .../GenericDataProcessorPresenterTest.h | 4 +- 16 files changed, 78 insertions(+), 115 deletions(-) delete mode 100644 Framework/Algorithms/inc/MantidAlgorithms/ReflectometryWorkflowBase3.h delete mode 100644 Framework/Algorithms/src/ReflectometryWorkflowBase3.cpp diff --git a/Framework/Algorithms/CMakeLists.txt b/Framework/Algorithms/CMakeLists.txt index d2ce33eee2c..c5c0b300c65 100644 --- a/Framework/Algorithms/CMakeLists.txt +++ b/Framework/Algorithms/CMakeLists.txt @@ -260,7 +260,6 @@ set(SRC_FILES src/ReflectometrySumInQ.cpp src/ReflectometryWorkflowBase.cpp src/ReflectometryWorkflowBase2.cpp - src/ReflectometryWorkflowBase3.cpp src/Regroup.cpp src/RemoveBackground.cpp src/RemoveBins.cpp @@ -610,7 +609,6 @@ set(INC_FILES inc/MantidAlgorithms/ReflectometrySumInQ.h inc/MantidAlgorithms/ReflectometryWorkflowBase.h inc/MantidAlgorithms/ReflectometryWorkflowBase2.h - inc/MantidAlgorithms/ReflectometryWorkflowBase3.h inc/MantidAlgorithms/Regroup.h inc/MantidAlgorithms/RemoveBackground.h inc/MantidAlgorithms/RemoveBins.h diff --git a/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOne2.h b/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOne2.h index 72b969e07a9..cc642cef5db 100644 --- a/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOne2.h +++ b/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOne2.h @@ -7,7 +7,7 @@ #ifndef MANTID_ALGORITHMS_REFLECTOMETRYREDUCTIONONE2_H_ #define MANTID_ALGORITHMS_REFLECTOMETRYREDUCTIONONE2_H_ -#include "MantidAlgorithms/ReflectometryWorkflowBase3.h" +#include "MantidAlgorithms/ReflectometryWorkflowBase2.h" namespace Mantid { // Forward declaration @@ -27,7 +27,7 @@ namespace Algorithms { /** ReflectometryReductionOne2 : Reflectometry reduction of a single input TOF workspace to an IvsQ workspace. Version 2 of the algorithm. */ -class DLLExport ReflectometryReductionOne2 : public ReflectometryWorkflowBase3 { +class DLLExport ReflectometryReductionOne2 : public ReflectometryWorkflowBase2 { public: /// Algorithm's name for identification const std::string name() const override { diff --git a/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOneAuto3.h b/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOneAuto3.h index e54fbb9d104..b8bbd266cd5 100644 --- a/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOneAuto3.h +++ b/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOneAuto3.h @@ -8,7 +8,7 @@ #define MANTID_ALGORITHMS_REFLECTOMETRYREDUCTIONONEAUTO3_H_ #include "MantidAPI/WorkspaceGroup_fwd.h" -#include "ReflectometryWorkflowBase3.h" +#include "ReflectometryWorkflowBase2.h" #include <boost/optional.hpp> @@ -19,7 +19,7 @@ namespace Algorithms { attempting to pick instrument parameters for missing properties. Version 3. */ class DLLExport ReflectometryReductionOneAuto3 - : public ReflectometryWorkflowBase3 { + : public ReflectometryWorkflowBase2 { public: const std::string name() const override; int version() const override; diff --git a/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryWorkflowBase2.h b/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryWorkflowBase2.h index 8d35470a2d5..0e282a691a6 100644 --- a/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryWorkflowBase2.h +++ b/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryWorkflowBase2.h @@ -33,6 +33,7 @@ protected: void initBackgroundProperties(); /// Initialize transmission properties void initTransmissionProperties(); + void initTransmissionOutputProperties(); /// Initialize properties for stitching transmission runs void initStitchProperties(); /// Initialize corection algorithm properties diff --git a/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryWorkflowBase3.h b/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryWorkflowBase3.h deleted file mode 100644 index bb44f98deee..00000000000 --- a/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryWorkflowBase3.h +++ /dev/null @@ -1,31 +0,0 @@ -// Mantid Repository : https://github.com/mantidproject/mantid -// -// Copyright © 2020 ISIS Rutherford Appleton Laboratory UKRI, -// NScD Oak Ridge National Laboratory, European Spallation Source -// & Institut Laue - Langevin -// SPDX - License - Identifier: GPL - 3.0 + -#ifndef MANTID_ALGORITHMS_REFLECTOMETRYWORKFLOWBASE3_H_ -#define MANTID_ALGORITHMS_REFLECTOMETRYWORKFLOWBASE3_H_ - -#include "ReflectometryWorkflowBase2.h" - -using namespace Mantid::API; -using namespace Mantid::Kernel; -using namespace Mantid::Geometry; -namespace Mantid { -namespace Algorithms { - -/** ReflectometryWorkflowBase3 : base class containing common implementation - functionality usable by concrete reflectometry workflow algorithms. Version 3. - This version is identical to version 2 but overrides the transmission - properties to provide some additional output workspace properties. - */ -class DLLExport ReflectometryWorkflowBase3 : public ReflectometryWorkflowBase2 { -protected: - /// Initialize transmission properties - void initTransmissionProperties(); -}; -} // namespace Algorithms -} // namespace Mantid - -#endif /* MANTID_ALGORITHMS_REFLECTOMETRYWORKFLOWBASE3_H_ */ diff --git a/Framework/Algorithms/src/ReflectometryReductionOne2.cpp b/Framework/Algorithms/src/ReflectometryReductionOne2.cpp index bc177d1e6b9..a60e38936d6 100644 --- a/Framework/Algorithms/src/ReflectometryReductionOne2.cpp +++ b/Framework/Algorithms/src/ReflectometryReductionOne2.cpp @@ -17,6 +17,7 @@ #include "MantidGeometry/Objects/BoundingBox.h" #include "MantidHistogramData/LinearGenerator.h" #include "MantidIndexing/IndexInfo.h" +#include "MantidKernel/EnabledWhenProperty.h" #include "MantidKernel/MandatoryValidator.h" #include "MantidKernel/StringTokenizer.h" #include "MantidKernel/Strings.h" @@ -171,6 +172,11 @@ void ReflectometryReductionOne2::init() { "OutputWorkspaceWavelength", "", Direction::Output, PropertyMode::Optional), "Output Workspace IvsLam. Intermediate workspace."); + setPropertySettings( + "OutputWorkspaceWavelength", + std::make_unique<Kernel::EnabledWhenProperty>("Debug", IS_EQUAL_TO, "1")); + + initTransmissionOutputProperties(); } /** Validate inputs @@ -548,8 +554,7 @@ MatrixWorkspace_sptr ReflectometryReductionOne2::transmissionCorrection( rebinToWorkspaceAlg->setProperty("WorkspaceToRebin", transmissionWS); rebinToWorkspaceAlg->execute(); transmissionWS = rebinToWorkspaceAlg->getProperty("OutputWorkspace"); - setProperty("OutputWorkspaceTransmission", transmissionWS); - if (!transmissionWSName.empty()) + if (isDefault("OutputWorkspaceTransmission") && !transmissionWSName.empty()) setPropertyValue("OutputWorkspaceTransmission", transmissionWSName); // If the detector workspace has been reduced then the spectrum maps diff --git a/Framework/Algorithms/src/ReflectometryReductionOneAuto3.cpp b/Framework/Algorithms/src/ReflectometryReductionOneAuto3.cpp index 81b538cc876..b66e6cc2f8b 100644 --- a/Framework/Algorithms/src/ReflectometryReductionOneAuto3.cpp +++ b/Framework/Algorithms/src/ReflectometryReductionOneAuto3.cpp @@ -342,6 +342,11 @@ void ReflectometryReductionOneAuto3::init() { "OutputWorkspaceWavelength", "", Direction::Output, PropertyMode::Optional), "Output workspace in wavelength"); + setPropertySettings( + "OutputWorkspaceWavelength", + std::make_unique<Kernel::EnabledWhenProperty>("Debug", IS_EQUAL_TO, "1")); + + initTransmissionOutputProperties(); } /** Execute the algorithm. @@ -428,7 +433,7 @@ void ReflectometryReductionOneAuto3::exec() { } // Set the output workspace in wavelength, if debug outputs are enabled - if (isDebug || isChild()) { + if (!isDefault("OutputWorkspaceWavelength") || isChild()) { MatrixWorkspace_sptr IvsLam = alg->getProperty("OutputWorkspaceWavelength"); setProperty("OutputWorkspaceWavelength", IvsLam); } diff --git a/Framework/Algorithms/src/ReflectometryWorkflowBase2.cpp b/Framework/Algorithms/src/ReflectometryWorkflowBase2.cpp index 6b373625af3..262aff90e31 100644 --- a/Framework/Algorithms/src/ReflectometryWorkflowBase2.cpp +++ b/Framework/Algorithms/src/ReflectometryWorkflowBase2.cpp @@ -244,6 +244,32 @@ void ReflectometryWorkflowBase2::initTransmissionProperties() { setPropertyGroup("TransmissionProcessingInstructions", "Transmission"); } +/** Initialize output properties related to transmission normalization + */ +void ReflectometryWorkflowBase2::initTransmissionOutputProperties() { + // Add additional output workspace properties + declareProperty(std::make_unique<WorkspaceProperty<MatrixWorkspace>>( + "OutputWorkspaceTransmission", "", Direction::Output, + PropertyMode::Optional), + "Output transmissison workspace in wavelength"); + declareProperty(std::make_unique<WorkspaceProperty<MatrixWorkspace>>( + "OutputWorkspaceFirstTransmission", "", Direction::Output, + PropertyMode::Optional), + "First transmissison workspace in wavelength"); + declareProperty(std::make_unique<WorkspaceProperty<MatrixWorkspace>>( + "OutputWorkspaceSecondTransmission", "", + Direction::Output, PropertyMode::Optional), + "Second transmissison workspace in wavelength"); + + // Specify conditional output properties for when debug is on + setPropertySettings( + "OutputWorkspaceFirstTransmission", + std::make_unique<Kernel::EnabledWhenProperty>("Debug", IS_EQUAL_TO, "1")); + setPropertySettings( + "OutputWorkspaceSecondTransmission", + std::make_unique<Kernel::EnabledWhenProperty>("Debug", IS_EQUAL_TO, "1")); +} + /** Initialize properties used for stitching transmission runs */ void ReflectometryWorkflowBase2::initStitchProperties() { @@ -916,9 +942,11 @@ void ReflectometryWorkflowBase2::setWorkspacePropertyFromChild( if (alg->isDefault(propertyName)) return; - std::string const workspaceName = alg->getPropertyValue(propertyName); + if (isDefault(propertyName)) { + std::string const workspaceName = alg->getPropertyValue(propertyName); + setPropertyValue(propertyName, workspaceName); + } MatrixWorkspace_sptr workspace = alg->getProperty(propertyName); - setPropertyValue(propertyName, workspaceName); setProperty(propertyName, workspace); } } // namespace Algorithms diff --git a/Framework/Algorithms/src/ReflectometryWorkflowBase3.cpp b/Framework/Algorithms/src/ReflectometryWorkflowBase3.cpp deleted file mode 100644 index 0ea7afed57a..00000000000 --- a/Framework/Algorithms/src/ReflectometryWorkflowBase3.cpp +++ /dev/null @@ -1,51 +0,0 @@ -// Mantid Repository : https://github.com/mantidproject/mantid -// -// Copyright © 2020 ISIS Rutherford Appleton Laboratory UKRI, -// NScD Oak Ridge National Laboratory, European Spallation Source -// & Institut Laue - Langevin -// SPDX - License - Identifier: GPL - 3.0 + -#include "MantidAlgorithms/ReflectometryWorkflowBase3.h" -#include "MantidKernel/EnabledWhenProperty.h" - -using namespace Mantid::API; -using namespace Mantid::Kernel; -using namespace Mantid::Geometry; - -namespace Mantid { -namespace Algorithms { - -/** Initialize properties related to transmission normalization - */ -void ReflectometryWorkflowBase3::initTransmissionProperties() { - // Include everything from the base class - ReflectometryWorkflowBase2::initTransmissionProperties(); - - // Add additional output workspace properties - declareProperty(std::make_unique<WorkspaceProperty<MatrixWorkspace>>( - "OutputWorkspaceTransmission", "", Direction::Output, - PropertyMode::Optional), - "Output transmissison workspace in wavelength"); - declareProperty(std::make_unique<WorkspaceProperty<MatrixWorkspace>>( - "OutputWorkspaceFirstTransmission", "", Direction::Output, - PropertyMode::Optional), - "First transmissison workspace in wavelength"); - declareProperty(std::make_unique<WorkspaceProperty<MatrixWorkspace>>( - "OutputWorkspaceSecondTransmission", "", - Direction::Output, PropertyMode::Optional), - "Second transmissison workspace in wavelength"); - - // Specify conditional output properties for when debug is on - setPropertySettings( - "OutputWorkspaceFirstTransmission", - std::make_unique<Kernel::EnabledWhenProperty>("Debug", IS_EQUAL_TO, "1")); - setPropertySettings( - "OutputWorkspaceSecondTransmission", - std::make_unique<Kernel::EnabledWhenProperty>("Debug", IS_EQUAL_TO, "1")); - - // Put them in the Transmission group - setPropertyGroup("OutputWorkspaceTransmission", "Transmission"); - setPropertyGroup("OutputWorkspaceFirstTransmission", "Transmission"); - setPropertyGroup("OutputWorkspaceSecondTransmission", "Transmission"); -} -} // namespace Algorithms -} // namespace Mantid diff --git a/Framework/Algorithms/test/ReflectometryReductionOneAuto3Test.h b/Framework/Algorithms/test/ReflectometryReductionOneAuto3Test.h index 6f2bd906fef..73e03c801f5 100644 --- a/Framework/Algorithms/test/ReflectometryReductionOneAuto3Test.h +++ b/Framework/Algorithms/test/ReflectometryReductionOneAuto3Test.h @@ -693,7 +693,7 @@ public: TS_ASSERT(AnalysisDataService::Instance().doesExist("IvsQ_binned")); TS_ASSERT(AnalysisDataService::Instance().doesExist("IvsQ")); - TS_ASSERT(!AnalysisDataService::Instance().doesExist("IvsLam")); + TS_ASSERT(AnalysisDataService::Instance().doesExist("IvsLam")); AnalysisDataService::Instance().clear(); } diff --git a/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ReflectometryISISLoadAndProcess.py b/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ReflectometryISISLoadAndProcess.py index b32ecc84c4d..d5b8a8e32dc 100644 --- a/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ReflectometryISISLoadAndProcess.py +++ b/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ReflectometryISISLoadAndProcess.py @@ -193,8 +193,7 @@ class ReflectometryISISLoadAndProcess(DataProcessorAlgorithm): # Add properties copied from child algorithm properties = [ 'Params', 'StartOverlap', 'EndOverlap', - 'ScaleRHSWorkspace', 'TransmissionProcessingInstructions', - Prop.OUTPUT_WS_TRANS, Prop.OUTPUT_WS_FIRST_TRANS, Prop.OUTPUT_WS_SECOND_TRANS + 'ScaleRHSWorkspace', 'TransmissionProcessingInstructions' ] self.copyProperties('ReflectometryReductionOneAuto', properties) self._reduction_properties += properties @@ -203,7 +202,8 @@ class ReflectometryISISLoadAndProcess(DataProcessorAlgorithm): properties = [Prop.DEBUG, 'MomentumTransferMin', 'MomentumTransferStep', 'MomentumTransferMax', 'ScaleFactor', - Prop.OUTPUT_WS, Prop.OUTPUT_WS_BINNED, Prop.OUTPUT_WS_LAM] + Prop.OUTPUT_WS_BINNED, Prop.OUTPUT_WS, Prop.OUTPUT_WS_LAM, + Prop.OUTPUT_WS_TRANS, Prop.OUTPUT_WS_FIRST_TRANS, Prop.OUTPUT_WS_SECOND_TRANS] self.copyProperties('ReflectometryReductionOneAuto', properties) self._reduction_properties += properties diff --git a/Testing/SystemTests/tests/analysis/INTERReductionTest.py b/Testing/SystemTests/tests/analysis/INTERReductionTest.py index 2834509c7a6..327b823d1d2 100644 --- a/Testing/SystemTests/tests/analysis/INTERReductionTest.py +++ b/Testing/SystemTests/tests/analysis/INTERReductionTest.py @@ -106,13 +106,16 @@ def eventRef(run_number, angle, start=0, stop=0, DB='TRANS'): ReflectometryISISLoadAndProcess(InputRunList=slice_name, FirstTransmissionRunList=DB, OutputWorkspaceBinned=slice_name+'_ref_binned', OutputWorkspace=slice_name+'_ref', - OutputWorkspaceWavelength=slice_name+'_lam', Debug=True) + OutputWorkspaceWavelength=slice_name+'_lam', + OutputWorkspaceTransmission=DB+'_LAM', + Debug=True) # Delete interim workspaces DeleteWorkspace(slice_name+'_lam') DeleteWorkspace(slice_name) DeleteWorkspace(slice_name+'_ref') DeleteWorkspace('mon_slice') DeleteWorkspace('mon_rebin') + DeleteWorkspace(DB+'_LAM') def quickRef(run_numbers=[], trans_workspace_names=[], angles=[]): @@ -122,11 +125,13 @@ def quickRef(run_numbers=[], trans_workspace_names=[], angles=[]): for run_index in range(len(run_numbers)): # Set up the reduction properties run_name=str(run_numbers[run_index]) + trans_name = str(trans_workspace_names[run_index]) properties = {'InputRunList': run_name+'.raw', - 'FirstTransmissionRunList': str(trans_workspace_names[run_index]), + 'FirstTransmissionRunList': trans_name, 'OutputWorkspaceBinned': run_name+'_IvsQ_binned', 'OutputWorkspace': run_name+'_IvsQ', 'OutputWorkspaceWavelength': run_name+'_IvsLam', + 'OutputWorkspaceTransmission': trans_name+'_LAM', 'Debug': True} # Set ThetaIn if the angles are given if angles: @@ -137,6 +142,7 @@ def quickRef(run_numbers=[], trans_workspace_names=[], angles=[]): properties['WavelengthMin']=2.6 # Do the reduction ReflectometryISISLoadAndProcess(**properties) + DeleteWorkspace(trans_name+'_LAM') reduced_runs=reduced_runs+run_name+'_IvsQ_binned' if run_index < len(run_numbers)-1: reduced_runs=reduced_runs+',' diff --git a/Testing/SystemTests/tests/analysis/ISISReflectometryAutoreductionTest.py b/Testing/SystemTests/tests/analysis/ISISReflectometryAutoreductionTest.py index 39ff2717fb9..a26b2ea2fb9 100644 --- a/Testing/SystemTests/tests/analysis/ISISReflectometryAutoreductionTest.py +++ b/Testing/SystemTests/tests/analysis/ISISReflectometryAutoreductionTest.py @@ -178,7 +178,7 @@ def AutoReduce(transRun=[], runRange=[], oldList=[]): if not mtd.doesExist(runno + '_IvsQ'): th = angle if len(transRun) > 1 and angle > 2.25: - wq, wq_binned = \ + wq, wq_unbinned, wlam, wtrans = \ ReflectometryISISLoadAndProcess( InputRunList=ws, FirstTransmissionRunList=transRun[1], @@ -188,7 +188,7 @@ def AutoReduce(transRun=[], runRange=[], oldList=[]): OutputWorkspace=runno + '_IvsQ', OutputWorkspaceBinned=runno + '_IvsQ_binned') else: - wq, wqbinned = \ + wq, wq_unbinned, wlam, wtrans = \ ReflectometryISISLoadAndProcess( InputRunList=ws, FirstTransmissionRunList=transRun[0], @@ -197,6 +197,8 @@ def AutoReduce(transRun=[], runRange=[], oldList=[]): EndOverlap=12, OutputWorkspace=runno + '_IvsQ', OutputWorkspaceBinned=runno + '_IvsQ_binned') + mtd.remove('wlam') + mtd.remove('wtrans') else: wq = mtd[runno + '_IvsQ'] th = angle diff --git a/docs/source/algorithms/ReflectometryReductionOne-v2.rst b/docs/source/algorithms/ReflectometryReductionOne-v2.rst index 61a694bdcdd..9e722fbdbaa 100644 --- a/docs/source/algorithms/ReflectometryReductionOne-v2.rst +++ b/docs/source/algorithms/ReflectometryReductionOne-v2.rst @@ -253,17 +253,17 @@ Output: trans1 = Load(Filename='INTER00013463.nxs') trans2 = Load(Filename='INTER00013464.nxs') # Basic reduction with two transmission runs - IvsQ, IvsLam = ReflectometryReductionOne(InputWorkspace=run, - WavelengthMin=1.0, - WavelengthMax=17.0, - ProcessingInstructions='4', - I0MonitorIndex=2, - MonitorBackgroundWavelengthMin=15.0, - MonitorBackgroundWavelengthMax=17.0, - MonitorIntegrationWavelengthMin=4.0, - MonitorIntegrationWavelengthMax=10.0, - FirstTransmissionRun=trans1, - SecondTransmissionRun=trans2) + IvsQ, IvsLam, TRANS = ReflectometryReductionOne(InputWorkspace=run, + WavelengthMin=1.0, + WavelengthMax=17.0, + ProcessingInstructions='4', + I0MonitorIndex=2, + MonitorBackgroundWavelengthMin=15.0, + MonitorBackgroundWavelengthMax=17.0, + MonitorIntegrationWavelengthMin=4.0, + MonitorIntegrationWavelengthMax=10.0, + FirstTransmissionRun=trans1, + SecondTransmissionRun=trans2) print("{:.4f}".format(IvsLam.readY(0)[480])) print("{:.4f}".format(IvsLam.readY(0)[481])) diff --git a/docs/source/algorithms/ReflectometryReductionOneAuto-v3.rst b/docs/source/algorithms/ReflectometryReductionOneAuto-v3.rst index 1d3b3799627..fd94d0c08c0 100644 --- a/docs/source/algorithms/ReflectometryReductionOneAuto-v3.rst +++ b/docs/source/algorithms/ReflectometryReductionOneAuto-v3.rst @@ -157,7 +157,7 @@ Output: run = Load(Filename='INTER00013460.nxs') trans = Load(Filename='INTER00013463.nxs') - IvsQ, IvsQ_unbinned = ReflectometryReductionOneAuto(InputWorkspace=run, FirstTransmissionRun=trans, ThetaIn=0.7) + IvsQ, IvsQ_unbinned, IvsLam, TRANS = ReflectometryReductionOneAuto(InputWorkspace=run, FirstTransmissionRun=trans, ThetaIn=0.7) print("{:.5f}".format(IvsQ_unbinned.readY(0)[96])) print("{:.5f}".format(IvsQ_unbinned.readY(0)[97])) diff --git a/qt/widgets/common/test/DataProcessorUI/GenericDataProcessorPresenterTest.h b/qt/widgets/common/test/DataProcessorUI/GenericDataProcessorPresenterTest.h index f13476e5c64..492e6339569 100644 --- a/qt/widgets/common/test/DataProcessorUI/GenericDataProcessorPresenterTest.h +++ b/qt/widgets/common/test/DataProcessorUI/GenericDataProcessorPresenterTest.h @@ -1681,8 +1681,8 @@ public: AnalysisDataService::Instance().doesExist("IvsQ_binned_TOF_dataB")); TS_ASSERT(AnalysisDataService::Instance().doesExist("IvsQ_TOF_dataA")); TS_ASSERT(AnalysisDataService::Instance().doesExist("IvsQ_TOF_dataB")); - TS_ASSERT(!AnalysisDataService::Instance().doesExist("IvsLam_TOF_dataA")); - TS_ASSERT(!AnalysisDataService::Instance().doesExist("IvsLam_TOF_dataB")); + TS_ASSERT(AnalysisDataService::Instance().doesExist("IvsLam_TOF_dataA")); + TS_ASSERT(AnalysisDataService::Instance().doesExist("IvsLam_TOF_dataB")); TS_ASSERT( AnalysisDataService::Instance().doesExist("IvsQ_TOF_dataA_TOF_dataB")); -- GitLab