diff --git a/Framework/Algorithms/inc/MantidAlgorithms/ConvertDiffCal.h b/Framework/Algorithms/inc/MantidAlgorithms/ConvertDiffCal.h index 8c4a70b770820bdef44eae290d7f34b96b01982b..9efc415141be4b49c3b8547f75c5223e07820d8e 100644 --- a/Framework/Algorithms/inc/MantidAlgorithms/ConvertDiffCal.h +++ b/Framework/Algorithms/inc/MantidAlgorithms/ConvertDiffCal.h @@ -2,7 +2,7 @@ #define MANTID_ALGORITHMS_CONVERTDIFFCAL_H_ #include "MantidKernel/System.h" -#include "MantidAPI/Algorithm.h" +#include "MantidAPI/ParallelAlgorithm.h" namespace Mantid { namespace Algorithms { @@ -29,7 +29,7 @@ namespace Algorithms { File change history is stored at: <https://github.com/mantidproject/mantid> Code Documentation is available at: <http://doxygen.mantidproject.org> */ -class DLLExport ConvertDiffCal : public API::Algorithm { +class DLLExport ConvertDiffCal : public API::ParallelAlgorithm { public: const std::string name() const override; int version() const override; @@ -44,4 +44,4 @@ private: } // namespace Algorithms } // namespace Mantid -#endif /* MANTID_ALGORITHMS_CONVERTDIFFCAL_H_ */ \ No newline at end of file +#endif /* MANTID_ALGORITHMS_CONVERTDIFFCAL_H_ */ diff --git a/Framework/DataHandling/inc/MantidDataHandling/LoadCalFile.h b/Framework/DataHandling/inc/MantidDataHandling/LoadCalFile.h index 3c6ec5a945145188da844632efcf4b9aca343caf..c303d3859e2a3a8927d848979bafea799edfeb85 100644 --- a/Framework/DataHandling/inc/MantidDataHandling/LoadCalFile.h +++ b/Framework/DataHandling/inc/MantidDataHandling/LoadCalFile.h @@ -47,6 +47,11 @@ public: Mantid::DataObjects::OffsetsWorkspace_sptr offsetsWS, Mantid::DataObjects::MaskWorkspace_sptr maskWS); +protected: + Parallel::ExecutionMode getParallelExecutionMode( + const std::map<std::string, Parallel::StorageMode> &storageModes) + const override; + private: /// Initialise the properties void init() override; diff --git a/Framework/DataHandling/inc/MantidDataHandling/LoadDiffCal.h b/Framework/DataHandling/inc/MantidDataHandling/LoadDiffCal.h index 39ae0b1f03c26b711011c47d2c6c4d11f6ee805f..a2a205d2264f62eeaaae42819d1e47fbbc348e32 100644 --- a/Framework/DataHandling/inc/MantidDataHandling/LoadDiffCal.h +++ b/Framework/DataHandling/inc/MantidDataHandling/LoadDiffCal.h @@ -43,6 +43,11 @@ public: const std::string category() const override; const std::string summary() const override; +protected: + Parallel::ExecutionMode getParallelExecutionMode( + const std::map<std::string, Parallel::StorageMode> &storageModes) + const override; + private: void init() override; void exec() override; diff --git a/Framework/DataHandling/src/LoadCalFile.cpp b/Framework/DataHandling/src/LoadCalFile.cpp index 3cb9b75c8ac635b076d15822164973e8aaa3232a..1f5ea0e122f51c12a7be9eb30363a950a73704c8 100644 --- a/Framework/DataHandling/src/LoadCalFile.cpp +++ b/Framework/DataHandling/src/LoadCalFile.cpp @@ -359,5 +359,15 @@ bool LoadCalFile::idIsMonitor(Instrument_const_sptr inst, int detID) { return (it != monitorList.end()); } +Parallel::ExecutionMode LoadCalFile::getParallelExecutionMode( + const std::map<std::string, Parallel::StorageMode> &storageModes) const { + // There is an optional input workspace which may have + // StorageMode::Distributed but it is merely used for passing an instrument. + // Output should always have StorageMode::Cloned, so we run with + // ExecutionMode::Identical. + static_cast<void>(storageModes); + return Parallel::ExecutionMode::Identical; +} + } // namespace Mantid } // namespace DataHandling diff --git a/Framework/DataHandling/src/LoadDiffCal.cpp b/Framework/DataHandling/src/LoadDiffCal.cpp index 7ff915eb1cae71e0ef57896a09fe0f31594d40d0..d4a9929d42162ce62af6035424f32b89817bbef3 100644 --- a/Framework/DataHandling/src/LoadDiffCal.cpp +++ b/Framework/DataHandling/src/LoadDiffCal.cpp @@ -458,5 +458,15 @@ void LoadDiffCal::exec() { makeCalWorkspace(detids, difc, difa, tzero, dasids, offset, use); } +Parallel::ExecutionMode LoadDiffCal::getParallelExecutionMode( + const std::map<std::string, Parallel::StorageMode> &storageModes) const { + // There is an optional input workspace which may have + // StorageMode::Distributed but it is merely used for passing an instrument. + // Output should always have StorageMode::Cloned, so we run with + // ExecutionMode::Identical. + static_cast<void>(storageModes); + return Parallel::ExecutionMode::Identical; +} + } // namespace DataHandling } // namespace Mantid diff --git a/dev-docs/source/AlgorithmMPISupport.rst b/dev-docs/source/AlgorithmMPISupport.rst index 88820fb81b811917c6d830a47ddd75a914e37565..c804d54bccaaff8d4cd29bff54a4050c9d7de387 100644 --- a/dev-docs/source/AlgorithmMPISupport.rst +++ b/dev-docs/source/AlgorithmMPISupport.rst @@ -500,6 +500,7 @@ CloneWorkspace all Comment all CompareWorkspace MasterOnly, Identical if one input has ``StorageMode::Cloned`` and the other has ``StorageMode::MasterOnly`` then ``ExecutionMode::MasterOnly`` is used, with ``ExecutionMode::MasterOnly`` the workspaces always compare equal on non-master ranks CompressEvents all +ConvertDiffCal MasterOnly, Identical ConvertToHistogram all ConvertToPointData all ConvertUnits all ``AlignBins`` not supported; for indirect energy mode the number of resulting bins is in general inconsistent across MPI ranks @@ -529,8 +530,10 @@ Load all actual supported LoadAscii2 Identical see ``IFileLoader`` LoadAscii Identical see ``IFileLoader`` LoadBBY Identical see ``IFileLoader`` +LoadCalFile Identical LoadCanSAS1D Identical see ``IFileLoader`` LoadDaveGrp Identical see ``IFileLoader`` +LoadDiffCal Identical LoadEmptyInstrument Identical see ``IFileLoader`` LoadEventNexus Distributed storage mode of output cannot be changed via a parameter currently, min and max bin boundary are not globally the same LoadEventPreNexus2 Identical see ``IFileLoader``