23#include "MantidHistogramData/Histogram.h"
45using Types::Core::DateAndTime;
56 : m_eventWS(), m_splittersWorkspace(), m_splitterTableWorkspace(), m_matrixSplitterWS(), m_detCorrectWorkspace(),
57 m_targetWorkspaceIndexSet(), m_outputWorkspacesMap(), m_wsNames(), m_detTofOffsets(), m_detTofFactors(),
58 m_filterByPulseTime(false), m_informationWS(), m_hasInfoWS(), m_progress(0.), m_outputWSNameBase(),
59 m_toGroupWS(false), m_vecSplitterTime(), m_vecSplitterGroup(), m_tofCorrType(NoneCorrect), m_specSkipType(),
60 m_vecSkip(), m_isSplittersRelativeTime(false), m_filterStartTime(0) {}
69 std::string titleInputWksp(
"Input Workspaces");
72 "Input event workspace.");
76 "Input workspace specifying \"splitters\", i.e. time intervals and targets for InputWorkspace filtering.");
79 "RelativeTime",
false,
80 "Flag indicating whether in SplitterWorkspace the times are absolute or "
81 "relative. If true, they are relative to either the run start time or, if specified, FilterStartTime.");
84 "Optional information on each filtering target workspace.");
93 std::string titleOutputWksp(
"Output Workspaces");
96 "The base name to use for the output workspaces. An output workspace "
97 "name is a combination of this and the target specified in SplitterWorkspace. "
98 "For unfiltered events the workspace name will end with \"_unfiltered\".");
101 "If selected, the names of the output workspaces will include their time intervals.");
104 "An option to group all the output workspaces. The group name will be OutputWorkspaceBaseName.");
107 "If selected, the target index included in the output workspace name will be 1-based.");
111 "Name of the output workspace for TOF correction factor.");
121 std::string titleLogSplit(
"Sample Logs Splitting");
124 declareProperty(
"SplitSampleLogs",
true,
"DEPRECATED. All logs will be split.");
128 "If selected, events will be filtered by their pulse time as opposed to full time.");
131 "DEPRECATED. All logs will be split.");
134 declareProperty(
"ExcludeSpecifiedLogs",
true,
"DEPRECATED. All logs will be split.");
145 std::string titleAdditionalOptions(
"Additional Options");
147 auto dateTime = std::make_shared<DateTimeValidator>();
148 dateTime->allowEmpty(
true);
149 std::string absoluteHelp(
"Specify date and UTC time in ISO8601 format, e.g. 2010-09-14T04:20:12.");
151 "Absolute base time for relative times in SplitterWorkspace. " + absoluteHelp);
153 vector<string> corrtypes{
"None",
"Customized",
"Direct",
"Elastic",
"Indirect"};
154 declareProperty(
"CorrectionToSample",
"None", std::make_shared<StringListValidator>(corrtypes),
155 "Type of correction on neutron events to sample time from "
160 "Workspace containing the log time correction factor for each detector. ");
162 std::make_unique<VisibleWhenProperty>(
"CorrectionToSample",
IS_EQUAL_TO,
"Customized"));
164 auto mustBePositive = std::make_shared<BoundedValidator<double>>();
165 mustBePositive->setLower(0.0);
167 "Value of incident energy (Ei) in meV in direct mode.");
169 std::make_unique<VisibleWhenProperty>(
"CorrectionToSample",
IS_EQUAL_TO,
"Direct"));
172 vector<string> spec_no_det{
"Skip",
"Skip only if TOF correction"};
173 declareProperty(
"SpectrumWithoutDetector",
"Skip", std::make_shared<StringListValidator>(spec_no_det),
174 "Approach to deal with spectrum without detectors. ");
188 declareProperty(
"NumberOutputWS", 0,
"Number of output workspaces after splitting InputWorkspace. ",
192 "List of output workspace names.");
194 declareProperty(
"OutputUnfilteredEvents",
false,
"If selected, unfiltered events will be output.");
199 const std::string SPLITTER_PROP_NAME =
"SplitterWorkspace";
200 std::map<std::string, std::string> result;
205 if (
bool(std::dynamic_pointer_cast<const SplittersWorkspace>(splitter))) {
206 if (std::dynamic_pointer_cast<const SplittersWorkspace>(splitter)->rowCount() == 0)
207 result[SPLITTER_PROP_NAME] =
"SplittersWorkspace must have rows defined";
209 const auto table = std::dynamic_pointer_cast<const TableWorkspace>(splitter);
210 const auto matrix = std::dynamic_pointer_cast<const MatrixWorkspace>(splitter);
212 if (table->columnCount() != 3)
213 result[SPLITTER_PROP_NAME] =
"TableWorkspace must have 3 columns";
214 else if (table->rowCount() == 0)
215 result[SPLITTER_PROP_NAME] =
"TableWorkspace must have rows defined";
216 }
else if (
bool(matrix)) {
217 if (matrix->getNumberHistograms() == 1) {
218 if (!matrix->isHistogramData())
219 result[SPLITTER_PROP_NAME] =
"MatrixWorkspace must be histogram";
221 result[SPLITTER_PROP_NAME] =
"MatrixWorkspace can have only one histogram";
224 result[SPLITTER_PROP_NAME] =
"Incompatible workspace type";
229 if (correctiontype ==
"Direct") {
233 if (!inputWS->run().hasProperty(
"Ei")) {
234 const string msg(
"InputWorkspace does not have Ei. Must specify IncidentEnergy");
235 result[
"CorrectionToSample"] = msg;
236 result[
"IncidentEnergy"] = msg;
239 }
else if (correctiontype ==
"Customized") {
242 const string msg(
"Must specify correction workspace with CorrectionToSample=Custom");
243 result[
"CorrectionToSample"] = msg;
244 result[
"DetectorTOFCorrectionWorkspace"] = msg;
282 double progressamount;
284 progressamount = 0.6;
286 progressamount = 0.7;
290 const auto startTime = std::chrono::high_resolution_clock::now();
291 const auto sortType =
m_filterByPulseTime ? EventSortType::PULSETIME_SORT : EventSortType::PULSETIMETOF_SORT;
293 addTimer(
"sortEvents", startTime, std::chrono::high_resolution_clock::now());
307 ws_i->mutableRun().setGoniometer(gon,
true);
308 }
catch (std::runtime_error &) {
309 g_log.
warning(
"Cannot set goniometer to output workspace.");
314 std::vector<std::string> outputwsnames;
316 std::string ws_name = it.second->getName();
319 if (!ws_name.empty())
320 outputwsnames.emplace_back(ws_name);
322 setProperty(
"OutputWorkspaceNames", outputwsnames);
333 size_t numhist =
m_eventWS->getNumberHistograms();
339 g_log.
warning(
"By user's choice, No spectrum will be skipped even if it has no detector.");
343 size_t numskipspec = 0;
344 size_t numeventsskip = 0;
346 const auto &spectrumInfo =
m_eventWS->spectrumInfo();
347 for (
size_t i = 0; i < numhist; ++i) {
348 if (!spectrumInfo.hasDetectors(i)) {
355 if (numskipspec % 10 == 0)
362 if (numskipspec > 0) {
363 g_log.
warning() <<
"There are " << numskipspec <<
" spectra that do not have detectors. "
364 <<
"They will be skipped during filtering. There are total " << numeventsskip
365 <<
" events in those spectra. \nList of these specta is as below:\n"
366 << msgss.str() <<
"\n";
383 errss <<
"Inputworkspace is not event workspace. ";
385 throw std::invalid_argument(errss.str());
403 throw runtime_error(
"Input \"SplitterWorkspace\" has invalid workspace type.");
428 std::stringstream errss;
429 errss <<
"It is not allowed to group output workspaces into the same name "
430 "(i..e, OutputWorkspaceBaseName = "
432 throw std::invalid_argument(errss.str());
440 if (correctiontype ==
"None")
442 else if (correctiontype ==
"Customized")
444 else if (correctiontype ==
"Direct")
446 else if (correctiontype ==
"Elastic")
448 else if (correctiontype ==
"Indirect")
451 g_log.
error() <<
"Correction type '" << correctiontype <<
"' is not supported. \n";
452 throw runtime_error(
"Impossible situation!");
457 if (skipappr ==
"Skip")
459 else if (skipappr ==
"Skip only if TOF correction")
462 throw runtime_error(
"An unrecognized option for SpectrumWithoutDetector");
465 std::string filter_start_time_str =
472 }
catch (std::runtime_error &) {
473 throw std::runtime_error(
474 "InputWorkspace doesn't have valid run start time set, and FilterStartTime is not specified.");
481 bool splitSampleLogs =
getProperty(
"SplitSampleLogs");
482 if (splitSampleLogs ==
false)
483 g_log.
warning() <<
"Option SplitSampleLogs is deprecated and ignored. All logs will be split.\n";
485 std::vector<std::string> timeSeriesPropertyLogs =
getProperty(
"TimeSeriesPropertyLogs");
486 if (!timeSeriesPropertyLogs.empty())
487 g_log.
warning() <<
"Options TimeSeriesPropertyLogs and ExcludeSpecifiedLogs are deprecated and ignored. "
488 "All logs will be split.\n";
504 groupws->setAlwaysStoreInADS(
true);
505 groupws->setProperty(
"InputWorkspaces",
m_wsNames);
506 groupws->setProperty(
"OutputWorkspace", groupname);
508 if (!groupws->isExecuted()) {
509 g_log.
error(
"Grouping all output workspaces fails.");
517 "Name of the workspace to be created as the output of grouping ");
522 if (!workspace_group) {
523 g_log.
error(
"Unable to retrieve output workspace from algorithm GroupWorkspaces");
546 const auto firstSplitter = splittingBoundaries.begin();
551 const auto lastSplitter = std::prev(splittingBoundaries.end());
554 throw std::runtime_error(
"FilterEvents::partialROI: the last splitter boundary must be TimeSplitter::NO_TARGET");
556 if (lastSplitter->first <
m_eventWS->run().endTime())
557 roi.addROI(lastSplitter->first,
m_eventWS->run().endTime());
589 const auto startTimeCreateWS = std::chrono::high_resolution_clock::now();
592 constexpr size_t min_expected_number_of_indexes = 2;
594 g_log.
warning(
"No output workspaces specified by input workspace.");
599 std::map<int, std::string> infomap;
603 g_log.
warning() <<
"Input Splitters Workspace specifies a different number of unique output workspaces ("
605 <<
") compared to the number of rows in the input information workspace ("
607 <<
" Information may not be accurate. \n";
612 infomap.emplace(row.
Int(0), row.
String(1));
617 int delta_wsindex{0};
621 g_log.
debug() <<
"Minimum target workspace index = " << min_wsindex <<
"\n";
622 delta_wsindex = 1 - min_wsindex;
628 bool descriptiveNames =
getProperty(
"DescriptiveOutputNames");
629 bool splitByTime =
true;
630 if (descriptiveNames) {
631 if (
m_hasInfoWS && infomap[0].find(
"Log") != std::string::npos) {
637 std::shared_ptr<EventWorkspace> templateWorkspace = create<EventWorkspace>(*
m_eventWS);
638 templateWorkspace->setSharedRun(Kernel::make_cow<Run>());
639 templateWorkspace->clearMRU();
640 templateWorkspace->switchEventType(
m_eventWS->getEventType());
643 size_t number_of_output_workspaces{0};
644 double progress_step_total =
646 double progress_step_current{0.};
647 const auto originalROI =
m_eventWS->run().getTimeROI();
648 const bool outputUnfiltered =
getProperty(
"OutputUnfilteredEvents");
651 bool add2output =
true;
652 std::stringstream wsname;
655 if (descriptiveNames && splitByTime) {
658 for (
size_t ii = 0; ii < timeIntervals.size(); ii++) {
659 auto startTimeInSeconds =
660 Mantid::Types::Core::DateAndTime::secondsFromDuration(timeIntervals[ii].start() -
m_filterStartTime);
661 auto stopTimeInSeconds =
662 Mantid::Types::Core::DateAndTime::secondsFromDuration(timeIntervals[ii].stop() -
m_filterStartTime);
663 wsname << startTimeInSeconds <<
"_" << stopTimeInSeconds;
664 if (ii < timeIntervals.size() - 1)
667 }
else if (descriptiveNames) {
668 auto infoiter = infomap.find(wsindex);
669 if (infoiter != infomap.end()) {
670 std::string nameFromMap = infoiter->second;
672 wsname << nameFromMap;
680 wsname <<
"unfiltered";
681 if (!outputUnfiltered)
687 std::shared_ptr<EventWorkspace> optws = templateWorkspace->clone();
696 info =
"Events that are filtered out. ";
698 std::map<int, std::string>::iterator infoiter;
699 infoiter = infomap.find(wsindex);
700 if (infoiter != infomap.end()) {
701 info = infoiter->second;
703 info =
"This workspace has no information provided. ";
706 optws->setComment(info);
707 optws->setTitle(info);
716 std::stringstream outputWorkspacePropertyName;
718 outputWorkspacePropertyName <<
"OutputWorkspace_unfiltered";
720 outputWorkspacePropertyName <<
"OutputWorkspace_" << wsindex;
727 AnalysisDataService::Instance().addOrReplace(wsname.str(), optws);
736 setProperty(outputWorkspacePropertyName.str(), optws);
737 g_log.
debug() <<
"Created output property " << outputWorkspacePropertyName.str()
738 <<
" for workspace with target index " << wsindex << std::endl;
741 ++number_of_output_workspaces;
742 g_log.
debug() <<
"Created output Workspace with target index = " << wsindex << std::endl;
745 m_progress = 0.1 + 0.1 * progress_step_current / progress_step_total;
747 progress_step_current += 1.;
751 addTimer(
"createOutputWorkspaces", startTimeCreateWS, std::chrono::high_resolution_clock::now());
754 templateWorkspace.reset();
757 const auto startTimeLogs = std::chrono::high_resolution_clock::now();
764 outputIter.second->mutableRun().copyAndFilterProperties(
m_eventWS->run(), roi);
766 addTimer(
"copyLogs", startTimeLogs, std::chrono::high_resolution_clock::now());
768 setProperty(
"NumberOutputWS",
static_cast<int>(number_of_output_workspaces));
782 const size_t numhist =
m_eventWS->getNumberHistograms();
784 setProperty(
"OutputTOFCorrectionWorkspace", corrws);
791 std::unique_ptr<API::TimeAtSampleStrategy> strategy;
806 for (
size_t i = 0; i < numhist; ++i) {
809 Correction correction = strategy->calculate(i);
813 corrws->mutableY(i)[0] = correction.
factor;
814 corrws->mutableY(i)[1] = correction.
offset;
830 if (
m_eventWS->run().hasProperty(
"Ei")) {
831 ei =
m_eventWS->run().getLogAsSingleValue(
"Ei");
832 g_log.
debug() <<
"Using stored Ei value " << ei <<
"\n";
834 throw std::invalid_argument(
"No Ei value has been set or stored within the run information.");
837 g_log.
debug() <<
"Using user-input Ei value " << ei <<
"\n";
858 bool hasshift =
false;
859 if (colnames.size() < 2)
860 throw runtime_error(
"Input table workspace is not valide.");
861 else if (colnames.size() >= 3)
865 if (colnames[0] ==
"DetectorID")
867 else if (colnames[0] ==
"Spectrum")
871 errss <<
"First column must be either DetectorID or Spectrum. " << colnames[0] <<
" is not supported. ";
872 throw runtime_error(errss.str());
877 map<detid_t, double> toffactormap;
878 map<detid_t, double> tofshiftmap;
880 for (
size_t i = 0; i < numrows; ++i) {
885 double offset_factor;
886 row >> detid >> offset_factor;
887 if (offset_factor >= 0 && offset_factor <= 1) {
889 toffactormap.emplace(detid, offset_factor);
893 errss <<
"Correction (i.e., offset) equal to " << offset_factor <<
" of row "
894 <<
"is out of range [0, 1].";
895 throw runtime_error(errss.str());
902 tofshiftmap.emplace(detid, shift);
907 size_t numhist =
m_eventWS->getNumberHistograms();
908 if (toffactormap.size() > numhist) {
909 g_log.
warning() <<
"Input correction table workspace has more detectors (" << toffactormap.size()
910 <<
") than input workspace " <<
m_eventWS->getName() <<
"'s spectra number (" << numhist <<
".\n";
911 }
else if (toffactormap.size() < numhist) {
913 errss <<
"Input correction table workspace has more detectors (" << toffactormap.size() <<
") than input workspace "
914 <<
m_eventWS->getName() <<
"'s spectra number (" << numhist <<
".\n";
915 throw runtime_error(errss.str());
921 vector<detid_t> vecDetIDs(numhist, 0);
923 for (
size_t i = 0; i < numhist; ++i) {
929 if (detids.size() != 1) {
932 errss <<
"The assumption is that one spectrum has one and only one "
934 <<
"Error is found at spectrum " << i <<
". It has " << detids.size() <<
" detectors.";
935 throw runtime_error(errss.str());
937 vecDetIDs[i] = *detids.begin();
941 map<detid_t, double>::iterator fiter;
942 for (
size_t i = 0; i < numhist; ++i) {
945 fiter = toffactormap.find(detid);
946 if (fiter != toffactormap.end())
951 <<
"w/ ID << " << detid <<
" of spectrum " << i <<
" in Eventworkspace " <<
m_eventWS->getName()
952 <<
" cannot be found in input TOF calibration workspace. ";
953 throw runtime_error(errss.str());
956 fiter = tofshiftmap.find(detid);
957 if (fiter != tofshiftmap.end())
962 map<detid_t, double>::iterator fiter;
964 for (fiter = toffactormap.begin(); fiter != toffactormap.end(); ++fiter) {
965 auto wsindex =
static_cast<size_t>(fiter->first);
966 if (wsindex < numhist)
970 errss <<
"Workspace index " << wsindex <<
" is out of range.";
971 throw runtime_error(errss.str());
975 for (fiter = tofshiftmap.begin(); fiter != tofshiftmap.end(); ++fiter) {
976 auto wsindex =
static_cast<size_t>(fiter->first);
977 if (wsindex < numhist)
981 errss <<
"Workspace index " << wsindex <<
" is out of range.";
982 throw runtime_error(errss.str());
991 const auto startTime = std::chrono::high_resolution_clock::now();
992 size_t numberOfSpectra =
m_eventWS->getNumberHistograms();
993 g_log.
debug() <<
"Number of spectra in input/source EventWorkspace = " << numberOfSpectra <<
".\n";
996 for (int64_t iws = 0; iws < int64_t(numberOfSpectra); ++iws) {
1000 if (!inputEventList.
empty()) {
1001 std::map<int, DataObjects::EventList *> partialEvenLists;
1003 const int index = ws.first;
1004 auto &partialEventList = ws.second->getSpectrum(iws);
1005 partialEvenLists.emplace(
index, &partialEventList);
1014 progress(0.1 + progressamount,
"Splitting logs");
1015 addTimer(
"filterEventsMethod", startTime, std::chrono::high_resolution_clock::now());
#define DECLARE_ALGORITHM(classname)
std::map< DeltaEMode::Type, std::string > index
#define PARALLEL_START_INTERRUPT_REGION
Begins a block to skip processing is the algorithm has been interupted Note the end of the block if n...
#define PARALLEL_FOR_NO_WSP_CHECK()
#define PARALLEL_END_INTERRUPT_REGION
Ends a block to skip processing is the algorithm has been interupted Note the start of the block if n...
#define PARALLEL_CHECK_INTERRUPT_REGION
Adds a check after a Parallel region to see if it was interupted.
void declareProperty(std::unique_ptr< Kernel::Property > p, const std::string &doc="") override
Add a property to the list of managed properties.
bool existsProperty(const std::string &name) const override
Checks whether the named property is already in the list of managed property.
std::string getPropertyValue(const std::string &name) const override
Get the value of a property as a string.
TypedValue getProperty(const std::string &name) const override
Get the value of a property.
virtual std::shared_ptr< Algorithm > createChildAlgorithm(const std::string &name, const double startProgress=-1., const double endProgress=-1., const bool enableLogging=true, const int &version=-1)
Create a Child Algorithm.
void progress(double p, const std::string &msg="", double estimatedTime=0.0, int progressPrecision=0)
Sends ProgressNotification.
bool isDefault(const std::string &name) const
static bool isEmpty(const NumT toCheck)
checks that the value was not set by users, uses the value in empty double/int.
void addTimer(const std::string &name, const Kernel::time_point_ns &begin, const Kernel::time_point_ns &end)
The Analysis data service stores instances of the Workspace objects and anything that derives from te...
const std::set< detid_t > & getDetectorIDs() const
Get a const reference to the detector IDs set.
TableRow represents a row in a TableWorkspace.
std::string & String(size_t col)
Returns a reference to the element in position col if its type is std::string.
int & Int(size_t col)
Returns a reference to the element in position col if its type is int.
TimeAtSampleStrategyDirect : Determine the Time at Sample corrections for a Direct Geometry instrumen...
TimeAtSampleStrategyElastic : Time at sample stragegy for elastic scattering.
TimeAtSampleStrategyIndirect : Determine Time At Sample for an indirect instrument setup.
TimeAtSampleStrategy : Strategy (technique dependent) for determining Time At Sample.
A property class for workspaces.
FilterEvents : Filter Events in EventWorkspace to multiple EventsWorkspace by Splitters.
Kernel::TimeROI partialROI(const int &index)
Find the TimeROI associated to a particular destination-workspace index.
std::vector< std::string > m_wsNames
bool m_isSplittersRelativeTime
void processAlgorithmProperties()
Process user input properties.
DataObjects::SplittersWorkspace_sptr m_splittersWorkspace
std::vector< double > m_detTofOffsets
std::vector< bool > m_vecSkip
Vector for skip information.
API::TimeAtSampleStrategy * setupDirectTOFCorrection() const
Set up detector calibration parmaeters for direct inelastic scattering instrument.
DataObjects::TimeSplitter m_timeSplitter
std::vector< double > m_detTofFactors
Types::Core::DateAndTime m_filterStartTime
bool m_toGroupWS
Flag to group workspace.
std::set< int > m_targetWorkspaceIndexSet
std::map< int, DataObjects::EventWorkspace_sptr > m_outputWorkspacesMap
void examineEventWS()
Mark event lists of workspace indexes with no associated detector pixels as not to be split.
API::TimeAtSampleStrategy * setupElasticTOFCorrection() const
Set up detector calibration parameters for elastic scattering instrument.
void exec() override
Execution body.
void groupOutputWorkspace()
group output workspaces
void setupDetectorTOFCalibration()
Set up detector calibration parameters.
void filterEvents(double progressamount)
Filter events by splitters in format of Splitter.
void setupCustomizedTOFCorrection()
Set up detector calibration parameters from customized values.
std::string m_outputWSNameBase
Base of output workspace's name.
@ EventFilterSkipNoDetTOFCorr
EVENTFILTERSKIP m_specSkipType
Spectrum skip type.
std::map< std::string, std::string > validateInputs() override
Method checking errors on ALL the inputs, before execution.
DataObjects::TableWorkspace_sptr m_informationWS
TOFCorrectionType m_tofCorrType
TOF detector/sample correction type.
DataObjects::TableWorkspace_sptr m_detCorrectWorkspace
API::TimeAtSampleStrategy * setupIndirectTOFCorrection() const
Set up detector calibration parameters for indirect inelastic scattering instrument.
DataObjects::EventWorkspace_sptr m_eventWS
API::MatrixWorkspace_sptr m_matrixSplitterWS
void parseInputSplitters()
process splitters specified by an input workspace
DataObjects::TableWorkspace_sptr m_splitterTableWorkspace
void createOutputWorkspaces()
create output workspaces
void init() override
Declare Inputs.
std::size_t getNumberEvents() const override
Return the number of events in the list.
bool empty() const
Much like stl containers, returns true if there is nothing in the event list.
const Kernel::TimeROI & getTimeROI(const int workspaceIndex) const
Returns a TimeROI for the requested workspace index.
const std::map< DateAndTime, int > & getSplittersMap() const
std::set< int > outputWorkspaceIndices() const
Return a set of the output workspace indices.
static constexpr int NO_TARGET
std::string getWorkspaceIndexName(const int workspaceIndex, const int numericalShift=0) const
void splitEventList(const EventList &events, std::map< int, EventList * > &partials, const bool pulseTof=false, const bool tofCorrect=false, const double factor=1.0, const double shift=0.0) const
Split a list of events according to Pulse time or Pulse + TOF time.
Class to represent a particular goniometer setting, which is described by the rotation matrix.
Support for a property that holds an array of values.
std::shared_ptr< T > retrieve(const std::string &name) const
Get a shared pointer to a stored data object.
IPropertyManager * setProperty(const std::string &name, const T &value)
Templated method to set the value of a PropertyWithValue.
void setPropertySettings(const std::string &name, std::unique_ptr< IPropertySettings > settings)
void setPropertyGroup(const std::string &name, const std::string &group)
Set the group for a given property.
void debug(const std::string &msg)
Logs at debug level.
void notice(const std::string &msg)
Logs at notice level.
void error(const std::string &msg)
Logs at error level.
void warning(const std::string &msg)
Logs at warning level.
void information(const std::string &msg)
Logs at information level.
TimeROI : Object that holds information about when the time measurement was active.
const std::vector< Kernel::TimeInterval > toTimeIntervals() const
This method is to lend itself to helping with transition.
void update_or_replace_intersection(const TimeROI &other)
If this is empty, replace it with the supplied TimeROI, otherwise calculate the intersection.
std::shared_ptr< WorkspaceGroup > WorkspaceGroup_sptr
shared pointer to Mantid::API::WorkspaceGroup
std::shared_ptr< Workspace > Workspace_sptr
shared pointer to Mantid::API::Workspace
std::shared_ptr< const Workspace > Workspace_const_sptr
shared pointer to Mantid::API::Workspace (const version)
std::shared_ptr< MatrixWorkspace > MatrixWorkspace_sptr
shared pointer to the matrix workspace base class
std::shared_ptr< const EventWorkspace > EventWorkspace_const_sptr
shared pointer to a const Workspace2D
std::shared_ptr< const TableWorkspace > TableWorkspace_const_sptr
shared pointer to Mantid::DataObjects::TableWorkspace (const version)
std::shared_ptr< EventWorkspace > EventWorkspace_sptr
shared pointer to the EventWorkspace class
MANTID_KERNEL_DLL std::string removeSpace(const std::string &CLine)
strip all spaces
Helper class which provides the Collimation Length for SANS instruments.
constexpr int EMPTY_INT() noexcept
Returns what we consider an "empty" integer within a property.
int32_t detid_t
Typedef for a detector ID.
constexpr double EMPTY_DBL() noexcept
Returns what we consider an "empty" double within a property.
The Correction struct to be applied as factor * TOF + offset multiplicativeFactor: TOF correction fac...
@ Input
An input workspace.
@ Output
An output workspace.