Mantid
Loading...
Searching...
No Matches
ConvertHFIRSCDtoMDE.h
Go to the documentation of this file.
1// Mantid Repository : https://github.com/mantidproject/mantid
2//
3// Copyright © 2018 ISIS Rutherford Appleton Laboratory UKRI,
4// NScD Oak Ridge National Laboratory, European Spallation Source,
5// Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
6// SPDX - License - Identifier: GPL - 3.0 +
7#pragma once
8
13#include "MantidMDAlgorithms/DllConfig.h"
14
15#include <optional>
16#include <vector>
17
18namespace Mantid {
19namespace MDAlgorithms {
20
23class MANTID_MDALGORITHMS_DLL ConvertHFIRSCDtoMDE : public API::BoxControllerSettingsAlgorithm {
24public:
25 const std::string name() const override;
26 int version() const override;
27 const std::vector<std::string> seeAlso() const override { return {"ConvertWANDSCDtoQ", "LoadWANDSCD"}; }
28 const std::string category() const override;
29 const std::string summary() const override;
30 std::map<std::string, std::string> validateInputs() override;
31 bool checkGroups() override { return false; }
32
33private:
34 void init() override;
35 void exec() override;
36 std::string validateInputWorkspace(const API::IMDHistoWorkspace_sptr &inputWS) const;
37 API::IMDEventWorkspace_sptr convertWorkspace(const API::IMDHistoWorkspace_sptr &inputWS, double wavelength);
38 API::IMDEventWorkspace_sptr mergeWorkspaces(const std::vector<API::IMDEventWorkspace_sptr> &workspaces);
39 static std::vector<API::IMDHistoWorkspace_sptr> inputWorkspaceList(const API::Workspace_sptr &input);
40 static std::optional<double> fallbackWavelength(const std::vector<double> &wavelengths, size_t index);
41 double resolveWavelength(const API::IMDHistoWorkspace &inputWS, const std::optional<double> &fallback,
42 bool logChoice) const;
43};
44
45} // namespace MDAlgorithms
46} // namespace Mantid
std::string name
Definition Run.cpp:60
std::map< DeltaEMode::Type, std::string > index
An abstract algorithm sub-class for algorithms that define properties for BoxController settings.
Abstract interface to MDHistoWorkspace, for use in exposing to Python.
ConvertHFIRSCDtoMDE : TODO: DESCRIPTION.
const std::vector< std::string > seeAlso() const override
Function to return all of the seeAlso (these are not validated) algorithms related to this algorithm....
bool checkGroups() override
Check the input workspace properties for groups.
std::shared_ptr< IMDEventWorkspace > IMDEventWorkspace_sptr
Shared pointer to Mantid::API::IMDEventWorkspace.
std::shared_ptr< Workspace > Workspace_sptr
shared pointer to Mantid::API::Workspace
std::shared_ptr< IMDHistoWorkspace > IMDHistoWorkspace_sptr
shared pointer to Mantid::API::IMDHistoWorkspace
Helper class which provides the Collimation Length for SANS instruments.