From cca03cc2c77e0d6794097dd21d8eddbf504f237c Mon Sep 17 00:00:00 2001 From: Pete Peterson Date: Tue, 8 Apr 2014 13:27:44 -0400 Subject: [PATCH 001/126] Re #9266. Making removeProperty public --- .../Framework/Kernel/inc/MantidKernel/IPropertyManager.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Code/Mantid/Framework/Kernel/inc/MantidKernel/IPropertyManager.h b/Code/Mantid/Framework/Kernel/inc/MantidKernel/IPropertyManager.h index 35872be12b24..6471493ec615 100644 --- a/Code/Mantid/Framework/Kernel/inc/MantidKernel/IPropertyManager.h +++ b/Code/Mantid/Framework/Kernel/inc/MantidKernel/IPropertyManager.h @@ -63,6 +63,9 @@ class MANTID_KERNEL_DLL IPropertyManager /// Function to declare properties (i.e. store them) virtual void declareProperty(Property *p, const std::string &doc="" ) = 0; + /// Removes the property from management + virtual void removeProperty(const std::string &name, const bool delproperty=true) = 0; + /** Sets all the declared properties from a string. @param propertiesArray :: A list of name = value pairs separated by a semicolon */ @@ -268,8 +271,6 @@ class MANTID_KERNEL_DLL IPropertyManager template T getValue(const std::string &name) const; - /// Removes the property from management - virtual void removeProperty(const std::string &name, const bool delproperty=true) = 0; /// Clears all properties under management virtual void clear() = 0; /// Override this method to perform a custom action right after a property was set. From aff23fe5c043105afae39567f668c17f2623ea52 Mon Sep 17 00:00:00 2001 From: Pete Peterson Date: Wed, 9 Apr 2014 08:30:44 -0400 Subject: [PATCH 002/126] Re #9266. Filling in features of PyDict in IPropertyManager. --- .../kernel/src/Exports/IPropertyManager.cpp | 82 ++++++++++++++++++- .../kernel/src/Exports/PropertyManager.cpp | 82 +------------------ 2 files changed, 83 insertions(+), 81 deletions(-) diff --git a/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/IPropertyManager.cpp b/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/IPropertyManager.cpp index 8da73daa0aec..79f74a93d5f8 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/IPropertyManager.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/IPropertyManager.cpp @@ -1,10 +1,14 @@ #include "MantidKernel/IPropertyManager.h" #include "MantidPythonInterface/kernel/Registry/TypeRegistry.h" #include "MantidPythonInterface/kernel/Registry/PropertyValueHandler.h" +#include "MantidPythonInterface/kernel/Registry/PropertyWithValueFactory.h" #include -#include #include +#include +#include +#include +#include using namespace Mantid::Kernel; namespace Registry = Mantid::PythonInterface::Registry; @@ -41,6 +45,42 @@ namespace } } + /** + * Create a new property from the value within the boost::python object + * It is equivalent to a python method that starts with 'self' + * @param self :: A reference to the calling object + * @param name :: The name of the property + * @param value :: The value of the property as a bpl object + */ + void declareProperty(IPropertyManager &self, const std::string & name, + boost::python::object value) + { + Mantid::Kernel::Property *p = Registry::PropertyWithValueFactory::create(name, value, 0); + self.declareProperty(p); + } + + /** + * Create or set a property from the value within the boost::python object + * It is equivalent to a python method that starts with 'self' and allows + * python dictionary type usage. + * @param self :: A reference to the calling object + * @param name :: The name of the property + * @param value :: The value of the property as a bpl object + */ + void declareOrSetProperty(IPropertyManager &self, const std::string & name, + boost::python::object value) + { + bool propExists = self.existsProperty(name); + if (propExists) + { + setProperty(self, name, value); + } + else + { + declareProperty(self, name, value); + } + } + /** * Clones the given settingsManager and passes it on to the calling object as it takes ownership * of the IPropertySettings object @@ -53,6 +93,31 @@ namespace { self.setPropertySettings(propName, settingsManager->clone()); } + + void deleteProperty(IPropertyManager &self, const std::string & propName) + { + self.removeProperty(propName); + } + + /** + * Return a PyList of all the keys in the IPropertyManager. + * @param self The calling object + * @return The list of keys. + */ + boost::python::list getKeys(IPropertyManager &self) + { + const std::vector< Property*>& props = self.getProperties(); + const size_t numProps = props.size(); + + boost::python::list result; + for (size_t i = 0; i < numProps; ++i) + { + result.append(props[i]->name()); + } + + return result; + } + } void export_IPropertyManager() @@ -71,6 +136,8 @@ void export_IPropertyManager() .def("getProperties", &IPropertyManager::getProperties, return_value_policy(), "Returns the list of properties managed by this object") + .def("declareProperty", &declareProperty, "Create a new named property") + .def("setPropertyValue", &IPropertyManager::setPropertyValue, "Set the value of the named property via a string") @@ -84,10 +151,19 @@ void export_IPropertyManager() .def("existsProperty", &IPropertyManager::existsProperty, "Returns whether a property exists") - // Special methods so that IPropertyManager acts like a dictionary + // Special methods so that IPropertyManager acts like a dictionary + // __len__, __getitem__, __setitem__, __delitem__, __iter__ and __contains__ .def("__len__", &IPropertyManager::propertyCount) + .def("__getitem__", &IPropertyManager::getPointerToProperty, return_value_policy()) + .def("__setitem__", &declareOrSetProperty) + .def("__delitem__", &deleteProperty) + // TODO .def("__iter__", iterator > ()) .def("__contains__", &IPropertyManager::existsProperty) - .def("__getitem__", &IPropertyManager::getProperty) + + // Bonus methods to be even more like a dict + .def("has_key", &IPropertyManager::existsProperty) + .def("keys", &getKeys) + .def("values", &IPropertyManager::getProperties, return_value_policy()) ; } diff --git a/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/PropertyManager.cpp b/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/PropertyManager.cpp index a10f31c142e3..f958225431e2 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/PropertyManager.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/PropertyManager.cpp @@ -9,10 +9,13 @@ #include "MantidPythonInterface/kernel/Registry/PropertyWithValueFactory.h" #include +#include +#include #include #include using Mantid::Kernel::IPropertyManager; +using Mantid::Kernel::Property; using Mantid::Kernel::PropertyManager; namespace Registry = Mantid::PythonInterface::Registry; @@ -20,91 +23,14 @@ using namespace boost::python; namespace { - /** - * Set the value of a property from the value within the - * boost::python object - * It is equivalent to a python method that starts with 'self' - * @param self :: A reference to the calling object - * @param name :: The name of the property - * @param value :: The value of the property as a bpl object - */ - void setProperty(PropertyManager &self, const std::string & name, - boost::python::object value) - { - if( PyString_Check(value.ptr()) ) // String values can be set directly - { - self.setPropertyValue(name, boost::python::extract(value)); - } - else - { - try { - Mantid::Kernel::Property *p = self.getProperty(name); - const auto & entry = Registry::TypeRegistry::retrieve(*(p->type_info())); - entry.set(&self, name, value); - } - catch (std::invalid_argument &e) - { - throw std::invalid_argument("When converting parameter \"" + name + "\": " + e.what()); - } - } - } - /** - * Create a new property from the value within the boost::python object - * It is equivalent to a python method that starts with 'self' - * @param self :: A reference to the calling object - * @param name :: The name of the property - * @param value :: The value of the property as a bpl object - */ - void declareProperty(PropertyManager &self, const std::string & name, - boost::python::object value) - { - Mantid::Kernel::Property *p = Registry::PropertyWithValueFactory::create(name, value, 0); - self.declareProperty(p); - } - - /** - * Create or set a property from the value within the boost::python object - * It is equivalent to a python method that starts with 'self' and allows - * python dictionary type usage. - * @param self :: A reference to the calling object - * @param name :: The name of the property - * @param value :: The value of the property as a bpl object - */ - void declareOrSetProperty(PropertyManager &self, const std::string & name, - boost::python::object value) - { - bool propExists = self.existsProperty(name); - if (propExists) - { - setProperty(self, name, value); - } - else - { - declareProperty(self, name, value); - } - } } void export_PropertyManager() { register_ptr_to_python>(); class_, boost::noncopyable>("PropertyManager") - .def("propertyCount", &PropertyManager::propertyCount, "Returns the number of properties being managed") - .def("getPropertyValue", &PropertyManager::getPropertyValue, - "Returns a string representation of the named property's value") - .def("getProperties", &PropertyManager::getProperties, return_value_policy(), - "Returns the list of properties managed by this object") - .def("setPropertyValue", &PropertyManager::setPropertyValue, - "Set the value of the named property via a string") - .def("setProperty", &setProperty, "Set the value of the named property") - .def("declareProperty", &declareProperty, "Create a new named property") - // Special methods to act like a dictionary - .def("__len__", &PropertyManager::propertyCount) - .def("__contains__", &PropertyManager::existsProperty) - .def("__setitem__", &declareOrSetProperty) - ; - + ; } #ifdef _MSC_VER From 0e9d0da7826380b6521e4571e4cf25577903d765 Mon Sep 17 00:00:00 2001 From: Pete Peterson Date: Wed, 9 Apr 2014 08:31:27 -0400 Subject: [PATCH 003/126] Re #9266. Adding unit test for PropertyManager python binding. --- .../test/python/mantid/kernel/CMakeLists.txt | 1 + .../mantid/kernel/PropertyManagerTest.py | 66 +++++++++++++++++++ 2 files changed, 67 insertions(+) create mode 100644 Code/Mantid/Framework/PythonInterface/test/python/mantid/kernel/PropertyManagerTest.py diff --git a/Code/Mantid/Framework/PythonInterface/test/python/mantid/kernel/CMakeLists.txt b/Code/Mantid/Framework/PythonInterface/test/python/mantid/kernel/CMakeLists.txt index f0295f188230..cd58f5d155ae 100644 --- a/Code/Mantid/Framework/PythonInterface/test/python/mantid/kernel/CMakeLists.txt +++ b/Code/Mantid/Framework/PythonInterface/test/python/mantid/kernel/CMakeLists.txt @@ -23,6 +23,7 @@ set ( TEST_PY_FILES NullValidatorTest.py ProgressBaseTest.py PropertyWithValueTest.py + PropertyManagerTest.py PythonPluginsTest.py StatisticsTest.py TimeSeriesPropertyTest.py diff --git a/Code/Mantid/Framework/PythonInterface/test/python/mantid/kernel/PropertyManagerTest.py b/Code/Mantid/Framework/PythonInterface/test/python/mantid/kernel/PropertyManagerTest.py new file mode 100644 index 000000000000..84395d2b98aa --- /dev/null +++ b/Code/Mantid/Framework/PythonInterface/test/python/mantid/kernel/PropertyManagerTest.py @@ -0,0 +1,66 @@ +import unittest +from mantid.kernel import PropertyManager, IPropertyManager + +class PropertyManagerTest(unittest.TestCase): + def test_propertymanager(self): + manager = PropertyManager() + + # check that it is empty + self.assertEquals(manager.__len__(), 0) + self.assertEquals(len(manager), 0) + + # add some values + manager["f"] = 1. + manager["i"] = 2 + manager["s"] = "3" + + self.assertEquals(len(manager), 3) + self.assertEquals(manager.propertyCount(), 3) + + # confirm they are in there + self.assertTrue("f" in manager) + self.assertTrue("i" in manager) + self.assertTrue("s" in manager) + self.assertFalse("nonsense" in manager) + + # check string return values + self.assertEquals(manager.getPropertyValue("f"), "1") + self.assertEquals(manager.getPropertyValue("i"), "2") + self.assertEquals(manager.getPropertyValue("s"), "3") + + # check actual values + self.assertEquals(manager.getProperty("f").value, 1.) + self.assertEquals(manager.getProperty("i").value, 2) + self.assertEquals(manager.getProperty("s").value, "3") + + # ...and accessing them through dict interface + self.assertEquals(manager["f"].value, 1.) + self.assertEquals(manager["i"].value, 2) + self.assertEquals(manager["s"].value, "3") + + # see that you can get keys and values + self.assertTrue(len(manager.values()), 3) + keys = manager.keys() + self.assertEquals(len(keys), 3) + self.assertTrue("f" in keys) + self.assertTrue("i" in keys) + self.assertTrue("s" in keys) + + # check for members + self.assertTrue(manager.has_key("f")) + self.assertTrue(manager.has_key("i")) + self.assertTrue(manager.has_key("s")) + self.assertFalse(manager.has_key("q")) + + self.assertTrue("f" in manager) + self.assertTrue("i" in manager) + self.assertTrue("s" in manager) + self.assertFalse("q" in manager) + + # check for delete + self.assertTrue(len(manager), 3) + del manager["f"] + self.assertTrue(len(manager), 2) + +if __name__ == "__main__": + unittest.main() From 5e81182dd39de646681292767be7ef24450ceb7d Mon Sep 17 00:00:00 2001 From: Pete Peterson Date: Wed, 9 Apr 2014 10:07:19 -0400 Subject: [PATCH 004/126] Re #9266. Adding docstrings to all of the python methods. --- .../kernel/src/Exports/IPropertyManager.cpp | 53 ++++++++++++------- 1 file changed, 34 insertions(+), 19 deletions(-) diff --git a/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/IPropertyManager.cpp b/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/IPropertyManager.cpp index 79f74a93d5f8..d40c6cb68a6f 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/IPropertyManager.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/kernel/src/Exports/IPropertyManager.cpp @@ -125,45 +125,60 @@ void export_IPropertyManager() register_ptr_to_python(); class_("IPropertyManager", no_init) - .def("propertyCount", &IPropertyManager::propertyCount, "Returns the number of properties being managed") + .def("propertyCount", &IPropertyManager::propertyCount, args("self"), + "Returns the number of properties being managed") - .def("getProperty", &IPropertyManager::getPointerToProperty, return_value_policy(), - "Returns the property of the given name. Use .value to give the value") + .def("getProperty", &IPropertyManager::getPointerToProperty, args("self", "name"), + return_value_policy(), + "Returns the property of the given name. Use .value to give the value") - .def("getPropertyValue", &IPropertyManager::getPropertyValue, + .def("getPropertyValue", &IPropertyManager::getPropertyValue, args("self", "name"), "Returns a string representation of the named property's value") - .def("getProperties", &IPropertyManager::getProperties, return_value_policy(), + .def("getProperties", &IPropertyManager::getProperties, args("self"), + return_value_policy(), "Returns the list of properties managed by this object") - .def("declareProperty", &declareProperty, "Create a new named property") + .def("declareProperty", &declareProperty, args("self", "name", "value"), + "Create a new named property") - .def("setPropertyValue", &IPropertyManager::setPropertyValue, + .def("setPropertyValue", &IPropertyManager::setPropertyValue, args("self", "name", "value"), "Set the value of the named property via a string") - .def("setProperty", &setProperty, "Set the value of the named property") + .def("setProperty", &setProperty, args("self", "name", "value"), + "Set the value of the named property") - .def("setPropertySettings", &setPropertySettings, + .def("setPropertySettings", &setPropertySettings, args("self", "name", "settingsManager"), "Assign the given IPropertySettings object to the named property") - .def("setPropertyGroup", &IPropertyManager::setPropertyGroup, "Set the group for a given property") + .def("setPropertyGroup", &IPropertyManager::setPropertyGroup, args("self", "name", "group"), + "Set the group for a given property") - .def("existsProperty", &IPropertyManager::existsProperty, + .def("existsProperty", &IPropertyManager::existsProperty, args("self", "name"), "Returns whether a property exists") // Special methods so that IPropertyManager acts like a dictionary // __len__, __getitem__, __setitem__, __delitem__, __iter__ and __contains__ - .def("__len__", &IPropertyManager::propertyCount) - .def("__getitem__", &IPropertyManager::getPointerToProperty, return_value_policy()) - .def("__setitem__", &declareOrSetProperty) - .def("__delitem__", &deleteProperty) + .def("__len__", &IPropertyManager::propertyCount, args("self"), + "Returns the number of properties being managed") + .def("__getitem__", &IPropertyManager::getPointerToProperty, args("self", "name"), + return_value_policy(), + "Returns the property of the given name. Use .value to give the value") + .def("__setitem__", &declareOrSetProperty, args("self", "name", "value"), + "Set the value of the named property or create it if it doesn't exist") + .def("__delitem__", &deleteProperty, args("self", "name"), + "Delete the named property") // TODO .def("__iter__", iterator > ()) - .def("__contains__", &IPropertyManager::existsProperty) + .def("__contains__", &IPropertyManager::existsProperty, args("self", "name"), + "Returns whether a property exists") // Bonus methods to be even more like a dict - .def("has_key", &IPropertyManager::existsProperty) - .def("keys", &getKeys) - .def("values", &IPropertyManager::getProperties, return_value_policy()) + .def("has_key", &IPropertyManager::existsProperty, args("self", "name"), + "Returns whether a property exists") + .def("keys", &getKeys, args("self")) + .def("values", &IPropertyManager::getProperties, args("self"), + return_value_policy(), + "Returns the list of properties managed by this object") ; } From 3a1e2a63a7cd1b0f7feaa9b033e56c1be73c1078 Mon Sep 17 00:00:00 2001 From: Wenduo Zhou Date: Wed, 16 Apr 2014 22:01:59 -0400 Subject: [PATCH 005/126] Added show hide to properties. Refs #6999. --- .../Algorithms/src/GenerateEventsFilter.cpp | 20 ++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp b/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp index 8da0697a4830..6bf4de2af6bf 100644 --- a/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp @@ -67,6 +67,7 @@ and thus the first splitter will start from the first log time. #include "MantidAPI/WorkspaceFactory.h" #include "MantidAPI/WorkspaceProperty.h" #include "MantidAPI/Column.h" +#include "MantidKernel/VisibleWhenProperty.h" using namespace Mantid; using namespace Mantid::Kernel; @@ -134,6 +135,8 @@ namespace Algorithms // Split by time (only) in steps declareProperty("TimeInterval", -1.0, "Length of the time splices if filtered in time only."); + setPropertySettings("TimeInterval", + new VisibleWhenProperty("LogName", IS_EQUAL_TO, "")); std::vector timeoptions; timeoptions.push_back("Seconds"); @@ -150,12 +153,18 @@ namespace Algorithms "For example, the pulse charge is recorded in 'ProtonCharge'."); declareProperty("MinimumLogValue", EMPTY_DBL(), "Minimum log value for which to keep events."); + setPropertySettings("MinimumLogValue", + new VisibleWhenProperty("LogName", IS_NOT_EQUAL_TO, "")); declareProperty("MaximumLogValue", EMPTY_DBL(), "Maximum log value for which to keep events."); + setPropertySettings("MaximumLogValue", + new VisibleWhenProperty("LogName", IS_NOT_EQUAL_TO, "")); declareProperty("LogValueInterval", EMPTY_DBL(), "Delta of log value to be sliced into from min log value and max log value.\n" "If not given, then only value "); + setPropertySettings("LogValueInterval", + new VisibleWhenProperty("LogName", IS_NOT_EQUAL_TO, "")); std::vector filteroptions; filteroptions.push_back("Both"); @@ -164,10 +173,14 @@ namespace Algorithms declareProperty("FilterLogValueByChangingDirection", "Both", boost::make_shared(filteroptions), "d(log value)/dt can be positive and negative. They can be put to different splitters."); + setPropertySettings("FilterLogValueByChangingDirection", + new VisibleWhenProperty("LogName", IS_NOT_EQUAL_TO, "")); declareProperty("TimeTolerance", 0.0, "Tolerance in time for the event times to keep. " "It is used in the case to filter by single value."); + setPropertySettings("TimeTolerance", + new VisibleWhenProperty("LogName", IS_NOT_EQUAL_TO, "")); vector logboundoptions; logboundoptions.push_back("Centre"); @@ -176,12 +189,13 @@ namespace Algorithms auto logvalidator = boost::make_shared(logboundoptions); declareProperty("LogBoundary", "Centre", logvalidator, "How to treat log values as being measured in the centre of time."); + setPropertySettings("LogBoundary", + new VisibleWhenProperty("LogName", IS_NOT_EQUAL_TO, "")); declareProperty("LogValueTolerance", EMPTY_DBL(), "Tolerance of the log value to be included in filter. It is used in the case to filter by multiple values."); - - declareProperty("LogValueTimeSections", 1, - "In one log value interval, it can be further divided into sections in even time slice."); + setPropertySettings("LogValueTolerance", + new VisibleWhenProperty("LogName", IS_NOT_EQUAL_TO, "")); // Output workspaces' title and name declareProperty("TitleOfSplitters", "", From 900891bcb1c6ae0d8e861ca7c2c2a4af1b62059b Mon Sep 17 00:00:00 2001 From: Russell Taylor Date: Wed, 23 Apr 2014 15:31:40 -0400 Subject: [PATCH 006/126] Re #9357. Remove CompressedWorkspace and all references thereto. --- .../API/inc/MantidAPI/MemoryManager.h | 2 +- .../Framework/API/src/MemoryManager.cpp | 32 +- .../Framework/API/src/WorkspaceFactory.cpp | 17 +- .../Framework/Algorithms/CMakeLists.txt | 1 - .../Algorithms/test/CompressedRebinTest.h | 131 --------- .../Framework/DataObjects/CMakeLists.txt | 3 - .../MantidDataObjects/CompressedWorkspace2D.h | 101 ------- .../DataObjects/src/CompressedWorkspace2D.cpp | 206 ------------- .../test/CompressedWorkspace2DTest.h | 275 ------------------ .../Properties/Mantid.properties.template | 1 - .../api/src/Exports/MatrixWorkspace.cpp | 4 +- .../MantidPlot/src/Mantid/WorkspaceIcons.cpp | 1 - 12 files changed, 8 insertions(+), 766 deletions(-) delete mode 100644 Code/Mantid/Framework/Algorithms/test/CompressedRebinTest.h delete mode 100644 Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/CompressedWorkspace2D.h delete mode 100644 Code/Mantid/Framework/DataObjects/src/CompressedWorkspace2D.cpp delete mode 100644 Code/Mantid/Framework/DataObjects/test/CompressedWorkspace2DTest.h diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/MemoryManager.h b/Code/Mantid/Framework/API/inc/MantidAPI/MemoryManager.h index 5e29cbf3c065..e058cab31e41 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/MemoryManager.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/MemoryManager.h @@ -54,7 +54,7 @@ namespace Mantid /// Returns available physical memory in the system in KB. MemoryInfo getMemoryInfo(); /// Returns true if there is not sufficient memory for a full Workspace2D. - bool goForManagedWorkspace(std::size_t NVectors,std::size_t XLength,std::size_t YLength, bool* isCompressedOK = NULL); + bool goForManagedWorkspace(std::size_t NVectors,std::size_t XLength,std::size_t YLength); /// Release memory back to the system if we linked againsed tcmalloc void releaseFreeMemory(); /// Release memory back to the system if we linked againsed tcmalloc and are above this much use diff --git a/Code/Mantid/Framework/API/src/MemoryManager.cpp b/Code/Mantid/Framework/API/src/MemoryManager.cpp index fb3b3fd9cd91..ae06fee4e2e6 100644 --- a/Code/Mantid/Framework/API/src/MemoryManager.cpp +++ b/Code/Mantid/Framework/API/src/MemoryManager.cpp @@ -56,10 +56,9 @@ MemoryInfo MemoryManagerImpl::getMemoryInfo() @param NVectors :: the number of vectors @param XLength :: the size of the X vector @param YLength :: the size of the Y vector - @param isCompressedOK :: The address of a boolean indicating if the compression succeeded or not @return true is managed workspace is needed */ -bool MemoryManagerImpl::goForManagedWorkspace(std::size_t NVectors, std::size_t XLength, std::size_t YLength, bool* isCompressedOK) +bool MemoryManagerImpl::goForManagedWorkspace(std::size_t NVectors, std::size_t XLength, std::size_t YLength) { int AlwaysInMemory;// Check for disabling flag if (Kernel::ConfigService::Instance().getValue("ManagedWorkspace.AlwaysInMemory", AlwaysInMemory) @@ -120,35 +119,6 @@ bool MemoryManagerImpl::goForManagedWorkspace(std::size_t NVectors, std::size_t g_log.debug() << "ManagedWS trigger memory: " << (triggerSize * sizeof(double))/1024 << " MB." << std::endl; } - if (isCompressedOK) - { - if (goManaged) - { - int notOK = 0; - if ( !Kernel::ConfigService::Instance().getValue("CompressedWorkspace.DoNotUse",notOK) ) notOK = 0; - if (notOK) *isCompressedOK = false; - else - { - double compressRatio; - if (!Kernel::ConfigService::Instance().getValue("CompressedWorkspace.EstimatedCompressRatio",compressRatio)) compressRatio = 4.; - int VectorsPerBlock; - if (!Kernel::ConfigService::Instance().getValue("CompressedWorkspace.VectorsPerBlock",VectorsPerBlock)) VectorsPerBlock = 4; - double compressedSize = (1./compressRatio + 100.0*static_cast(VectorsPerBlock)/static_cast(NVectors)) - * static_cast(wsSize); - double memoryLeft = (static_cast(triggerSize)/availPercent*100. - compressedSize)/1024. * sizeof(double); - // To prevent bad allocation on Windows when free memory is too low. - if (memoryLeft < 200.) - *isCompressedOK = false; - else - *isCompressedOK = compressedSize < static_cast(triggerSize); - } - } - else - { - *isCompressedOK = false; - } - } - return goManaged; } diff --git a/Code/Mantid/Framework/API/src/WorkspaceFactory.cpp b/Code/Mantid/Framework/API/src/WorkspaceFactory.cpp index 4336c305c203..a584cf4bab84 100644 --- a/Code/Mantid/Framework/API/src/WorkspaceFactory.cpp +++ b/Code/Mantid/Framework/API/src/WorkspaceFactory.cpp @@ -168,9 +168,8 @@ MatrixWorkspace_sptr WorkspaceFactoryImpl::create(const std::string& className, // Creates a managed workspace if over the trigger size and a 2D workspace is being requested. // Otherwise calls the vanilla create method. bool is2D = className.find("2D") != std::string::npos; - bool isCompressedOK = false; if ( MemoryManager::Instance().goForManagedWorkspace(static_cast(NVectors), static_cast(XLength), - static_cast(YLength),&isCompressedOK) && is2D ) + static_cast(YLength)) && is2D ) { // check if there is enough memory for 100 data blocks int blockMemory; @@ -187,21 +186,13 @@ MatrixWorkspace_sptr WorkspaceFactoryImpl::create(const std::string& className, throw std::runtime_error("There is not enough memory to allocate the workspace"); } - if ( !isCompressedOK ) - { - ws = boost::dynamic_pointer_cast(this->create("ManagedWorkspace2D")); - g_log.information("Created a ManagedWorkspace2D"); - } - else - { - ws = boost::dynamic_pointer_cast(this->create("CompressedWorkspace2D")); - g_log.information("Created a CompressedWorkspace2D"); - } + ws = boost::dynamic_pointer_cast(this->create("ManagedWorkspace2D")); + g_log.information("Created a ManagedWorkspace2D"); } else { // No need for a Managed Workspace - if ( is2D && ( className.substr(0,7) == "Managed" || className.substr(0,10) == "Compressed")) + if ( is2D && ( className.substr(0,7) == "Managed" )) ws = boost::dynamic_pointer_cast(this->create("Workspace2D")); else ws = boost::dynamic_pointer_cast(this->create(className)); diff --git a/Code/Mantid/Framework/Algorithms/CMakeLists.txt b/Code/Mantid/Framework/Algorithms/CMakeLists.txt index 805a9d834e56..5a8e90176c8e 100644 --- a/Code/Mantid/Framework/Algorithms/CMakeLists.txt +++ b/Code/Mantid/Framework/Algorithms/CMakeLists.txt @@ -501,7 +501,6 @@ set ( TEST_FILES ClearMaskFlagTest.h CloneWorkspaceTest.h CommutativeBinaryOperationTest.h - CompressedRebinTest.h ConjoinWorkspacesTest.h ConvertAxisByFormulaTest.h ConvertFromDistributionTest.h diff --git a/Code/Mantid/Framework/Algorithms/test/CompressedRebinTest.h b/Code/Mantid/Framework/Algorithms/test/CompressedRebinTest.h deleted file mode 100644 index f569b1726f11..000000000000 --- a/Code/Mantid/Framework/Algorithms/test/CompressedRebinTest.h +++ /dev/null @@ -1,131 +0,0 @@ -#ifndef COMPRESSEDREBINTEST_H_ -#define COMPRESSEDREBINTEST_H_ - -#include - -#include "MantidDataObjects/CompressedWorkspace2D.h" -#include "MantidAPI/AnalysisDataService.h" -#include "MantidAlgorithms/Rebin.h" -#include "MantidAPI/WorkspaceProperty.h" - -using namespace Mantid::Kernel; -using namespace Mantid::DataObjects; -using namespace Mantid::API; -using namespace Mantid::Algorithms; - - -class CompressedRebinTest : public CxxTest::TestSuite -{ -public: - - void testworkspace2D_dist() - { - Workspace2D_sptr test_in2D = Create2DWorkspaceForCompressedRebin(50,20); - test_in2D->isDistribution(true); - AnalysisDataService::Instance().add("test_in2D", test_in2D); - - Rebin rebin; - rebin.initialize(); - rebin.setPropertyValue("InputWorkspace","test_in2D"); - rebin.setPropertyValue("OutputWorkspace","test_out"); - rebin.setPropertyValue("Params", "1.5,2.0,20,-0.1,30,1.0,35"); - TS_ASSERT(rebin.execute()) - TS_ASSERT(rebin.isExecuted()) - MatrixWorkspace_sptr rebindata = AnalysisDataService::Instance().retrieveWS("test_out"); - - const Mantid::MantidVec outX=rebindata->dataX(5); - const Mantid::MantidVec outY=rebindata->dataY(5); - const Mantid::MantidVec outE=rebindata->dataE(5); - TS_ASSERT_DELTA(outX[7],15.5 ,0.000001); - TS_ASSERT_DELTA(outY[7],3.0 ,0.000001); - TS_ASSERT_DELTA(outE[7],sqrt(4.5)/2.0 ,0.000001); - - TS_ASSERT_DELTA(outX[12],24.2 ,0.000001); - TS_ASSERT_DELTA(outY[12],3.0 ,0.000001); - TS_ASSERT_DELTA(outE[12],sqrt(5.445)/2.42 ,0.000001); - - TS_ASSERT_DELTA(outX[17],32.0 ,0.000001); - TS_ASSERT_DELTA(outY[17],3.0 ,0.000001); - TS_ASSERT_DELTA(outE[17],sqrt(2.25) ,0.000001); - bool dist=rebindata->isDistribution(); - TS_ASSERT(dist); - - AnalysisDataService::Instance().remove("test_in2D"); - AnalysisDataService::Instance().remove("test_out"); - } - - void testworkspace2D_nondist() - { - Workspace2D_sptr test_in2D = Create2DWorkspaceForCompressedRebin(50,20); - AnalysisDataService::Instance().add("test_in2D", test_in2D); - - // Mask a couple of bins for a test - test_in2D->maskBin(10,4); - test_in2D->maskBin(10,5); - - Rebin rebin; - rebin.initialize(); - rebin.setPropertyValue("InputWorkspace","test_in2D"); - rebin.setPropertyValue("OutputWorkspace","test_out"); - rebin.setPropertyValue("Params", "1.5,2.0,20,-0.1,30,1.0,35"); - TS_ASSERT(rebin.execute()) - TS_ASSERT(rebin.isExecuted()) - MatrixWorkspace_sptr rebindata = AnalysisDataService::Instance().retrieveWS("test_out"); - const Mantid::MantidVec outX=rebindata->dataX(5); - const Mantid::MantidVec outY=rebindata->dataY(5); - const Mantid::MantidVec outE=rebindata->dataE(5); - TS_ASSERT_DELTA(outX[7],15.5 ,0.000001); - TS_ASSERT_DELTA(outY[7],8.0 ,0.000001); - TS_ASSERT_DELTA(outE[7],sqrt(8.0) ,0.000001); - TS_ASSERT_DELTA(outX[12],24.2 ,0.000001); - TS_ASSERT_DELTA(outY[12],9.68 ,0.000001); - TS_ASSERT_DELTA(outE[12],sqrt(9.68) ,0.000001); - TS_ASSERT_DELTA(outX[17],32 ,0.000001); - TS_ASSERT_DELTA(outY[17],4.0 ,0.000001); - TS_ASSERT_DELTA(outE[17],sqrt(4.0) ,0.000001); - bool dist=rebindata->isDistribution(); - TS_ASSERT(!dist); - - // Test that the masking was propagated correctly - TS_ASSERT( test_in2D->hasMaskedBins(10) ) - TS_ASSERT( rebindata->hasMaskedBins(10) ) - TS_ASSERT_THROWS_NOTHING ( - const MatrixWorkspace::MaskList& masks = rebindata->maskedBins(10); - TS_ASSERT_EQUALS( masks.size(),1 ) - TS_ASSERT_EQUALS( masks.begin()->first, 1 ) - TS_ASSERT_EQUALS( masks.begin()->second, 0.75 ) - ) - - AnalysisDataService::Instance().remove("test_in2D"); - AnalysisDataService::Instance().remove("test_out"); - } - -private: - - Workspace2D_sptr Create2DWorkspaceForCompressedRebin(int xlen, int ylen) - { - boost::shared_ptr x1(new Mantid::MantidVec(xlen,0.0)); - boost::shared_ptr y1(new Mantid::MantidVec(xlen-1,3.0)); - boost::shared_ptr e1(new Mantid::MantidVec(xlen-1,sqrt(3.0))); - - Workspace2D_sptr retVal(new CompressedWorkspace2D); - retVal->initialize(ylen,xlen,xlen-1); - double j=1.0; - - for (int i=0; isetX(i,x1); - retVal->setData(i,y1,e1); - } - - return retVal; - } - -}; -#endif /* COMPRESSEDREBINTEST_H_ */ diff --git a/Code/Mantid/Framework/DataObjects/CMakeLists.txt b/Code/Mantid/Framework/DataObjects/CMakeLists.txt index 4476049c0556..f2bf870b8169 100644 --- a/Code/Mantid/Framework/DataObjects/CMakeLists.txt +++ b/Code/Mantid/Framework/DataObjects/CMakeLists.txt @@ -1,6 +1,5 @@ set ( SRC_FILES src/AbsManagedWorkspace2D.cpp - src/CompressedWorkspace2D.cpp src/EventList.cpp src/EventWorkspace.cpp src/EventWorkspaceHelpers.cpp @@ -35,7 +34,6 @@ set ( SRC_UNITY_IGNORE_FILES set ( INC_FILES inc/MantidDataObjects/AbsManagedWorkspace2D.h - inc/MantidDataObjects/CompressedWorkspace2D.h inc/MantidDataObjects/DllConfig.h inc/MantidDataObjects/EventList.h inc/MantidDataObjects/EventWorkspace.h @@ -64,7 +62,6 @@ set ( INC_FILES ) set ( TEST_FILES - CompressedWorkspace2DTest.h EventListTest.h EventWorkspaceMRUTest.h EventWorkspaceTest.h diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/CompressedWorkspace2D.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/CompressedWorkspace2D.h deleted file mode 100644 index 43bcc1901421..000000000000 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/CompressedWorkspace2D.h +++ /dev/null @@ -1,101 +0,0 @@ -#ifndef COMPRESSEDWORKSPACE2D_H -#define COMPRESSEDWORKSPACE2D_H - -#include "MantidDataObjects/Workspace2D.h" -#include "MantidDataObjects/AbsManagedWorkspace2D.h" - -#include -#include - -#include -#include -#include -#include - -namespace Mantid -{ -namespace DataObjects -{ - /** CompressedWorkspace2D. - - Works similar to the ManagedWorkspace2D but keeps the data compressed in memory instead of the disk. - Set CompressedWorkspace.VectorsPerBlock in .properties file to change the number of spectra in each of the - 100 blocks that are kept uncompressed for quick access. - Set CompressedWorkspace.DoNotUse to switch off the use of the CompressedWorkspace2D. - - @author Roman Tolchenov, Tessella plc - @date 28/07/2009 - - Copyright © 2008 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory - - This file is part of Mantid. - - Mantid is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - Mantid is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - - File change history is stored at: . - Code Documentation is available at: - */ - class DLLExport CompressedWorkspace2D : public AbsManagedWorkspace2D - { - public: - - /// Constructor - CompressedWorkspace2D(); - /// Destructor - ~CompressedWorkspace2D(); - virtual const std::string id() const {return "CompressedWorkspace2D";} - /// Returns the size of physical memory the workspace takes - std::size_t getMemorySize() const; - - protected: - - virtual void init(const std::size_t &NVectors, const std::size_t &XLength, const std::size_t &YLength); - - /// Reads in a data block. - virtual void readDataBlock(ManagedDataBlock2D *newBlock,std::size_t startIndex)const; - /// Saves the dropped data block to disk. - virtual void writeDataBlock(ManagedDataBlock2D *toWrite) const; - - private: - // Make copy constructor and copy assignment operator private (and without definition) unless they're needed - /// Private copy constructor - CompressedWorkspace2D(const CompressedWorkspace2D&); - /// Private copy assignment operator - CompressedWorkspace2D& operator=(const CompressedWorkspace2D&); - - /// Type of a pointer to a compressed data block along with its size - typedef std::pair CompressedPointer; - /// Map of the compressed data storage - typedef std::map CompressedMap; - - /// Compresses a block - CompressedPointer compressBlock(ManagedDataBlock2D* block,std::size_t startIndex) const; - /// Uncompress a block - void uncompressBlock(ManagedDataBlock2D* block,std::size_t startIndex)const; - - /// Data buffer used in compression and decompression - mutable MantidVec m_inBuffer; - /// Data buffer used in compression and decompression - mutable std::vector m_outBuffer; - - /// Keeps all compressed data - mutable CompressedMap m_compressedData; - }; - - - -} // namespace DataObjects -} // namespace Mantid - -#endif /* COMPRESSEDWORKSPACE2D_H */ diff --git a/Code/Mantid/Framework/DataObjects/src/CompressedWorkspace2D.cpp b/Code/Mantid/Framework/DataObjects/src/CompressedWorkspace2D.cpp deleted file mode 100644 index e36d865c5599..000000000000 --- a/Code/Mantid/Framework/DataObjects/src/CompressedWorkspace2D.cpp +++ /dev/null @@ -1,206 +0,0 @@ -#include "MantidDataObjects/CompressedWorkspace2D.h" -#include "MantidAPI/RefAxis.h" -#include "MantidKernel/ConfigService.h" -#include "MantidAPI/WorkspaceFactory.h" - -#include -#include -#include "MantidDataObjects/ManagedHistogram1D.h" - -namespace Mantid -{ -namespace DataObjects -{ - -using std::size_t; - -DECLARE_WORKSPACE(CompressedWorkspace2D) - -/// Constructor -CompressedWorkspace2D::CompressedWorkspace2D() : -AbsManagedWorkspace2D() -{ -} - -/** Sets the size of the workspace and sets up the temporary file -* @param NVectors :: The number of vectors/histograms/detectors in the workspace -* @param XLength :: The number of X data points/bin boundaries in each vector (must all be the same) -* @param YLength :: The number of data/error points in each vector (must all be the same) -* @throw std::runtime_error if unable to open a temporary file -*/ -void CompressedWorkspace2D::init(const std::size_t &NVectors, const std::size_t &XLength, const std::size_t &YLength) -{ - AbsManagedWorkspace2D::init(NVectors,XLength,YLength); - m_vectorSize = ( m_XLength + ( 2*m_YLength ) ) * sizeof(double); - - if (! Kernel::ConfigService::Instance().getValue("CompressedWorkspace.VectorsPerBlock", m_vectorsPerBlock) ) - m_vectorsPerBlock = 4; - // Should this ever come out to be zero, then actually set it to 1 - if ( m_vectorsPerBlock == 0 ) m_vectorsPerBlock = 1; - // Because of iffy design, force to 1. - m_vectorsPerBlock = 1; - - m_blockSize = m_vectorSize * m_vectorsPerBlock; - m_inBuffer.resize( ( m_XLength + 2*m_YLength ) * m_vectorsPerBlock ); - - // make the compressed buffer as big as to be able to hold uncompressed data + - size_t bufferSize = (m_vectorSize + m_vectorSize/1000 + 12) * m_vectorsPerBlock; - m_outBuffer.resize(bufferSize); - - // Create all the blocks - this->initBlocks(); - - //std::cerr<<"Compressed buffer size "<initialize(); - CompressedPointer tmpBuff = compressBlock(newBlock,0); - - for(size_t i=0;isecond.first; - } -} - -/** This function decides if ManagedDataBlock2D with given startIndex needs to -be loaded from storage and loads it. -@param newBlock :: Returned data block address -@param startIndex :: Starting spectrum index in the block -*/ -void CompressedWorkspace2D::readDataBlock(ManagedDataBlock2D *newBlock,std::size_t startIndex)const -{ - // You only need to read it if it hasn't been loaded before - if (!newBlock->isLoaded()) - { - uncompressBlock(newBlock,startIndex); - } -} - -void CompressedWorkspace2D::writeDataBlock(ManagedDataBlock2D *toWrite) const -{ - CompressedPointer p = compressBlock(toWrite,toWrite->minIndex()); - CompressedPointer old_p = m_compressedData[toWrite->minIndex()]; - if (old_p.first) delete [] old_p.first; - m_compressedData[toWrite->minIndex()] = p; -} - -size_t CompressedWorkspace2D::getMemorySize() const -{ - double sz = 0.; - for(CompressedMap::const_iterator it=m_compressedData.begin();it!= m_compressedData.end();++it) - sz += static_cast(it->second.second); - //std::cerr<<"Memory: "<(getNumberBlocks() * m_blockSize + m_inBuffer.size()*sizeof(double) + m_outBuffer.size()); - return static_cast(sz); -} - -/** - * @param block :: Pointer to the source block for compression - * @param startIndex :: The starting index of the block - * @return pointer to the compressed block - */ -CompressedWorkspace2D::CompressedPointer CompressedWorkspace2D::compressBlock(ManagedDataBlock2D* block,std::size_t startIndex) const -{ - //std::cerr<<"compress "<(block->getSpectrum(startIndex + i)); - MantidVec& X = spec->directDataX(); - std::copy(X.begin(),X.end(),m_inBuffer.begin() + j); - j += m_XLength; - } - for(size_t i=0;i(block->getSpectrum(startIndex + i)); - MantidVec& Y = spec->directDataY(); - std::copy(Y.begin(),Y.end(),m_inBuffer.begin() + j); - j += m_YLength; - } - for(size_t i=0;i(block->getSpectrum(startIndex + i)); - MantidVec& E = spec->directDataE(); - std::copy(E.begin(),E.end(),m_inBuffer.begin() + j); - j += m_YLength; - } - - uLongf nBuff = static_cast(m_outBuffer.size()); - - compress2(&m_outBuffer[0],&nBuff,reinterpret_cast(&m_inBuffer[0]),static_cast(m_vectorSize*m_vectorsPerBlock),1); - - Bytef* tmp = new Bytef[nBuff]; - memcpy(tmp,&m_outBuffer[0],nBuff); - - return CompressedPointer(tmp,nBuff); -} - -/** - * @param block :: Pointer to the destination decompressed block - * @param startIndex :: The starting index of the block - */ -void CompressedWorkspace2D::uncompressBlock(ManagedDataBlock2D* block,std::size_t startIndex)const -{ - uLongf nBuff = static_cast(m_outBuffer.size()); - CompressedPointer p = m_compressedData[startIndex]; - int status = uncompress (&m_outBuffer[0], &nBuff, p.first, static_cast(p.second)); - - if (status == Z_MEM_ERROR) - throw std::runtime_error("There is not enough memory to complete the uncompress operation."); - if (status == Z_BUF_ERROR) - throw std::runtime_error("There is not enough room in the buffer to complete the uncompress operation."); - if (status == Z_DATA_ERROR) - throw std::runtime_error("Compressed data has been corrupted."); - //std::cerr<<"uncompressed "< x1(new MantidVec(vecLength,1+i) ); - boost::shared_ptr y1(new MantidVec(vecLength,5+i) ); - boost::shared_ptr e1(new MantidVec(vecLength,4+i) ); - bigWorkspace.setX(i,x1); - bigWorkspace.setData(i,y1,e1); - // As of 20/7/2011, revision [13332], these calls have no (lasting) effect. - // When they do, the testSpectrumAndDetectorNumbers test will start to fail - bigWorkspace.getSpectrum(i)->setSpectrumNo((int)i); - bigWorkspace.getSpectrum(i)->setDetectorID((int)i*100); - } - } - - void testInit() - { - Mantid::DataObjects::CompressedWorkspace2D ws; - ws.setTitle("testInit"); - TS_ASSERT_THROWS_NOTHING( ws.initialize(5,5,5) );; - TS_ASSERT_EQUALS( ws.getNumberHistograms(), 5 );; - TS_ASSERT_EQUALS( ws.blocksize(), 5 ); - TS_ASSERT_EQUALS( ws.size(), 25 ); - - for (int i = 0; i < 5; ++i) - { - TS_ASSERT_EQUALS( ws.dataX(i).size(), 5 ); - TS_ASSERT_EQUALS( ws.dataY(i).size(), 5 ); - TS_ASSERT_EQUALS( ws.dataE(i).size(), 5 ); - } - - } - - void testCast() - { - Mantid::DataObjects::CompressedWorkspace2D *ws = new Mantid::DataObjects::CompressedWorkspace2D; - TS_ASSERT( dynamic_cast(ws) ); - TS_ASSERT( dynamic_cast(ws) ); - delete ws; - } - - void testId() - { - TS_ASSERT( ! smallWorkspace.id().compare("CompressedWorkspace2D") ); - TS_ASSERT_EQUALS( smallWorkspace.id(), "CompressedWorkspace2D" ); - } - - void testgetNumberHistograms() - { - TS_ASSERT_EQUALS( smallWorkspace.getNumberHistograms(), 2 ); - TS_ASSERT_EQUALS( bigWorkspace.getNumberHistograms(), 1250 ); - - Mantid::DataObjects::Workspace2D &ws = dynamic_cast(smallWorkspace); - TS_ASSERT_EQUALS( ws.getNumberHistograms(), 2);; - } - - void testSetX() - { - Mantid::DataObjects::CompressedWorkspace2D ws; - ws.setTitle("testSetX"); - ws.initialize(1,1,1); - double aNumber = 5.5; - boost::shared_ptr v(new MantidVec(1, aNumber)); - TS_ASSERT_THROWS_NOTHING( ws.setX(0,v) ); - TS_ASSERT_EQUALS( ws.dataX(0)[0], aNumber ); - TS_ASSERT_THROWS( ws.setX(-1,v), std::range_error ); - TS_ASSERT_THROWS( ws.setX(1,v), std::range_error ); - - double anotherNumber = 9.99; - boost::shared_ptr vec(new MantidVec(25, anotherNumber)); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.setX(10, vec) ); - TS_ASSERT_EQUALS( bigWorkspace.dataX(10)[7], anotherNumber ); - TS_ASSERT_EQUALS( bigWorkspace.dataX(10)[22], anotherNumber ); - } - - void testSetData() - { - Mantid::DataObjects::CompressedWorkspace2D ws; - ws.setTitle("testSetData"); - ws.initialize(1,1,1); - double aNumber = 9.9; - boost::shared_ptr v(new MantidVec(1, aNumber)); - double anotherNumber = 3.3; - boost::shared_ptr w(new MantidVec(1, anotherNumber)); - TS_ASSERT_THROWS_NOTHING( ws.setData(0,v,v) ); - TS_ASSERT_EQUALS( ws.dataY(0)[0], aNumber ) ; - TS_ASSERT_THROWS( ws.setData(-1,v,v), std::range_error ); - TS_ASSERT_THROWS( ws.setData(1,v,v), std::range_error ); - - double yetAnotherNumber = 2.25; - (*v)[0] = yetAnotherNumber; - TS_ASSERT_THROWS_NOTHING( ws.setData(0,v,w) ); - TS_ASSERT_EQUALS( ws.dataY(0)[0], yetAnotherNumber ); - TS_ASSERT_EQUALS( ws.dataE(0)[0], anotherNumber ); - TS_ASSERT_THROWS( ws.setData(-1,v,w), std::range_error ); - TS_ASSERT_THROWS( ws.setData(1,v,w), std::range_error ); - - double oneMoreNumber = 8478.6728; - boost::shared_ptr vec(new MantidVec(25, oneMoreNumber)); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.setData(49, vec, vec) ); - TS_ASSERT_EQUALS( bigWorkspace.dataY(49)[0], oneMoreNumber ); - TS_ASSERT_EQUALS( bigWorkspace.dataE(49)[9], oneMoreNumber ); - } - - void testSize() - { - TS_ASSERT_EQUALS( smallWorkspace.size(), 6 ); - TS_ASSERT_EQUALS( bigWorkspace.size(), 31250 ); - } - - void testBlocksize() - { - TS_ASSERT_EQUALS( smallWorkspace.blocksize(), 3 ); - TS_ASSERT_EQUALS( bigWorkspace.blocksize(), 25 ) ; - } - - void testDataX() - { - MantidVec x; - TS_ASSERT_THROWS( smallWorkspace.dataX(-1), std::range_error ); - TS_ASSERT_THROWS_NOTHING( x = smallWorkspace.dataX(0) ); - MantidVec xx; - TS_ASSERT_THROWS_NOTHING( xx = smallWorkspace.dataX(1) ); - TS_ASSERT_THROWS( smallWorkspace.dataX(2), std::range_error ); - TS_ASSERT_EQUALS( x.size(), 4 ); - TS_ASSERT_EQUALS( xx.size(), 4 ); - for (unsigned int i = 0; i < x.size(); ++i) - { - TS_ASSERT_EQUALS( x[i], i ); - TS_ASSERT_EQUALS( xx[i], i+4 ); - } - - // test const version - const Mantid::DataObjects::CompressedWorkspace2D &constRefToData = smallWorkspace; - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataX(-1), std::range_error ); - const MantidVec xc = constRefToData.dataX(0); - const MantidVec xxc = constRefToData.dataX(1); - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataX(2), std::range_error ); - TS_ASSERT_EQUALS( xc.size(), 4 ); - TS_ASSERT_EQUALS( xxc.size(), 4 ); - for (unsigned int i = 0; i < xc.size(); ++i) - { - TS_ASSERT_EQUALS( xc[i], i ); - TS_ASSERT_EQUALS( xxc[i], i+4 ); - } - - TS_ASSERT_EQUALS( bigWorkspace.dataX(101)[5], 102 ); - TS_ASSERT_EQUALS( bigWorkspace.dataX(201)[24], 202 ); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.dataX(39)[10] = 2.22 ); - TS_ASSERT_EQUALS( bigWorkspace.dataX(39)[10], 2.22 ); - } - - void testDataY() - { - MantidVec y; - TS_ASSERT_THROWS( smallWorkspace.dataY(-1), std::range_error ); - TS_ASSERT_THROWS_NOTHING( y = smallWorkspace.dataY(0) ); - MantidVec yy; - TS_ASSERT_THROWS_NOTHING( yy = smallWorkspace.dataY(1) ); - TS_ASSERT_THROWS( smallWorkspace.dataY(2), std::range_error ); - TS_ASSERT_EQUALS( y.size(), 3 ); - TS_ASSERT_EQUALS( yy.size(), 3 ); - for (unsigned int i = 0; i < y.size(); ++i) - { - TS_ASSERT_EQUALS( y[i], i*10 ); - TS_ASSERT_EQUALS( yy[i], i*100 ); - } - - // test const version - const Mantid::DataObjects::CompressedWorkspace2D &constRefToData = smallWorkspace; - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataY(-1), std::range_error ); - const MantidVec yc = constRefToData.dataY(0); - const MantidVec yyc = constRefToData.dataY(1); - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataY(2), std::range_error ); - TS_ASSERT_EQUALS( yc.size(), 3 ); - TS_ASSERT_EQUALS( yyc.size(), 3 ); - for (unsigned int i = 0; i < yc.size(); ++i) - { - TS_ASSERT_EQUALS( yc[i], i*10 ); - TS_ASSERT_EQUALS( yyc[i], i*100 ); - } - - TS_ASSERT_EQUALS( bigWorkspace.dataY(178)[8], 183 ); - TS_ASSERT_EQUALS( bigWorkspace.dataY(64)[11], 69 ); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.dataY(123)[8] = 3.33 ); - TS_ASSERT_EQUALS( bigWorkspace.dataY(123)[8], 3.33 ); - } - - void testDataE() - { - MantidVec e; - TS_ASSERT_THROWS( smallWorkspace.dataE(-1), std::range_error ); - TS_ASSERT_THROWS_NOTHING( e = smallWorkspace.dataE(0) ); - MantidVec ee; - TS_ASSERT_THROWS_NOTHING( ee = smallWorkspace.dataE(1) ); - TS_ASSERT_THROWS( smallWorkspace.dataE(2), std::range_error ); - TS_ASSERT_EQUALS( e.size(), 3 ); - TS_ASSERT_EQUALS( ee.size(), 3 ); - for (unsigned int i = 0; i < e.size(); ++i) - { - TS_ASSERT_EQUALS( e[i], sqrt(i*10.0) ); - TS_ASSERT_EQUALS( ee[i], sqrt(i*100.0) ); - } - - // test const version - const Mantid::DataObjects::CompressedWorkspace2D &constRefToData = smallWorkspace; - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataE(-1), std::range_error ); - const MantidVec ec = constRefToData.dataE(0); - const MantidVec eec = constRefToData.dataE(1); - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataE(2), std::range_error ); - TS_ASSERT_EQUALS( ec.size(), 3 ); - TS_ASSERT_EQUALS( eec.size(), 3 ); - for (unsigned int i = 0; i < ec.size(); ++i) - { - TS_ASSERT_EQUALS( ec[i], sqrt(i*10.0) ); - TS_ASSERT_EQUALS( eec[i], sqrt(i*100.0) ); - } - - TS_ASSERT_EQUALS( bigWorkspace.dataE(0)[23], 4 ); - TS_ASSERT_EQUALS( bigWorkspace.dataE(249)[2], 253 ); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.dataE(11)[11] = 4.44 ); - TS_ASSERT_EQUALS( bigWorkspace.dataE(11)[11], 4.44 ); - } - - void testSpectrumAndDetectorNumbers() - { - for (size_t i = 0; i < bigWorkspace.getNumberHistograms(); ++i) - { - TS_ASSERT_EQUALS( bigWorkspace.getAxis(1)->spectraNo(i), i ); - TS_ASSERT_EQUALS( bigWorkspace.getSpectrum(i)->getSpectrumNo(), i ); - TS_ASSERT( bigWorkspace.getSpectrum(i)->hasDetectorID((int)i*100) ); - } - } - -private: - Mantid::DataObjects::CompressedWorkspace2D smallWorkspace; - Mantid::DataObjects::CompressedWorkspace2D bigWorkspace; -}; - -#endif /*COMPRESSEDWORKSPACE2D_H_*/ diff --git a/Code/Mantid/Framework/Properties/Mantid.properties.template b/Code/Mantid/Framework/Properties/Mantid.properties.template index 7fc4798e6fc8..9d0fec2b105d 100644 --- a/Code/Mantid/Framework/Properties/Mantid.properties.template +++ b/Code/Mantid/Framework/Properties/Mantid.properties.template @@ -110,7 +110,6 @@ ManagedWorkspace.DataBlockSize = 4000 ManagedWorkspace.FilePath = # Setting this to 1 will disable managedrawfileworkspaces ManagedRawFileWorkspace.DoNotUse = 0 -CompressedWorkspace.DoNotUse = 1 # Defines the maximum number of cores to use for OpenMP # For machine default set to 0 diff --git a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp index 510803e90276..5fb31fb4f80d 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp @@ -239,9 +239,9 @@ void export_MatrixWorkspace() //------------------------------------------------------------------------------------------------- - static const int NUM_IDS = 10; + static const int NUM_IDS = 9; static const char * WORKSPACE_IDS[NUM_IDS] = {\ - "CompressedWorkspace2D", "GroupingWorkspace", "ManagedWorkspace2D", + "GroupingWorkspace", "ManagedWorkspace2D", "ManagedRawFileWorkspace2D", "MaskWorkspace", "OffsetsWorkspace", "RebinnedOutput", "SpecialWorkspace2D", "Workspace2D", "WorkspaceSingleValue" }; diff --git a/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp b/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp index 0d7735942f04..eed7f0725b6f 100644 --- a/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp +++ b/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp @@ -38,7 +38,6 @@ void WorkspaceIcons::initInternalLookup() { m_idToPixmapName.clear(); // MatrixWorkspace types - m_idToPixmapName["CompressedWorkspace2D"] = "mantid_matrix_xpm"; m_idToPixmapName["EventWorkspace"] = "mantid_matrix_xpm"; m_idToPixmapName["GroupingWorkspace"] = "mantid_matrix_xpm"; m_idToPixmapName["ManagedWorkspace2D"] = "mantid_matrix_xpm"; From 59f2b71eec62367bb5683b5c9eabb8cae77fa6d9 Mon Sep 17 00:00:00 2001 From: Russell Taylor Date: Wed, 23 Apr 2014 15:34:21 -0400 Subject: [PATCH 007/126] Re #9357. Remove DataObjects depency on zlib. It was only used by CompressedWorkspace (which is now gone). --- Code/Mantid/Framework/DataObjects/CMakeLists.txt | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Code/Mantid/Framework/DataObjects/CMakeLists.txt b/Code/Mantid/Framework/DataObjects/CMakeLists.txt index f2bf870b8169..7bc5229f482b 100644 --- a/Code/Mantid/Framework/DataObjects/CMakeLists.txt +++ b/Code/Mantid/Framework/DataObjects/CMakeLists.txt @@ -109,9 +109,7 @@ set_target_properties ( DataObjects PROPERTIES OUTPUT_NAME MantidDataObjects # Add to the 'Framework' group in VS set_property ( TARGET DataObjects PROPERTY FOLDER "MantidFramework" ) -include_directories ( ${ZLIB_INCLUDE_DIRS} ) - -target_link_libraries ( DataObjects ${MANTIDLIBS} ${ZLIB_LIBRARIES} ) +target_link_libraries ( DataObjects ${MANTIDLIBS} ) # Add the unit tests directory add_subdirectory ( test ) From 02a18b45f9c738d5e0d26523b17032349b645cc3 Mon Sep 17 00:00:00 2001 From: Russell Taylor Date: Wed, 23 Apr 2014 17:13:34 -0400 Subject: [PATCH 008/126] Re #9357. Remove ManagedRawFileWorkspace2D. --- .../Framework/DataHandling/CMakeLists.txt | 3 - .../inc/MantidDataHandling/LoadRaw3.h | 5 - .../ManagedRawFileWorkspace2D.h | 114 ------ .../Framework/DataHandling/src/LoadRaw3.cpp | 64 --- .../src/ManagedRawFileWorkspace2D.cpp | 368 ------------------ .../test/ManagedRawFileWorkspace2DTest.h | 300 -------------- .../Properties/Mantid.properties.template | 2 - .../api/src/Exports/MatrixWorkspace.cpp | 4 +- .../MantidPlot/src/Mantid/WorkspaceIcons.cpp | 1 - 9 files changed, 2 insertions(+), 859 deletions(-) delete mode 100644 Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/ManagedRawFileWorkspace2D.h delete mode 100644 Code/Mantid/Framework/DataHandling/src/ManagedRawFileWorkspace2D.cpp delete mode 100644 Code/Mantid/Framework/DataHandling/test/ManagedRawFileWorkspace2DTest.h diff --git a/Code/Mantid/Framework/DataHandling/CMakeLists.txt b/Code/Mantid/Framework/DataHandling/CMakeLists.txt index 61ddb8a9674a..b30cecbd4b99 100644 --- a/Code/Mantid/Framework/DataHandling/CMakeLists.txt +++ b/Code/Mantid/Framework/DataHandling/CMakeLists.txt @@ -84,7 +84,6 @@ set ( SRC_FILES src/LoadSpec.cpp src/LoadSpice2D.cpp src/LoadTOFRawNexus.cpp - src/ManagedRawFileWorkspace2D.cpp src/MaskDetectors.cpp src/MaskDetectorsInShape.cpp src/MergeLogs.cpp @@ -212,7 +211,6 @@ set ( INC_FILES inc/MantidDataHandling/LoadSpec.h inc/MantidDataHandling/LoadSpice2D.h inc/MantidDataHandling/LoadTOFRawNexus.h - inc/MantidDataHandling/ManagedRawFileWorkspace2D.h inc/MantidDataHandling/MaskDetectors.h inc/MantidDataHandling/MaskDetectorsInShape.h inc/MantidDataHandling/MergeLogs.h @@ -336,7 +334,6 @@ set ( TEST_FILES LoadSpice2dTest.h LoadTOFRawNexusTest.h LoadTest.h - ManagedRawFileWorkspace2DTest.h MaskDetectorsInShapeTest.h MaskDetectorsTest.h MergeLogsTest.h diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h index 4b64e76fe145..49998b8b11e2 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h @@ -80,11 +80,6 @@ namespace Mantid void validateWorkspaceSizes( bool bexcludeMonitors ,bool bseparateMonitors, const int64_t normalwsSpecs,const int64_t monitorwsSpecs); - /// this method will be executed if not enough memory. - void goManagedRaw(bool bincludeMonitors,bool bexcludeMonitors, - bool bseparateMonitors,const std::string& fileName); - - /// This method is useful for separating or excluding monitors from the output workspace void separateOrexcludeMonitors(DataObjects::Workspace2D_sptr localWorkspace, bool binclude,bool bexclude,bool bseparate, diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/ManagedRawFileWorkspace2D.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/ManagedRawFileWorkspace2D.h deleted file mode 100644 index 91d72011c19d..000000000000 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/ManagedRawFileWorkspace2D.h +++ /dev/null @@ -1,114 +0,0 @@ -#ifndef MANTID_DATAOBJECTS_MANAGEDRAWFILEWORKSPACE2D_H_ -#define MANTID_DATAOBJECTS_MANAGEDRAWFILEWORKSPACE2D_H_ - -//---------------------------------------------------------------------- -// Includes -//---------------------------------------------------------------------- -#include "MantidDataObjects/ManagedWorkspace2D.h" -#include "MantidKernel/System.h" -#include -#include "MantidGeometry/IDetector.h" - -class ISISRAW2; - -namespace Mantid -{ - -//---------------------------------------------------------------------- -// Forward declarations -//---------------------------------------------------------------------- - -namespace DataHandling -{ -/** \class ManagedRawFileWorkspace2D - - Concrete workspace implementation. Data is a vector of Histogram1D. - Since Histogram1D have share ownership of X, Y or E arrays, - duplication is avoided for workspaces for example with identical time bins. - - \author - \date - - Copyright © 2007-9 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory - - This file is part of Mantid. - - Mantid is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - Mantid is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - - File change history is stored at: . - Code Documentation is available at: -*/ -class DLLExport ManagedRawFileWorkspace2D : public DataObjects::ManagedWorkspace2D -{ -public: - /** - Gets the name of the workspace type - @return Standard string name - */ - virtual const std::string id() const {return "ManagedRawFileWorkspace2D";} - - explicit ManagedRawFileWorkspace2D(const std::string& fileName, int opt=0); - virtual ~ManagedRawFileWorkspace2D(); - -protected: - /// Reads in a data block. - virtual void readDataBlock(DataObjects::ManagedDataBlock2D *newBlock,size_t startIndex)const; - /// Saves the dropped data block to disk. - virtual void writeDataBlock(DataObjects::ManagedDataBlock2D *toWrite) const; - -private: - /// Private copy constructor. NO COPY ALLOWED - ManagedRawFileWorkspace2D(const ManagedRawFileWorkspace2D&); - /// Private copy assignment operator. NO ASSIGNMENT ALLOWED - ManagedRawFileWorkspace2D& operator=(const ManagedRawFileWorkspace2D&); - - /// Sets the RAW file for this workspace. Called by the constructor. - void setRawFile(const int opt); - void getTimeChannels(); - bool needCache(const int opt); - void openTempFile(); - void removeTempFile()const; - /// returns true if the given spectrum index is a monitor - bool isMonitor(const detid_t readIndex) const; - - boost::shared_ptr isisRaw; ///< Pointer to an ISISRAW2 object - const std::string m_filenameRaw;///< RAW file name. - FILE* m_fileRaw; ///< RAW file pointer. - fpos_t m_data_pos; ///< Position in the file where the data start. - mutable int m_readIndex; ///< Index of the spectrum which starts at current position in the file (== index_of_last_read + 1) - std::vector > m_timeChannels; ///< Time bins - std::map m_specTimeRegimes; ///< Stores the time regime for each spectrum - - // For each data block holds true if it has been modified and must read from ManagedWorkspace2D flat file - // of false if it must be read from the RAW file. - // The block's index = startIndex / m_vectorsPerBlock. - mutable std::vector m_changedBlock; ///< Flags for modified blocks. Modified blocks are accessed through ManagedWorkspace2D interface - static int64_t g_uniqueID; ///< Counter used to create unique file names - std::string m_tempfile; ///< The temporary file name - - int64_t m_numberOfTimeChannels; ///< The number of time channels (i.e. bins) from the RAW file - int64_t m_numberOfBinBoundaries; ///< The number of time bin boundaries == m_numberOfTimeChannels + 1 - int64_t m_numberOfSpectra; ///< The number of spectra in the raw file - int64_t m_numberOfPeriods; ///< The number of periods in the raw file - - mutable Poco::FastMutex m_mutex; ///< The mutex - - /// a counter used for skipping the raw file if it's a monitor - mutable int64_t m_nmonitorSkipCounter; - -}; - -} // namespace DataHandling -} // Namespace Mantid -#endif /*MANTID_DATAOBJECTS_MANAGEDRAWFILEWORKSPACE2D_H_*/ diff --git a/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp b/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp index 4c62bce0bd31..559df364766e 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp @@ -24,7 +24,6 @@ LoadRaw version 1 and 2 are no longer available in Mantid. Version 3 has been v // Includes //---------------------------------------------------------------------- #include "MantidDataHandling/LoadRaw3.h" -#include "MantidDataHandling/ManagedRawFileWorkspace2D.h" #include "MantidDataObjects/Workspace2D.h" #include "MantidGeometry/Instrument/XMLlogfile.h" #include "MantidAPI/MemoryManager.h" @@ -140,16 +139,6 @@ namespace Mantid // Calculate the size of a workspace, given its number of periods & spectra to read m_total_specs = calculateWorkspaceSize(); - // If there is not enough memory use ManagedRawFileWorkspace2D. - if ( ConfigService::Instance().getString("ManagedRawFileWorkspace.DoNotUse") != "1" && - m_numberOfPeriods == 1 && m_total_specs == m_numberOfSpectra && - MemoryManager::Instance().goForManagedWorkspace(m_total_specs,m_lengthIn, m_lengthIn-1) ) - { - fclose(file); - goManagedRaw(bincludeMonitors, bexcludeMonitors, bseparateMonitors,m_filename); - return; - } - // Get the time channel array(s) and store in a vector inside a shared pointer m_timeChannelsVec =getTimeChannels(m_noTimeRegimes,m_lengthIn); @@ -584,59 +573,6 @@ namespace Mantid return bMonitor; } - /// Creates a ManagedRawFileWorkspace2D - /// @param bincludeMonitors :: Include monitors or not - /// @param bexcludeMonitors :: Exclude monitors or not - /// @param bseparateMonitors :: Separate monitors or not - /// @param fileName :: the filename - void LoadRaw3::goManagedRaw(bool bincludeMonitors, bool bexcludeMonitors, bool bseparateMonitors, - const std::string& fileName) - { - const std::string cache_option = getPropertyValue("Cache"); - bool bLoadlogFiles = getProperty("LoadLogFiles"); - size_t option = find(m_cache_options.begin(), m_cache_options.end(), cache_option) - - m_cache_options.begin(); - progress(m_prog, "Reading raw file data..."); - DataObjects::Workspace2D_sptr localWorkspace = DataObjects::Workspace2D_sptr( - new ManagedRawFileWorkspace2D(fileName, static_cast(option))); - setProg( 0.2 ); - progress(m_prog); - loadRunParameters(localWorkspace); - setProg( 0.4 ); - progress(m_prog); - runLoadInstrument(fileName,localWorkspace, 0.2, 0.4 ); - setProg( 0.5 ); - progress(m_prog); - // Since all spectra are being loaded if we get to here, - // we can just set the spectrum numbers to start at 1 and increase monotonically - for (int i = 0; i < m_numberOfSpectra; ++i) - { - localWorkspace->getSpectrum(i)->setSpectrumNo(i+1); - } - setProg( 0.6 ); - progress(m_prog); - runLoadMappingTable(fileName,localWorkspace); - setProg( 0.7 ); - progress(m_prog); - if (bLoadlogFiles) - { - runLoadLog(fileName,localWorkspace, 0.5, 0.7); - const int current_period = 1; - createPeriodLogs(current_period,localWorkspace); - } - setProtonCharge(localWorkspace->mutableRun()); - - setProg( 0.8 ); - progress(m_prog); - localWorkspace->populateInstrumentParameters(); - setProg( 0.9 ); - separateOrexcludeMonitors(localWorkspace, bincludeMonitors, bexcludeMonitors, - bseparateMonitors,m_numberOfSpectra,fileName); - setProg( 1.0 ); - progress(m_prog); - setProperty("OutputWorkspace", boost::dynamic_pointer_cast(localWorkspace)); - } - /** This method separates/excludes monitors from output workspace and creates a separate workspace for monitors * THIS METHOD IS ONLY CALLED BY THE goManagedRaw METHOD ABOVE AND NOT IN THE GENERAL CASE * @param localWorkspace :: shared pointer to workspace diff --git a/Code/Mantid/Framework/DataHandling/src/ManagedRawFileWorkspace2D.cpp b/Code/Mantid/Framework/DataHandling/src/ManagedRawFileWorkspace2D.cpp deleted file mode 100644 index 8bfb50911b6a..000000000000 --- a/Code/Mantid/Framework/DataHandling/src/ManagedRawFileWorkspace2D.cpp +++ /dev/null @@ -1,368 +0,0 @@ -#include "MantidDataHandling/ManagedRawFileWorkspace2D.h" -#include "MantidKernel/Exception.h" -#include "MantidAPI/RefAxis.h" -#include "MantidAPI/WorkspaceProperty.h" -#include "MantidAPI/WorkspaceFactory.h" -#include "MantidKernel/UnitFactory.h" -#include "MantidKernel/ConfigService.h" -#include "MantidKernel/System.h" - -#include "LoadRaw/isisraw2.h" -#include -#include -#include -#include -#include -#include "MantidDataObjects/ManagedHistogram1D.h" - -using Mantid::DataObjects::ManagedHistogram1D; - -//DECLARE_WORKSPACE(ManagedRawFileWorkspace2D) - -namespace Mantid -{ - namespace DataHandling - { - namespace - { - // Get a reference to the logger - Kernel::Logger g_log("ManagedRawFileWorkspace2D"); - } - - // Initialise the instance count - int64_t ManagedRawFileWorkspace2D::g_uniqueID = 1; - - /// Constructor - ManagedRawFileWorkspace2D::ManagedRawFileWorkspace2D(const std::string& fileName, int opt) : - ManagedWorkspace2D(), - isisRaw(new ISISRAW2),m_filenameRaw(fileName),m_fileRaw(NULL),m_readIndex(0),m_nmonitorSkipCounter(0) - { - this->setRawFile(opt); - } - - ///Destructor - ManagedRawFileWorkspace2D::~ManagedRawFileWorkspace2D() - { - if (m_fileRaw) fclose(m_fileRaw); - removeTempFile(); - } - - /** Sets the RAW file for this workspace. - @param opt :: Caching option. 0 - cache on local drive if raw file is very slow to read. - 1 - cache anyway, 2 - never cache. - */ - void ManagedRawFileWorkspace2D::setRawFile(const int opt) - { - m_fileRaw = fopen(m_filenameRaw.c_str(),"rb"); - if (m_fileRaw == NULL) - { - throw Kernel::Exception::FileError("Unable to open File:" , m_filenameRaw); - } - - if ( needCache(opt) ) - { - openTempFile(); - } - - isisRaw->ioRAW(m_fileRaw, true); - - m_numberOfBinBoundaries = isisRaw->t_ntc1 + 1; - m_numberOfPeriods = isisRaw->t_nper; - initialize(isisRaw->t_nsp1,m_numberOfBinBoundaries,isisRaw->t_ntc1); - int64_t noOfBlocks = m_noVectors / m_vectorsPerBlock; - if ( noOfBlocks * m_vectorsPerBlock != m_noVectors ) ++noOfBlocks; - m_changedBlock.resize(noOfBlocks,false); - - isisRaw->skipData(m_fileRaw,0); - fgetpos(m_fileRaw, &m_data_pos); //< Save the data start position. - - getTimeChannels(); - getAxis(0)->unit() = Kernel::UnitFactory::Instance().create("TOF"); - setYUnit("Counts"); - setTitle(std::string(isisRaw->r_title, 80)); - } - - /// Constructs the time channel (X) vector(s) - void ManagedRawFileWorkspace2D::getTimeChannels() - { - float* const timeChannels = new float[m_numberOfBinBoundaries]; - isisRaw->getTimeChannels(timeChannels, static_cast(m_numberOfBinBoundaries)); - - const int regimes = isisRaw->daep.n_tr_shift; - if ( regimes >=2 ) - { - g_log.debug() << "Raw file contains " << regimes << " time regimes\n"; - // If more than 1 regime, create a timeChannelsVec for each regime - for (int i=0; i < regimes; ++i) - { - // Create a vector with the 'base' time channels - boost::shared_ptr channelsVec( - new MantidVec(timeChannels,timeChannels + m_numberOfBinBoundaries)); - const double shift = isisRaw->daep.tr_shift[i]; - g_log.debug() << "Time regime " << i+1 << " shifted by " << shift << " microseconds\n"; - // Add on the shift for this vector - std::transform(channelsVec->begin(), channelsVec->end(), - channelsVec->begin(), std::bind2nd(std::plus(),shift)); - m_timeChannels.push_back(channelsVec); - } - // In this case, also need to populate the map of spectrum-regime correspondence - const int64_t ndet = static_cast(isisRaw->i_det); - std::map::iterator hint = m_specTimeRegimes.begin(); - for (int64_t j=0; j < ndet; ++j) - { - // No checking for consistency here - that all detectors for given spectrum - // are declared to use same time regime. Will just use first encountered - hint = m_specTimeRegimes.insert(hint,std::make_pair(isisRaw->spec[j],isisRaw->timr[j])); - } - } - else // Just need one in this case - { - boost::shared_ptr channelsVec( - new MantidVec(timeChannels,timeChannels + m_numberOfBinBoundaries)); - m_timeChannels.push_back(channelsVec); - } - // Done with the timeChannels C array so clean up - delete[] timeChannels; - } - - // Pointer to sqrt function (used in calculating errors below) - typedef double (*uf)(double); - static uf dblSqrt = std::sqrt; - - // readData(int) should be changed to readNextSpectrum() returning the spectrum index - // and skipData to skipNextSpectrum() - void ManagedRawFileWorkspace2D::readDataBlock(DataObjects::ManagedDataBlock2D *newBlock,size_t startIndex)const - { - Poco::ScopedLock mutex(m_mutex); - if (!m_fileRaw) - { - g_log.error("Raw file was not open."); - throw std::runtime_error("Raw file was not open."); - } - int64_t blockIndex = startIndex / m_vectorsPerBlock; - - // Modified data is stored in ManagedWorkspace2D flat file. - if (m_changedBlock[blockIndex]) - { - ManagedWorkspace2D::readDataBlock(newBlock,startIndex); - return; - } - - if(m_monitorList.size()>0) - { - if ( static_cast(startIndex) > m_readIndex) - { - while(static_cast(startIndex) > m_readIndex-m_nmonitorSkipCounter) - { - isisRaw->skipData(m_fileRaw,m_readIndex+1);// Adding 1 because we dropped the first spectrum. - ++m_readIndex; - if(isMonitor(m_readIndex)) - ++m_nmonitorSkipCounter; - } - } - else - { - int nwords = 0; - while(static_cast(startIndex)+ m_nmonitorSkipCounter+1 < m_readIndex) - { - if(isMonitor(m_readIndex)) - --m_nmonitorSkipCounter; - --m_readIndex; - nwords += 4*isisRaw->ddes[m_readIndex+1].nwords; - } - if (fseek(m_fileRaw,-nwords,SEEK_CUR) != 0) - { - fclose(m_fileRaw); - removeTempFile(); - g_log.error("Error reading RAW file."); - throw std::runtime_error("ManagedRawFileWorkspace2D: Error reading RAW file."); - } - } - int64_t endIndex = startIndex+m_vectorsPerBlock < m_noVectors?startIndex+m_vectorsPerBlock:m_noVectors; - if (endIndex >= static_cast(m_noVectors)) endIndex = static_cast(m_noVectors); - int64_t index=startIndex; - while(indexskipData(m_fileRaw,m_readIndex+1); - //g_log.error()<<"skipData called for monitor index"<readData(m_fileRaw,m_readIndex+1); - //g_log.error()<<"readData called for spectrum index"<(m_noVectors+m_monitorList.size()) ) - break; - - // The managed histogram we are modifying - ManagedHistogram1D * spec = dynamic_cast(newBlock->getSpectrum(index)); - - MantidVec& y = spec->directDataY(); - y.assign(isisRaw->dat1 + 1, isisRaw->dat1 + m_numberOfBinBoundaries); - //g_log.error()<<"readData called for m_readIndex"<directDataE(); - e.resize(y.size(), 0); - std::transform(y.begin(), y.end(), e.begin(), dblSqrt); - if (m_timeChannels.size() == 1) - spec->directSetX(m_timeChannels[0]); - else - { - // std::map::const_iterator regime = m_specTimeRegimes.find(index+1); - std::map::const_iterator regime = m_specTimeRegimes.find(m_readIndex+1); - if ( regime == m_specTimeRegimes.end() ) - { - g_log.error() << "Spectrum " << index << " not present in spec array:\n"; - g_log.error(" Assuming time regime of spectrum 1"); - regime = m_specTimeRegimes.begin(); - } - spec->directSetX(m_timeChannels[(*regime).second-1]); - } - spec->setLoaded(true); - ++index; - ++m_readIndex; - } - } - - } - else - { - if ( static_cast(startIndex) > m_readIndex) - { - while( static_cast(startIndex) > m_readIndex) - { - isisRaw->skipData(m_fileRaw,m_readIndex+1);// Adding 1 because we dropped the first spectrum. - ++m_readIndex; - } - } - else - { - int nwords = 0; - while( static_cast(startIndex) < m_readIndex) - { - --m_readIndex; - nwords += 4*isisRaw->ddes[m_readIndex+1].nwords; - } - if (fseek(m_fileRaw,-nwords,SEEK_CUR) != 0) - { - fclose(m_fileRaw); - removeTempFile(); - g_log.error("Error reading RAW file."); - throw std::runtime_error("ManagedRawFileWorkspace2D: Error reading RAW file."); - } - } - int64_t endIndex = startIndex+m_vectorsPerBlock < m_noVectors?startIndex+m_vectorsPerBlock:m_noVectors; - if (endIndex >= static_cast(m_noVectors)) endIndex = m_noVectors; - for(int64_t index = startIndex;indexreadData(m_fileRaw,m_readIndex+1); - // g_log.error()<<"counter is "<(newBlock->getSpectrum(index)); - - MantidVec& y = spec->directDataY(); - y.assign(isisRaw->dat1 + 1, isisRaw->dat1 + m_numberOfBinBoundaries); - MantidVec& e = spec->directDataE(); - e.resize(y.size(), 0); - std::transform(y.begin(), y.end(), e.begin(), dblSqrt); - if (m_timeChannels.size() == 1) - spec->directSetX(m_timeChannels[0]); - else - { - std::map::const_iterator regime = m_specTimeRegimes.find(index+1); - if ( regime == m_specTimeRegimes.end() ) - { - g_log.error() << "Spectrum " << index << " not present in spec array:\n"; - g_log.error(" Assuming time regime of spectrum 1"); - regime = m_specTimeRegimes.begin(); - } - spec->directSetX(m_timeChannels[(*regime).second-1]); - } - spec->setLoaded(true); - } - } - - newBlock->hasChanges(false); - newBlock->setLoaded(true); - } - /** This method checks given spectrum is a monitor - * @param readIndex :: a spectrum index - * @return true if it's a monitor ,otherwise false - */ - bool ManagedRawFileWorkspace2D::isMonitor(const specid_t readIndex)const - { - std::vector::const_iterator itr; - for(itr=m_monitorList.begin();itr!=m_monitorList.end();++itr) - { - if((*itr)==readIndex) - return true; - } - return false; - } - - void ManagedRawFileWorkspace2D::writeDataBlock(DataObjects::ManagedDataBlock2D *toWrite) const - { - Poco::ScopedLock mutex(m_mutex); - // ManagedWorkspace2D resets the hasChanges flag but we need to make sure we keep track of it here as well - const bool blockHasChanged = toWrite->hasChanges(); - ManagedWorkspace2D::writeDataBlock(toWrite); - int blockIndex = static_cast(toWrite->minIndex() / m_vectorsPerBlock); - m_changedBlock[blockIndex] = blockHasChanged; - } - - /** - Decides if the raw file must be copied to a cache file on the local drive to improve reading time. - */ - bool ManagedRawFileWorkspace2D::needCache(const int opt) - { - if (opt == 1) return true; - if (opt == 2) return false; - - return Kernel::ConfigService::Instance().isNetworkDrive(m_filenameRaw); - } - - /** Opens a temporary file - */ - void ManagedRawFileWorkspace2D::openTempFile() - { - // Look for the (optional) path from the configuration file - std::string path = Kernel::ConfigService::Instance().getString("ManagedWorkspace.FilePath"); - if( path.empty() || !Poco::File(path).exists() || !Poco::File(path).canWrite() ) - { - path = Mantid::Kernel::ConfigService::Instance().getUserPropertiesDir(); - g_log.debug() << "Temporary file written to " << path << std::endl; - } - if ( ( *(path.rbegin()) != '/' ) && ( *(path.rbegin()) != '\\' ) ) - { - path.push_back('/'); - } - - std::stringstream filename; - filename << "WS2D_" << Poco::Path(m_filenameRaw).getBaseName() <<'_'<< ManagedRawFileWorkspace2D::g_uniqueID <<".raw"; - // Increment the instance count - ++ManagedRawFileWorkspace2D::g_uniqueID; - m_tempfile = path + filename.str(); - Poco::File(m_filenameRaw).copyTo(m_tempfile); - - FILE *fileRaw = fopen(m_tempfile.c_str(),"rb"); - if (fileRaw) - { - fclose(m_fileRaw); - m_fileRaw = fileRaw; - } - - } - - /** Removes the temporary file - */ - void ManagedRawFileWorkspace2D::removeTempFile() const - { - if (!m_tempfile.empty()) Poco::File(m_tempfile).remove(); - } - - - } // namespace DataHandling -} //NamespaceMantid - diff --git a/Code/Mantid/Framework/DataHandling/test/ManagedRawFileWorkspace2DTest.h b/Code/Mantid/Framework/DataHandling/test/ManagedRawFileWorkspace2DTest.h deleted file mode 100644 index 4dd1c931a309..000000000000 --- a/Code/Mantid/Framework/DataHandling/test/ManagedRawFileWorkspace2DTest.h +++ /dev/null @@ -1,300 +0,0 @@ -#ifndef ManagedRawFileWorkspace2DTEST_H_ -#define ManagedRawFileWorkspace2DTEST_H_ - -#include "MantidAPI/FileFinder.h" -#include "MantidAPI/IAlgorithm.h" -#include "MantidDataHandling/LoadRaw3.h" -#include "MantidDataHandling/ManagedRawFileWorkspace2D.h" -#include "MantidGeometry/Instrument/Detector.h" -#include "MantidKernel/ConfigService.h" -#include "MantidKernel/TimeSeriesProperty.h" -#include - -using Mantid::MantidVec; -using namespace Mantid; -using namespace Mantid::API; -using namespace Mantid::DataHandling; -using namespace Mantid::DataObjects; -using namespace Mantid::Kernel; - -class ManagedRawFileWorkspace2DTest : public CxxTest::TestSuite -{ -public: - - static ManagedRawFileWorkspace2DTest *createSuite() { return new ManagedRawFileWorkspace2DTest(); } - static void destroySuite(ManagedRawFileWorkspace2DTest *suite) { delete suite; } - - ManagedRawFileWorkspace2DTest() - { - file = FileFinder::Instance().getFullPath("HET15869.raw"); - Workspace = new ManagedRawFileWorkspace2D(file,2); - } - - virtual ~ManagedRawFileWorkspace2DTest() - { - delete Workspace; - } - - void testSetFile() - { - TS_ASSERT_EQUALS( Workspace->getNumberHistograms(), 2584 ) - TS_ASSERT_EQUALS( Workspace->blocksize(), 1675 ) - TS_ASSERT_EQUALS( Workspace->size(), 4328200 ) - - TS_ASSERT_THROWS_NOTHING( Workspace->readX(0) ) - } - - void testCast() - { - TS_ASSERT( dynamic_cast(Workspace) ) - TS_ASSERT( dynamic_cast(Workspace) ) - TS_ASSERT( dynamic_cast(Workspace) ) - } - - void testId() - { - TS_ASSERT( ! Workspace->id().compare("ManagedRawFileWorkspace2D") ) - } - - void testData() - { - ManagedRawFileWorkspace2D ws(file); - - const MantidVec& x0 = ws.readX(0); - TS_ASSERT_EQUALS( x0[0], 5. ) - TS_ASSERT_EQUALS( x0[10], 7.5 ) - const MantidVec& x100 = ws.readX(100); - TS_ASSERT_EQUALS( x100[0], 5. ) - TS_ASSERT_EQUALS( x100[10], 7.5 ) - - const MantidVec& y0 = ws.readY(0); - TS_ASSERT_EQUALS( y0[0], 0. ) - TS_ASSERT_EQUALS( y0[10], 1. ) - const MantidVec& y100 = ws.readY(100); - TS_ASSERT_EQUALS( y100[0], 1. ) - TS_ASSERT_EQUALS( y100[10], 1. ) - - } - - void testChanges() - { - ManagedRawFileWorkspace2D ws(file); - // Need to ensure that the number of writes is greater than the MRUList size - // so that we check the read/write from the file - // There is no public API to find the size so this will have to do. - const size_t nhist = 400; - for(size_t i = 0; i < nhist; ++i) - { - MantidVec& y0 = ws.dataY(i); - y0[0] = 100.0; - } - - // Check that we have actually changed it - for(size_t i = 0; i < nhist; ++i) - { - const MantidVec& y0 = ws.readY(i); - const std::string msg = "The first value at index " + boost::lexical_cast(i) + " does not have the expected value."; - TSM_ASSERT_EQUALS(msg, y0[0], 100.0 ); - } - } - - // Test is taken from LoadRawTest - void testLoadRaw3() - { - // Make sure we go managed - ConfigServiceImpl& conf = ConfigService::Instance(); - const std::string managed = "ManagedWorkspace.LowerMemoryLimit"; - const std::string oldValue = conf.getString(managed); - conf.setString(managed,"0"); - const std::string managed2 = "ManagedRawFileWorkspace.DoNotUse"; - const std::string oldValue2 = conf.getString(managed2); - conf.setString(managed2,"0"); - - LoadRaw3 loader; - if ( !loader.isInitialized() ) loader.initialize(); - - // Should fail because mandatory parameter has not been set - TS_ASSERT_THROWS(loader.execute(),std::runtime_error); - - std::string inputFile = "HET15869.raw"; - - // Now set it... - loader.setPropertyValue("Filename", inputFile); - - std::string outputSpace = "outer"; - loader.setPropertyValue("OutputWorkspace", outputSpace); - - TS_ASSERT_THROWS_NOTHING(loader.execute()); - TS_ASSERT( loader.isExecuted() ); - - // Get back the saved workspace - Workspace_sptr output; - TS_ASSERT_THROWS_NOTHING(output = AnalysisDataService::Instance().retrieve(outputSpace)); - Workspace2D_const_sptr output2D = boost::dynamic_pointer_cast(output); - TS_ASSERT(boost::dynamic_pointer_cast(output2D) ) - // Should be 2584 for file HET15869.RAW - TS_ASSERT_EQUALS( output2D->getNumberHistograms(), 2584); - // Check two X vectors are the same - TS_ASSERT( (output2D->dataX(99)) == (output2D->dataX(1734)) ); - // Check two Y arrays have the same number of elements - TS_ASSERT_EQUALS( output2D->dataY(673).size(), output2D->dataY(2111).size() ); - // Check one particular value - TS_ASSERT_EQUALS( output2D->dataY(999)[777], 9); - // Check that the error on that value is correct - TS_ASSERT_EQUALS( output2D->dataE(999)[777], 3); - // Check that the error on that value is correct - TS_ASSERT_EQUALS( output2D->dataX(999)[777], 554.1875); - - // Check the unit has been set correctly - TS_ASSERT_EQUALS( output2D->getAxis(0)->unit()->unitID(), "TOF" ) - TS_ASSERT( ! output2D-> isDistribution() ) - - // Check the proton charge has been set correctly - TS_ASSERT_DELTA( output2D->run().getProtonCharge(), 171.0353, 0.0001 ) - - //---------------------------------------------------------------------- - // Tests taken from LoadInstrumentTest to check Child Algorithm is running properly - //---------------------------------------------------------------------- - boost::shared_ptr i = output2D->getInstrument(); - boost::shared_ptr source = i->getSource(); - - TS_ASSERT_EQUALS( source->getName(), "undulator"); - TS_ASSERT_DELTA( source->getPos().Y(), 0.0,0.01); - - boost::shared_ptr samplepos = i->getSample(); - TS_ASSERT_EQUALS( samplepos->getName(), "nickel-holder"); - TS_ASSERT_DELTA( samplepos->getPos().Z(), 0.0,0.01); - - boost::shared_ptr ptrDet103 = boost::dynamic_pointer_cast(i->getDetector(103)); - TS_ASSERT_EQUALS( ptrDet103->getID(), 103); - TS_ASSERT_EQUALS( ptrDet103->getName(), "pixel"); - TS_ASSERT_DELTA( ptrDet103->getPos().X(), 0.4013,0.01); - TS_ASSERT_DELTA( ptrDet103->getPos().Z(), 2.4470,0.01); - - //---------------------------------------------------------------------- - // Test code copied from LoadLogTest to check Child Algorithm is running properly - //---------------------------------------------------------------------- - // boost::shared_ptr sample = output2D->getSample(); - Property *l_property = output2D->run().getLogData( std::string("TEMP1") ); - TimeSeriesProperty *l_timeSeriesDouble = dynamic_cast*>(l_property); - std::string timeSeriesString = l_timeSeriesDouble->value(); - TS_ASSERT_EQUALS( timeSeriesString.substr(0,23), "2007-Nov-13 15:16:20 0" ); - - //---------------------------------------------------------------------- - // Tests to check that spectra-detector mapping is done correctly - //---------------------------------------------------------------------- - // Test one to one mapping, for example spectra 6 has only 1 pixel - TS_ASSERT_EQUALS( output2D->getSpectrum(6)->getDetectorIDs().size(), 1); // rummap.ndet(6),1); - - // Test one to many mapping, for example 10 pixels contribute to spectra 2084 (workspace index 2083) - TS_ASSERT_EQUALS( output2D->getSpectrum(2083)->getDetectorIDs().size(), 10); //map.ndet(2084),10); - - // Check the id number of all pixels contributing - std::set detectorgroup; - detectorgroup = output2D->getSpectrum(2083)->getDetectorIDs(); - std::set::const_iterator it; - int pixnum=101191; - for (it=detectorgroup.begin();it!=detectorgroup.end();it++) - TS_ASSERT_EQUALS(*it,pixnum++); - - //---------------------------------------------------------------------- - // Test new-style spectrum/detector number retrieval - //---------------------------------------------------------------------- - // Just test a few.... - TS_ASSERT_EQUALS( output2D->getAxis(1)->spectraNo(0), 1 ); - TS_ASSERT_EQUALS( output2D->getSpectrum(0)->getSpectrumNo(), 1 ); - TS_ASSERT( output2D->getSpectrum(0)->hasDetectorID(601) ); - TS_ASSERT_EQUALS( output2D->getDetector(0)->getID(), 601); - TS_ASSERT_EQUALS( output2D->getAxis(1)->spectraNo(1500), 1501 ); - TS_ASSERT_EQUALS( output2D->getSpectrum(1500)->getSpectrumNo(), 1501 ); - TS_ASSERT( output2D->getSpectrum(1500)->hasDetectorID(405049) ); - TS_ASSERT_EQUALS( output2D->getDetector(1500)->getID(), 405049); - TS_ASSERT_EQUALS( output2D->getAxis(1)->spectraNo(2580), 2581 ); - TS_ASSERT_EQUALS( output2D->getSpectrum(2580)->getSpectrumNo(), 2581 ); - TS_ASSERT( output2D->getSpectrum(2580)->hasDetectorID(310217) ); - TS_ASSERT_EQUALS( output2D->getDetector(2580)->getID(), 310217); - - AnalysisDataService::Instance().remove(outputSpace); - conf.setString(managed,oldValue); - conf.setString(managed2,oldValue2); - } - -private: - ManagedRawFileWorkspace2D* Workspace; - std::string file; -}; - -////------------------------------------------------------------------------------ -//// Performance test -////------------------------------------------------------------------------------ -// -//class NOTATEST : public CxxTest::TestSuite -//{ -//private: -// const std::string outputSpace; -// -//public: -// // This pair of boilerplate methods prevent the suite being created statically -// // This means the constructor isn't called when running other tests -// static NOTATEST *createSuite() { return new NOTATEST(); } -// static void destroySuite( NOTATEST *suite ) { delete suite; } -// -// NOTATEST() : outputSpace("wishWS") -// { -// // Load the instrument alone so as to isolate the raw file loading time from the instrument loading time -// IAlgorithm * loader = FrameworkManager::Instance().createAlgorithm("LoadEmptyInstrument"); -// loader->setPropertyValue("Filename","WISH_Definition.xml"); -// loader->setPropertyValue("OutputWorkspace", "InstrumentOnly"); -// TS_ASSERT( loader->execute() ); -// } -// -// // This should take ~no time. If it does an unacceptable change has occurred! -// void testLoadTime() -// { -// // Make sure we go managed -// ConfigServiceImpl& conf = ConfigService::Instance(); -// const std::string managed = "ManagedWorkspace.LowerMemoryLimit"; -// const std::string oldValue = conf.getString(managed); -// conf.setString(managed,"0"); -// const std::string managed2 = "ManagedRawFileWorkspace.DoNotUse"; -// const std::string oldValue2 = conf.getString(managed2); -// conf.setString(managed2,"0"); -// const std::string datapath = "datasearch.directories"; -// std::string pathValue = conf.getString(datapath); -// pathValue.append(";../../Data/SystemTests/"); -// conf.setString(datapath,pathValue); -// -// IAlgorithm * loader = FrameworkManager::Instance().createAlgorithm("LoadRaw"); -// //IAlgorithm_sptr loader = AlgorithmFactory::Instance().create("LoadRaw"); -// loader->setPropertyValue("Filename","WISH00016748.raw"); -// loader->setPropertyValue("OutputWorkspace",outputSpace); -// TS_ASSERT( loader->execute() ); -// -// conf.setString(managed,oldValue); -// conf.setString(managed2,oldValue2); -// } -// -// // This also should be very quick (nothing should get written to disk) -// void testReadValues() -// { -// MatrixWorkspace_const_sptr ws = AnalysisDataService::Instance().retrieveWS(outputSpace); -// TS_ASSERT( ws ); -// -// double x(0),y(0),e(0); -// for ( std::size_t i = 0 ; i < ws->getNumberHistograms() ; ++i ) -// { -// x = ws->readX(i)[0]; -// y = ws->readY(i)[0]; -// e = ws->readE(i)[0]; -// } -// -// TS_ASSERT( x > 0.0 ); -// TS_ASSERT( y == 0.0 ); -// TS_ASSERT( e == 0.0 ); -// -// AnalysisDataService::Instance().remove(outputSpace); -// } -// -//}; - -#endif /*ManagedRawFileWorkspace2DTEST_H_*/ diff --git a/Code/Mantid/Framework/Properties/Mantid.properties.template b/Code/Mantid/Framework/Properties/Mantid.properties.template index 9d0fec2b105d..9aa0919a9946 100644 --- a/Code/Mantid/Framework/Properties/Mantid.properties.template +++ b/Code/Mantid/Framework/Properties/Mantid.properties.template @@ -108,8 +108,6 @@ ManagedWorkspace.LowerMemoryLimit = 80 ManagedWorkspace.AlwaysInMemory = 0 ManagedWorkspace.DataBlockSize = 4000 ManagedWorkspace.FilePath = -# Setting this to 1 will disable managedrawfileworkspaces -ManagedRawFileWorkspace.DoNotUse = 0 # Defines the maximum number of cores to use for OpenMP # For machine default set to 0 diff --git a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp index 5fb31fb4f80d..73714e1afa3c 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp @@ -239,10 +239,10 @@ void export_MatrixWorkspace() //------------------------------------------------------------------------------------------------- - static const int NUM_IDS = 9; + static const int NUM_IDS = 8; static const char * WORKSPACE_IDS[NUM_IDS] = {\ "GroupingWorkspace", "ManagedWorkspace2D", - "ManagedRawFileWorkspace2D", "MaskWorkspace", "OffsetsWorkspace", + "MaskWorkspace", "OffsetsWorkspace", "RebinnedOutput", "SpecialWorkspace2D", "Workspace2D", "WorkspaceSingleValue" }; diff --git a/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp b/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp index eed7f0725b6f..92dad1d753ef 100644 --- a/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp +++ b/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp @@ -41,7 +41,6 @@ void WorkspaceIcons::initInternalLookup() m_idToPixmapName["EventWorkspace"] = "mantid_matrix_xpm"; m_idToPixmapName["GroupingWorkspace"] = "mantid_matrix_xpm"; m_idToPixmapName["ManagedWorkspace2D"] = "mantid_matrix_xpm"; - m_idToPixmapName["ManagedRawFileWorkspace2D"] = "mantid_matrix_xpm"; m_idToPixmapName["MaskWorkspace"] = "mantid_matrix_xpm"; m_idToPixmapName["OffsetsWorkspace"] = "mantid_matrix_xpm"; m_idToPixmapName["RebinnedOutput"] = "mantid_matrix_xpm"; From 5ee366d160901d6b88d40f8e2e68fc233600d91f Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Thu, 24 Apr 2014 17:22:36 +0100 Subject: [PATCH 009/126] refs #9364 Performance test --- .../test/CopyInstrumentParametersTest.h | 99 +++++++++++++++++++ 1 file changed, 99 insertions(+) diff --git a/Code/Mantid/Framework/Algorithms/test/CopyInstrumentParametersTest.h b/Code/Mantid/Framework/Algorithms/test/CopyInstrumentParametersTest.h index f010f9fb8bec..98dff9ef48f4 100644 --- a/Code/Mantid/Framework/Algorithms/test/CopyInstrumentParametersTest.h +++ b/Code/Mantid/Framework/Algorithms/test/CopyInstrumentParametersTest.h @@ -191,6 +191,105 @@ class CopyInstrumentParametersTest : public CxxTest::TestSuite CopyInstrumentParameters copyInstParam; +}; + + +class CopyInstrumentParametersTestPerformance : public CxxTest::TestSuite +{ +public: + // This pair of boilerplate methods prevent the suite being created statically + // This means the constructor isn't called when running other tests + static CopyInstrumentParametersTestPerformance *createSuite() { return new CopyInstrumentParametersTestPerformance(); } + static void destroySuite( CopyInstrumentParametersTestPerformance *suite ) { delete suite; } + + + CopyInstrumentParametersTestPerformance(): + m_SourceWSName("SourceWS"),m_TargetWSName("TargWS") + { + size_t n_detectors=44327; + size_t n_Parameters=200; + // Create input workspace with parameterized instrument and put into data store + MatrixWorkspace_sptr ws1 = WorkspaceCreationHelper::create2DWorkspaceWithFullInstrument(n_detectors+2, 10, true,false,true,"Instr_calibrated"); + AnalysisDataServiceImpl & dataStore = AnalysisDataService::Instance(); + dataStore.add(m_SourceWSName, ws1); + + + Geometry::Instrument_const_sptr instrument = ws1->getInstrument(); + Geometry::ParameterMap *pmap; + pmap = &(ws1->instrumentParameters()); + for(size_t i=0;iaddDouble(instrument.get(),"Param-"+boost::lexical_cast(i),static_cast(i*10)); + } + // calibrate detectors; + for(size_t i=0;igetDetector(1); + Geometry::ComponentHelper::moveComponent(*det, *pmap, V3D(sin(3.1415926*double(i)),cos(3.1415926*double(i/500)),7), Absolute ); + } + + // Create output workspace with another parameterized instrument and put into data store + MatrixWorkspace_sptr ws2 = WorkspaceCreationHelper::create2DWorkspaceWithFullInstrument(n_detectors, 10, true,false,true,"Instr_base"); + dataStore.add(m_TargetWSName, ws2); + + + copyInstParam.initialize(); + + } + +public: + + void test_copy_performance() + { + // Set properties + TS_ASSERT_THROWS_NOTHING(copyInstParam.setPropertyValue("InputWorkspace", m_SourceWSName )); + TS_ASSERT_THROWS_NOTHING(copyInstParam.setPropertyValue("OutputWorkspace", m_TargetWSName )); + + // Execute Algorithm, should warn but proceed + copyInstParam.setRethrows(true); + TS_ASSERT(copyInstParam.execute()); + TS_ASSERT( copyInstParam.isExecuted() ); + TS_ASSERT(copyInstParam.isInstrumentDifferent()); + + MatrixWorkspace_sptr ws2 =copyInstParam.getProperty("OutputWorkspace"); + auto instr2=ws2->getInstrument(); + + + std::set param_names = instr2->getParameterNames(); + + for(auto it =param_names.begin(); it!=param_names.end();it++) + { + auto name = *it; + double num = boost::lexical_cast(name.substr(6,name.size()-6)); + double val = instr2->getNumberParameter(name)[0]; + TS_ASSERT_DELTA(num,val,1.e-8); + } + + // new detector allocation applied + size_t nDetectors = ws2->getNumberHistograms(); + for(size_t i=0;igetDetector(i); + int id = deto1->getID(); + V3D newPos1 = deto1->getPos(); + TS_ASSERT_EQUALS( id, i+1); + TS_ASSERT_DELTA( newPos1.X() ,sin(3.1415926*double(id)), 0.0001); + TS_ASSERT_DELTA( newPos1.Y() ,cos(3.1415926*double(i/500)), 0.0001); + TS_ASSERT_DELTA( newPos1.Z() , 7, 1.e-6); + + } + + AnalysisDataServiceImpl & dataStore = AnalysisDataService::Instance(); + dataStore.remove(m_SourceWSName); + dataStore.remove(m_TargetWSName); + + } +private: + CopyInstrumentParameters copyInstParam; + const std::string m_SourceWSName,m_TargetWSName; + + }; #endif /*COPYINSTRUMENTPARAMETERSTEST_H_*/ From d7d614ed1027f5ff9e2357f49273018baf2c24af Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Thu, 24 Apr 2014 18:43:45 +0100 Subject: [PATCH 010/126] refs #9364 Working performance test --- .../test/CopyInstrumentParametersTest.h | 24 +++++++++++++------ 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/test/CopyInstrumentParametersTest.h b/Code/Mantid/Framework/Algorithms/test/CopyInstrumentParametersTest.h index 98dff9ef48f4..6ba3a32b5df3 100644 --- a/Code/Mantid/Framework/Algorithms/test/CopyInstrumentParametersTest.h +++ b/Code/Mantid/Framework/Algorithms/test/CopyInstrumentParametersTest.h @@ -21,6 +21,7 @@ #include "MantidGeometry/Instrument/ComponentHelper.h" #include + using namespace Mantid::Algorithms; using namespace Mantid::API; using namespace Mantid::Kernel; @@ -209,7 +210,7 @@ class CopyInstrumentParametersTestPerformance : public CxxTest::TestSuite size_t n_detectors=44327; size_t n_Parameters=200; // Create input workspace with parameterized instrument and put into data store - MatrixWorkspace_sptr ws1 = WorkspaceCreationHelper::create2DWorkspaceWithFullInstrument(n_detectors+2, 10, true,false,true,"Instr_calibrated"); + MatrixWorkspace_sptr ws1 = WorkspaceCreationHelper::create2DWorkspaceWithFullInstrument(static_cast(n_detectors+2), 10, true,false,true,"Instr_calibrated"); AnalysisDataServiceImpl & dataStore = AnalysisDataService::Instance(); dataStore.add(m_SourceWSName, ws1); @@ -225,12 +226,12 @@ class CopyInstrumentParametersTestPerformance : public CxxTest::TestSuite // calibrate detectors; for(size_t i=0;igetDetector(1); + IComponent_const_sptr det =instrument->getDetector(static_cast(i+1)); Geometry::ComponentHelper::moveComponent(*det, *pmap, V3D(sin(3.1415926*double(i)),cos(3.1415926*double(i/500)),7), Absolute ); } // Create output workspace with another parameterized instrument and put into data store - MatrixWorkspace_sptr ws2 = WorkspaceCreationHelper::create2DWorkspaceWithFullInstrument(n_detectors, 10, true,false,true,"Instr_base"); + MatrixWorkspace_sptr ws2 = WorkspaceCreationHelper::create2DWorkspaceWithFullInstrument(static_cast(n_detectors), 10, true,false,true,"Instr_base"); dataStore.add(m_TargetWSName, ws2); @@ -242,17 +243,27 @@ class CopyInstrumentParametersTestPerformance : public CxxTest::TestSuite void test_copy_performance() { + // Set properties TS_ASSERT_THROWS_NOTHING(copyInstParam.setPropertyValue("InputWorkspace", m_SourceWSName )); TS_ASSERT_THROWS_NOTHING(copyInstParam.setPropertyValue("OutputWorkspace", m_TargetWSName )); + // Execute Algorithm, should warn but proceed copyInstParam.setRethrows(true); + + clock_t t_start = clock(); TS_ASSERT(copyInstParam.execute()); + clock_t t_end = clock(); + + double seconds=static_cast(t_end-t_start)/static_cast(CLOCKS_PER_SEC); + std::cout<<" Time to copy all parameters is: "<(m_TargetWSName); auto instr2=ws2->getInstrument(); @@ -263,7 +274,7 @@ class CopyInstrumentParametersTestPerformance : public CxxTest::TestSuite auto name = *it; double num = boost::lexical_cast(name.substr(6,name.size()-6)); double val = instr2->getNumberParameter(name)[0]; - TS_ASSERT_DELTA(num,val,1.e-8); + TS_ASSERT_DELTA(num*10,val,1.e-8); } // new detector allocation applied @@ -274,13 +285,12 @@ class CopyInstrumentParametersTestPerformance : public CxxTest::TestSuite int id = deto1->getID(); V3D newPos1 = deto1->getPos(); TS_ASSERT_EQUALS( id, i+1); - TS_ASSERT_DELTA( newPos1.X() ,sin(3.1415926*double(id)), 0.0001); + TS_ASSERT_DELTA( newPos1.X() ,sin(3.1415926*double(i)), 0.0001); TS_ASSERT_DELTA( newPos1.Y() ,cos(3.1415926*double(i/500)), 0.0001); TS_ASSERT_DELTA( newPos1.Z() , 7, 1.e-6); } - AnalysisDataServiceImpl & dataStore = AnalysisDataService::Instance(); dataStore.remove(m_SourceWSName); dataStore.remove(m_TargetWSName); From ae9556712b19e228518a579702259742375ee74d Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Fri, 25 Apr 2014 16:18:07 +0100 Subject: [PATCH 011/126] refs #9364 Add parameter through pointer implemented and deployed within CopyInstrumentParameters. The map is now copy of itself ? (clear way to introduce cow_ptr to map) --- .../src/CopyInstrumentParameters.cpp | 17 +--- .../MantidGeometry/Instrument/ParameterMap.h | 17 ++++ .../Geometry/src/Instrument/ParameterMap.cpp | 92 +++++++++++++++++-- .../Geometry/test/ParameterMapTest.h | 52 ++++++++--- 4 files changed, 142 insertions(+), 36 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp index ff4be2b61c60..a5f73a2b50f2 100644 --- a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp @@ -83,19 +83,6 @@ void CopyInstrumentParameters::exec() Geometry::ParameterMap targMap; - //// vector of all components contained in the target instrument - //std::vector targComponents; - //// flattens instrument definition tree - //inst2->getChildren(targComponents,true); - //// multimap of existing instrument parameters - //std::multimap existingComponents; - //for(size_t i=0;i(targComponents[i].get())) - // continue; - // existingComponents.insert(std::pair(targComponents[i]->getFullName(),targComponents[i].get())); - //} - auto it = givParams.begin(); for(;it!= givParams.end(); it++) { @@ -130,8 +117,8 @@ void CopyInstrumentParameters::exec() targComp = spTargComp->getBaseComponent(); } // merge maps for existing target component - auto param = it->second.get(); - targMap.add(param->type(),targComp,param->name(),param->asString()); + auto param = it->second; //.get(); + targMap.add(targComp, param); } diff --git a/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/ParameterMap.h b/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/ParameterMap.h index 4d5f68c48a92..87c8082c403f 100644 --- a/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/ParameterMap.h +++ b/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/ParameterMap.h @@ -59,6 +59,16 @@ namespace Geometry File change history is stored at: . Code Documentation is available at: */ +#ifndef HAS_UNORDERED_MAP_H + /// Parameter map iterator typedef + typedef std::multimap >::iterator component_map_it; + typedef std::multimap >::const_iterator component_map_cit; +#else + /// Parameter map iterator typedef + typedef std::tr1::unordered_multimap >::iterator component_map_it; + typedef std::tr1::unordered_multimap >::const_iterator component_map_cit; +#endif + class MANTID_GEOMETRY_DLL ParameterMap { public: @@ -148,6 +158,8 @@ namespace Geometry } } } + /// Method for adding a parameter providing shared pointer to it. The class stores share pointer and increment ref count to it + void add(const IComponent* comp,const boost::shared_ptr ¶m); /** @name Helper methods for adding and updating parameter types */ /// Create or adjust "pos" parameter for a component void addPositionCoordinate(const IComponent* comp,const std::string& name, const double value); @@ -285,6 +297,11 @@ namespace Geometry /// Retrieve a parameter by either creating a new one of getting an existing one Parameter_sptr retrieveParameter(bool &created, const std::string & type, const IComponent* comp, const std::string & name); + /// internal function to get position of the parameter in the parameter map + component_map_it getMapPlace(const IComponent* comp,const char *name, const char * type); + ///const version of the internal function to get position of the parameter in the parameter map + component_map_cit getMapPlace(const IComponent* comp,const char *name, const char * type)const; + /// internal parameter map instance pmap m_map; diff --git a/Code/Mantid/Framework/Geometry/src/Instrument/ParameterMap.cpp b/Code/Mantid/Framework/Geometry/src/Instrument/ParameterMap.cpp index 7544be861f05..baa2d7fbbbe3 100644 --- a/Code/Mantid/Framework/Geometry/src/Instrument/ParameterMap.cpp +++ b/Code/Mantid/Framework/Geometry/src/Instrument/ParameterMap.cpp @@ -247,6 +247,30 @@ namespace Mantid } } + /** Method for adding a parameter providing shared pointer to it. + * @param comp :: A pointer to the component that this parameter is attached to + * @param par :: a shared pointer to existing parameter. The ParameterMap stores share pointer and increment ref count to it + */ + void ParameterMap::add(const IComponent* comp,const boost::shared_ptr &par) + { + // can not add null pointer + if(!par)return; + + PARALLEL_CRITICAL(parameter_add) + { + auto existing_par = getMapPlace(comp,par->name().c_str(),""); + if (existing_par != m_map.end()) + { + existing_par->second = par; + } + else + { + m_map.insert(std::make_pair(comp->getComponentID(),par)); + } + } + + } + /** Create or adjust "pos" parameter for a component * Assumed that name either equals "x", "y" or "z" otherwise this * method will not add or modify "pos" parameter @@ -571,11 +595,62 @@ namespace Mantid { Parameter_sptr result; if(!comp) return result; - const bool anytype = (strlen(type) == 0); + PARALLEL_CRITICAL(ParameterMap_get) { - if( !m_map.empty() ) - { + auto itr = getMapPlace(comp,name, type); + if (itr != m_map.end()) + result = itr->second; + } + return result; + } + + /**Return an iterator pointing to a named parameter of a given type. + * @param comp :: Component to which parameter is related + * @param name :: Parameter name + * @param type :: An optional type string. If empty, any type is returned + * @returns The iterator parameter of the given type if it exists or a NULL shared pointer if not + */ + component_map_it ParameterMap::getMapPlace(const IComponent* comp,const char *name, const char * type) + { + pmap_it result = m_map.end(); + if(!comp) return result; + const bool anytype = (strlen(type) == 0); + if( !m_map.empty() ) + { + const ComponentID id = comp->getComponentID(); + pmap_it it_found = m_map.find(id); + if (it_found != m_map.end()) + { + pmap_it itr = m_map.lower_bound(id); + pmap_it itr_end = m_map.upper_bound(id); + for( ; itr != itr_end; ++itr ) + { + Parameter_sptr param = itr->second; + if( boost::iequals(param->nameAsCString(), name) && (anytype || param->type() == type) ) + { + result = itr; + break; + } + } + } + } + return result; + } + + /**Return a const iterator pointing to a named parameter of a given type. + * @param comp :: Component to which parameter is related + * @param name :: Parameter name + * @param type :: An optional type string. If empty, any type is returned + * @returns The iterator parameter of the given type if it exists or a NULL shared pointer if not + */ + component_map_cit ParameterMap::getMapPlace(const IComponent* comp,const char *name, const char * type)const + { + pmap_cit result = m_map.end(); + if(!comp) return result; + const bool anytype = (strlen(type) == 0); + if( !m_map.empty() ) + { const ComponentID id = comp->getComponentID(); pmap_cit it_found = m_map.find(id); if (it_found != m_map.end()) @@ -587,16 +662,17 @@ namespace Mantid Parameter_sptr param = itr->second; if( boost::iequals(param->nameAsCString(), name) && (anytype || param->type() == type) ) { - result = param; + result = itr; break; } } } - } - } + } return result; } + + /** Look for a parameter in the given component by the type of the parameter. * @param comp :: Component to which parameter is related * @param type :: Parameter type @@ -784,7 +860,7 @@ namespace Mantid } } - ///Attempts to retreive a location from the location cache + ///Attempts to retrieve a location from the location cache /// @param comp :: The Component to find the location of /// @param location :: If the location is found it's value will be set here /// @returns true if the location is in the map, otherwise false @@ -810,7 +886,7 @@ namespace Mantid } } - ///Attempts to retreive a rotation from the rotation cache + ///Attempts to retrieve a rotation from the rotation cache /// @param comp :: The Component to find the rotation of /// @param rotation :: If the rotation is found it's value will be set here /// @returns true if the rotation is in the map, otherwise false diff --git a/Code/Mantid/Framework/Geometry/test/ParameterMapTest.h b/Code/Mantid/Framework/Geometry/test/ParameterMapTest.h index c77797d8c161..f9e6f49ef599 100644 --- a/Code/Mantid/Framework/Geometry/test/ParameterMapTest.h +++ b/Code/Mantid/Framework/Geometry/test/ParameterMapTest.h @@ -61,6 +61,7 @@ class ParameterMapTest : public CxxTest::TestSuite ParameterMap pmapA; ParameterMap pmapB; + ParameterMap pmapG; // Empty TS_ASSERT_EQUALS(pmapA,pmapB); @@ -69,36 +70,61 @@ class ParameterMapTest : public CxxTest::TestSuite TS_ASSERT_EQUALS(pmapA,pmapA); // Differs from other TS_ASSERT_DIFFERS(pmapA,pmapB); + TS_ASSERT_DIFFERS(pmapA,pmapG); + + auto par= pmapA.getRecursive(m_testInstrument.get(),name); + pmapG.add(m_testInstrument.get(),par); + TS_ASSERT_EQUALS(pmapA,pmapG); // Same name/value/component pmapB.addDouble(m_testInstrument.get(), name, value); // Now equal TS_ASSERT_EQUALS(pmapA,pmapB); + TS_ASSERT_EQUALS(pmapA,pmapG); - ParameterMap pmapC; + //--- C + ParameterMap pmapC,pmapC1; // Same name/value different component IComponent_sptr comp = m_testInstrument->getChild(0); pmapC.addDouble(comp.get(), name, value); + auto par1=pmapC.getRecursive(comp.get(),name); + pmapC1.add(comp.get(), par1); // Differs from other TS_ASSERT_DIFFERS(pmapA,pmapC); + // Equal + TS_ASSERT_EQUALS(pmapC,pmapC1); + + //--- D // Same name/component different value ParameterMap pmapD; pmapD.addDouble(m_testInstrument.get(), name, value + 1.0); // Differs from other TS_ASSERT_DIFFERS(pmapA,pmapD); + // Adding the same replaces the same par + pmapD.add(m_testInstrument.get(), par1); + // Equal + TS_ASSERT_EQUALS(pmapA,pmapD); + + //--- E // Same value/component different name ParameterMap pmapE; pmapE.addDouble(m_testInstrument.get(), name + "_differ", value); // Differs from other TS_ASSERT_DIFFERS(pmapA,pmapE); + //--- F //Different type ParameterMap pmapF; pmapF.addInt(m_testInstrument.get(), name, 5); // Differs from other TS_ASSERT_DIFFERS(pmapA,pmapF); + // Adding the same replaces the same par regardless of type + pmapF.add(m_testInstrument.get(), par1); + // Equal + TS_ASSERT_EQUALS(pmapA,pmapF); + } void testAdding_A_Parameter_That_Is_Not_Present_Puts_The_Parameter_In() @@ -343,24 +369,24 @@ class ParameterMapTest : public CxxTest::TestSuite void test_copy_from_old_pmap_to_new_pmap_with_new_component(){ - IComponent_sptr oldComp = m_testInstrument->getChild(0); - IComponent_sptr newComp = m_testInstrument->getChild(1); + IComponent_sptr oldComp = m_testInstrument->getChild(0); + IComponent_sptr newComp = m_testInstrument->getChild(1); - ParameterMap oldPMap; - oldPMap.addBool(oldComp.get(), "A", false); - oldPMap.addDouble(oldComp.get(), "B", 1.2); + ParameterMap oldPMap; + oldPMap.addBool(oldComp.get(), "A", false); + oldPMap.addDouble(oldComp.get(), "B", 1.2); - ParameterMap newPMap; + ParameterMap newPMap; - TS_ASSERT_DIFFERS(oldPMap,newPMap); + TS_ASSERT_DIFFERS(oldPMap,newPMap); - newPMap.copyFromParameterMap(oldComp.get(),newComp.get(), &oldPMap); + newPMap.copyFromParameterMap(oldComp.get(),newComp.get(), &oldPMap); - TS_ASSERT_EQUALS(newPMap.contains(newComp.get(), "A", ParameterMap::pBool()), true); - TS_ASSERT_EQUALS(newPMap.contains(newComp.get(), "B", ParameterMap::pDouble()), true); + TS_ASSERT_EQUALS(newPMap.contains(newComp.get(), "A", ParameterMap::pBool()), true); + TS_ASSERT_EQUALS(newPMap.contains(newComp.get(), "B", ParameterMap::pDouble()), true); - Parameter_sptr a = newPMap.get(newComp.get(), "A"); - TS_ASSERT_EQUALS( a->value(), false); + Parameter_sptr a = newPMap.get(newComp.get(), "A"); + TS_ASSERT_EQUALS( a->value(), false); } From a46f4cd242591995c50c36b0c0751cc214940450 Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Fri, 25 Apr 2014 17:19:56 +0100 Subject: [PATCH 012/126] refs #9364 clone method on Parameter and test for it. --- .../inc/MantidGeometry/Instrument/Parameter.h | 5 ++++ .../Geometry/test/ParameterMapTest.h | 27 +++++++++++++++++++ 2 files changed, 32 insertions(+) diff --git a/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/Parameter.h b/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/Parameter.h index 9f0b69f8ffda..bb86e91fb6b5 100644 --- a/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/Parameter.h +++ b/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/Parameter.h @@ -79,6 +79,9 @@ namespace Mantid const std::string& name() const { return m_name; } /// Parameter name const char* nameAsCString() const{ return m_name.c_str(); } + + /// type-independent clone method; + virtual Parameter * clone()const=0; /// Returns the value of the property as a string virtual std::string asString() const{return m_str_value;} @@ -135,6 +138,8 @@ namespace Mantid /// Get the value of the parameter inline const Type& operator()()const{ return m_value; } + Parameter * clone()const + { return new ParameterType(*this);} private: friend class ParameterMap; friend class Parameter; diff --git a/Code/Mantid/Framework/Geometry/test/ParameterMapTest.h b/Code/Mantid/Framework/Geometry/test/ParameterMapTest.h index f9e6f49ef599..269e86e733ce 100644 --- a/Code/Mantid/Framework/Geometry/test/ParameterMapTest.h +++ b/Code/Mantid/Framework/Geometry/test/ParameterMapTest.h @@ -1,9 +1,11 @@ #ifndef PARAMETERMAPTEST_H_ #define PARAMETERMAPTEST_H_ +#include "MantidGeometry/Instrument/Parameter.h" #include "MantidGeometry/Instrument/ParameterMap.h" #include "MantidGeometry/Instrument/Detector.h" #include "MantidTestHelpers/ComponentCreationHelper.h" +#include "MantidKernel/V3D.h" #include #include @@ -127,6 +129,31 @@ class ParameterMapTest : public CxxTest::TestSuite } + void testClone() + { + const double value(5.1); + + ParameterMap pmapA,pmapB; + + pmapA.addDouble(m_testInstrument.get(), "testDouble", value); + pmapA.addV3D(m_testInstrument.get(), "testV3D", Mantid::Kernel::V3D(1,2,3)); + + auto parD= pmapA.getRecursive(m_testInstrument.get(),"testDouble"); + auto parV3= pmapA.getRecursive(m_testInstrument.get(),"testV3D"); + + Mantid::Geometry::Parameter *pParD = parD->clone(); + Mantid::Geometry::Parameter *pParV = parV3->clone(); + + TS_ASSERT_EQUALS(pParD->asString(),parD->asString()) + TS_ASSERT_EQUALS(pParV->asString(),parV3->asString()) + + pmapB.add(m_testInstrument.get(),Parameter_sptr(pParD)); + pmapB.add(m_testInstrument.get(),Parameter_sptr(pParV)); + + TS_ASSERT_EQUALS(pmapA,pmapB); + } + + void testAdding_A_Parameter_That_Is_Not_Present_Puts_The_Parameter_In() { // Add a parameter for the first component of the instrument From 9e500a45ec039458a48a087d9d71a1ac023c0408 Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Fri, 25 Apr 2014 17:35:27 +0100 Subject: [PATCH 013/126] refs #9364 CopyInstrumentParameters clones parameters rather then recreates it through strings --- .../Framework/Algorithms/src/CopyInstrumentParameters.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp index a5f73a2b50f2..abb063df08a0 100644 --- a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp @@ -116,8 +116,10 @@ void CopyInstrumentParameters::exec() } targComp = spTargComp->getBaseComponent(); } - // merge maps for existing target component - auto param = it->second; //.get(); + + // create shared pointer to independent copy of original parameter. Would be easy and nice to have cow_pointer instead of shared_ptr in the parameter map. + auto param = Parameter_sptr(it->second->clone()); + // add new parameter to the maps for existing target component targMap.add(targComp, param); } From a8ac6eed0f2ff83aba782bb866bc8ce979218954 Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Fri, 25 Apr 2014 18:00:42 +0100 Subject: [PATCH 014/126] refs #9364 Avoid copying second parameter map. swap contents of new map with contents of old map instead. --- .../Framework/API/inc/MantidAPI/ExperimentInfo.h | 2 ++ Code/Mantid/Framework/API/src/ExperimentInfo.cpp | 10 ++++++++++ .../Algorithms/src/CopyInstrumentParameters.cpp | 2 +- .../inc/MantidGeometry/Instrument/ParameterMap.h | 6 ++++++ 4 files changed, 19 insertions(+), 1 deletion(-) diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/ExperimentInfo.h b/Code/Mantid/Framework/API/inc/MantidAPI/ExperimentInfo.h index 41e5e65a0a5f..ddf8051b4304 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/ExperimentInfo.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/ExperimentInfo.h @@ -73,6 +73,8 @@ namespace API /// Replaces current parameter map with copy of given map void replaceInstrumentParameters(const Geometry::ParameterMap & pmap); + /// exchange contents of current parameter map with contents of other map) + void swapInstrumentParameters(Geometry::ParameterMap & pmap); /// Cache a lookup of grouped detIDs to member IDs void cacheDetectorGroupings(const det2group_map & mapping); diff --git a/Code/Mantid/Framework/API/src/ExperimentInfo.cpp b/Code/Mantid/Framework/API/src/ExperimentInfo.cpp index e5b056cbe020..8da1f2679ab8 100644 --- a/Code/Mantid/Framework/API/src/ExperimentInfo.cpp +++ b/Code/Mantid/Framework/API/src/ExperimentInfo.cpp @@ -316,6 +316,16 @@ namespace API { this->m_parmap.reset(new ParameterMap(pmap)); } + //--------------------------------------------------------------------------------------- + /** + * exchanges contents of current parameter map with contents of other map) + * @ pmap reference to parameter map which would exchange its contents with current map + */ + void ExperimentInfo::swapInstrumentParameters(Geometry::ParameterMap & pmap) + { + this->m_parmap->swap(pmap); + } + //--------------------------------------------------------------------------------------- /** diff --git a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp index abb063df08a0..97473749b4e7 100644 --- a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp @@ -125,7 +125,7 @@ void CopyInstrumentParameters::exec() } // changed parameters - m_receivingWorkspace->replaceInstrumentParameters( targMap ); + m_receivingWorkspace->swapInstrumentParameters(targMap); } else diff --git a/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/ParameterMap.h b/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/ParameterMap.h index 87c8082c403f..d638377223be 100644 --- a/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/ParameterMap.h +++ b/Code/Mantid/Framework/Geometry/inc/MantidGeometry/Instrument/ParameterMap.h @@ -120,6 +120,12 @@ namespace Geometry m_map.clear(); clearPositionSensitiveCaches(); } + /// method swaps two parameter maps contents each other. All caches contents is nullified (TO DO: it can be efficiently swapped too) + void swap(ParameterMap &other) + { + m_map.swap(other.m_map); + clearPositionSensitiveCaches(); + } /// Clear any parameters with the given name void clearParametersByName(const std::string & name); From 275e70994ccf8c7c0c58a8db6737339c9f952352 Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Fri, 25 Apr 2014 18:08:41 +0100 Subject: [PATCH 015/126] refs #9364 Comments bla bla --- .../Algorithms/src/CopyInstrumentParameters.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp index 97473749b4e7..049166b41377 100644 --- a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp @@ -1,11 +1,12 @@ /*WIKI* -Transfer an instrument from a giving workspace to a receiving workspace for the same instrument. +Transfer an instrument parameters from a giving workspace to a receiving workspace. -The instrument in of the receiving workspace is replaced by a copy of the instrument in the giving workspace -and so gains any manipulations such as calibration done to the instrument in the giving workspace. -The two workspaces can have spectra allocated to their detectors differently. +The instrument parameters in the receiving workspace are REPLACED (despite you can assume from the name of the algorithm) +by a copy of the instrument parameters in the giving workspace +so gaining any manipulations such as calibration done to the instrument in the giving workspace. +Does not work on workspaces with grouped detectors if some of the detectors were calibrated. *WIKI*/ //---------------------------------------------------------------------- From c595e7fa242470a3d6b5cfbfa25a51bd6a509d24 Mon Sep 17 00:00:00 2001 From: Russell Taylor Date: Mon, 28 Apr 2014 13:40:14 -0400 Subject: [PATCH 016/126] Re #9357. Remove Managed Workspaces along with associated classes and references thereto. Now that we only support 64 bit we can just fall back on swap when memory runs out. --- .../Framework/API/inc/MantidAPI/ISpectrum.h | 2 - .../API/inc/MantidAPI/MemoryManager.h | 2 - .../Framework/API/src/MemoryManager.cpp | 74 -- .../Framework/API/src/WorkspaceFactory.cpp | 43 +- .../Framework/API/test/WorkspaceFactoryTest.h | 16 - .../inc/MantidDataHandling/LoadRaw3.h | 5 - .../Framework/DataHandling/src/LoadRaw3.cpp | 87 --- .../DataHandling/test/LoadMappingTableTest.h | 2 - .../DataHandling/test/LoadMuonNexus1Test.h | 1 - .../DataHandling/test/LoadMuonNexus2Test.h | 1 - .../DataHandling/test/LoadRaw3Test.h | 52 -- .../DataHandling/test/LoadRawBin0Test.h | 1 - .../DataHandling/test/LoadRawSpectrum0Test.h | 1 - .../Framework/DataObjects/CMakeLists.txt | 11 - .../MantidDataObjects/AbsManagedWorkspace2D.h | 158 ----- .../inc/MantidDataObjects/Histogram1D.h | 19 +- .../MantidDataObjects/ManagedDataBlock2D.h | 109 --- .../MantidDataObjects/ManagedHistogram1D.h | 207 ------ .../MantidDataObjects/ManagedWorkspace2D.h | 98 --- .../DataObjects/src/AbsManagedWorkspace2D.cpp | 199 ------ .../DataObjects/src/ManagedDataBlock2D.cpp | 206 ------ .../DataObjects/src/ManagedHistogram1D.cpp | 89 --- .../DataObjects/src/ManagedWorkspace2D.cpp | 322 --------- .../DataObjects/test/ManagedDataBlock2DTest.h | 267 -------- .../DataObjects/test/ManagedHistogram1DTest.h | 120 ---- .../DataObjects/test/ManagedWorkspace2DTest.h | 639 ------------------ .../Framework/Kernel/src/ConfigService.cpp | 1 - .../Framework/Kernel/test/ConfigServiceTest.h | 13 +- .../Properties/Mantid.properties.template | 14 - .../api/src/Exports/MatrixWorkspace.cpp | 5 +- .../Mantid/MantidPlot/src/Mantid/MantidUI.cpp | 2 +- .../MantidPlot/src/Mantid/WorkspaceIcons.cpp | 1 - 32 files changed, 15 insertions(+), 2752 deletions(-) delete mode 100644 Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/AbsManagedWorkspace2D.h delete mode 100644 Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedDataBlock2D.h delete mode 100644 Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedHistogram1D.h delete mode 100644 Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedWorkspace2D.h delete mode 100644 Code/Mantid/Framework/DataObjects/src/AbsManagedWorkspace2D.cpp delete mode 100644 Code/Mantid/Framework/DataObjects/src/ManagedDataBlock2D.cpp delete mode 100644 Code/Mantid/Framework/DataObjects/src/ManagedHistogram1D.cpp delete mode 100644 Code/Mantid/Framework/DataObjects/src/ManagedWorkspace2D.cpp delete mode 100644 Code/Mantid/Framework/DataObjects/test/ManagedDataBlock2DTest.h delete mode 100644 Code/Mantid/Framework/DataObjects/test/ManagedHistogram1DTest.h delete mode 100644 Code/Mantid/Framework/DataObjects/test/ManagedWorkspace2DTest.h diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/ISpectrum.h b/Code/Mantid/Framework/API/inc/MantidAPI/ISpectrum.h index 3f37b5998c2e..e535a7bfdb62 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/ISpectrum.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/ISpectrum.h @@ -46,8 +46,6 @@ namespace API */ class DLLExport ISpectrum { - friend class ManagedDataBlock2D; - public: ISpectrum(); ISpectrum(const specid_t specNo); diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/MemoryManager.h b/Code/Mantid/Framework/API/inc/MantidAPI/MemoryManager.h index e058cab31e41..ec9cef64a1e9 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/MemoryManager.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/MemoryManager.h @@ -53,8 +53,6 @@ namespace Mantid public: /// Returns available physical memory in the system in KB. MemoryInfo getMemoryInfo(); - /// Returns true if there is not sufficient memory for a full Workspace2D. - bool goForManagedWorkspace(std::size_t NVectors,std::size_t XLength,std::size_t YLength); /// Release memory back to the system if we linked againsed tcmalloc void releaseFreeMemory(); /// Release memory back to the system if we linked againsed tcmalloc and are above this much use diff --git a/Code/Mantid/Framework/API/src/MemoryManager.cpp b/Code/Mantid/Framework/API/src/MemoryManager.cpp index ae06fee4e2e6..28bdaabb6cb6 100644 --- a/Code/Mantid/Framework/API/src/MemoryManager.cpp +++ b/Code/Mantid/Framework/API/src/MemoryManager.cpp @@ -39,8 +39,6 @@ MemoryManagerImpl::~MemoryManagerImpl() { } - - MemoryInfo MemoryManagerImpl::getMemoryInfo() { Kernel::MemoryStats mem_stats; @@ -51,78 +49,6 @@ MemoryInfo MemoryManagerImpl::getMemoryInfo() return info; } -/** Decides if a ManagedWorkspace2D sould be created for the current memory conditions - and workspace parameters NVectors, XLength,and YLength. - @param NVectors :: the number of vectors - @param XLength :: the size of the X vector - @param YLength :: the size of the Y vector - @return true is managed workspace is needed - */ -bool MemoryManagerImpl::goForManagedWorkspace(std::size_t NVectors, std::size_t XLength, std::size_t YLength) -{ - int AlwaysInMemory;// Check for disabling flag - if (Kernel::ConfigService::Instance().getValue("ManagedWorkspace.AlwaysInMemory", AlwaysInMemory) - && AlwaysInMemory) - return false; - - // check potential size to create and determine trigger - int availPercent; - if (!Kernel::ConfigService::Instance().getValue("ManagedWorkspace.LowerMemoryLimit", availPercent)) - { - // Default to 40% if missing - availPercent = 40; - } - if (availPercent > 150) - { - g_log.warning("ManagedWorkspace.LowerMemoryLimit is not allowed to be greater than 150%."); - availPercent = 150; - } - if (availPercent < 0) - { - g_log.warning("Negative value for ManagedWorkspace.LowerMemoryLimit. Setting to 0."); - availPercent = 0; - } - if (availPercent > 90) - { - g_log.warning("ManagedWorkspace.LowerMemoryLimit is greater than 90%. Danger of memory errors."); - } - MemoryInfo mi = getMemoryInfo(); - size_t triggerSize = mi.availMemory / 100 * availPercent / sizeof(double); - // Avoid int overflow - size_t wsSize = 0; - if (NVectors > 1024) - wsSize = NVectors / 1024 * (YLength * 2 + XLength); - else if (YLength * 2 + XLength > 1024) - wsSize = (YLength * 2 + XLength) / 1024 * NVectors; - else - wsSize = NVectors * (YLength * 2 + XLength) / 1024; - -// g_log.debug() << "Requested memory: " << (wsSize * sizeof(double))/1024 << " MB. " << std::endl; -// g_log.debug() << "Available memory: " << mi.availMemory << " KB.\n"; -// g_log.debug() << "MWS trigger memory: " << triggerSize * sizeof(double) << " KB.\n"; - - bool goManaged = (wsSize > triggerSize); - // If we're on the cusp of going managed, add in the reserved but unused memory - if( goManaged ) - { - // This is called separately as on some systems it is an expensive calculation. - // See Kernel/src/Memory.cpp - reservedMem() for more details - Kernel::MemoryStats mem_stats; - const size_t reserved = mem_stats.reservedMem(); -// g_log.debug() << "Windows - Adding reserved but unused memory of " << reserved << " KB\n"; - mi.availMemory += reserved; - triggerSize += reserved / 100 * availPercent / sizeof(double); - goManaged = (wsSize > triggerSize); - - g_log.debug() << "Requested memory: " << (wsSize * sizeof(double))/1024 << " MB." << std::endl; - g_log.debug() << "Available memory: " << (mi.availMemory)/1024 << " MB." << std::endl; - g_log.debug() << "ManagedWS trigger memory: " << (triggerSize * sizeof(double))/1024 << " MB." << std::endl; - } - - return goManaged; -} - - /** Release any free memory back to the system. * Calling this could help the system avoid going into swap. * NOTE: This only works if you linked against tcmalloc. diff --git a/Code/Mantid/Framework/API/src/WorkspaceFactory.cpp b/Code/Mantid/Framework/API/src/WorkspaceFactory.cpp index a584cf4bab84..7d8e5bacefe3 100644 --- a/Code/Mantid/Framework/API/src/WorkspaceFactory.cpp +++ b/Code/Mantid/Framework/API/src/WorkspaceFactory.cpp @@ -149,9 +149,6 @@ void WorkspaceFactoryImpl::initializeFromParent(const MatrixWorkspace_const_sptr } /** Creates a new instance of the class with the given name, and allocates memory for the arrays - * where it creates and initialises either a Workspace2D or a ManagedWorkspace2D - * according to the size requested and the value of the configuration parameter - * ManagedWorkspace.LowerMemoryLimit (default 40% of available physical memory) Workspace2D only. * @param className The name of the class you wish to create * @param NVectors The number of vectors/histograms/detectors in the workspace * @param XLength The number of X data points/bin boundaries in each vector (must all be the same) @@ -163,46 +160,14 @@ void WorkspaceFactoryImpl::initializeFromParent(const MatrixWorkspace_const_sptr MatrixWorkspace_sptr WorkspaceFactoryImpl::create(const std::string& className, const size_t& NVectors, const size_t& XLength, const size_t& YLength) const { - MatrixWorkspace_sptr ws; - - // Creates a managed workspace if over the trigger size and a 2D workspace is being requested. - // Otherwise calls the vanilla create method. - bool is2D = className.find("2D") != std::string::npos; - if ( MemoryManager::Instance().goForManagedWorkspace(static_cast(NVectors), static_cast(XLength), - static_cast(YLength)) && is2D ) - { - // check if there is enough memory for 100 data blocks - int blockMemory; - if ( ! Kernel::ConfigService::Instance().getValue("ManagedWorkspace.DataBlockSize", blockMemory) - || blockMemory <= 0 ) - { - // default to 1MB if property not found - blockMemory = 1024*1024; - } - - MemoryInfo mi = MemoryManager::Instance().getMemoryInfo(); - if ( static_cast(blockMemory)*100/1024 > mi.availMemory ) - { - throw std::runtime_error("There is not enough memory to allocate the workspace"); - } - - ws = boost::dynamic_pointer_cast(this->create("ManagedWorkspace2D")); - g_log.information("Created a ManagedWorkspace2D"); - } - else - { - // No need for a Managed Workspace - if ( is2D && ( className.substr(0,7) == "Managed" )) - ws = boost::dynamic_pointer_cast(this->create("Workspace2D")); - else - ws = boost::dynamic_pointer_cast(this->create(className)); - } + MatrixWorkspace_sptr ws = boost::dynamic_pointer_cast(this->create(className)); if (!ws) { - g_log.error("Workspace was not created"); - throw std::runtime_error("Workspace was not created"); + g_log.error("Workspace was not created"); + throw std::runtime_error("Workspace was not created"); } + ws->initialize(NVectors,XLength,YLength); return ws; } diff --git a/Code/Mantid/Framework/API/test/WorkspaceFactoryTest.h b/Code/Mantid/Framework/API/test/WorkspaceFactoryTest.h index a28d8cf1dbf2..67fc8db05836 100644 --- a/Code/Mantid/Framework/API/test/WorkspaceFactoryTest.h +++ b/Code/Mantid/Framework/API/test/WorkspaceFactoryTest.h @@ -41,13 +41,6 @@ class WorkspaceFactoryTest : public CxxTest::TestSuite std::vector size; }; - class ManagedWorkspace2DTest: public Workspace2DTest - { - public: - const std::string id() const {return "ManagedWorkspace2DTest";} - size_t getNumberHistograms() const { return 2;} - }; - class NotInFactory : public WorkspaceTester { public: @@ -60,15 +53,6 @@ class WorkspaceFactoryTest : public CxxTest::TestSuite { WorkspaceFactory::Instance().subscribe("Workspace1DTest"); WorkspaceFactory::Instance().subscribe("Workspace2DTest"); - try - { - WorkspaceFactory::Instance().subscribe("ManagedWorkspace2DTest"); - } - catch (std::runtime_error&) - { - // In theory, we shouldn't have the 'real' ManagedWorkspace2D when running this test, but - // in reality we do so need catch the error from trying to subscribe again - } } void testReturnType() diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h index 49998b8b11e2..11a57bae0d54 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h @@ -80,11 +80,6 @@ namespace Mantid void validateWorkspaceSizes( bool bexcludeMonitors ,bool bseparateMonitors, const int64_t normalwsSpecs,const int64_t monitorwsSpecs); - /// This method is useful for separating or excluding monitors from the output workspace - void separateOrexcludeMonitors(DataObjects::Workspace2D_sptr localWorkspace, - bool binclude,bool bexclude,bool bseparate, - int64_t numberOfSpectra,const std::string &fileName); - /// creates output workspace, monitors excluded from this workspace void excludeMonitors(FILE* file,const int& period,const std::vector& monitorList, DataObjects::Workspace2D_sptr ws_sptr); diff --git a/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp b/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp index 559df364766e..906379b23121 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp @@ -573,92 +573,5 @@ namespace Mantid return bMonitor; } - /** This method separates/excludes monitors from output workspace and creates a separate workspace for monitors - * THIS METHOD IS ONLY CALLED BY THE goManagedRaw METHOD ABOVE AND NOT IN THE GENERAL CASE - * @param localWorkspace :: shared pointer to workspace - * @param binclude :: boolean variable for including monitors - * @param bexclude :: boolean variable for excluding monitors - * @param bseparate :: boolean variable for separating the monitor workspace from output workspace - * @param m_numberOfSpectra :: number of spectra - * @param fileName :: raw file name - */ - void LoadRaw3::separateOrexcludeMonitors(DataObjects::Workspace2D_sptr localWorkspace, - bool binclude,bool bexclude,bool bseparate, - int64_t m_numberOfSpectra,const std::string &fileName) - { - (void) binclude; // Avoid compiler warning - - std::vector monitorwsList; - DataObjects::Workspace2D_sptr monitorWorkspace; - FILE *file(NULL); - std::vector monitorSpecList = getmonitorSpectrumList(SpectrumDetectorMapping(localWorkspace.get())); - if (bseparate && !monitorSpecList.empty()) - { - Property *ws = getProperty("OutputWorkspace"); - std::string localWSName = ws->value(); - std::string monitorWSName = localWSName + "_Monitors"; - - declareProperty(new WorkspaceProperty ("MonitorWorkspace", monitorWSName, - Direction::Output)); - //create monitor workspace - const int64_t nMons(static_cast(monitorSpecList.size())); - monitorWorkspace = boost::dynamic_pointer_cast( - WorkspaceFactory::Instance().create(localWorkspace,nMons,m_lengthIn,m_lengthIn-1)); - - setProperty("MonitorWorkspace", boost::dynamic_pointer_cast(monitorWorkspace)); - file =openRawFile(fileName); - ioRaw(file,true ); - } - // Now check whether there is more than one time regime in use - m_noTimeRegimes =getNumberofTimeRegimes(); - // Get the time channel array(s) and store in a vector inside a shared pointer - m_timeChannelsVec = getTimeChannels(m_noTimeRegimes,m_lengthIn); - //read raw file - if (bseparate && !monitorSpecList.empty()) - { - readData(file, 0); - } - int64_t monitorwsIndex = 0; - for (specid_t i = 0; i < m_numberOfSpectra; ++i) - { - int64_t histToRead = i + 1; - if (bseparate && !monitorSpecList.empty()) - { - if (!readData(file, histToRead)) - { - throw std::runtime_error("Error reading raw file"); - } - } - if ((bseparate && !monitorSpecList.empty()) || bexclude) - { - if (isMonitor(monitorSpecList, static_cast(i) + 1)) - { - spec2index_map wsIndexmap; - SpectraAxis* axis = dynamic_cast(localWorkspace->getAxis(1)); - axis->getSpectraIndexMap(wsIndexmap); - spec2index_map::const_iterator wsItr; - wsItr = wsIndexmap.find(static_cast(i + 1)); - if (wsItr != wsIndexmap.end()) - monitorwsList.push_back(static_cast(wsItr->second)); - if (bseparate) - { - monitorWorkspace->getSpectrum(monitorwsIndex)->setSpectrumNo(i+1); - setWorkspaceData(monitorWorkspace, m_timeChannelsVec, monitorwsIndex, i + 1, m_noTimeRegimes,m_lengthIn,1); - ++monitorwsIndex; - } - } - } - - } - if ((bseparate && !monitorwsList.empty()) || bexclude) - { - localWorkspace->setMonitorList(monitorwsList); - if (bseparate) - { - fclose(file); - } - } - } - } // namespace DataHandling } // namespace Mantid diff --git a/Code/Mantid/Framework/DataHandling/test/LoadMappingTableTest.h b/Code/Mantid/Framework/DataHandling/test/LoadMappingTableTest.h index be1cceae7a51..b95336f57465 100644 --- a/Code/Mantid/Framework/DataHandling/test/LoadMappingTableTest.h +++ b/Code/Mantid/Framework/DataHandling/test/LoadMappingTableTest.h @@ -6,7 +6,6 @@ #include "MantidAPI/WorkspaceFactory.h" #include "MantidDataHandling/LoadInstrumentFromRaw.h" #include "MantidDataHandling/LoadMappingTable.h" -#include "MantidDataObjects/ManagedWorkspace2D.h" #include "MantidKernel/ConfigService.h" #include "MantidKernel/TimeSeriesProperty.h" #include @@ -16,7 +15,6 @@ using namespace Mantid; using namespace Mantid::API; using namespace Mantid::Kernel; using namespace Mantid::DataHandling; -using namespace Mantid::DataObjects; class LoadMappingTableTest : public CxxTest::TestSuite { diff --git a/Code/Mantid/Framework/DataHandling/test/LoadMuonNexus1Test.h b/Code/Mantid/Framework/DataHandling/test/LoadMuonNexus1Test.h index f796c0d1b020..4e942bf6cc65 100644 --- a/Code/Mantid/Framework/DataHandling/test/LoadMuonNexus1Test.h +++ b/Code/Mantid/Framework/DataHandling/test/LoadMuonNexus1Test.h @@ -16,7 +16,6 @@ #include "MantidDataHandling/LoadMuonNexus1.h" #include "MantidAPI/WorkspaceFactory.h" -#include "MantidDataObjects/ManagedWorkspace2D.h" #include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/FrameworkManager.h" #include "MantidKernel/ConfigService.h" diff --git a/Code/Mantid/Framework/DataHandling/test/LoadMuonNexus2Test.h b/Code/Mantid/Framework/DataHandling/test/LoadMuonNexus2Test.h index 0d145fdbf48d..e7841302387a 100644 --- a/Code/Mantid/Framework/DataHandling/test/LoadMuonNexus2Test.h +++ b/Code/Mantid/Framework/DataHandling/test/LoadMuonNexus2Test.h @@ -13,7 +13,6 @@ #include "MantidDataHandling/LoadMuonNexus2.h" #include "MantidAPI/WorkspaceFactory.h" -#include "MantidDataObjects/ManagedWorkspace2D.h" #include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/FrameworkManager.h" #include "MantidKernel/ConfigService.h" diff --git a/Code/Mantid/Framework/DataHandling/test/LoadRaw3Test.h b/Code/Mantid/Framework/DataHandling/test/LoadRaw3Test.h index aca30ad89109..6114749f8c70 100644 --- a/Code/Mantid/Framework/DataHandling/test/LoadRaw3Test.h +++ b/Code/Mantid/Framework/DataHandling/test/LoadRaw3Test.h @@ -6,7 +6,6 @@ #include "MantidAPI/WorkspaceFactory.h" #include "MantidAPI/WorkspaceGroup.h" #include "MantidDataHandling/LoadRaw3.h" -#include "MantidDataObjects/ManagedWorkspace2D.h" #include "MantidGeometry/Instrument.h" #include "MantidGeometry/Instrument/Detector.h" #include "MantidKernel/ConfigService.h" @@ -389,7 +388,6 @@ class LoadRaw3Test : public CxxTest::TestSuite TS_ASSERT_THROWS_NOTHING( loader4.execute() ) TS_ASSERT( loader4.isExecuted() ) - // Get back workspace and check it really is a ManagedWorkspace2D Workspace_sptr output; TS_ASSERT_THROWS_NOTHING( output = AnalysisDataService::Instance().retrieve("parameterIDF") ); @@ -890,56 +888,6 @@ class LoadRaw3Test : public CxxTest::TestSuite } - void testWithManagedWorkspace() - { - ConfigServiceImpl& conf = ConfigService::Instance(); - const std::string managed = "ManagedWorkspace.LowerMemoryLimit"; - const std::string oldValue = conf.getString(managed); - conf.setString(managed,"0"); - - LoadRaw3 loader4; - loader4.initialize(); - loader4.setPropertyValue("Filename", inputFile); - loader4.setPropertyValue("OutputWorkspace", "managedws2"); - TS_ASSERT_THROWS_NOTHING( loader4.execute() ) - TS_ASSERT( loader4.isExecuted() ) - - // Get back workspace and check it really is a ManagedWorkspace2D - Workspace_sptr output; - TS_ASSERT_THROWS_NOTHING( output = AnalysisDataService::Instance().retrieve("managedws2") ); - TS_ASSERT( dynamic_cast(output.get()) ) - - AnalysisDataService::Instance().remove("managedws2"); - conf.setString(managed,oldValue); - } - - void testSeparateMonitorsWithManagedWorkspace() - { - ConfigServiceImpl& conf = ConfigService::Instance(); - const std::string managed = "ManagedWorkspace.LowerMemoryLimit"; - const std::string oldValue = conf.getString(managed); - conf.setString(managed,"0"); - - LoadRaw3 loader8; - loader8.initialize(); - loader8.setPropertyValue("Filename", inputFile); - loader8.setPropertyValue("OutputWorkspace", "managedws2"); - loader8.setPropertyValue("LoadMonitors", "Separate"); - TS_ASSERT_THROWS_NOTHING( loader8.execute() ) - TS_ASSERT( loader8.isExecuted() ) - - // Get back workspace and check it really is a ManagedWorkspace2D - Workspace_sptr output; - TS_ASSERT_THROWS_NOTHING( output = AnalysisDataService::Instance().retrieve("managedws2") ); - TS_ASSERT( dynamic_cast(output.get()) ) - Workspace_sptr output1; - TS_ASSERT_THROWS_NOTHING( output1 = AnalysisDataService::Instance().retrieve("managedws2_Monitors") ); - // TS_ASSERT( dynamic_cast(output1.get()) ) - AnalysisDataService::Instance().remove("managedws2"); - AnalysisDataService::Instance().remove("managedws2_Monitors"); - conf.setString(managed,oldValue); - } - void testExecWithRawDatafile_s_type() { LoadRaw3 loader12; diff --git a/Code/Mantid/Framework/DataHandling/test/LoadRawBin0Test.h b/Code/Mantid/Framework/DataHandling/test/LoadRawBin0Test.h index e6014d579695..6a9528ee5a74 100644 --- a/Code/Mantid/Framework/DataHandling/test/LoadRawBin0Test.h +++ b/Code/Mantid/Framework/DataHandling/test/LoadRawBin0Test.h @@ -5,7 +5,6 @@ #include "MantidDataHandling/LoadRawBin0.h" #include "MantidAPI/WorkspaceFactory.h" -#include "MantidDataObjects/ManagedWorkspace2D.h" #include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/FrameworkManager.h" #include "MantidKernel/ConfigService.h" diff --git a/Code/Mantid/Framework/DataHandling/test/LoadRawSpectrum0Test.h b/Code/Mantid/Framework/DataHandling/test/LoadRawSpectrum0Test.h index b96665896b0f..6fc2de8f379f 100644 --- a/Code/Mantid/Framework/DataHandling/test/LoadRawSpectrum0Test.h +++ b/Code/Mantid/Framework/DataHandling/test/LoadRawSpectrum0Test.h @@ -5,7 +5,6 @@ #include "MantidDataHandling/LoadRawSpectrum0.h" #include "MantidAPI/WorkspaceFactory.h" -#include "MantidDataObjects/ManagedWorkspace2D.h" #include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/FrameworkManager.h" #include "MantidKernel/ConfigService.h" diff --git a/Code/Mantid/Framework/DataObjects/CMakeLists.txt b/Code/Mantid/Framework/DataObjects/CMakeLists.txt index 7bc5229f482b..8a90f3cfe0d3 100644 --- a/Code/Mantid/Framework/DataObjects/CMakeLists.txt +++ b/Code/Mantid/Framework/DataObjects/CMakeLists.txt @@ -1,5 +1,4 @@ set ( SRC_FILES - src/AbsManagedWorkspace2D.cpp src/EventList.cpp src/EventWorkspace.cpp src/EventWorkspaceHelpers.cpp @@ -7,9 +6,6 @@ set ( SRC_FILES src/Events.cpp src/GroupingWorkspace.cpp src/Histogram1D.cpp - src/ManagedDataBlock2D.cpp - src/ManagedHistogram1D.cpp - src/ManagedWorkspace2D.cpp src/MaskWorkspace.cpp src/MementoTableWorkspace.cpp src/OffsetsWorkspace.cpp @@ -33,7 +29,6 @@ set ( SRC_UNITY_IGNORE_FILES ) set ( INC_FILES - inc/MantidDataObjects/AbsManagedWorkspace2D.h inc/MantidDataObjects/DllConfig.h inc/MantidDataObjects/EventList.h inc/MantidDataObjects/EventWorkspace.h @@ -42,9 +37,6 @@ set ( INC_FILES inc/MantidDataObjects/Events.h inc/MantidDataObjects/GroupingWorkspace.h inc/MantidDataObjects/Histogram1D.h - inc/MantidDataObjects/ManagedDataBlock2D.h - inc/MantidDataObjects/ManagedHistogram1D.h - inc/MantidDataObjects/ManagedWorkspace2D.h inc/MantidDataObjects/MaskWorkspace.h inc/MantidDataObjects/MementoTableWorkspace.h inc/MantidDataObjects/OffsetsWorkspace.h @@ -69,9 +61,6 @@ set ( TEST_FILES GroupingWorkspaceTest.h Histogram1DTest.h LibraryManagerTest.h - ManagedDataBlock2DTest.h - ManagedHistogram1DTest.h - ManagedWorkspace2DTest.h MaskWorkspaceTest.h MementoTableWorkspaceTest.h OffsetsWorkspaceTest.h diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/AbsManagedWorkspace2D.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/AbsManagedWorkspace2D.h deleted file mode 100644 index 4452e2f2356f..000000000000 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/AbsManagedWorkspace2D.h +++ /dev/null @@ -1,158 +0,0 @@ -#ifndef ABSMANAGEDWORKSPACE2D_H -#define ABSMANAGEDWORKSPACE2D_H - -#include "MantidDataObjects/Workspace2D.h" -#include "MantidKernel/MRUList.h" -#include "MantidDataObjects/ManagedDataBlock2D.h" - -namespace Mantid -{ -namespace DataObjects -{ - - /** For use in the AbsManagedWorkspace2D MRU list */ - class ManagedDataBlockMRUMarker - { - public: - /** Constructor - * @param dataBlockIndex :: index of the data block in the list of data blocks of the ManagedWorkspace2D - */ - ManagedDataBlockMRUMarker(size_t dataBlockIndex) - : m_index(dataBlockIndex) - { - } - - /// Function returns a unique index, used for hashing for MRU list - size_t hashIndexFunction() const - { - return m_index; - } - - /// @return index of the data block in the list of data blocks of the ManagedWorkspace2D - size_t getBlockIndex() const - { - return m_index; - } - - private: - size_t m_index; ///< unique index of a data block - - }; - - - - /** AbsManagedWorkspace2D - - This is an abstract class for a managed workspace. - Implementations must override init(..) which sets m_vectorsPerBlock and - readDataBlock(..) and writeDataBlock(..) - - Copyright © 2008-2012 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory - - This file is part of Mantid. - - Mantid is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - Mantid is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - - File change history is stored at: . - Code Documentation is available at: - */ - class DLLExport AbsManagedWorkspace2D : public Workspace2D - { - friend class ManagedHistogram1D; - - protected: - /// Most-Recently-Used list of markers of ManagedDataBlocks objects. - typedef Mantid::Kernel::MRUList mru_list; - - public: - AbsManagedWorkspace2D(); - virtual ~AbsManagedWorkspace2D(); - - virtual const std::string id() const {return "AbsManagedWorkspace2D";} - - /// Return the underlying ISpectrum ptr at the given workspace index. - virtual Mantid::API::ISpectrum * getSpectrum(const size_t index); - - /// Return the underlying ISpectrum ptr (const version) at the given workspace index. - virtual const Mantid::API::ISpectrum * getSpectrum(const size_t index) const; - - //section required for iteration - virtual std::size_t size() const; - virtual std::size_t blocksize() const; - - /// Returns the size of physical memory the workspace takes - virtual size_t getMemorySize() const = 0; - - /// Managed workspaces are not really thread-safe (and parallel file access - /// would be silly anyway) - virtual bool threadSafe() const { return false; } - - protected: - /// Vector of the data blocks contained. All blocks are in memory but their contents might be empty - std::vector m_blocks; - - /// Initialize - virtual void init(const std::size_t &NVectors, const std::size_t &XLength, const std::size_t &YLength); - - /// Init the blocks alone - void initBlocks(); - - /// Number of blocks in temporary storage - std::size_t getNumberBlocks() const - { - return m_bufferedMarkers.size(); - } - - /// Get a data block for a workspace index - ManagedDataBlock2D* getDataBlock(const std::size_t index) const; - - /// Get and read in a data block only if required by the MRU lsit - void readDataBlockIfNeeded(const std::size_t index) const; - - /// Reads in a data block. - virtual void readDataBlock(ManagedDataBlock2D *newBlock,size_t startIndex)const = 0; - /// Saves the dropped data block to disk. - virtual void writeDataBlock(ManagedDataBlock2D *toWrite) const = 0; - - /// The number of vectors in each data block - std::size_t m_vectorsPerBlock; - /// The length of the X vector in each Histogram1D. Must all be the same. - std::size_t m_XLength; - /// The length of the Y & E vectors in each Histogram1D. Must all be the same. - std::size_t m_YLength; - /// The size in bytes of each vector - std::size_t m_vectorSize; - /// The size in bytes of one block - std::size_t m_blockSize; - - /// Markers used only to track which data blocks to release - mutable mru_list m_bufferedMarkers; - - private: - // Make copy constructor and copy assignment operator private (and without definition) unless they're needed - /// Private copy constructor - AbsManagedWorkspace2D(const AbsManagedWorkspace2D&); - /// Private copy assignment operator - AbsManagedWorkspace2D& operator=(const AbsManagedWorkspace2D&); - - virtual std::size_t getHistogramNumberHelper() const; - - public: - - }; - -} // namespace DataObjects -} // namespace Mantid - -#endif /* ABSMANAGEDWORKSPACE2D_H */ diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/Histogram1D.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/Histogram1D.h index f6bb7b74f38e..deeb407c2155 100644 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/Histogram1D.h +++ b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/Histogram1D.h @@ -4,21 +4,15 @@ #include "MantidAPI/ISpectrum.h" #include "MantidKernel/cow_ptr.h" #include "MantidKernel/System.h" -#include -#include namespace Mantid { namespace DataObjects { /** - 1D histogram implementation. + 1D histogram implementation. - \class Histogram1D Histogram1D.h - \author Laurent C Chapon, ISIS, RAL - \date 26/09/2007 - - Copyright © 2007-8 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory + Copyright © 2007-2014 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory This file is part of Mantid. @@ -40,15 +34,6 @@ namespace DataObjects */ class DLLExport Histogram1D : public Mantid::API::ISpectrum { - friend class ManagedDataBlock2D; - -public: - - // The data storage type used internally in a Histogram1D - // typedef std::vector MantidVec; //Removed redundant typedef - // Data Store: NOTE:: CHANGED TO BREAK THE WRONG USEAGE OF SHARED_PTR - //typedef Kernel::cow_ptr MantidVecPtr; - protected: MantidVecPtr refY; ///< RefCounted Y MantidVecPtr refE; ///< RefCounted Error diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedDataBlock2D.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedDataBlock2D.h deleted file mode 100644 index b3339d32e593..000000000000 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedDataBlock2D.h +++ /dev/null @@ -1,109 +0,0 @@ -#ifndef MANTID_DATAOBJECTS_MANAGEDDATABLOCK2D_H_ -#define MANTID_DATAOBJECTS_MANAGEDDATABLOCK2D_H_ - -//---------------------------------------------------------------------- -// Includes -//---------------------------------------------------------------------- -#include "MantidAPI/ISpectrum.h" -#include "MantidDataObjects/DllConfig.h" -#include "MantidDataObjects/Histogram1D.h" -#include "MantidDataObjects/ManagedHistogram1D.h" -#include "MantidKernel/cow_ptr.h" -#include -#include - -namespace Mantid -{ - -namespace DataObjects -{ -/** Stores a block of 2D data. - The data storage is the same as that of a Workspace2D (i.e. a vector of Histogram1D's), - but no sample, instrument or history data is held here. - The class supports the Workspace iterators. - - Copyright © 2008-2012 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory - - This file is part of Mantid. - - Mantid is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - Mantid is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - - File change history is stored at: . - Code Documentation is available at: -*/ -class DLLExport ManagedDataBlock2D -{ - /// Output a string representation to a stream - friend DLLExport std::fstream& operator<<(std::fstream&, ManagedDataBlock2D&); - /// Input a string representation to a stream - friend DLLExport std::fstream& operator>>(std::fstream&, ManagedDataBlock2D&); - -public: - ManagedDataBlock2D(const std::size_t &minIndex, const std::size_t &noVectors, const std::size_t &XLength, const std::size_t &YLength, - AbsManagedWorkspace2D * parentWS, MantidVecPtr sharedDx); - virtual ~ManagedDataBlock2D(); - - void initialize(); - - int minIndex() const; - bool hasChanges() const; - void hasChanges(bool has); - - void releaseData(); - - size_t getNumSpectra() const - { return m_data.size(); } - - /// Return the underlying ISpectrum ptr at the given workspace index. - virtual Mantid::API::ISpectrum * getSpectrum(const size_t index); - - /// Return the underlying ISpectrum ptr (const version) at the given workspace index. - virtual const Mantid::API::ISpectrum * getSpectrum(const size_t index) const; - - //------------------------------------------------------------------------ - /// @return true if the data was loaded from disk - bool isLoaded() const - { return m_loaded; } - - /** Set the loaded flag - * @param loaded :: bool flag value */ - void setLoaded(bool loaded) - { m_loaded = loaded; } - - -private: - // Make copy constructor and copy assignment operator private (and without definition) unless they're needed - /// Private copy constructor - ManagedDataBlock2D(const ManagedDataBlock2D&); - /// Private copy assignment operator - ManagedDataBlock2D& operator=(const ManagedDataBlock2D&); - - /// The data 'chunk'. NOTE: These pointers are owned by Workspace2D! - std::vector m_data; - - /// The length of the X vector in each Histogram1D. Must all be the same. - const std::size_t m_XLength; - /// The length of the Y & E vectors in each Histogram1D. Must all be the same. - const std::size_t m_YLength; - /// The index of the workspace that this datablock starts from. - const std::size_t m_minIndex; - - /// Is the data block initialized or loaded from disk? - bool m_loaded; -}; - -} // namespace DataObjects -} // namespace Mantid - -#endif /*MANTID_DATAOBJECTS_MANAGEDDATABLOCK2D_H_*/ diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedHistogram1D.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedHistogram1D.h deleted file mode 100644 index d52a9517e1fe..000000000000 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedHistogram1D.h +++ /dev/null @@ -1,207 +0,0 @@ -#ifndef MANTID_DATAOBJECTS_MANAGEDHISTOGRAM1D_H_ -#define MANTID_DATAOBJECTS_MANAGEDHISTOGRAM1D_H_ - -#include "MantidKernel/System.h" -#include "MantidAPI/ISpectrum.h" -#include "MantidDataObjects/Histogram1D.h" -//#include "MantidDataObjects/AbsManagedWorkspace2D.h" -//#include "MantidDataObjects/ManagedDataBlock2D.h" - - -namespace Mantid -{ -namespace DataObjects -{ - - // Forward declaration - class AbsManagedWorkspace2D; - - /** A "managed" version of Histogram1D where the - * data is loaded only when required - - @author Janik Zikovsky - @date 2011-07-26 - - Copyright © 2011 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory - - This file is part of Mantid. - - Mantid is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - Mantid is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - - File change history is stored at: - Code Documentation is available at: - */ - class DLLExport ManagedHistogram1D : public Histogram1D //Mantid::API::ISpectrum - { - public: - friend class ManagedDataBlock2D; - - ManagedHistogram1D(AbsManagedWorkspace2D * parentWS, size_t workspaceIndex); - - ManagedHistogram1D(const ManagedHistogram1D&); - ManagedHistogram1D& operator=(const ManagedHistogram1D&); - virtual ~ManagedHistogram1D(); - - //------------------------------------------------------------------------ - /** Method that retrieves the data from the disk - * if needed. - */ - void retrieveData() const; - - /** Method that clears the data vectors to release - * memory when the spectrum can be released to disk. - */ - void releaseData(); - - // ------------ Y/E data setters ----------------------------- - /// Sets the data. - void setData(const MantidVec& Y) - { retrieveData(); refY.access()=Y; m_dirty=true; } - /// Sets the data and errors - void setData(const MantidVec& Y, const MantidVec& E) - { retrieveData(); refY.access()=Y; refE.access()=E; m_dirty=true; } - - /// Sets the data. - void setData(const MantidVecPtr& Y) - { retrieveData(); refY=Y; m_dirty=true; } - /// Sets the data and errors - void setData(const MantidVecPtr& Y, const MantidVecPtr& E) - { retrieveData(); refY=Y; refE=E; m_dirty=true; } - - /// Sets the data. - void setData(const MantidVecPtr::ptr_type& Y) - { retrieveData(); refY=Y; m_dirty=true; } - /// Sets the data and errors - void setData(const MantidVecPtr::ptr_type& Y, const MantidVecPtr::ptr_type& E) - { retrieveData(); refY=Y; refE=E; m_dirty=true; } - - /// Zero the data (Y&E) in this spectrum - void clearData(); - - // ------------ Y/E data accessors ----------------------------- - // Get the array data - /// Returns the y data const - virtual const MantidVec& dataY() const - { retrieveData(); return *refY; } - /// Returns the error data const - virtual const MantidVec& dataE() const - { retrieveData(); return *refE; } - - ///Returns the y data - virtual MantidVec& dataY() - { retrieveData(); m_dirty=true; return refY.access(); } - ///Returns the error data - virtual MantidVec& dataE() - { retrieveData(); m_dirty=true; return refE.access(); } - - /// Returns the y data const - virtual const MantidVec& readY() const - { retrieveData(); return *refY; } - /// Returns the error data const - virtual const MantidVec& readE() const - { retrieveData(); return *refE; } - - // ------------ X data accessors ----------------------------- - virtual void setX(const MantidVec& X) - { retrieveData(); refX.access()=X; m_dirty = true; } - - virtual void setX(const MantidVecPtr& X) - { retrieveData(); refX=X; m_dirty = true; } - - virtual void setX(const MantidVecPtr::ptr_type& X) - { retrieveData(); refX=X; m_dirty = true; } - - virtual MantidVec& dataX() - { retrieveData(); m_dirty = true; - return refX.access(); } - - virtual const MantidVec& dataX() const - { retrieveData(); - return *refX; } - - virtual const MantidVec& readX() const - { retrieveData(); - return *refX; } - - virtual MantidVecPtr ptrX() const - { retrieveData(); m_dirty = true; - return refX; } - - virtual std::size_t size() const - { retrieveData(); - return refY->size(); - } - - /// Checks for errors - bool isError() const - { retrieveData(); - return refE->empty(); - } - - /// Gets the memory size of the histogram - size_t getMemorySize() const - { return ((refX->size()+refY->size()+refE->size())*sizeof(double)); } - - //------------------------------------------------------------------------ - /// @return true if the data was modified. - bool isDirty() const - { return m_dirty; } - - /** Set the dirty flag - * @param dirty :: bool flag value */ - void setDirty(bool dirty) - { m_dirty = dirty; } - - //------------------------------------------------------------------------ - /// @return true if the data was loaded from disk - bool isLoaded() const - { return m_loaded; } - - /** Set the loaded flag - * @param loaded :: bool flag value */ - void setLoaded(bool loaded) - { m_loaded = loaded; } - - //------------------------------------------------------------------------ - /// @return m_workspaceIndex (for debugging mostly) - size_t getWorkspaceIndex() const - { return m_workspaceIndex; } - - protected: - /// Are the data vectors loaded from the disk? - mutable bool m_loaded; - - /// Was the data modified? - mutable bool m_dirty; - - /// Workspace that owns this histogram - AbsManagedWorkspace2D * m_parentWorkspace; - - /// Index in m_parentWorkspace - size_t m_workspaceIndex; - - public: - // ------------ Direct data accessors, for use by ManagedDataBlock2D ----------------------------- - MantidVec& directDataX() { return refX.access(); } - MantidVec& directDataY() { return refY.access(); } - MantidVec& directDataE() { return refE.access(); } - void directSetX(boost::shared_ptr newX) { refX = newX; } - - }; - - -} // namespace DataObjects -} // namespace Mantid - -#endif /* MANTID_DATAOBJECTS_MANAGEDHISTOGRAM1D_H_ */ diff --git a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedWorkspace2D.h b/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedWorkspace2D.h deleted file mode 100644 index 8bbbd84b26be..000000000000 --- a/Code/Mantid/Framework/DataObjects/inc/MantidDataObjects/ManagedWorkspace2D.h +++ /dev/null @@ -1,98 +0,0 @@ -#ifndef MANTID_DATAOBJECTS_MANAGEDWORKSPACE2D_H_ -#define MANTID_DATAOBJECTS_MANAGEDWORKSPACE2D_H_ - -//---------------------------------------------------------------------- -// Includes -//---------------------------------------------------------------------- -#include "MantidDataObjects/AbsManagedWorkspace2D.h" - -namespace Mantid -{ -namespace DataObjects -{ -/** The ManagedWorkspace2D allows the framework to handle 2D datasets that are too - large to fit in the available system memory by making use of a temporary file. - It is a specialisation of Workspace2D. - - The optional configuration property ManagedWorkspace.DataBlockSize sets the size - (in bytes) of the blocks used to internally buffer data. The default is 1MB. - - @author Russell Taylor, Tessella Support Services plc - @date 22/01/2008 - - Copyright © 2008-2011 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory - - This file is part of Mantid. - - Mantid is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - Mantid is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - - File change history is stored at: . - Code Documentation is available at: -*/ -class DLLExport ManagedWorkspace2D : public AbsManagedWorkspace2D -{ -public: - ManagedWorkspace2D(); - virtual ~ManagedWorkspace2D(); - - virtual const std::string id() const {return "ManagedWorkspace2D";} - - virtual size_t getMemorySize() const; - virtual bool threadSafe() const { return false; } - - std::string get_filename() const; - - /// Get number of temporary files used to store the data. - size_t getNumberFiles() const {return m_datafile.size();} - -protected: - - /// Reads in a data block. - virtual void readDataBlock(ManagedDataBlock2D *newBlock,std::size_t startIndex)const; - /// Saves the dropped data block to disk. - virtual void writeDataBlock(ManagedDataBlock2D *toWrite) const; - -private: - // Make copy constructor and copy assignment operator private (and without definition) unless they're needed - /// Private copy constructor - ManagedWorkspace2D(const ManagedWorkspace2D&); - /// Private copy assignment operator - ManagedWorkspace2D& operator=(const ManagedWorkspace2D&); - - virtual void init(const std::size_t &NVectors, const std::size_t &XLength, const std::size_t &YLength); - - virtual std::size_t getHistogramNumberHelper() const; - - ManagedDataBlock2D* getDataBlock(const std::size_t index) const; - - /// The number of blocks per temporary file - std::size_t m_blocksPerFile; - /// Size of each temp file in bytes - long long m_fileSize; - - /// The name of the temporary file - std::string m_filename; - /// The stream handle to the temporary file used to store the data - mutable std::vector m_datafile; - /// Index written up to in temporary file - mutable int m_indexWrittenTo; - - /// Static instance count. Used to ensure temporary filenames are distinct. - static int g_uniqueID; -}; - -} // namespace DataObjects -} // namespace Mantid - -#endif /*MANTID_DATAOBJECTS_MANAGEDWORKSPACE2D_H_*/ diff --git a/Code/Mantid/Framework/DataObjects/src/AbsManagedWorkspace2D.cpp b/Code/Mantid/Framework/DataObjects/src/AbsManagedWorkspace2D.cpp deleted file mode 100644 index eb3b62ba560f..000000000000 --- a/Code/Mantid/Framework/DataObjects/src/AbsManagedWorkspace2D.cpp +++ /dev/null @@ -1,199 +0,0 @@ -//---------------------------------------------------------------------- -// Includes -//---------------------------------------------------------------------- -#include "MantidDataObjects/AbsManagedWorkspace2D.h" -#include "MantidDataObjects/Workspace2D.h" -#include "MantidDataObjects/ManagedDataBlock2D.h" -#include "MantidAPI/ISpectrum.h" -#include "MantidAPI/RefAxis.h" -#include "MantidAPI/SpectraAxis.h" -#include "MantidKernel/ConfigService.h" - -#include -#include - -#include -#include -#include -#include - -using Mantid::API::ISpectrum; - -namespace Mantid -{ -namespace DataObjects -{ - -using std::size_t; - - -/// Constructor -AbsManagedWorkspace2D::AbsManagedWorkspace2D() : -Workspace2D() -{ -} - - -//------------------------------------------------------------------------------ -/** Sets the size of the workspace and sets up the temporary file. - * The m_vectorsPerBlock value needs to be set by now. - * -* @param NVectors :: The number of vectors/histograms/detectors in the workspace -* @param XLength :: The number of X data points/bin boundaries in each vector (must all be the same) -* @param YLength :: The number of data/error points in each vector (must all be the same) -* @throw std::runtime_error if unable to open a temporary file -*/ -void AbsManagedWorkspace2D::init(const std::size_t &NVectors, const std::size_t &XLength, const std::size_t &YLength) -{ - m_noVectors = NVectors; - m_axes.resize(2); - m_axes[0] = new API::RefAxis(XLength, this); - m_axes[1] = new API::SpectraAxis(this); - m_XLength = XLength; - m_YLength = YLength; -} - -//------------------------------------------------------------------------------ -/** Create all the blocks and spectra in the workspace - * The m_vectorsPerBlock value needs to be set by now. - * Must be called AFTER init() - * - */ -void AbsManagedWorkspace2D::initBlocks() -{ - // Make a default-0 DX vector (X error vector). It will be shared by all spectra - MantidVecPtr sharedDx; - sharedDx.access().resize(m_XLength, 0.0); - - // Create all the data bloocks - m_blocks.clear(); - for (size_t i=0; i m_noVectors) numVectorsInThisBlock = m_noVectors - i; - // Each ManagedDataBlock2D will create its own vectors. - ManagedDataBlock2D * block = new ManagedDataBlock2D(i, numVectorsInThisBlock, m_XLength, m_YLength, this, sharedDx ); - m_blocks.push_back( block ); - } - - // Copy the pointers over into the Workspace2D thing - data.resize(m_noVectors, NULL); - for (size_t i=0; igetSpectrum(i); -} - - - -/// Destructor. Clears the buffer and deletes the temporary file. -AbsManagedWorkspace2D::~AbsManagedWorkspace2D() -{ - // Clear MRU list (minor amount of memory) - m_bufferedMarkers.clear(); - // Delete the blocks (big memory); - for (size_t i=0; i 0) ? m_YLength : 0; -} - - -//-------------------------------------------------------------------------------------------- -/// Return the underlying ISpectrum ptr at the given workspace index. -ISpectrum * AbsManagedWorkspace2D::getSpectrum(const size_t index) -{ - if (index>=m_noVectors) - throw std::range_error("AbsManagedWorkspace2D::getSpectrum, histogram number out of range"); - ISpectrum * spec = getDataBlock(index)->getSpectrum(index); - return spec; -} - - -const ISpectrum * AbsManagedWorkspace2D::getSpectrum(const size_t index) const -{ - if (index>=m_noVectors) - throw std::range_error("AbsManagedWorkspace2D::getSpectrum, histogram number out of range"); - - ISpectrum * spec = const_cast(getDataBlock(index)->getSpectrum(index)); - return spec; -} - -//-------------------------------------------------------------------------------------------- -/** Returns the number of histograms. - * For some reason Visual Studio couldn't deal with the main getHistogramNumber() method - * being virtual so it now just calls this private (and virtual) method which does the work. - * @return the number of histograms associated with the workspace - */ -size_t AbsManagedWorkspace2D::getHistogramNumberHelper() const -{ - return m_noVectors; -} - - -//-------------------------------------------------------------------------------------------- -/** Get a pointer to the data block containing the data corresponding to a given index -* @param index :: The index to search for -* @return A pointer to the data block containing the index requested -*/ -// not really a const method, but need to pretend it is so that const data getters can call it -ManagedDataBlock2D* AbsManagedWorkspace2D::getDataBlock(const std::size_t index) const -{ - // Which clock does this correspond to? - size_t blockIndex = index / m_vectorsPerBlock; - // Address of that block - return const_cast(m_blocks[blockIndex]); -} - - -/** Get and read in a data block only if required by the MRU lsit - * - * @param index :: workspace index of the spectrum wanted - */ -void AbsManagedWorkspace2D::readDataBlockIfNeeded(const std::size_t index) const -{ - // Which block does this correspond to? - size_t blockIndex = index / m_vectorsPerBlock; - - // Read it in first. - ManagedDataBlock2D* readBlock = const_cast(m_blocks[blockIndex]); - this->readDataBlock(readBlock, readBlock->minIndex()); - - // Mark that this latest-read block was recently read into the MRU list - ManagedDataBlockMRUMarker * markerToDrop = m_bufferedMarkers.insert( - new ManagedDataBlockMRUMarker(blockIndex)); - - // Do we need to drop out a data block? - if (markerToDrop) - { - size_t dropIndex = markerToDrop->getBlockIndex(); - //std::cout << "Dropping block at " << dropIndex << " when asked to read block " << blockIndex << std::endl; - delete markerToDrop; - if (dropIndex < m_blocks.size()) - { - // Address of that block - ManagedDataBlock2D* droppedBlock = const_cast(m_blocks[dropIndex]); - // Write it to disk only when needed - if (droppedBlock->hasChanges()) - this->writeDataBlock(droppedBlock); - // Free up the memory - droppedBlock->releaseData(); - } - } - - -} - - -} // namespace DataObjects -} // namespace Mantid diff --git a/Code/Mantid/Framework/DataObjects/src/ManagedDataBlock2D.cpp b/Code/Mantid/Framework/DataObjects/src/ManagedDataBlock2D.cpp deleted file mode 100644 index f5e56b78689a..000000000000 --- a/Code/Mantid/Framework/DataObjects/src/ManagedDataBlock2D.cpp +++ /dev/null @@ -1,206 +0,0 @@ -//---------------------------------------------------------------------- -// Includes -//---------------------------------------------------------------------- -#include "MantidAPI/ISpectrum.h" -#include "MantidAPI/WorkspaceFactory.h" -#include "MantidDataObjects/ManagedDataBlock2D.h" -#include "MantidDataObjects/ManagedHistogram1D.h" -#include "MantidKernel/Exception.h" -#include - -using Mantid::API::ISpectrum; - -namespace Mantid -{ -namespace DataObjects -{ - namespace - { - /// static logger - Kernel::Logger g_log("ManagedDataBlock2D"); - } - -using std::size_t; - - - -/** Constructor. - * @param minIndex :: The index of the workspace that this data block starts at - * @param NVectors :: The number of Histogram1D's in this data block - * @param XLength :: The number of elements in the X data - * @param YLength :: The number of elements in the Y/E data - * @param parentWS :: The workspace that owns this block - * @param sharedDx :: A cow-ptr to a correctly-sized DX vector that every spectrum will share (until written to). - */ -ManagedDataBlock2D::ManagedDataBlock2D(const std::size_t &minIndex, const std::size_t &NVectors, - const std::size_t &XLength, const std::size_t &YLength, AbsManagedWorkspace2D * parentWS, MantidVecPtr sharedDx) : - m_XLength(XLength), m_YLength(YLength), m_minIndex(minIndex), m_loaded(false) -{ -// MantidVecPtr t1; -// t1.access().resize(XLength); //this call initializes array to zero - - m_data.clear(); - for (size_t i=0; isetDx(sharedDx); - //TODO: Anything about Dx? - } - if (!parentWS) - this->initialize(); -} - -//----------------------------------------------------------------------- -/** Initialize the vectors to empty values */ -void ManagedDataBlock2D::initialize() -{ - for (size_t i=0; idirectDataX().resize(m_XLength, 0.0); - m_data[i]->directDataY().resize(m_YLength, 0.0); - m_data[i]->directDataE().resize(m_YLength, 0.0); - // It was 'loaded' so it won't get re-initialized in this block - m_data[i]->setLoaded(true); - } - this->m_loaded = true; -} - -/// Virtual destructor -ManagedDataBlock2D::~ManagedDataBlock2D() -{ - // Do nothing: Workspace2D owns the pointer!!! -} - -/// The minimum index of the workspace data that this data block contains -int ManagedDataBlock2D::minIndex() const // TODO this should return size_t but it breaks lots of things -{ - return static_cast(m_minIndex); -} - -/** Flags whether the data has changed since being read in. - * In fact indicates whether the data has been accessed in a non-const fashion. - * @return True if the data has been changed. - */ -bool ManagedDataBlock2D::hasChanges() const -{ - bool hasChanges = false; - for (std::vector::const_iterator iter = m_data.begin(); iter != m_data.end(); ++iter) - { - const ManagedHistogram1D * it = *iter; - hasChanges = hasChanges || it->isDirty(); - } - return hasChanges; -} - -/** Gives the possibility to drop the flag. Used in ManagedRawFileWorkspace2D atfer - * reading in from a raw file. - * @param has :: True if the data has been changed. - */ -void ManagedDataBlock2D::hasChanges(bool has) -{ - for (std::vector::iterator iter = m_data.begin(); iter != m_data.end(); ++iter) - { - ManagedHistogram1D * it = *iter; - it->m_dirty = has; - } -} - - - -//-------------------------------------------------------------------------------------------- -/// Return the underlying ISpectrum ptr at the given workspace index. -ISpectrum * ManagedDataBlock2D::getSpectrum(const size_t index) -{ - if ( ( index < m_minIndex ) - || ( index >= m_minIndex + m_data.size() ) ) - throw std::range_error("ManagedDataBlock2D::getSpectrum, histogram number out of range"); - return m_data[index-m_minIndex]; -} - -const ISpectrum * ManagedDataBlock2D::getSpectrum(const size_t index) const -{ - if ( ( index < m_minIndex ) - || ( index >= m_minIndex + m_data.size() ) ) - throw std::range_error("ManagedDataBlock2D::getSpectrum, histogram number out of range"); - return m_data[index-m_minIndex]; -} - - -//-------------------------------------------------------------------------------------------- -/** Release the memory in the loaded data blocks */ -void ManagedDataBlock2D::releaseData() -{ - for (std::vector::iterator iter = m_data.begin(); iter != m_data.end(); ++iter) - { - ManagedHistogram1D * it = *iter; - it->releaseData(); - } - this->m_loaded = false; -} - - - -/** Output file stream operator. - * @param fs :: The stream to write to - * @param data :: The object to write to file - * @return stream representation of data - */ -std::fstream& operator<<(std::fstream& fs, ManagedDataBlock2D& data) -{ - for (std::vector::iterator iter = data.m_data.begin(); iter != data.m_data.end(); ++iter) - { - ManagedHistogram1D * it = *iter; - // If anyone's gone and changed the size of the vectors then get them back to the - // correct size, removing elements or adding zeroes as appropriate. - if (it->directDataX().size() != data.m_XLength) - { - it->directDataX().resize(data.m_XLength, 0.0); - g_log.warning() << "X vector resized to " << data.m_XLength << " elements."; - } - fs.write(reinterpret_cast(&(it->directDataX().front())), data.m_XLength * sizeof(double)); - if (it->directDataY().size() != data.m_YLength) - { - it->directDataY().resize(data.m_YLength, 0.0); - g_log.warning() << "Y vector resized to " << data.m_YLength << " elements."; - } - fs.write(reinterpret_cast(&(it->directDataY().front())), data.m_YLength * sizeof(double)); - if (it->directDataE().size() != data.m_YLength) - { - it->directDataE().resize(data.m_YLength, 0.0); - g_log.warning() << "E vector resized to " << data.m_YLength << " elements."; - } - fs.write(reinterpret_cast(&(it->directDataE().front())), data.m_YLength * sizeof(double)); - - // Clear the "dirty" flag since it was just written out. - it->setDirty(false); - } - return fs; -} - -/** Input file stream operator. - * @param fs :: The stream to read from - * @param data :: The object to fill with the read-in data - * @return stream representation of data - */ -std::fstream& operator>>(std::fstream& fs, ManagedDataBlock2D& data) -{ - // Assumes that the ManagedDataBlock2D passed in is the same size as the data to be read in - // Will be ManagedWorkspace2D's job to ensure that this is so - for (std::vector::iterator iter = data.m_data.begin(); iter != data.m_data.end(); ++iter) - { - ManagedHistogram1D * it = *iter; - it->directDataX().resize(data.m_XLength, 0.0); - fs.read(reinterpret_cast(&(it->directDataX().front())), data.m_XLength * sizeof(double)); - it->directDataY().resize(data.m_YLength, 0.0); - fs.read(reinterpret_cast(&(it->directDataY().front())), data.m_YLength * sizeof(double)); - it->directDataE().resize(data.m_YLength, 0.0); - fs.read(reinterpret_cast(&(it->directDataE().front())), data.m_YLength * sizeof(double)); - // Yes, it is loaded - it->setLoaded(true); - } - return fs; -} - -} // namespace DataObjects -} // namespace Mantid diff --git a/Code/Mantid/Framework/DataObjects/src/ManagedHistogram1D.cpp b/Code/Mantid/Framework/DataObjects/src/ManagedHistogram1D.cpp deleted file mode 100644 index 4e060e5a8ac9..000000000000 --- a/Code/Mantid/Framework/DataObjects/src/ManagedHistogram1D.cpp +++ /dev/null @@ -1,89 +0,0 @@ -#include "MantidDataObjects/ManagedHistogram1D.h" -#include "MantidKernel/System.h" -#include "MantidDataObjects/AbsManagedWorkspace2D.h" -#include "MantidDataObjects/ManagedWorkspace2D.h" - -namespace Mantid -{ -namespace DataObjects -{ - - - //---------------------------------------------------------------------------------------------- - /** Constructor - */ - ManagedHistogram1D::ManagedHistogram1D(AbsManagedWorkspace2D * parentWS, size_t workspaceIndex) - : m_loaded(false), m_dirty(false), - m_parentWorkspace(parentWS), m_workspaceIndex(workspaceIndex) - { - } - - //---------------------------------------------------------------------------------------------- - /** Destructor - */ - ManagedHistogram1D::~ManagedHistogram1D() - { - } - - - //------------------------------------------------------------------------ - /** Clear Y and E vectors */ - void ManagedHistogram1D::clearData() - { - retrieveData(); - m_dirty = true; - MantidVec & yValues = this->dataY(); - std::fill(yValues.begin(), yValues.end(), 0.0); - MantidVec & eValues = this->dataE(); - std::fill(eValues.begin(), eValues.end(), 0.0); - } - - - //------------------------------------------------------------------------ - /** Method that retrieves the data from the disk - * if needed. - */ - void ManagedHistogram1D::retrieveData() const - { - // Only load from disk when needed - if (!m_loaded) - { - if (m_parentWorkspace) - { - // This method will read in the data and fill in this (and other nearby) spectra - m_parentWorkspace->readDataBlockIfNeeded(m_workspaceIndex); - } - // OK, we're loaded - m_loaded = true; - // We have not modified anything yet. - m_dirty = false; - } - } - - - //------------------------------------------------------------------------ - /** Method that clears the data vectors to release - * memory when the spectrum can be released to disk. - * The data should have been saved already. - */ - void ManagedHistogram1D::releaseData() - { - if (m_loaded) - { - // Clear all the vectors to release the memory - refX.access().clear(); - MantidVec().swap(refX.access()); - refY.access().clear(); - MantidVec().swap(refY.access()); - refE.access().clear(); - MantidVec().swap(refE.access()); - // Note: we leave DX alone since it is kept in memory always. - // Reset Markers - m_loaded = false; - m_dirty = false; - } - } - -} // namespace Mantid -} // namespace DataObjects - diff --git a/Code/Mantid/Framework/DataObjects/src/ManagedWorkspace2D.cpp b/Code/Mantid/Framework/DataObjects/src/ManagedWorkspace2D.cpp deleted file mode 100644 index 07b69836b2e5..000000000000 --- a/Code/Mantid/Framework/DataObjects/src/ManagedWorkspace2D.cpp +++ /dev/null @@ -1,322 +0,0 @@ -//---------------------------------------------------------------------- -// Includes -//---------------------------------------------------------------------- -#include "MantidDataObjects/ManagedWorkspace2D.h" -#include "MantidKernel/ConfigService.h" -#include "MantidAPI/RefAxis.h" -#include "MantidAPI/SpectraAxis.h" -#include "MantidAPI/WorkspaceFactory.h" -#include -#include - -namespace Mantid -{ -namespace DataObjects -{ - - namespace - { - /// static logger - Kernel::Logger g_log("ManagedWorkspace2D"); - } - -using std::size_t; - -DECLARE_WORKSPACE(ManagedWorkspace2D) - -// Initialise the instance count -int ManagedWorkspace2D::g_uniqueID = 1; - -#ifdef _WIN32 -#pragma warning (push) -#pragma warning( disable:4355 ) -//Disable warning for using this in constructor. -//This is safe as long as the class that gets the pointer does not use any methods on it in it's constructor. -//In this case this is an inner class that is only used internally to this class, and is safe. -#endif //_WIN32 -/// Constructor -ManagedWorkspace2D::ManagedWorkspace2D() : - AbsManagedWorkspace2D(), m_indexWrittenTo(-1) -{ -} -#ifdef _WIN32 -#pragma warning (pop) -#endif //_WIN32 - -//------------------------------------------------------------------------------------------------------ -/** Sets the size of the workspace and sets up the temporary file - * @param NVectors :: The number of vectors/histograms/detectors in the workspace - * @param XLength :: The number of X data points/bin boundaries in each vector (must all be the same) - * @param YLength :: The number of data/error points in each vector (must all be the same) - * @throw std::runtime_error if unable to open a temporary file - */ -void ManagedWorkspace2D::init(const std::size_t &NVectors, const std::size_t &XLength, const std::size_t &YLength) -{ - AbsManagedWorkspace2D::init(NVectors,XLength,YLength); - - m_vectorSize = /*sizeof(int) +*/ ( m_XLength + ( 2*m_YLength ) ) * sizeof(double); - - // CALCULATE BLOCKSIZE - // Get memory size of a block from config file - int blockMemory; - if ( ! Kernel::ConfigService::Instance().getValue("ManagedWorkspace.DataBlockSize", blockMemory) - || blockMemory <= 0 ) - { - // default to 1MB if property not found - blockMemory = 1024*1024; - } - - - m_vectorsPerBlock = blockMemory / static_cast(m_vectorSize); - // Should this ever come out to be zero, then actually set it to 1 - if ( m_vectorsPerBlock == 0 ) m_vectorsPerBlock = 1; - - // Create all the blocks - this->initBlocks(); - - - g_log.debug()<<"blockMemory: "<::max() / (m_vectorsPerBlock * static_cast(m_vectorSize)); - if (std::numeric_limits::max()%(m_vectorsPerBlock * m_vectorSize) != 0) ++m_blocksPerFile; - } - m_fileSize = m_vectorSize * m_vectorsPerBlock * m_blocksPerFile; - - // Now work out the number of files needed - size_t totalBlocks = m_noVectors / m_vectorsPerBlock; - if (m_noVectors%m_vectorsPerBlock != 0) ++totalBlocks; - size_t numberOfFiles = totalBlocks / m_blocksPerFile; - if (totalBlocks%m_blocksPerFile != 0) ++numberOfFiles; - m_datafile.resize(numberOfFiles); - - // Look for the (optional) path from the configuration file - std::string path = Kernel::ConfigService::Instance().getString("ManagedWorkspace.FilePath"); - if( path.empty() || !Poco::File(path).exists() || !Poco::File(path).canWrite() ) - { - path = Kernel::ConfigService::Instance().getUserPropertiesDir(); - g_log.debug() << "Temporary file written to " << path << std::endl; - } - // Append a slash if necessary - if( ( *(path.rbegin()) != '/' ) && ( *(path.rbegin()) != '\\' ) ) - { - path.push_back('/'); - } - - std::stringstream filestem; - filestem << "WS2D" << ManagedWorkspace2D::g_uniqueID; - m_filename = filestem.str() + this->getTitle() + ".tmp"; - // Increment the instance count - ++ManagedWorkspace2D::g_uniqueID; - std::string fullPath = path + m_filename; - - { - std::string fileToOpen = fullPath + "0"; - - // Create the temporary file - m_datafile[0] = new std::fstream(fileToOpen.c_str(), std::ios::in | std::ios::out | std::ios::binary | std::ios::trunc); - - if ( ! *m_datafile[0] ) - { - m_datafile[0]->clear(); - // Try to open in current working directory instead - std::string file = m_filename + "0"; - m_datafile[0]->open(file.c_str(), std::ios::in | std::ios::out | std::ios::binary | std::ios::trunc); - - // Throw an exception if it still doesn't work - if ( ! *m_datafile[0] ) - { - g_log.error("Unable to open temporary data file"); - throw std::runtime_error("ManagedWorkspace2D: Unable to open temporary data file"); - } - } - else - { - m_filename = fullPath; - } - } // block to restrict scope of fileToOpen - - // Set exception flags for fstream so that any problems from now on will throw - m_datafile[0]->exceptions( std::fstream::eofbit | std::fstream::failbit | std::fstream::badbit ); - - // Open the other temporary files (if any) - for (unsigned int i = 1; i < m_datafile.size(); ++i) - { - std::stringstream fileToOpen; - fileToOpen << m_filename << i; - m_datafile[i] = new std::fstream(fileToOpen.str().c_str(), std::ios::in | std::ios::out | std::ios::binary | std::ios::trunc); - if ( ! *m_datafile[i] ) - { - g_log.error("Unable to open temporary data file"); - throw std::runtime_error("ManagedWorkspace2D: Unable to open temporary data file"); - } - m_datafile[i]->exceptions( std::fstream::eofbit | std::fstream::failbit | std::fstream::badbit ); - } - -} - -/// Destructor. Clears the buffer and deletes the temporary file. -ManagedWorkspace2D::~ManagedWorkspace2D() -{ - // delete all ManagedDataBlock2D's - //m_bufferedData.clear(); - // delete the temporary file and fstream objects - for (unsigned int i = 0; i < m_datafile.size(); ++i) - { - m_datafile[i]->close(); - delete m_datafile[i]; - std::stringstream fileToRemove; - fileToRemove << m_filename << i; - remove(fileToRemove.str().c_str()); - } -} - - - -/** This function decides if ManagedDataBlock2D with given startIndex needs to - be loaded from storage and loads it. - @param newBlock :: Returned data block address - @param startIndex :: Starting spectrum index in the block -*/ -void ManagedWorkspace2D::readDataBlock(ManagedDataBlock2D *newBlock,std::size_t startIndex)const -{ - // You only need to read it if it hasn't been loaded before - if (!newBlock->isLoaded()) - { - // Check whether datablock has previously been saved. If so, read it in. - // @todo: Careful here. Without the (int)cast the m_indexWrittenTo variable is cast to a size_t and if it - // is at its default (-1) then this wraps around and the if evaluates to true when it should not, i.e. the - // first time the function is called with startIndex = 0 and m_indexWrittenTo = -1 - if ((int)startIndex <= m_indexWrittenTo) - { - long long seekPoint = startIndex * m_vectorSize; - - int fileIndex = 0; - //while (seekPoint > std::numeric_limits::max()) - while (seekPoint >= m_fileSize) - { - seekPoint -= m_fileSize; - ++fileIndex; - } - - // Safe to cast seekPoint to int because the while loop above guarantees that - // it'll be in range by this point. - m_datafile[fileIndex]->seekg(static_cast(seekPoint), std::ios::beg); - // The stream operator does the loading - *m_datafile[fileIndex] >> *newBlock; - } - else - { - // The block does not exist on file. - // It needs to be created with some empty vectors of the right length. - newBlock->initialize(); - } - } -} - -/** - * Write a data block to disk. - * @param toWrite :: pointer to the ManagedDataBlock2D to write. - */ -void ManagedWorkspace2D::writeDataBlock(ManagedDataBlock2D *toWrite) const -{ - //std::cout << "Writing " << toWrite->minIndex() << std::endl; - //std::cout << ">>> " << m_indexWrittenTo << std::endl; - //std::cout << ">>> " << m_vectorsPerBlock << std::endl; - size_t fileIndex = 0; - // Check whether we need to pad file with zeroes before writing data - if ( toWrite->minIndex() > static_cast(m_indexWrittenTo+m_vectorsPerBlock) /*&& m_indexWrittenTo >= 0*/ ) - { - if ( m_indexWrittenTo < 0 ) - { - fileIndex = 0; - } - else - { - fileIndex = m_indexWrittenTo / (m_vectorsPerBlock * m_blocksPerFile); - } - - m_datafile[fileIndex]->seekp(0, std::ios::end); - //const int speczero = 0; - const std::vector xzeroes(m_XLength); - const std::vector yzeroes(m_YLength); - // if i is a workspace index the loop has to start with 1 because m_indexWrittenTo + 0 is the index - // of the last saved histogram. - for (int i = 1; i < (toWrite->minIndex() - m_indexWrittenTo); ++i) - { - size_t fi = (m_indexWrittenTo + i) / (m_blocksPerFile * m_vectorsPerBlock); - if ( fi > fileIndex ) - { - fileIndex = fi; - m_datafile[fileIndex]->seekp(0, std::ios::beg); - } - - //std::cerr << "Zeroes to " << fi << ' ' << m_indexWrittenTo + i << ' ' << m_datafile[fileIndex]->tellg() << std::endl; - - m_datafile[fileIndex]->write(reinterpret_cast(const_cast(&*xzeroes.begin())), - m_XLength * sizeof(double)); - m_datafile[fileIndex]->write(reinterpret_cast(const_cast(&*yzeroes.begin())), - m_YLength * sizeof(double)); - m_datafile[fileIndex]->write(reinterpret_cast(const_cast(&*yzeroes.begin())), - m_YLength * sizeof(double)); - // these don't match the ManagedWorkspace2D file stream operators. - //m_datafile[fileIndex]->write((char *) &*yzeroes.begin(), m_YLength * sizeof(double)); - //m_datafile[fileIndex]->write((char *) &speczero, sizeof(int) ); - } - //std::cout << "Here!!!!" << std::endl; - } - else - // If no padding needed, go to correct place in file - { - long long seekPoint = toWrite->minIndex() * m_vectorSize; - - //while (seekPoint > std::numeric_limits::max()) - while (seekPoint >= m_fileSize) - { - seekPoint -= m_fileSize; - ++fileIndex; - } - - // Safe to cast seekPoint to int because the while loop above guarantees that - // it'll be in range by this point. - m_datafile[fileIndex]->seekp(static_cast(seekPoint), std::ios::beg); - //std::cout << "Now here!!!!" << std::endl; - } - - *m_datafile[fileIndex] << *toWrite; - m_indexWrittenTo = std::max(m_indexWrittenTo, toWrite->minIndex()); -} - - -/** Returns the number of histograms. - * For some reason Visual Studio couldn't deal with the main getHistogramNumber() method - * being virtual so it now just calls this private (and virtual) method which does the work. - * @return the number of histograms assocaited with the workspace - */ -size_t ManagedWorkspace2D::getHistogramNumberHelper() const -{ - return m_noVectors; -} - -/// Return the size used in memory -size_t ManagedWorkspace2D::getMemorySize() const -{ - return size_t(m_vectorSize)*size_t(m_bufferedMarkers.size())*size_t(m_vectorsPerBlock); -} - -/// Return the full path to the file used. -std::string ManagedWorkspace2D::get_filename() const -{ - return this->m_filename; -} - -} // namespace DataObjects -} // namespace Mantid diff --git a/Code/Mantid/Framework/DataObjects/test/ManagedDataBlock2DTest.h b/Code/Mantid/Framework/DataObjects/test/ManagedDataBlock2DTest.h deleted file mode 100644 index bafc8bd0fcd9..000000000000 --- a/Code/Mantid/Framework/DataObjects/test/ManagedDataBlock2DTest.h +++ /dev/null @@ -1,267 +0,0 @@ -#ifndef MANAGEDDATABLOCK2DTEST_H_ -#define MANAGEDDATABLOCK2DTEST_H_ - -#include -#include "MantidDataObjects/ManagedDataBlock2D.h" -#include "MantidAPI/MatrixWorkspace.h" -#include "MantidKernel/cow_ptr.h" - -using namespace Mantid::DataObjects; -using Mantid::MantidVec; -using Mantid::MantidVecPtr; - -class ManagedDataBlock2DTest : public CxxTest::TestSuite -{ -public: - // This pair of boilerplate methods prevent the suite being created statically - // This means the constructor isn't called when running other tests - static ManagedDataBlock2DTest *createSuite() { return new ManagedDataBlock2DTest(); } - static void destroySuite( ManagedDataBlock2DTest *suite ) { delete suite; } - - ManagedDataBlock2DTest() - : data(0,2,4,3, NULL, MantidVecPtr() ) - { - for (int i = 0; i < 4; ++i) - { - data.getSpectrum(0)->dataX()[i] = i; - data.getSpectrum(1)->dataX()[i] = i+4; - } - - for (int i = 0; i < 3; ++i) - { - data.getSpectrum(0)->dataY()[i] = i*10; - data.getSpectrum(0)->dataE()[i] = sqrt(data.getSpectrum(0)->dataY()[i]); - data.getSpectrum(1)->dataY()[i] = i*100; - data.getSpectrum(1)->dataE()[i] = sqrt(data.getSpectrum(1)->dataY()[i]); - } - } - - void testConstructor() - { - ManagedDataBlock2D aBlock(0,2,2,2, NULL, MantidVecPtr()); - TS_ASSERT_EQUALS( aBlock.minIndex(), 0 ); - TS_ASSERT( ! aBlock.hasChanges() ); - TSM_ASSERT("When initialized the block says it is loaded", aBlock.isLoaded() ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(0)->dataX().size(), 2 ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(0)->dataY().size(), 2 ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(0)->dataE().size(), 2 ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(1)->dataX().size(), 2 ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(1)->dataY().size(), 2 ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(1)->dataE().size(), 2 ); - } - - void test_releaseData() - { - ManagedDataBlock2D aBlock(0,2,2,2, NULL, MantidVecPtr()); - TSM_ASSERT("When initialized the block says it is loaded", aBlock.isLoaded() ); - // Spectra start loaded too - ManagedHistogram1D * h0 = dynamic_cast(aBlock.getSpectrum(0)); - ManagedHistogram1D * h1 = dynamic_cast(aBlock.getSpectrum(1)); - TS_ASSERT(h0->isLoaded()); - TS_ASSERT(h1->isLoaded()); - - aBlock.releaseData(); - - // No longer loaded - TS_ASSERT(!h0->isLoaded()); - TS_ASSERT(!h1->isLoaded()); - } - - void testSetX() - { - ManagedDataBlock2D aBlock(0,1,1,1, NULL, MantidVecPtr()); - double aNumber = 5.5; - boost::shared_ptr v( new MantidVec(1, aNumber) ); - TS_ASSERT_THROWS_NOTHING( aBlock.getSpectrum(0)->setX(v) ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(0)->dataX()[0], aNumber ); - TS_ASSERT_THROWS( aBlock.getSpectrum(-1)->setX(v), std::range_error ); - TS_ASSERT_THROWS( aBlock.getSpectrum(1)->setX(v), std::range_error ); - TS_ASSERT( aBlock.hasChanges() ); - } - - void testSpectrumNo() - { - ManagedDataBlock2D aBlock(0,1,1,1, NULL, MantidVecPtr()); - TS_ASSERT_THROWS_NOTHING( aBlock.getSpectrum(0)->setSpectrumNo(1234) ); - // You don't need to save back to disk since that's in memory all the time - TS_ASSERT( !aBlock.hasChanges() ); - } - - void testDetectorIDs() - { - ManagedDataBlock2D aBlock(0,1,1,1, NULL, MantidVecPtr()); - TS_ASSERT_THROWS_NOTHING( aBlock.getSpectrum(0)->addDetectorID(1234) ); - // You don't need to save back to disk since that's in memory all the time - TS_ASSERT( !aBlock.hasChanges() ); - } - - void testSetData() - { - ManagedDataBlock2D aBlock(0,1,1,1, NULL, MantidVecPtr()); - double aNumber = 9.9; - boost::shared_ptr v( new MantidVec(1, aNumber) ); - double anotherNumber = 3.3; - boost::shared_ptr w( new MantidVec(1, anotherNumber) ); - TS_ASSERT_THROWS_NOTHING( aBlock.getSpectrum(0)->setData(v,v) ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(0)->dataY()[0], aNumber ) ; - TS_ASSERT_THROWS( aBlock.getSpectrum(-1)->setData(v,v), std::range_error ); - TS_ASSERT_THROWS( aBlock.getSpectrum(1)->setData(v,v), std::range_error ); - - double yetAnotherNumber = 2.25; - (*v)[0] = yetAnotherNumber; - TS_ASSERT_THROWS_NOTHING( aBlock.getSpectrum(0)->setData(v,w) ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(0)->dataY()[0], yetAnotherNumber ); - TS_ASSERT_EQUALS( aBlock.getSpectrum(0)->dataE()[0], anotherNumber ); - TS_ASSERT_THROWS( aBlock.getSpectrum(-1)->setData(v,w), std::range_error ); - TS_ASSERT_THROWS( aBlock.getSpectrum(1)->setData(v,w), std::range_error ); - TS_ASSERT( aBlock.hasChanges() ); - } - - void testDataX() - { - dataXTester(data); - } - - void testDataY() - { - dataYTester(data); - } - - void testDataE() - { - dataETester(data); - } - - void testStreamOperators() - { - std::fstream outfile("ManagedDataBlock2DTest.tmp", std::ios::binary | std::ios::out); - TS_ASSERT( outfile ); - outfile << data; - outfile.close(); - - std::fstream infile("ManagedDataBlock2DTest.tmp", std::ios::binary | std::ios::in); - TS_ASSERT( infile ); - - // Empty block - ManagedDataBlock2D readData(0,2,4,3, NULL, MantidVecPtr()); - - // The spectra say "loaded" because they were initialized - ManagedHistogram1D * h0 = dynamic_cast(readData.getSpectrum(0)); - ManagedHistogram1D * h1 = dynamic_cast(readData.getSpectrum(1)); - TS_ASSERT(h0->isLoaded()); - TS_ASSERT(h1->isLoaded()); - - infile >> readData; - // use const methods so that I can check the changes flag behaves as it should - TS_ASSERT( ! readData.hasChanges() ); - dataXTester(readData); - dataYTester(readData); - dataETester(readData); - TS_ASSERT( readData.hasChanges() ); - - // The spectra are now marked as loaded - TS_ASSERT(h0->isLoaded()); - TS_ASSERT(h1->isLoaded()); - - - remove("ManagedDataBlock2DTest.tmp"); - } - -private: - ManagedDataBlock2D data; - - void dataXTester(ManagedDataBlock2D &dataToTest) - { - MantidVec x; - TS_ASSERT_THROWS( dataToTest.getSpectrum(-1)->dataX(), std::range_error ); - TS_ASSERT_THROWS_NOTHING( x = dataToTest.getSpectrum(0)->dataX() ); - MantidVec xx; - TS_ASSERT_THROWS_NOTHING( xx = dataToTest.getSpectrum(1)->dataX() ); - TS_ASSERT_THROWS( dataToTest.getSpectrum(2)->dataX(), std::range_error ); - TS_ASSERT_EQUALS( x.size(), 4 ); - TS_ASSERT_EQUALS( xx.size(), 4 ); - for (unsigned int i = 0; i < x.size(); ++i) - { - TS_ASSERT_EQUALS( x[i], i ); - TS_ASSERT_EQUALS( xx[i], i+4 ); - } - - // test const version - const ManagedDataBlock2D &constRefToData = dataToTest; - TS_ASSERT_THROWS( const MantidVec v = constRefToData.getSpectrum(-1)->dataX(), std::range_error ); - const MantidVec xc = constRefToData.getSpectrum(0)->dataX(); - const MantidVec xxc = constRefToData.getSpectrum(1)->dataX(); - TS_ASSERT_THROWS( const MantidVec v = constRefToData.getSpectrum(2)->dataX(), std::range_error ); - TS_ASSERT_EQUALS( xc.size(), 4 ); - TS_ASSERT_EQUALS( xxc.size(), 4 ); - for (unsigned int i = 0; i < xc.size(); ++i) - { - TS_ASSERT_EQUALS( xc[i], i ); - TS_ASSERT_EQUALS( xxc[i], i+4 ); - } - } - - void dataYTester(ManagedDataBlock2D &dataToTest) - { - MantidVec y; - TS_ASSERT_THROWS( dataToTest.getSpectrum(-1)->dataY(), std::range_error ); - TS_ASSERT_THROWS_NOTHING( y = dataToTest.getSpectrum(0)->dataY() ); - MantidVec yy; - TS_ASSERT_THROWS_NOTHING( yy = dataToTest.getSpectrum(1)->dataY() ); - TS_ASSERT_THROWS( dataToTest.getSpectrum(2)->dataY(), std::range_error ); - TS_ASSERT_EQUALS( y.size(), 3 ); - TS_ASSERT_EQUALS( yy.size(), 3 ); - for (unsigned int i = 0; i < y.size(); ++i) - { - TS_ASSERT_EQUALS( y[i], i*10 ); - TS_ASSERT_EQUALS( yy[i], i*100 ); - } - - // test const version - const ManagedDataBlock2D &constRefToData = dataToTest; - TS_ASSERT_THROWS( const MantidVec v = constRefToData.getSpectrum(-1)->dataY(), std::range_error ); - const MantidVec yc = constRefToData.getSpectrum(0)->dataY(); - const MantidVec yyc = constRefToData.getSpectrum(1)->dataY(); - TS_ASSERT_THROWS( const MantidVec v = constRefToData.getSpectrum(2)->dataY(), std::range_error ); - TS_ASSERT_EQUALS( yc.size(), 3 ); - TS_ASSERT_EQUALS( yyc.size(), 3 ); - for (unsigned int i = 0; i < yc.size(); ++i) - { - TS_ASSERT_EQUALS( yc[i], i*10 ); - TS_ASSERT_EQUALS( yyc[i], i*100 ); - } - } - - void dataETester(ManagedDataBlock2D &dataToTest) - { - MantidVec e; - TS_ASSERT_THROWS( dataToTest.getSpectrum(-1)->dataE(), std::range_error ); - TS_ASSERT_THROWS_NOTHING( e = dataToTest.getSpectrum(0)->dataE() ); - MantidVec ee; - TS_ASSERT_THROWS_NOTHING( ee = dataToTest.getSpectrum(1)->dataE() ); - TS_ASSERT_THROWS( dataToTest.getSpectrum(2)->dataE(), std::range_error ); - TS_ASSERT_EQUALS( e.size(), 3 ); - TS_ASSERT_EQUALS( ee.size(), 3 ); - for (unsigned int i = 0; i < e.size(); ++i) - { - TS_ASSERT_EQUALS( e[i], sqrt(i*10.0) ); - TS_ASSERT_EQUALS( ee[i], sqrt(i*100.0) ); - } - - // test const version - const ManagedDataBlock2D &constRefToData = dataToTest; - TS_ASSERT_THROWS( const MantidVec v = constRefToData.getSpectrum(-1)->dataE(), std::range_error ); - const MantidVec ec = constRefToData.getSpectrum(0)->dataE(); - const MantidVec eec = constRefToData.getSpectrum(1)->dataE(); - TS_ASSERT_THROWS( const MantidVec v = constRefToData.getSpectrum(2)->dataE(), std::range_error ); - TS_ASSERT_EQUALS( ec.size(), 3 ); - TS_ASSERT_EQUALS( eec.size(), 3 ); - for (unsigned int i = 0; i < ec.size(); ++i) - { - TS_ASSERT_EQUALS( ec[i], sqrt(i*10.0) ); - TS_ASSERT_EQUALS( eec[i], sqrt(i*100.0) ); - } - } -}; - -#endif /*MANAGEDDATABLOCK2DTEST_H_*/ diff --git a/Code/Mantid/Framework/DataObjects/test/ManagedHistogram1DTest.h b/Code/Mantid/Framework/DataObjects/test/ManagedHistogram1DTest.h deleted file mode 100644 index 6bb220248ec2..000000000000 --- a/Code/Mantid/Framework/DataObjects/test/ManagedHistogram1DTest.h +++ /dev/null @@ -1,120 +0,0 @@ -#ifndef MANTID_DATAOBJECTS_MANAGEDHISTOGRAM1DTEST_H_ -#define MANTID_DATAOBJECTS_MANAGEDHISTOGRAM1DTEST_H_ - -#include "MantidDataObjects/ManagedHistogram1D.h" -#include "MantidKernel/System.h" -#include "MantidKernel/Timer.h" -#include -#include -#include - -using namespace Mantid; -using namespace Mantid::DataObjects; -using namespace Mantid::API; - -class ManagedHistogram1DTest : public CxxTest::TestSuite -{ -public: - - void test_constructor() - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT_EQUALS( h.getWorkspaceIndex(), 1234); - } - - /** Const access does not set the dirty flag */ - void test_dirtyFlag_const() - { - const ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - const MantidVec & x = h.dataX(); - TS_ASSERT( !h.isDirty() ); - const MantidVec & y = h.dataY(); - TS_ASSERT( !h.isDirty() ); - const MantidVec & e = h.dataE(); - TS_ASSERT( !h.isDirty() ); - const MantidVec & dx = h.dataDx(); - TS_ASSERT( !h.isDirty() ); - UNUSED_ARG(x);UNUSED_ARG(dx);UNUSED_ARG(y);UNUSED_ARG(e); - } - - - /** Non-const access does set the dirty flag (except for Dx)*/ - void test_dirtyFlag_isSet() - { - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - h.dataX(); - TS_ASSERT( h.isDirty() ); - ManagedHistogram1D * h2 = new ManagedHistogram1D(NULL, 1234); - // Check that the method is properly overridden in ISpectrum - ISpectrum * spec = h2; - TS_ASSERT( !h2->isDirty() ); - spec->dataX(); - TS_ASSERT( h2->isDirty() ); - } - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - h.ptrX(); - TS_ASSERT( h.isDirty() ); - } - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - h.dataY(); - TS_ASSERT( h.isDirty() ); - } - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - h.dataE(); - TS_ASSERT( h.isDirty() ); - } - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - h.dataDx(); - // Dx does NOT dirty it - TS_ASSERT( !h.isDirty() ); - } - } - - /** setX or setData() makes it dirty */ - void test_dirtyFlag_isSet_whenUsingSetData() - { - MantidVec X, Y, E; - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - h.setData(Y); - TS_ASSERT( h.isDirty() ); - } - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - h.setData(Y, E); - TS_ASSERT( h.isDirty() ); - } - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - h.setX(X); - TS_ASSERT( h.isDirty() ); - } - { - ManagedHistogram1D h(NULL, 1234); - TS_ASSERT( !h.isDirty() ); - h.setDx(X); - // Dx does NOT dirty it - TS_ASSERT( !h.isDirty() ); - } - } - - -}; - - -#endif /* MANTID_DATAOBJECTS_MANAGEDHISTOGRAM1DTEST_H_ */ - diff --git a/Code/Mantid/Framework/DataObjects/test/ManagedWorkspace2DTest.h b/Code/Mantid/Framework/DataObjects/test/ManagedWorkspace2DTest.h deleted file mode 100644 index 7812cd70c26b..000000000000 --- a/Code/Mantid/Framework/DataObjects/test/ManagedWorkspace2DTest.h +++ /dev/null @@ -1,639 +0,0 @@ -#ifndef MANAGEDWORKSPACE2DTEST_H_ -#define MANAGEDWORKSPACE2DTEST_H_ - -#include "MantidAPI/MemoryManager.h" -#include "MantidAPI/WorkspaceFactory.h" -#include "MantidDataObjects/ManagedWorkspace2D.h" -#include "MantidGeometry/IDTypes.h" -#include "MantidKernel/ConfigService.h" -#include "MantidKernel/Memory.h" -#include -#include -#include - -using Mantid::MantidVec; -using std::size_t; -using Mantid::DataObjects::ManagedWorkspace2D; - -class ManagedWorkspace2DTest : public CxxTest::TestSuite -{ -public: - static ManagedWorkspace2DTest *createSuite() { return new ManagedWorkspace2DTest(); } - static void destroySuite( ManagedWorkspace2DTest *suite ) { delete suite; } - - ManagedWorkspace2DTest() - { - smallWorkspace.setTitle("ManagedWorkspace2DTest_smallWorkspace"); - smallWorkspace.initialize(2,4,3); - for (size_t i = 0; i < 4; ++i) - { - smallWorkspace.dataX(0)[i] = static_cast(i); - smallWorkspace.dataX(1)[i] = static_cast(i+4); - } - - for (size_t i = 0; i < 3; ++i) - { - smallWorkspace.dataY(0)[i] = static_cast(i*10); - smallWorkspace.dataE(0)[i] = sqrt(smallWorkspace.dataY(0)[i]); - smallWorkspace.dataY(1)[i] = static_cast(i*100); - smallWorkspace.dataE(1)[i] = sqrt(smallWorkspace.dataY(1)[i]); - } - - bigWorkspace.setTitle("ManagedWorkspace2DTest_bigWorkspace"); - size_t nVec = 1250; - size_t vecLength = 25; - bigWorkspace.initialize(nVec, vecLength, vecLength); - for (size_t i=0; i< nVec; i++) - { - boost::shared_ptr x1(new MantidVec(vecLength, static_cast(1+i) ) ); - boost::shared_ptr y1(new MantidVec(vecLength, static_cast(5+i) ) ); - boost::shared_ptr e1(new MantidVec(vecLength, static_cast(4+i) ) ); - bigWorkspace.setX(i,x1); - bigWorkspace.setData(i,y1,e1); - // As of 20/7/2011, revision [13332], these calls have no (lasting) effect. - // When they do, the testSpectrumAndDetectorNumbers test will start to fail - bigWorkspace.getSpectrum(i)->setSpectrumNo((int)i); - bigWorkspace.getSpectrum(i)->setDetectorID((int)i*100); - } - } - - void testInit() - { - Mantid::DataObjects::ManagedWorkspace2D ws; - ws.setTitle("testInit"); - TS_ASSERT_THROWS_NOTHING( ws.initialize(5,5,5) );; - TS_ASSERT_EQUALS( ws.getNumberHistograms(), 5 );; - TS_ASSERT_EQUALS( ws.blocksize(), 5 );; - TS_ASSERT_EQUALS( ws.size(), 25 );; - - for (size_t i = 0; i < 5; ++i) - { - TS_ASSERT_EQUALS( ws.dataX(i).size(), 5 );; - TS_ASSERT_EQUALS( ws.dataY(i).size(), 5 );; - TS_ASSERT_EQUALS( ws.dataE(i).size(), 5 );; - } - - // Test all is as it should be with the temporary file - std::string filename = ws.get_filename() + "0"; - std::fstream file(filename.c_str(), std::ios::in | std::ios::binary); - TSM_ASSERT(filename, file);; - - double temp; - file.read((char *) &temp, sizeof(double)); - TS_ASSERT( file.fail() ); - file.close(); - } - - void testCast() - { - Mantid::DataObjects::ManagedWorkspace2D *ws = new Mantid::DataObjects::ManagedWorkspace2D; - TS_ASSERT( dynamic_cast(ws) ); - TS_ASSERT( dynamic_cast(ws) ); - delete ws; - } - - void testId() - { - TS_ASSERT( ! smallWorkspace.id().compare("ManagedWorkspace2D") ); - } - - void testgetNumberHistograms() - { - TS_ASSERT_EQUALS( smallWorkspace.getNumberHistograms(), 2 ); - TS_ASSERT_EQUALS( bigWorkspace.getNumberHistograms(), 1250 ); - - Mantid::DataObjects::Workspace2D &ws = dynamic_cast(smallWorkspace); - TS_ASSERT_EQUALS( ws.getNumberHistograms(), 2);; - } - - void testSetX() - { - Mantid::DataObjects::ManagedWorkspace2D ws; - ws.setTitle("testSetX"); - ws.initialize(1,1,1); - double aNumber = 5.5; - boost::shared_ptr v(new MantidVec(1, aNumber)); - TS_ASSERT_THROWS_NOTHING( ws.setX(0,v) ); - TS_ASSERT_EQUALS( ws.dataX(0)[0], aNumber ); - TS_ASSERT_THROWS( ws.setX(-1,v), std::range_error ); - TS_ASSERT_THROWS( ws.setX(1,v), std::range_error ); - - double anotherNumber = 9.99; - boost::shared_ptr vec(new MantidVec(25, anotherNumber)); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.setX(10, vec) ); - TS_ASSERT_EQUALS( bigWorkspace.dataX(10)[7], anotherNumber ); - TS_ASSERT_EQUALS( bigWorkspace.dataX(10)[22], anotherNumber ); - } - - void testSetData() - { - Mantid::DataObjects::ManagedWorkspace2D ws; - ws.setTitle("testSetData"); - ws.initialize(1,1,1); - double aNumber = 9.9; - boost::shared_ptr v(new MantidVec(1, aNumber)); - double anotherNumber = 3.3; - boost::shared_ptr w(new MantidVec(1, anotherNumber)); - TS_ASSERT_THROWS_NOTHING( ws.setData(0,v,v) ); - TS_ASSERT_EQUALS( ws.dataY(0)[0], aNumber ) ; - TS_ASSERT_THROWS( ws.setData(-1,v,v), std::range_error ); - TS_ASSERT_THROWS( ws.setData(1,v,v), std::range_error ); - - double yetAnotherNumber = 2.25; - (*v)[0] = yetAnotherNumber; - TS_ASSERT_THROWS_NOTHING( ws.setData(0,v,w) ); - TS_ASSERT_EQUALS( ws.dataY(0)[0], yetAnotherNumber ); - TS_ASSERT_EQUALS( ws.dataE(0)[0], anotherNumber ); - TS_ASSERT_THROWS( ws.setData(-1,v,w), std::range_error ); - TS_ASSERT_THROWS( ws.setData(1,v,w), std::range_error ); - - double oneMoreNumber = 8478.6728; - boost::shared_ptr vec(new MantidVec(25, oneMoreNumber)); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.setData(49, vec, vec) ); - TS_ASSERT_EQUALS( bigWorkspace.dataY(49)[0], oneMoreNumber ); - TS_ASSERT_EQUALS( bigWorkspace.dataE(49)[9], oneMoreNumber ); - } - - void testSize() - { - TS_ASSERT_EQUALS( smallWorkspace.size(), 6 ); - TS_ASSERT_EQUALS( bigWorkspace.size(), 31250 ); - } - - void testBlocksize() - { - TS_ASSERT_EQUALS( smallWorkspace.blocksize(), 3 ); - TS_ASSERT_EQUALS( bigWorkspace.blocksize(), 25 ) ; - } - - void testDataX() - { - MantidVec x; - TS_ASSERT_THROWS( smallWorkspace.dataX(-1), std::range_error ); - TS_ASSERT_THROWS_NOTHING( x = smallWorkspace.dataX(0) ); - MantidVec xx; - TS_ASSERT_THROWS_NOTHING( xx = smallWorkspace.dataX(1) ); - TS_ASSERT_THROWS( smallWorkspace.dataX(2), std::range_error ); - TS_ASSERT_EQUALS( x.size(), 4 ); - TS_ASSERT_EQUALS( xx.size(), 4 ); - for (size_t i = 0; i < x.size(); ++i) - { - TS_ASSERT_EQUALS( x[i], i ); - TS_ASSERT_EQUALS( xx[i], i+4 ); - } - - // test const version - const Mantid::DataObjects::ManagedWorkspace2D &constRefToData = smallWorkspace; - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataX(-1), std::range_error ); - const MantidVec xc = constRefToData.dataX(0); - const MantidVec xxc = constRefToData.dataX(1); - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataX(2), std::range_error ); - TS_ASSERT_EQUALS( xc.size(), 4 ); - TS_ASSERT_EQUALS( xxc.size(), 4 ); - for (size_t i = 0; i < xc.size(); ++i) - { - TS_ASSERT_EQUALS( xc[i], i ); - TS_ASSERT_EQUALS( xxc[i], i+4 ); - } - - TS_ASSERT_EQUALS( bigWorkspace.dataX(101)[5], 102 ); - TS_ASSERT_EQUALS( bigWorkspace.dataX(201)[24], 202 ); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.dataX(39)[10] = 2.22 ); - TS_ASSERT_EQUALS( bigWorkspace.dataX(39)[10], 2.22 ); - } - - void testDataDx() - { - TS_ASSERT_EQUALS( smallWorkspace.dataDx(0).size(), 4 ); - TS_ASSERT_EQUALS( smallWorkspace.readDx(1)[3], 0.0 ); - - TS_ASSERT_THROWS_NOTHING( smallWorkspace.dataDx(1)[3] = 9.9 ); - TS_ASSERT_EQUALS( smallWorkspace.readDx(1)[3], 9.9 ); - } - - void testDataY() - { - MantidVec y; - TS_ASSERT_THROWS( smallWorkspace.dataY(-1), std::range_error ); - TS_ASSERT_THROWS_NOTHING( y = smallWorkspace.dataY(0) ); - MantidVec yy; - TS_ASSERT_THROWS_NOTHING( yy = smallWorkspace.dataY(1) ); - TS_ASSERT_THROWS( smallWorkspace.dataY(2), std::range_error ); - TS_ASSERT_EQUALS( y.size(), 3 ); - TS_ASSERT_EQUALS( yy.size(), 3 ); - for (size_t i = 0; i < y.size(); ++i) - { - TS_ASSERT_EQUALS( y[i], i*10 ); - TS_ASSERT_EQUALS( yy[i], i*100 ); - } - - // test const version - const Mantid::DataObjects::ManagedWorkspace2D &constRefToData = smallWorkspace; - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataY(-1), std::range_error ); - const MantidVec yc = constRefToData.dataY(0); - const MantidVec yyc = constRefToData.dataY(1); - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataY(2), std::range_error ); - TS_ASSERT_EQUALS( yc.size(), 3 ); - TS_ASSERT_EQUALS( yyc.size(), 3 ); - for (size_t i = 0; i < yc.size(); ++i) - { - TS_ASSERT_EQUALS( yc[i], i*10 ); - TS_ASSERT_EQUALS( yyc[i], i*100 ); - } - - TS_ASSERT_EQUALS( bigWorkspace.dataY(178)[8], 183 ); - TS_ASSERT_EQUALS( bigWorkspace.dataY(64)[11], 69 ); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.dataY(123)[8] = 3.33 ); - TS_ASSERT_EQUALS( bigWorkspace.dataY(123)[8], 3.33 ); - } - - void testDataE() - { - MantidVec e; - TS_ASSERT_THROWS( smallWorkspace.dataE(-1), std::range_error ); - TS_ASSERT_THROWS_NOTHING( e = smallWorkspace.dataE(0) ); - MantidVec ee; - TS_ASSERT_THROWS_NOTHING( ee = smallWorkspace.dataE(1) ); - TS_ASSERT_THROWS( smallWorkspace.dataE(2), std::range_error ); - TS_ASSERT_EQUALS( e.size(), 3 ); - TS_ASSERT_EQUALS( ee.size(), 3 ); - for (size_t i = 0; i < e.size(); ++i) - { - TS_ASSERT_EQUALS( e[i], sqrt(static_cast(i)*10.0) ); - TS_ASSERT_EQUALS( ee[i], sqrt(static_cast(i)*100.0) ); - } - - // test const version - const Mantid::DataObjects::ManagedWorkspace2D &constRefToData = smallWorkspace; - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataE(-1), std::range_error ); - const MantidVec ec = constRefToData.dataE(0); - const MantidVec eec = constRefToData.dataE(1); - TS_ASSERT_THROWS( const MantidVec v = constRefToData.dataE(2), std::range_error ); - TS_ASSERT_EQUALS( ec.size(), 3 ); - TS_ASSERT_EQUALS( eec.size(), 3 ); - for (size_t i = 0; i < ec.size(); ++i) - { - TS_ASSERT_EQUALS( ec[i], sqrt(static_cast(i)*10.0) ); - TS_ASSERT_EQUALS( eec[i], sqrt(static_cast(i)*100.0) ); - } - - TS_ASSERT_EQUALS( bigWorkspace.dataE(0)[23], 4 ); - TS_ASSERT_EQUALS( bigWorkspace.dataE(249)[2], 253 ); - TS_ASSERT_THROWS_NOTHING( bigWorkspace.dataE(11)[11] = 4.44 ); - TS_ASSERT_EQUALS( bigWorkspace.dataE(11)[11], 4.44 ); - } - - void testSpectrumAndDetectorNumbers() - { - for (size_t i = 0; i < bigWorkspace.getNumberHistograms(); ++i) - { - TS_ASSERT_EQUALS( bigWorkspace.getAxis(1)->spectraNo(i), i ); - // Values were set in the constructor - TS_ASSERT_EQUALS( bigWorkspace.getSpectrum(i)->getSpectrumNo(), i ); - TS_ASSERT( bigWorkspace.getSpectrum(i)->hasDetectorID((int)i*100) ); - } - } - - void testMultipleFiles() - { - const size_t NHist = 111; - const size_t NY = 9; - const size_t NX = NY + 1; - - double dBlockSize = 2 * ( sizeof(int) + ( NX + 2*NY ) * sizeof(double) ); - - // This will make sure 1 ManagedDataBlock = 2 Vectors - Mantid::Kernel::ConfigServiceImpl& conf = Mantid::Kernel::ConfigService::Instance(); - const std::string blocksize = "ManagedWorkspace.DataBlockSize"; - const std::string oldValue = conf.getString(blocksize); - conf.setString(blocksize,boost::lexical_cast(dBlockSize)); - - const std::string blockPerFile = "ManagedWorkspace.BlocksPerFile"; - const std::string oldValueBlockPerFile = conf.getString(blockPerFile); - conf.setString(blockPerFile,"9"); - - Mantid::DataObjects::ManagedWorkspace2D ws; - ws.initialize(NHist, NX, NY); - - TS_ASSERT_EQUALS( ws.getNumberFiles(), NHist /( 2 * 9 ) + 1 ); - - for(size_t i = 0; i < ws.getNumberHistograms(); ++i ) - { - auto& y = ws.dataY( i ); - for(size_t j = 0; j < y.size(); ++j) - { - y[j] = double(1000*i) + double(j); - } - } - - for(size_t i = 0; i < ws.getNumberHistograms(); ++i ) - { - auto& y = ws.dataY( i ); - for(size_t j = 0; j < y.size(); ++j) - { - TS_ASSERT_EQUALS( y[j], double(1000*i) + double(j) ); - } - } - - conf.setString(blocksize,oldValue); - conf.setString(blockPerFile,oldValueBlockPerFile); - } - - void testMultipleFiles1() - { - - const size_t NHist = 211; - const size_t NY = 9; - const size_t NX = NY + 1; - const size_t StartHist = 90; - - double dBlockSize = /*sizeof(int) +*/ ( NX + 2*NY ) * sizeof(double); - - // This will make sure 1 ManagedDataBlock = 1 Vector - Mantid::Kernel::ConfigServiceImpl& conf = Mantid::Kernel::ConfigService::Instance(); - const std::string blocksize = "ManagedWorkspace.DataBlockSize"; - const std::string oldValue = conf.getString(blocksize); - conf.setString(blocksize,boost::lexical_cast(dBlockSize)); - - const std::string blockPerFile = "ManagedWorkspace.BlocksPerFile"; - const std::string oldValueBlockPerFile = conf.getString(blockPerFile); - conf.setString(blockPerFile,"40"); - - Mantid::DataObjects::ManagedWorkspace2D ws; - ws.initialize(NHist, NX, NY); - - TS_ASSERT_EQUALS( ws.getNumberFiles(), NHist /( 40 ) + 1 ); - - // start writing from some index > 0 - for(size_t i = StartHist; i < ws.getNumberHistograms(); ++i ) - { - auto& y = ws.dataY( i ); - for(size_t j = 0; j < y.size(); ++j) - { - y[j] = double(1000*i) + double(j); - } - } - - for(size_t i = StartHist; i < ws.getNumberHistograms(); ++i ) - { - auto& y = ws.dataY( i ); - for(size_t j = 0; j < y.size(); ++j) - { - TS_ASSERT_EQUALS( y[j], double(1000*i) + double(j) ); - } - } - - // check that front spectra can be read and zero - TS_ASSERT_EQUALS( ws.readY( 0 )[0], 0.0 ); - TS_ASSERT_EQUALS( ws.readY( 1 )[0], 0.0 ); - - conf.setString(blocksize,oldValue); - conf.setString(blockPerFile,oldValueBlockPerFile); - } - - void testMultipleFiles2() - { - - const size_t NHist = 211; - const size_t NY = 9; - const size_t NX = NY + 1; - const size_t StartHist = 90; - - double dBlockSize = /*sizeof(int) +*/ ( NX + 2*NY ) * sizeof(double); - - // This will make sure 1 ManagedDataBlock = 1 Vector - Mantid::Kernel::ConfigServiceImpl& conf = Mantid::Kernel::ConfigService::Instance(); - const std::string blocksize = "ManagedWorkspace.DataBlockSize"; - const std::string oldValue = conf.getString(blocksize); - conf.setString(blocksize,boost::lexical_cast(dBlockSize)); - - const std::string blockPerFile = "ManagedWorkspace.BlocksPerFile"; - const std::string oldValueBlockPerFile = conf.getString(blockPerFile); - conf.setString(blockPerFile,"40"); - - Mantid::DataObjects::ManagedWorkspace2D ws; - ws.initialize(NHist, NX, NY); - - TS_ASSERT_EQUALS( ws.getNumberFiles(), NHist /( 40 ) + 1 ); - - // write at front - ws.dataY( 0 )[0] = 1.0; - ws.dataY( 1 )[0] = 2.0; - - // leave a gap - for(size_t i = StartHist; i < ws.getNumberHistograms(); ++i ) - { - auto& y = ws.dataY( i ); - for(size_t j = 0; j < y.size(); ++j) - { - y[j] = double(1000*i) + double(j); - } - } - - // check the filled spectra - for(size_t i = StartHist; i < ws.getNumberHistograms(); ++i ) - { - auto& y = ws.dataY( i ); - for(size_t j = 0; j < y.size(); ++j) - { - TS_ASSERT_EQUALS( y[j], double(1000*i) + double(j) ); - } - } - - // check that front spectra weren't changed by padding - TS_ASSERT_EQUALS( ws.readY( 0 )[0], 1.0 ); - TS_ASSERT_EQUALS( ws.readY( 1 )[0], 2.0 ); - - conf.setString(blocksize,oldValue); - conf.setString(blockPerFile,oldValueBlockPerFile); - } - - void testPadding() - { - //std::cout << "Start!!!!" << std::endl; - - // This will make sure 1 ManagedDataBlock = 1 Vector - Mantid::Kernel::ConfigServiceImpl& conf = Mantid::Kernel::ConfigService::Instance(); - const std::string blocksize = "ManagedWorkspace.DataBlockSize"; - const std::string oldValue = conf.getString(blocksize); - conf.setString(blocksize,"1"); - - const std::string blockPerFile = "ManagedWorkspace.BlocksPerFile"; - const std::string oldValueBlockPerFile = conf.getString(blockPerFile); - conf.setString(blockPerFile,"10"); - - Mantid::DataObjects::ManagedWorkspace2D ws; - ws.initialize(111,10,9); - - MantidVec fours(10,4.0); - MantidVec fives(9,5.0); - MantidVec sixes(9,6.0); - for ( std::size_t i = 10; i < ws.getNumberHistograms(); ++i ) - { - ws.dataX(i) = fours; - ws.dataY(i) = fives; - ws.dataE(i) = sixes; - } - - // Get back a block that should have gone out to disk and check its values - MantidVec xvals = ws.dataX(50); - MantidVec yvals = ws.dataY(50); - MantidVec evals = ws.dataE(50); - TS_ASSERT_EQUALS( xvals.size(), 10 ); - TS_ASSERT_EQUALS( yvals.size(), 9 ); - TS_ASSERT_EQUALS( evals.size(), 9 ); - for ( std::size_t j = 0; j < 9; ++j ) - { - TS_ASSERT_EQUALS( xvals[j], 4.0 ); - TS_ASSERT_EQUALS( yvals[j], 5.0 ); - TS_ASSERT_EQUALS( evals[j], 6.0 ); - } - TS_ASSERT_EQUALS( xvals.back(), 4.0 ); - - conf.setString(blocksize,oldValue); - conf.setString(blockPerFile,oldValueBlockPerFile); - //std::cout << "End!!!! " << std::endl; - } - - void testDestructor() - { - std::string filename; - { // Scoping block - Mantid::DataObjects::ManagedWorkspace2D tmp; - tmp.initialize(1,1,1); - filename = tmp.get_filename() + "0"; - // File should exist - TS_ASSERT ( Poco::File(filename).exists() ); - } - TSM_ASSERT ( "File should have been deleted", ! Poco::File(filename).exists() ); - } - -private: - Mantid::DataObjects::ManagedWorkspace2D smallWorkspace; - Mantid::DataObjects::ManagedWorkspace2D bigWorkspace; -}; - -//------------------------------------------------------------------------------ -// Performance test -//------------------------------------------------------------------------------ - -class ManagedWorkspace2DTestPerformance : public CxxTest::TestSuite -{ -private: - Mantid::API::MatrixWorkspace_sptr inWS; - Mantid::API::MatrixWorkspace_sptr managedWS; - -public: - static ManagedWorkspace2DTestPerformance *createSuite() { return new ManagedWorkspace2DTestPerformance(); } - static void destroySuite( ManagedWorkspace2DTestPerformance *suite ) { delete suite; } - - ManagedWorkspace2DTestPerformance() - { - // Make sure the input workspace is NOT managed - Mantid::Kernel::ConfigServiceImpl& conf = Mantid::Kernel::ConfigService::Instance(); - conf.setString("ManagedWorkspace.AlwaysInMemory","1"); - // Workspace should use up around 800 MB of memory - inWS = Mantid::API::WorkspaceFactory::Instance().create("Workspace2D",7000,5000,5000); - conf.setString("ManagedWorkspace.AlwaysInMemory","0"); - } - - // This should take ~no time (nothing should be written to disk) - void testCreationViaFactory() - { - // Make sure we go managed - Mantid::Kernel::ConfigServiceImpl& conf = Mantid::Kernel::ConfigService::Instance(); - const std::string managed = "ManagedWorkspace.LowerMemoryLimit"; - const std::string oldValue = conf.getString(managed); - conf.setString(managed,"0"); - const std::string managed2 = "ManagedRawFileWorkspace.DoNotUse"; - const std::string oldValue2 = conf.getString(managed2); - conf.setString(managed2,"0"); - // 1 MB block size - conf.setString("ManagedWorkspace.DataBlockSize", "1000000"); - - Mantid::Kernel::MemoryStats stats; - stats.update(); - size_t memBefore = stats.availMem() ; - - managedWS = Mantid::API::WorkspaceFactory::Instance().create(inWS); - - stats.update(); - double memLoss = double(memBefore) - double(stats.availMem()); - TSM_ASSERT_LESS_THAN( "Memory used up in creating a ManagedWorkspace should be minimal", memLoss, 20*1024); - std::cout << memLoss/(1024.0) << " MB of memory used up in creating an empty ManagedWorkspace." << std::endl; - } - - // This should also take ~no time (nothing should be written to disk) - void testReadSpectrumNumber() - { - Mantid::Kernel::MemoryStats stats; - stats.update(); - size_t memBefore = stats.availMem() ; - - Mantid::specid_t num(0); - for ( std::size_t i = 0 ; i < managedWS->getNumberHistograms(); ++i ) - { - Mantid::API::ISpectrum * spec = managedWS->getSpectrum(i); - if ( ! spec->hasDetectorID(0) ) - { - num = spec->getSpectrumNo(); - } - } - TS_ASSERT ( num != 0 ); - - stats.update(); - double memLoss = double(memBefore) - double(stats.availMem()); - TSM_ASSERT_LESS_THAN( "Memory used up by looping only for spectrum numbers should be minimal", memLoss, 20*1024); - std::cout << memLoss/(1024.0) << " MB of memory used up in looping looking only for spectra." << std::endl; - } - - // This should take a while... - void testLoopOverHalf() - { - Mantid::Kernel::MemoryStats stats; - - // Temporary while I ensure that the memory-per-process code works on each platform -#if _WIN32 - size_t processMemBefore = stats.residentMem(); -#else - size_t memBefore = stats.availMem(); -#endif - - boost::shared_ptr ws = boost::dynamic_pointer_cast(managedWS); - TSM_ASSERT("Workspace is really managed", ws); - - for ( std::size_t i = 0; i < 3500; ++i ) - { - managedWS->dataX(i) = inWS->readX(i); - managedWS->dataY(i) = inWS->readY(i); - managedWS->dataE(i) = inWS->readE(i); - } - // For linux, make sure to release old memory - Mantid::API::MemoryManager::Instance().releaseFreeMemory(); - stats.update(); - -#if _WIN32 - size_t processMemNow = stats.residentMem(); - double memLoss = static_cast(processMemNow) - static_cast(processMemBefore); -#else - size_t memNow = stats.availMem(); - double memLoss = static_cast(memBefore) - static_cast(memNow); -#endif - - TSM_ASSERT_LESS_THAN( "MRU list should limit the amount of memory to around 100 MB used when accessing the data.", memLoss, 200*1024); - std::cout << memLoss/(1024.0) << " MB of memory used up in looping. Memory looped over = " << 3500.0*5000*24 / (1024.0*1024.0) << " MB." << std::endl; - } - - // ...but only about half as long as this - void testLoopOverWhole() - { - Mantid::API::MatrixWorkspace_sptr managedWS2 = Mantid::API::WorkspaceFactory::Instance().create(inWS); - for ( std::size_t i = 0 ; i < managedWS2->getNumberHistograms(); ++i ) - { - managedWS2->dataX(i) = inWS->readX(i); - managedWS2->dataY(i) = inWS->readY(i); - managedWS2->dataE(i) = inWS->readE(i); - } - } -}; -#endif /*MANAGEDWORKSPACE2DTEST_H_*/ diff --git a/Code/Mantid/Framework/Kernel/src/ConfigService.cpp b/Code/Mantid/Framework/Kernel/src/ConfigService.cpp index c829caa436b8..86a330312a85 100644 --- a/Code/Mantid/Framework/Kernel/src/ConfigService.cpp +++ b/Code/Mantid/Framework/Kernel/src/ConfigService.cpp @@ -232,7 +232,6 @@ ConfigServiceImpl::ConfigServiceImpl() : m_ConfigPaths.insert(std::make_pair("user.python.plugins.directories", true)); m_ConfigPaths.insert(std::make_pair("datasearch.directories", true)); m_ConfigPaths.insert(std::make_pair("icatDownload.directory", true)); - m_ConfigPaths.insert(std::make_pair("ManagedWorkspace.FilePath", true)); //attempt to load the default properties file that resides in the directory of the executable std::string propertiesFilesList; diff --git a/Code/Mantid/Framework/Kernel/test/ConfigServiceTest.h b/Code/Mantid/Framework/Kernel/test/ConfigServiceTest.h index 1c9039fb0b37..5af09a06f008 100644 --- a/Code/Mantid/Framework/Kernel/test/ConfigServiceTest.h +++ b/Code/Mantid/Framework/Kernel/test/ConfigServiceTest.h @@ -191,21 +191,20 @@ class ConfigServiceTest : public CxxTest::TestSuite void TestCustomProperty() { - //Mantid.legs is defined in the properties script as 6 - std::string countString = ConfigService::Instance().getString("ManagedWorkspace.DataBlockSize"); - TS_ASSERT_EQUALS(countString, "4000"); + std::string countString = ConfigService::Instance().getString("algorithms.retained"); + TS_ASSERT_EQUALS(countString, "50"); } void TestCustomPropertyAsValue() { //Mantid.legs is defined in the properties script as 6 int value = 0; - ConfigService::Instance().getValue("ManagedWorkspace.DataBlockSize",value); + ConfigService::Instance().getValue("algorithms.retained",value); double dblValue = 0; - ConfigService::Instance().getValue("ManagedWorkspace.DataBlockSize",dblValue); + ConfigService::Instance().getValue("algorithms.retained",dblValue); - TS_ASSERT_EQUALS(value, 4000); - TS_ASSERT_EQUALS(dblValue, 4000.0); + TS_ASSERT_EQUALS(value, 50); + TS_ASSERT_EQUALS(dblValue, 50.0); } void TestMissingProperty() diff --git a/Code/Mantid/Framework/Properties/Mantid.properties.template b/Code/Mantid/Framework/Properties/Mantid.properties.template index 9aa0919a9946..ac2bfe7691a5 100644 --- a/Code/Mantid/Framework/Properties/Mantid.properties.template +++ b/Code/Mantid/Framework/Properties/Mantid.properties.template @@ -95,20 +95,6 @@ icatDownload.directory = # The Number of algorithms properties to retain im memory for refence in scripts. algorithms.retained = 50 -# ManagedWorkspace.LowerMemoryLimit sets the memory limit to trigger the use of -# a ManagedWorkspace. A ManagedWorkspace will be used for a workspace requiring greater amount of memory -# than defined by LowerMemoryLimit. LowerMemoryLimit is a precentage of the physical memory available for -# the process. On Linux it is the free physical memory, on Windows it is the smaller of the free physical memory -# and the available virtual memory. The default value for LowerMemoryLimit is 40%. Setting the limit too high -# may lead to unrecoverable bad allocations. If this happens the advice is to close Mantid and relaunch it -# with a smaller LowerMemoryLimit. -# -ManagedWorkspace.LowerMemoryLimit = 80 -# Setting this to 1 will disable managed workspaces completely - use with care! -ManagedWorkspace.AlwaysInMemory = 0 -ManagedWorkspace.DataBlockSize = 4000 -ManagedWorkspace.FilePath = - # Defines the maximum number of cores to use for OpenMP # For machine default set to 0 MultiThreaded.MaxCores = 0 diff --git a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp index 73714e1afa3c..3ee289eeb291 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/MatrixWorkspace.cpp @@ -239,10 +239,9 @@ void export_MatrixWorkspace() //------------------------------------------------------------------------------------------------- - static const int NUM_IDS = 8; + static const int NUM_IDS = 7; static const char * WORKSPACE_IDS[NUM_IDS] = {\ - "GroupingWorkspace", "ManagedWorkspace2D", - "MaskWorkspace", "OffsetsWorkspace", + "GroupingWorkspace", "MaskWorkspace", "OffsetsWorkspace", "RebinnedOutput", "SpecialWorkspace2D", "Workspace2D", "WorkspaceSingleValue" }; diff --git a/Code/Mantid/MantidPlot/src/Mantid/MantidUI.cpp b/Code/Mantid/MantidPlot/src/Mantid/MantidUI.cpp index d151fe48cf82..9b27e1eb040b 100644 --- a/Code/Mantid/MantidPlot/src/Mantid/MantidUI.cpp +++ b/Code/Mantid/MantidPlot/src/Mantid/MantidUI.cpp @@ -1921,7 +1921,7 @@ void MantidUI::manageMantidWorkspaces() #ifdef _WIN32 memoryImage(); #else - QMessageBox::warning(appWindow(),tr("Mantid Workspace"),tr("Clicked on Managed Workspace"),tr("Ok"),tr("Cancel"),QString(),0,1); + QMessageBox::warning(appWindow(),tr("Mantid Workspace"),tr("Clicked on Manage Workspace"),tr("Ok"),tr("Cancel"),QString(),0,1); #endif } diff --git a/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp b/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp index 92dad1d753ef..757413ba0891 100644 --- a/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp +++ b/Code/Mantid/MantidPlot/src/Mantid/WorkspaceIcons.cpp @@ -40,7 +40,6 @@ void WorkspaceIcons::initInternalLookup() // MatrixWorkspace types m_idToPixmapName["EventWorkspace"] = "mantid_matrix_xpm"; m_idToPixmapName["GroupingWorkspace"] = "mantid_matrix_xpm"; - m_idToPixmapName["ManagedWorkspace2D"] = "mantid_matrix_xpm"; m_idToPixmapName["MaskWorkspace"] = "mantid_matrix_xpm"; m_idToPixmapName["OffsetsWorkspace"] = "mantid_matrix_xpm"; m_idToPixmapName["RebinnedOutput"] = "mantid_matrix_xpm"; From 208633ab7a21eb10cca711320e9c76eae36122a9 Mon Sep 17 00:00:00 2001 From: Russell Taylor Date: Tue, 29 Apr 2014 14:29:12 -0400 Subject: [PATCH 017/126] Re #9357. Slight refactoring now that managed WS is gone. The comments indicate that something unusual we being done because of managed workspaces. --- Code/Mantid/Framework/DataHandling/src/GroupDetectors.cpp | 7 ++----- Code/Mantid/Framework/DataHandling/src/GroupDetectors2.cpp | 6 ++---- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/Code/Mantid/Framework/DataHandling/src/GroupDetectors.cpp b/Code/Mantid/Framework/DataHandling/src/GroupDetectors.cpp index bc97c506b309..3e3b966f23b7 100644 --- a/Code/Mantid/Framework/DataHandling/src/GroupDetectors.cpp +++ b/Code/Mantid/Framework/DataHandling/src/GroupDetectors.cpp @@ -163,6 +163,7 @@ void GroupDetectors::exec() const specid_t firstIndex = static_cast(indexList[0]); ISpectrum * firstSpectrum = WS->getSpectrum(firstIndex); + MantidVec &firstY = WS->dataY(firstIndex); setProperty("ResultIndex",firstIndex); @@ -178,13 +179,10 @@ void GroupDetectors::exec() firstSpectrum->addDetectorIDs(spec->getDetectorIDs()); // Add up all the Y spectra and store the result in the first one - // Need to keep the next 3 lines inside loop for now until ManagedWorkspace mru-list works properly - MantidVec &firstY = WS->dataY(firstIndex); - MantidVec::iterator fYit; MantidVec::iterator fEit = firstSpectrum->dataE().begin(); MantidVec::iterator Yit = spec->dataY().begin(); MantidVec::iterator Eit = spec->dataE().begin(); - for (fYit = firstY.begin(); fYit != firstY.end(); ++fYit, ++fEit, ++Yit, ++Eit) + for (auto fYit = firstY.begin(); fYit != firstY.end(); ++fYit, ++fEit, ++Yit, ++Eit) { *fYit += *Yit; // Assume 'normal' (i.e. Gaussian) combination of errors @@ -192,7 +190,6 @@ void GroupDetectors::exec() } // Now zero the now redundant spectrum and set its spectraNo to indicate this (using -1) - // N.B. Deleting spectra would cause issues for ManagedWorkspace2D, hence the the approach taken here spec->dataY().assign(vectorSize,0.0); spec->dataE().assign(vectorSize,0.0); spec->setSpectrumNo(-1); diff --git a/Code/Mantid/Framework/DataHandling/src/GroupDetectors2.cpp b/Code/Mantid/Framework/DataHandling/src/GroupDetectors2.cpp index 376e3b06d24d..ec783ea33b6a 100644 --- a/Code/Mantid/Framework/DataHandling/src/GroupDetectors2.cpp +++ b/Code/Mantid/Framework/DataHandling/src/GroupDetectors2.cpp @@ -778,6 +778,7 @@ size_t GroupDetectors2::formGroups( API::MatrixWorkspace_const_sptr inputWS, API outSpec->dataX() = inputWS->readX(0); // the Y values and errors from spectra being grouped are combined in the output spectrum + MantidVec &firstY = outSpec->dataY(); // Keep track of number of detectors required for masking size_t nonMaskedSpectra(0); beh->dataX(outIndex)[0] = 0.0; @@ -790,13 +791,10 @@ size_t GroupDetectors2::formGroups( API::MatrixWorkspace_const_sptr inputWS, API const ISpectrum * fromSpectrum = inputWS->getSpectrum(originalWI); // Add up all the Y spectra and store the result in the first one - // Need to keep the next 3 lines inside loop for now until ManagedWorkspace mru-list works properly - MantidVec &firstY = outSpec->dataY(); - MantidVec::iterator fYit; MantidVec::iterator fEit = outSpec->dataE().begin(); MantidVec::const_iterator Yit = fromSpectrum->dataY().begin(); MantidVec::const_iterator Eit = fromSpectrum->dataE().begin(); - for (fYit = firstY.begin(); fYit != firstY.end(); ++fYit, ++fEit, ++Yit, ++Eit) + for (auto fYit = firstY.begin(); fYit != firstY.end(); ++fYit, ++fEit, ++Yit, ++Eit) { *fYit += *Yit; // Assume 'normal' (i.e. Gaussian) combination of errors From ccd49545679265b6875d9da047b5df6d67b674dc Mon Sep 17 00:00:00 2001 From: Roman Tolchenov Date: Mon, 12 May 2014 11:11:25 +0100 Subject: [PATCH 018/126] Re #9439. Added code to parse index ranges in 'domains' attributes --- .../API/inc/MantidAPI/MultiDomainFunction.h | 4 +- .../Framework/API/src/MultiDomainFunction.cpp | 50 +++++++++++++++++-- .../API/test/MultiDomainFunctionTest.h | 37 ++++++++++++++ 3 files changed, 86 insertions(+), 5 deletions(-) diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/MultiDomainFunction.h b/Code/Mantid/Framework/API/inc/MantidAPI/MultiDomainFunction.h index a02d2a887308..1618b97e0243 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/MultiDomainFunction.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/MultiDomainFunction.h @@ -72,7 +72,9 @@ class MANTID_API_DLL MultiDomainFunction : public CompositeFunction /// Get domain indices for a member function void getDomainIndices(size_t i, size_t nDomains, std::vector& domains)const; - /// Returns the number of attributes associated with the function + /// Returns the number of "local" attributes associated with the function. + /// Local attributes are attributes of MultiDomainFunction but describe properties + /// of individual member functions. virtual size_t nLocalAttributes()const {return 1;} /// Returns a list of attribute names virtual std::vector getLocalAttributeNames()const {return std::vector(1,"domains");} diff --git a/Code/Mantid/Framework/API/src/MultiDomainFunction.cpp b/Code/Mantid/Framework/API/src/MultiDomainFunction.cpp index 4628407a5de3..71d8434c0e53 100644 --- a/Code/Mantid/Framework/API/src/MultiDomainFunction.cpp +++ b/Code/Mantid/Framework/API/src/MultiDomainFunction.cpp @@ -232,7 +232,24 @@ namespace API } /** - * Set a value to attribute attName + * Set a value to a "local" attribute, ie an attribute related to a member function. + * + * The only attribute that can be set here is "domains" which defines the + * indices of domains a particular function is applied to. Possible values are (strings): + * + * 1) "All" : the function is applied to all domains defined for this MultiDomainFunction. + * 2) "i" : the function is applied to a single domain which index is equal to the + * function's index in this MultiDomainFunction. + * 3) "non-negative integer" : a domain index. + * 4) "a,b,c,..." : a list of domain indices (a,b,c,.. are non-negative integers). + * 5) "a - b" : a range of domain indices (a,b are non-negative integers a <= b). + * + * To be used with Fit algorithm at least one of the member functions must have "domains" value + * of type 2), 3), 4) or 5) because these values can tell Fit how many domains need to be created. + * + * @param i :: Index of a function for which the attribute is being set. + * @param attName :: Name of an attribute. + * @param att :: Value of the attribute to set. */ void MultiDomainFunction::setLocalAttribute(size_t i, const std::string& attName,const IFunction::Attribute& att) { @@ -263,15 +280,40 @@ namespace API else if (value.empty()) {// do not fit to any domain setDomainIndices(i,std::vector()); + return; } + // fit to a selection of domains std::vector indx; Expression list; list.parse(value); - list.toList(); - for(size_t k = 0; k < list.size(); ++k) + if (list.name() == "+") + { + if ( list.size() != 2 || list.terms()[1].operator_name() != "-" ) + { + throw std::runtime_error("MultiDomainFunction: attribute \"domains\" expects two integers separated by a \"-\""); + } + // value looks like "a - b". a and b must be ints and define a range of domain indices + size_t start = boost::lexical_cast( list.terms()[0].str() ); + size_t end = boost::lexical_cast( list.terms()[1].str() ) + 1; + if ( start >= end ) + { + throw std::runtime_error("MultiDomainFunction: attribute \"domains\": wrong range limits."); + } + indx.resize( end - start ); + for(size_t i = start; i < end; ++i) + { + indx[i - start] = i; + } + } + else { - indx.push_back(boost::lexical_cast(list[k].name())); + // value must be either an int or a list of ints: "a,b,c,..." + list.toList(); + for(size_t k = 0; k < list.size(); ++k) + { + indx.push_back(boost::lexical_cast(list[k].name())); + } } setDomainIndices(i,indx); } diff --git a/Code/Mantid/Framework/API/test/MultiDomainFunctionTest.h b/Code/Mantid/Framework/API/test/MultiDomainFunctionTest.h index 8ec432d09093..8047c8cba065 100644 --- a/Code/Mantid/Framework/API/test/MultiDomainFunctionTest.h +++ b/Code/Mantid/Framework/API/test/MultiDomainFunctionTest.h @@ -299,6 +299,43 @@ class MultiDomainFunctionTest : public CxxTest::TestSuite } + void test_attribute_domain_range() + { + multi.clearDomainIndices(); + multi.setLocalAttributeValue(0,"domains","0-2"); + return; + multi.setLocalAttributeValue(1,"domains","i"); + multi.setLocalAttributeValue(2,"domains","i"); + + FunctionValues values(domain); + multi.function(domain,values); + + double A = multi.getFunction(0)->getParameter("A"); + double B = multi.getFunction(0)->getParameter("B"); + const FunctionDomain1D& d0 = static_cast(domain.getDomain(0)); + for(size_t i = 0; i < 9; ++i) + { + TS_ASSERT_EQUALS(values.getCalculated(i), A + B * d0[i]); + } + + A = multi.getFunction(0)->getParameter("A") + multi.getFunction(1)->getParameter("A"); + B = multi.getFunction(0)->getParameter("B") + multi.getFunction(1)->getParameter("B"); + const FunctionDomain1D& d1 = static_cast(domain.getDomain(1)); + for(size_t i = 9; i < 19; ++i) + { + TS_ASSERT_EQUALS(values.getCalculated(i), A + B * d1[i-9]); + } + + A = multi.getFunction(0)->getParameter("A") + multi.getFunction(2)->getParameter("A"); + B = multi.getFunction(0)->getParameter("B") + multi.getFunction(2)->getParameter("B"); + const FunctionDomain1D& d2 = static_cast(domain.getDomain(2)); + for(size_t i = 19; i < 30; ++i) + { + TS_ASSERT_EQUALS(values.getCalculated(i), A + B * d2[i-19]); + } + + } + void test_attribute_in_FunctionFactory() { std::string ini = "composite=MultiDomainFunction;" From a7f230e97eb4f5759d30caef2463eed9a4694d69 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Tue, 13 May 2014 12:01:57 +0100 Subject: [PATCH 019/126] Refs #8922 Add support for nested history saving. --- .../API/inc/MantidAPI/AlgorithmHistory.h | 3 ++ .../Framework/API/src/AlgorithmHistory.cpp | 29 +++++++++++++++++ .../Framework/API/src/WorkspaceHistory.cpp | 31 ++++--------------- 3 files changed, 38 insertions(+), 25 deletions(-) diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmHistory.h b/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmHistory.h index 01c3da5be058..52870483455e 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmHistory.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmHistory.h @@ -7,6 +7,7 @@ #include "MantidAPI/DllConfig.h" #include "MantidKernel/PropertyHistory.h" #include "MantidKernel/DateAndTime.h" +#include #include #include @@ -120,6 +121,8 @@ class MANTID_API_DLL AlgorithmHistory boost::shared_ptr createAlgorithm() const; /// Create an child algorithm from a history record at a given index boost::shared_ptr getChildAlgorithm(const size_t index) const; + /// Write this history object to a nexus file + void saveNexus(::NeXus::File* file, int& algCount) const; // Allow Algorithm::execute to change the exec count & duration after the algorithm was executed friend class Algorithm; diff --git a/Code/Mantid/Framework/API/src/AlgorithmHistory.cpp b/Code/Mantid/Framework/API/src/AlgorithmHistory.cpp index 3f7c08bef36c..d9361ee1ad13 100644 --- a/Code/Mantid/Framework/API/src/AlgorithmHistory.cpp +++ b/Code/Mantid/Framework/API/src/AlgorithmHistory.cpp @@ -3,6 +3,7 @@ //---------------------------------------------------------------------- #include "MantidAPI/AlgorithmHistory.h" #include "MantidAPI/Algorithm.h" +#include namespace Mantid { @@ -208,5 +209,33 @@ std::ostream& operator<<(std::ostream& os, const AlgorithmHistory& AH) return os; } +/** Write out this history record to file. + * @param file :: The handle to the nexus file to save to + * @param algCount :: Counter of the number of algorithms written to file. + */ +void AlgorithmHistory::saveNexus(::NeXus::File* file, int& algCount) const +{ + std::stringstream algNumber; + ++algCount; + algNumber << "MantidAlgorithm_" << algCount; //history entry names start at 1 not 0 + + std::stringstream algData; + printSelf(algData); + + file->makeGroup(algNumber.str(), "NXnote", true); + file->writeData("author", std::string("mantid")); + file->writeData("description", std::string("Mantid Algorithm data")); + file->writeData("data", algData.str()); + + //child algorithms + AlgorithmHistories::const_iterator histIter = m_childHistories.begin(); + for(; histIter != m_childHistories.end(); ++histIter) + { + (*histIter)->saveNexus(file, algCount); + } + + file->closeGroup(); +} + } // namespace API } // namespace Mantid diff --git a/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp b/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp index 3c0db0ce7a83..f5ca43887e6b 100644 --- a/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp +++ b/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp @@ -187,33 +187,14 @@ void WorkspaceHistory::saveNexus(::NeXus::File * file) const file->closeGroup(); // Algorithm History - typedef std::map orderedHistMap; - orderedHistMap ordMap; - for(std::size_t i=0;isize();i++) + int algCount = 0; + AlgorithmHistories::const_iterator histIter = m_algorithms.begin(); + for(; histIter != m_algorithms.end(); ++histIter) { - std::stringstream algData; - auto entry = this->getAlgorithmHistory(i); - entry->printSelf(algData); - - //get execute count - std::size_t nexecCount=entry->execCount(); - //order by execute count - ordMap.insert(orderedHistMap::value_type(nexecCount,algData.str())); - } - int num=0; - std::map ::iterator m_Iter; - for (m_Iter=ordMap.begin( );m_Iter!=ordMap.end( );++m_Iter) - { - ++num; - std::stringstream algNumber; - algNumber << "MantidAlgorithm_" << num; - - file->makeGroup(algNumber.str(), "NXnote", true); - file->writeData("author", std::string("mantid")); - file->writeData("description", std::string("Mantid Algorithm data")); - file->writeData("data", m_Iter->second); - file->closeGroup(); + (*histIter)->saveNexus(file, algCount); } + + //close process group file->closeGroup(); } From 7685625d22a8033f08027c5eaa6bb5cd5be8cf57 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Tue, 13 May 2014 12:02:11 +0100 Subject: [PATCH 020/126] Refs #8922 Refactor history loading. --- .../API/inc/MantidAPI/WorkspaceHistory.h | 5 +- .../Framework/API/src/WorkspaceHistory.cpp | 209 ++++++++++-------- 2 files changed, 121 insertions(+), 93 deletions(-) diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceHistory.h b/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceHistory.h index 0619e8f5a07c..f306e2a832e9 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceHistory.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceHistory.h @@ -89,7 +89,10 @@ class MANTID_API_DLL WorkspaceHistory private: /// Private, unimplemented copy assignment operator WorkspaceHistory& operator=(const WorkspaceHistory& ); - + /// Parse an algorithm history string loaded from file + AlgorithmHistory_sptr parseAlgorithmHistory(const std::string& rawData); + /// Find the history entries at this level in the file. + std::set findHistoryEntries(::NeXus::File* file); /// The environment of the workspace const Kernel::EnvironmentHistory m_environment; /// The algorithms which have been called on the workspace diff --git a/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp b/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp index f5ca43887e6b..71c421fdafdf 100644 --- a/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp +++ b/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp @@ -251,16 +251,6 @@ void getWordsInString(const std::string & words4, std::string & w1, std::string */ void WorkspaceHistory::loadNexus(::NeXus::File * file) { - /// specifies the order that algorithm data is listed in workspaces' histories - enum AlgorithmHist - { - NAME = 0, //< algorithms name - EXEC_TIME = 1, //< when the algorithm was run - EXEC_DUR = 2, //< execution time for the algorithm - PARAMS = 3 //< the algorithm's parameters - }; - - // Warn but continue if the group does not exist. try { @@ -271,13 +261,44 @@ void WorkspaceHistory::loadNexus(::NeXus::File * file) g_log.warning() << "Error opening the algorithm history field 'process'. Workspace will have no history." << "\n"; return; } + + // historyNumbers should be sorted by number + std::set historyNumbers = findHistoryEntries(file); + for (auto it = historyNumbers.begin(); it != historyNumbers.end(); ++it) + { + std::string entryName = "MantidAlgorithm_" + Kernel::Strings::toString(*it); + std::string rawData; + file->openGroup(entryName, "NXnote"); + file->readData("data", rawData); + file->closeGroup(); + + try + { + AlgorithmHistory_sptr history = parseAlgorithmHistory(rawData); + this->addHistory(history); + } + catch (std::runtime_error& e) + { + //just log the exception as a warning and continue parsing history + g_log.warning() << e.what() << "\n"; + } + } + + file->closeGroup(); +} + +/** Find all the algorithm entries at a particular point the the nexus file + * @param file :: The handle to the nexus file + * @returns set of integers. One for each algorithm at the level in the file. + */ +std::set WorkspaceHistory::findHistoryEntries(::NeXus::File* file) +{ + std::set historyNumbers; std::map entries; file->getEntries(entries); - // Histories are numberd MantidAlgorithm_0, ..., MantidAlgorithm_10, etc. // Find all the unique numbers - std::set historyNumbers; for (auto it = entries.begin(); it != entries.end(); ++it) { std::string entryName = it->first; @@ -291,91 +312,95 @@ void WorkspaceHistory::loadNexus(::NeXus::File * file) } } - // historyNumbers should be sorted by number - for (auto it = historyNumbers.begin(); it != historyNumbers.end(); ++it) - { - std::string entryName = "MantidAlgorithm_" + Kernel::Strings::toString(*it); - file->openGroup(entryName, "NXnote"); - std::string rawData; - file->readData("data", rawData); - file->closeGroup(); + return historyNumbers; +} - // Split into separate lines - std::vector info; - boost::split(info, rawData, boost::is_any_of("\n")); +/** Parse an algorithm history entry loaded from file. + * @param rawData :: The string containing the history entry loaded from file + * @returns a pointer to the loaded algorithm history object + * @throws std::runtime_error if the loaded data could not be parsed + */ +AlgorithmHistory_sptr WorkspaceHistory::parseAlgorithmHistory(const std::string& rawData) +{ + /// specifies the order that algorithm data is listed in workspaces' histories + enum AlgorithmHist + { + NAME = 0, //< algorithms name + EXEC_TIME = 1, //< when the algorithm was run + EXEC_DUR = 2, //< execution time for the algorithm + PARAMS = 3 //< the algorithm's parameters + }; - const size_t nlines = info.size(); - if( nlines < 4 ) - {// ignore badly formed history entries - continue; - } + std::vector info; + boost::split(info, rawData, boost::is_any_of("\n")); - std::string algName, dummy, temp; - // get the name and version of the algorithm - getWordsInString(info[NAME], dummy, algName, temp); - - //Chop of the v from the version string - size_t numStart = temp.find('v'); - // this doesn't abort if the version string doesn't contain a v - numStart = numStart != 1 ? 1 : 0; - temp = std::string(temp.begin() + numStart, temp.end()); - const int version = boost::lexical_cast(temp); - - //Get the execution date/time - std::string date, time; - getWordsInString(info[EXEC_TIME], dummy, dummy, date, time); - Poco::DateTime start_timedate; - //This is needed by the Poco parsing function - int tzdiff(-1); - if( !Poco::DateTimeParser::tryParse("%Y-%b-%d %H:%M:%S", date + " " + time, start_timedate, tzdiff)) - { - g_log.warning() << "Error parsing start time in algorithm history entry." << "\n"; - file->closeGroup(); - return; - } - //Get the duration - getWordsInString(info[EXEC_DUR], dummy, dummy, temp, dummy); - double dur = boost::lexical_cast(temp); - if ( dur < 0.0 ) - { - g_log.warning() << "Error parsing start time in algorithm history entry." << "\n"; - file->closeGroup(); - return; - } - //Convert the timestamp to time_t to DateAndTime - Mantid::Kernel::DateAndTime utc_start; - utc_start.set_from_time_t( start_timedate.timestamp().epochTime() ); - //Create the algorithm history - API::AlgorithmHistory alg_hist(algName, version, utc_start, dur,Algorithm::g_execCount); - // Simulate running an algorithm - ++Algorithm::g_execCount; - - //Add property information - for( size_t index = static_cast(PARAMS)+1;index < nlines;++index ) - { - const std::string line = info[index]; - std::string::size_type colon = line.find(":"); - std::string::size_type comma = line.find(","); - //Each colon has a space after it - std::string prop_name = line.substr(colon + 2, comma - colon - 2); - colon = line.find(":", comma); - comma = line.find(", Default?", colon); - std::string prop_value = line.substr(colon + 2, comma - colon - 2); - colon = line.find(":", comma); - comma = line.find(", Direction", colon); - std::string is_def = line.substr(colon + 2, comma - colon - 2); - colon = line.find(":", comma); - comma = line.find(",", colon); - std::string direction = line.substr(colon + 2, comma - colon - 2); - unsigned int direc(Mantid::Kernel::Direction::asEnum(direction)); - alg_hist.addProperty(prop_name, prop_value, (is_def[0] == 'Y'), direc); - } - - boost::shared_ptr history = boost::make_shared(alg_hist); - this->addHistory(history); + const size_t nlines = info.size(); + if( nlines < 4 ) + {// ignore badly formed history entries + throw std::runtime_error("Malformed history record: Incorrect record size."); } - file->closeGroup(); + std::string algName, dummy, temp; + // get the name and version of the algorithm + getWordsInString(info[NAME], dummy, algName, temp); + + //Chop of the v from the version string + size_t numStart = temp.find('v'); + // this doesn't abort if the version string doesn't contain a v + numStart = numStart != 1 ? 1 : 0; + temp = std::string(temp.begin() + numStart, temp.end()); + const int version = boost::lexical_cast(temp); + + //Get the execution date/time + std::string date, time; + getWordsInString(info[EXEC_TIME], dummy, dummy, date, time); + Poco::DateTime start_timedate; + //This is needed by the Poco parsing function + int tzdiff(-1); + if( !Poco::DateTimeParser::tryParse("%Y-%b-%d %H:%M:%S", date + " " + time, start_timedate, tzdiff)) + { + g_log.warning() << "Error parsing start time in algorithm history entry." << "\n"; + throw std::runtime_error("Malformed history record: could not parse algorithm start time."); + } + //Get the duration + getWordsInString(info[EXEC_DUR], dummy, dummy, temp, dummy); + double dur = boost::lexical_cast(temp); + if ( dur < 0.0 ) + { + g_log.warning() << "Error parsing start time in algorithm history entry." << "\n"; + throw std::runtime_error("Malformed history record: could not parse algorithm duration."); + } + //Convert the timestamp to time_t to DateAndTime + Mantid::Kernel::DateAndTime utc_start; + utc_start.set_from_time_t( start_timedate.timestamp().epochTime() ); + //Create the algorithm history + API::AlgorithmHistory alg_hist(algName, version, utc_start, dur,Algorithm::g_execCount); + // Simulate running an algorithm + ++Algorithm::g_execCount; + + //Add property information + for( size_t index = static_cast(PARAMS)+1;index < nlines;++index ) + { + const std::string line = info[index]; + std::string::size_type colon = line.find(":"); + std::string::size_type comma = line.find(","); + //Each colon has a space after it + std::string prop_name = line.substr(colon + 2, comma - colon - 2); + colon = line.find(":", comma); + comma = line.find(", Default?", colon); + std::string prop_value = line.substr(colon + 2, comma - colon - 2); + colon = line.find(":", comma); + comma = line.find(", Direction", colon); + std::string is_def = line.substr(colon + 2, comma - colon - 2); + colon = line.find(":", comma); + comma = line.find(",", colon); + std::string direction = line.substr(colon + 2, comma - colon - 2); + unsigned int direc(Mantid::Kernel::Direction::asEnum(direction)); + alg_hist.addProperty(prop_name, prop_value, (is_def[0] == 'Y'), direc); + } + + AlgorithmHistory_sptr history = boost::make_shared(alg_hist); + return history; } From c60223824f8503455463718992e4bc2ae1c7bc03 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Tue, 13 May 2014 13:25:55 +0100 Subject: [PATCH 021/126] Refs #8922 Add support for loading nested histories. --- .../API/inc/MantidAPI/WorkspaceHistory.h | 4 +++ .../Framework/API/src/WorkspaceHistory.cpp | 30 +++++++++++++++++-- 2 files changed, 31 insertions(+), 3 deletions(-) diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceHistory.h b/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceHistory.h index f306e2a832e9..5ea3b959a05c 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceHistory.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceHistory.h @@ -82,13 +82,17 @@ class MANTID_API_DLL WorkspaceHistory /// Pretty print the entire history void printSelf(std::ostream&, const int indent = 0) const; + /// Save the workspace history to a nexus file void saveNexus(::NeXus::File * file) const; + /// Load the workspace history from a nexus file void loadNexus(::NeXus::File * file); private: /// Private, unimplemented copy assignment operator WorkspaceHistory& operator=(const WorkspaceHistory& ); + /// Recursive function to load the algorithm history tree from file + void loadNestedHistory(::NeXus::File * file, AlgorithmHistory_sptr parent = boost::shared_ptr()); /// Parse an algorithm history string loaded from file AlgorithmHistory_sptr parseAlgorithmHistory(const std::string& rawData); /// Find the history entries at this level in the file. diff --git a/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp b/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp index 71c421fdafdf..9b3e50cb6dbc 100644 --- a/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp +++ b/Code/Mantid/Framework/API/src/WorkspaceHistory.cpp @@ -262,6 +262,20 @@ void WorkspaceHistory::loadNexus(::NeXus::File * file) return; } + loadNestedHistory(file); + file->closeGroup(); +} + +/** Load every algorithm history object at this point in the hierarchy. + * This method will recurse over every algorithm entry in the nexus file and + * load both the record and its children. + * + * @param file :: The handle to the nexus file + * @param parent :: Pointer to the parent AlgorithmHistory object. If null then loaded histories are added to + * the workspace history. + */ +void WorkspaceHistory::loadNestedHistory(::NeXus::File * file, AlgorithmHistory_sptr parent) +{ // historyNumbers should be sorted by number std::set historyNumbers = findHistoryEntries(file); for (auto it = historyNumbers.begin(); it != historyNumbers.end(); ++it) @@ -270,21 +284,31 @@ void WorkspaceHistory::loadNexus(::NeXus::File * file) std::string rawData; file->openGroup(entryName, "NXnote"); file->readData("data", rawData); - file->closeGroup(); try { AlgorithmHistory_sptr history = parseAlgorithmHistory(rawData); - this->addHistory(history); + loadNestedHistory(file, history); + if(parent) + { + parent->addChildHistory(history); + } + else + { + //if not parent point is supplied, asssume we're at the top + //and attach the history to the workspace + this->addHistory(history); + } } catch (std::runtime_error& e) { //just log the exception as a warning and continue parsing history g_log.warning() << e.what() << "\n"; } + + file->closeGroup(); } - file->closeGroup(); } /** Find all the algorithm entries at a particular point the the nexus file From 0ad1585dd68800c49e7a1d9b7b6c797ef3de3541 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Wed, 14 May 2014 10:50:50 +0100 Subject: [PATCH 022/126] Refs #8922 Fix bug with WorkspaceProperty. Should only give the workspace a temp name if we have a pointer to a workspace. --- Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceProperty.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceProperty.h b/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceProperty.h index 0da355d0cc93..c3a7f72c6ef9 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceProperty.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/WorkspaceProperty.h @@ -345,7 +345,7 @@ namespace Mantid virtual const Kernel::PropertyHistory createHistory() const { std::string wsName = m_workspaceName; - if (wsName.empty()) + if (wsName.empty() && this->operator()()) { //give the property a temporary name in the history std::ostringstream os; From 120dc060f82866c8cff58a5f8acbb1f148750996 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Wed, 14 May 2014 11:16:18 +0100 Subject: [PATCH 023/126] Refs #8922 Add unit tests for nested WorkspaceHistory loading. --- .../Framework/API/test/WorkspaceHistoryTest.h | 53 +++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h b/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h index bbf731872dce..cb564b9c9ca7 100644 --- a/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h +++ b/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h @@ -292,6 +292,35 @@ class WorkspaceHistoryTest : public CxxTest::TestSuite Poco::File("WorkspaceHistoryTest_test_SaveNexus.nxs").remove(); } + void test_SaveNexus_NestedHistory() + { + WorkspaceHistory testHistory; + AlgorithmHistory algHist("ParentHistory", 1,DateAndTime::defaultTime(),-1.0, 0); + AlgorithmHistory childHist("ChildHistory", 1,DateAndTime::defaultTime(),-1.0, 1); + + algHist.addChildHistory(boost::make_shared(childHist)); + testHistory.addHistory(boost::make_shared(algHist)); + + auto savehandle = boost::make_shared< ::NeXus::File >("WorkspaceHistoryTest_test_SaveNexus.nxs",NXACC_CREATE5); + TS_ASSERT_THROWS_NOTHING(testHistory.saveNexus(savehandle.get())); + savehandle->close(); + + auto loadhandle = boost::make_shared< ::NeXus::File >("WorkspaceHistoryTest_test_SaveNexus.nxs"); + std::string rootstring = "/process/"; + TS_ASSERT_THROWS_NOTHING(loadhandle->openPath(rootstring + "MantidAlgorithm_1/")); + TS_ASSERT_THROWS_NOTHING(loadhandle->openPath(rootstring + "MantidAlgorithm_1/author")); + TS_ASSERT_THROWS_NOTHING(loadhandle->openPath(rootstring + "MantidAlgorithm_1/data")); + TS_ASSERT_THROWS_NOTHING(loadhandle->openPath(rootstring + "MantidAlgorithm_1/description")); + + TS_ASSERT_THROWS_NOTHING(loadhandle->openPath(rootstring + "MantidAlgorithm_1/MantidAlgorithm_2")); + TS_ASSERT_THROWS_NOTHING(loadhandle->openPath(rootstring + "MantidAlgorithm_1/MantidAlgorithm_2/author")); + TS_ASSERT_THROWS_NOTHING(loadhandle->openPath(rootstring + "MantidAlgorithm_1/MantidAlgorithm_2/data")); + TS_ASSERT_THROWS_NOTHING(loadhandle->openPath(rootstring + "MantidAlgorithm_1/MantidAlgorithm_2/description")); + + loadhandle->close(); + Poco::File("WorkspaceHistoryTest_test_SaveNexus.nxs").remove(); + } + void test_SaveNexus_Empty() { WorkspaceHistory testHistory; @@ -329,7 +358,31 @@ class WorkspaceHistoryTest : public CxxTest::TestSuite TS_ASSERT_EQUALS(DateAndTime("2009-10-09T16:56:54"), history->executionDate()); TS_ASSERT_EQUALS(2.3, history->executionDuration()); loadhandle->close(); + } + + void test_LoadNexus_NestedHistory() + { + std::string filename = FileFinder::Instance().getFullPath("HistoryTest_CreateTransmissionAuto.nxs"); + auto loadhandle = boost::make_shared< ::NeXus::File >(filename); + loadhandle->openPath("/mantid_workspace_1"); + + WorkspaceHistory wsHistory; + TS_ASSERT_THROWS_NOTHING(wsHistory.loadNexus(loadhandle.get())); + const auto & histories = wsHistory.getAlgorithmHistories(); + TS_ASSERT_EQUALS(3,histories.size()); + + const auto history = wsHistory.getAlgorithmHistory(1); + + TS_ASSERT_EQUALS("CreateTransmissionWorkspaceAuto", history->name()); + TS_ASSERT_EQUALS(1, history->version()); + + const auto childHistory = history->getChildAlgorithmHistory(0); + + TS_ASSERT_EQUALS("CreateTransmissionWorkspace", childHistory->name()); + TS_ASSERT_EQUALS(1, childHistory->version()); + + loadhandle->close(); } void test_LoadNexus_Blank_File() From 60dfa90f2749cb5c31371c68a6aff8186dd13c43 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Wed, 14 May 2014 17:00:09 +0100 Subject: [PATCH 024/126] Refs #8922 Fix SaveNexus and SaveNexusProcessed to capture history. SaveNexus and SaveNexusProcessed wouldn't append a record to the history. This commit fixes that issue and leaves a record on the input workspace so the result is that we get a complete history, but we lose the execution start time and duration. --- .../Framework/API/inc/MantidAPI/Algorithm.h | 8 +++++--- .../API/inc/MantidAPI/AlgorithmHistory.h | 2 +- .../Framework/API/src/AlgorithmHistory.cpp | 8 +++----- .../Framework/API/src/WorkspaceHistory.cpp | 10 +++++----- .../inc/MantidDataHandling/SaveNexusProcessed.h | 5 ++--- .../Framework/DataHandling/src/SaveNexus.cpp | 14 ++++++++++++++ .../DataHandling/src/SaveNexusProcessed.cpp | 17 +++++++++++++++-- 7 files changed, 45 insertions(+), 19 deletions(-) diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/Algorithm.h b/Code/Mantid/Framework/API/inc/MantidAPI/Algorithm.h index e91c534a62cf..aa29ecbd7820 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/Algorithm.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/Algorithm.h @@ -349,6 +349,9 @@ class MANTID_API_DLL Algorithm : public IAlgorithm, public Kernel::PropertyManag Kernel::Logger m_log; Kernel::Logger &g_log; + /// Pointer to the parent history object (if set) + boost::shared_ptr m_parentHistory; + private: /// Private Copy constructor: NO COPY ALLOWED Algorithm(const Algorithm&); @@ -359,11 +362,12 @@ class MANTID_API_DLL Algorithm : public IAlgorithm, public Kernel::PropertyManag void unlockWorkspaces(); void store(); - void fillHistory(); void logAlgorithmInfo() const; bool executeAsyncImpl(const Poco::Void & i); + /// Copy workspace history for input workspaces to output workspaces and record the history for ths algorithm + void fillHistory(); // --------------------- Private Members ----------------------------------- /// Poco::ActiveMethod used to implement asynchronous execution. @@ -411,8 +415,6 @@ class MANTID_API_DLL Algorithm : public IAlgorithm, public Kernel::PropertyManag size_t m_groupSize; /// All the groups have similar names (group_1, group_2 etc.) bool m_groupsHaveSimilarNames; - /// Pointer to the parent history object (if set) - boost::shared_ptr m_parentHistory; /// A non-recursive mutex for thread-safety mutable Kernel::Mutex m_mutex; }; diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmHistory.h b/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmHistory.h index 52870483455e..93f420e07c5a 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmHistory.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmHistory.h @@ -126,9 +126,9 @@ class MANTID_API_DLL AlgorithmHistory // Allow Algorithm::execute to change the exec count & duration after the algorithm was executed friend class Algorithm; -private: // Set the execution count void setExecCount(std::size_t execCount) { m_execCount = execCount; } +private: /// The name of the Algorithm std::string m_name; /// The version of the algorithm diff --git a/Code/Mantid/Framework/API/src/AlgorithmHistory.cpp b/Code/Mantid/Framework/API/src/AlgorithmHistory.cpp index d9361ee1ad13..bafc88b286de 100644 --- a/Code/Mantid/Framework/API/src/AlgorithmHistory.cpp +++ b/Code/Mantid/Framework/API/src/AlgorithmHistory.cpp @@ -155,11 +155,9 @@ void AlgorithmHistory::printSelf(std::ostream& os, const int indent)const { os << std::string(indent,' ') << "Algorithm: " << m_name; os << std::string(indent,' ') << " v" << m_version << std::endl; - if (m_executionDate != Mantid::Kernel::DateAndTime::defaultTime()) - { - os << std::string(indent,' ') << "Execution Date: " << m_executionDate.toFormattedString() <::const_iterator it; os << std::string(indent,' ') << "Parameters:" <addHistory(history); } @@ -321,7 +321,7 @@ std::set WorkspaceHistory::findHistoryEntries(::NeXus::File* file) std::map entries; file->getEntries(entries); - // Histories are numberd MantidAlgorithm_0, ..., MantidAlgorithm_10, etc. + // Histories are numbered MantidAlgorithm_0, ..., MantidAlgorithm_10, etc. // Find all the unique numbers for (auto it = entries.begin(); it != entries.end(); ++it) { @@ -381,10 +381,11 @@ AlgorithmHistory_sptr WorkspaceHistory::parseAlgorithmHistory(const std::string& Poco::DateTime start_timedate; //This is needed by the Poco parsing function int tzdiff(-1); + Mantid::Kernel::DateAndTime utc_start; if( !Poco::DateTimeParser::tryParse("%Y-%b-%d %H:%M:%S", date + " " + time, start_timedate, tzdiff)) { g_log.warning() << "Error parsing start time in algorithm history entry." << "\n"; - throw std::runtime_error("Malformed history record: could not parse algorithm start time."); + utc_start = Kernel::DateAndTime::defaultTime(); } //Get the duration getWordsInString(info[EXEC_DUR], dummy, dummy, temp, dummy); @@ -392,10 +393,9 @@ AlgorithmHistory_sptr WorkspaceHistory::parseAlgorithmHistory(const std::string& if ( dur < 0.0 ) { g_log.warning() << "Error parsing start time in algorithm history entry." << "\n"; - throw std::runtime_error("Malformed history record: could not parse algorithm duration."); + dur = -1.0; } //Convert the timestamp to time_t to DateAndTime - Mantid::Kernel::DateAndTime utc_start; utc_start.set_from_time_t( start_timedate.timestamp().epochTime() ); //Create the algorithm history API::AlgorithmHistory alg_hist(algName, version, utc_start, dur,Algorithm::g_execCount); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/SaveNexusProcessed.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/SaveNexusProcessed.h index 30b524c192f5..d8658a30d37e 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/SaveNexusProcessed.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/SaveNexusProcessed.h @@ -76,9 +76,9 @@ namespace Mantid static void appendEventListData( std::vector events, size_t offset, double * tofs, float * weights, float * errorSquareds, int64_t * pulsetimes); void execEvent(Mantid::NeXus::NexusFileIO * nexusFile,const bool uniformSpectra,const std::vector spec); - /// sets non workspace properties for the algorithm + /// sets non workspace properties for the algorithm void setOtherProperties(IAlgorithm* alg,const std::string & propertyName,const std::string &propertyValue,int perioidNum); - + /// The name and path of the input file std::string m_filename; /// The name and path of the input file @@ -91,7 +91,6 @@ namespace Mantid DataObjects::EventWorkspace_const_sptr m_eventWorkspace; /// Proportion of progress time expected to write initial part double m_timeProgInit; - /// Progress bar API::Progress * prog; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveNexus.cpp b/Code/Mantid/Framework/DataHandling/src/SaveNexus.cpp index 25a28381391b..5773012600fd 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveNexus.cpp @@ -195,6 +195,20 @@ void SaveNexus::runSaveNexusProcessed() // Pass through the append property saveNexusPro->setProperty("Append",getProperty("Append")); + // If we're tracking history, add the entry before we save it to file + if (trackingHistory()) + { + m_history->setExecCount(Algorithm::g_execCount); + if (!isChild()) + { + m_inputWorkspace->history().addHistory(m_history); + } + //this is a child algorithm, but we still want to keep the history. + else if (isRecordingHistoryForChild() && m_parentHistory) + { + m_parentHistory->addChildHistory(m_history); + } + } // Now execute the Child Algorithm. Catch and log any error, but don't stop. try { diff --git a/Code/Mantid/Framework/DataHandling/src/SaveNexusProcessed.cpp b/Code/Mantid/Framework/DataHandling/src/SaveNexusProcessed.cpp index 24eaeb9e5eab..bfceaee6b5d6 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveNexusProcessed.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveNexusProcessed.cpp @@ -347,10 +347,23 @@ namespace DataHandling } // finish table workspace specifics // Switch to the Cpp API for the algorithm history - inputWorkspace->getHistory().saveNexus(cppFile); + if (trackingHistory()) + { + m_history->setExecCount(Algorithm::g_execCount); + if (!isChild()) + { + inputWorkspace->history().addHistory(m_history); + } + //this is a child algorithm, but we still want to keep the history. + else if (isRecordingHistoryForChild() && m_parentHistory) + { + m_parentHistory->addChildHistory(m_history); + } + } + + inputWorkspace->history().saveNexus(cppFile); nexusFile->closeNexusFile(); - delete nexusFile; return; From f9dc5b737ef7ee6c3f776a974159d633944b8c96 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Wed, 14 May 2014 17:00:55 +0100 Subject: [PATCH 025/126] Refs #8922 Fix unit tests. --- .../Framework/API/test/WorkspaceHistoryTest.h | 9 +++++-- .../API/test/WorkspacePropertyTest.h | 24 ++++++++++-------- .../test/GeneratePythonScriptTest.h | 4 ++- .../HistoryTest_CreateTransmissionAuto.nxs | Bin 0 -> 268036 bytes 4 files changed, 23 insertions(+), 14 deletions(-) create mode 100644 Test/AutoTestData/HistoryTest_CreateTransmissionAuto.nxs diff --git a/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h b/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h index cb564b9c9ca7..14f0deec94db 100644 --- a/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h +++ b/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h @@ -371,8 +371,8 @@ class WorkspaceHistoryTest : public CxxTest::TestSuite const auto & histories = wsHistory.getAlgorithmHistories(); TS_ASSERT_EQUALS(3,histories.size()); - - const auto history = wsHistory.getAlgorithmHistory(1); + + auto history = wsHistory.getAlgorithmHistory(1); TS_ASSERT_EQUALS("CreateTransmissionWorkspaceAuto", history->name()); TS_ASSERT_EQUALS(1, history->version()); @@ -382,6 +382,11 @@ class WorkspaceHistoryTest : public CxxTest::TestSuite TS_ASSERT_EQUALS("CreateTransmissionWorkspace", childHistory->name()); TS_ASSERT_EQUALS(1, childHistory->version()); + history = wsHistory.getAlgorithmHistory(2); + + TS_ASSERT_EQUALS("SaveNexusProcessed", history->name()); + TS_ASSERT_EQUALS(1, history->version()); + loadhandle->close(); } diff --git a/Code/Mantid/Framework/API/test/WorkspacePropertyTest.h b/Code/Mantid/Framework/API/test/WorkspacePropertyTest.h index 03114eeee31b..eb5ffe00d5e9 100644 --- a/Code/Mantid/Framework/API/test/WorkspacePropertyTest.h +++ b/Code/Mantid/Framework/API/test/WorkspacePropertyTest.h @@ -191,17 +191,6 @@ class WorkspacePropertyTest : public CxxTest::TestSuite TS_ASSERT( ! history2.isDefault() ) TS_ASSERT_EQUALS( history2.type(), wsp2->type() ) TS_ASSERT_EQUALS( history2.direction(), 1 ) - - wsp3->setValue(""); - PropertyHistory history3 = wsp3->createHistory(); - TS_ASSERT_EQUALS( history3.name(), "workspace3" ) - TS_ASSERT( !history3.value().empty() ) - TS_ASSERT_EQUALS( history3.value().substr(0,5), "__TMP" ) - //TS_ASSERT( history3.isDefault() ) - TS_ASSERT_EQUALS( history3.type(), wsp3->type() ) - TS_ASSERT_EQUALS( history3.direction(), 2 ) - wsp3->setValue("ws3"); - } void testStore() @@ -230,6 +219,19 @@ class WorkspacePropertyTest : public CxxTest::TestSuite TS_ASSERT( ! wsp3->operator()() ) } + void testTempName() + { + wsp4->setValue(""); + // Create and assign the workspace + Workspace_sptr space; + TS_ASSERT_THROWS_NOTHING(space = WorkspaceFactory::Instance().create("WorkspacePropertyTest",1,1,1) ); + *wsp4 = space; + + PropertyHistory history = wsp4->createHistory(); + TS_ASSERT( !history.value().empty() ) + TS_ASSERT_EQUALS( history.value().substr(0,5), "__TMP" ) + } + void testDirection() { TS_ASSERT_EQUALS( wsp1->direction(), 0 ); diff --git a/Code/Mantid/Framework/Algorithms/test/GeneratePythonScriptTest.h b/Code/Mantid/Framework/Algorithms/test/GeneratePythonScriptTest.h index 9a0f948cb008..0a78a47d6ced 100644 --- a/Code/Mantid/Framework/Algorithms/test/GeneratePythonScriptTest.h +++ b/Code/Mantid/Framework/Algorithms/test/GeneratePythonScriptTest.h @@ -68,6 +68,8 @@ class GeneratePythonScriptTest : public CxxTest::TestSuite "#Python Script Generated by GeneratePythonScript Algorithm", "######################################################################", "ERROR: MISSING ALGORITHM: NonExistingAlgorithm with parameters Algorithm: NonExistingAlgorithm v1", + " Execution Date: 1970-Jan-01 00:00:00", + " Execution Duration: -1 seconds", " Parameters:", " Name: InputWorkspace, Value: [\\_A-Za-z0-9]*, Default\\?: Yes, Direction: Input", " Name: OutputWorkspace, Value: [\\_A-Za-z0-9]*, Default\\?: Yes, Direction: Output", @@ -107,7 +109,7 @@ class GeneratePythonScriptTest : public CxxTest::TestSuite } // Verify that if we set the content of ScriptText that it is set correctly. - alg.setPropertyValue("ScriptText", result[10]); + alg.setPropertyValue("ScriptText", result[12]); TS_ASSERT_EQUALS(alg.getPropertyValue("ScriptText"), "CropWorkspace\\(InputWorkspace='testGeneratePython',OutputWorkspace='testGeneratePython',XMin='2',XMax='5'\\)"); file.close(); diff --git a/Test/AutoTestData/HistoryTest_CreateTransmissionAuto.nxs b/Test/AutoTestData/HistoryTest_CreateTransmissionAuto.nxs new file mode 100644 index 0000000000000000000000000000000000000000..a6488bdf75650470fb4b48238bff163f96f63c09 GIT binary patch literal 268036 zcmeD^3qVvw*B4(PKA^I&%)F5Wl{}WWqV4s8Xep4OkXp+E3v9wJ?k)maL1t;0Vww4> zpoeK?X-~}_@@4+|_0lgZ$}%W3%`&wz?4kT;=FIHl!Y&K3wz_-uaCYvTd7U|P&diy) z_ue~h%-BBum-q|h^79kA34!z{|I^H_Zb9AXEgt6a+3bf8!wVQ**9Cw02t5Q6*Pq=F zWciC-@kS_1m@z3SNdQWoKgTSY;OC3K{P+zo_9zaFOB$I*8l1&iEi$~5$r%d@#cG{N zo2M$%8)g_w)VUg!0%N#*CU8P0@p(*M<#OFyh@?6A2z>=V_?M!|DmAKRX$(fKUI#H3 z0CWf7<;H|Zhm#b&g>mqg-1n#H^0h@8l}=r(p?5LeAR3Q1A`11znuy#&qaqIFNw&|7){~2awFu&>(Phi2g5m5HN{+w7WGhsCxpj9)~(jVq_wHX#a8u*id4je zMaG6HVlou5!=e?#q7tr+j2sq;rIYq_rEQgu^E5VK)37-Lj`J>d$N9#dNLbG3KbVh- zB9Mi>=-lQ2ALkocGpiU5Sc*Tm{Wy3VhH*3zc}7X}5qjcy%u?kRsf|XKoQ?w`ihMk# zWEs`PB}IJL3F#@RV|*Z%iK{RU%^gqf#ZGd7>&p_xza>2|p)>tMOuVIkG&+-^0>U_d z;1S)ShX_rVE?p>TR~9Dv_7a*NHIR=F=EU>k*binR4LC;N4W(?IqfcptTulA99IiRg&>F*I;P{}DDoo5blEI=(}Rxbxc=^aH=F1=CO_k` z#zMWpBo?WQbMn-p$)MI5i?v2-yNPKPCemqym}b!DYK%rro|wre6po_Cr(`5eGHJ?9 z5#_~2SraFSxq6)mpkM%3zzCPQg4+!Du+87mUwA5Igg#%S`jI;{yN58;qj zv^KXfXl}z5ipa>=NVrCdkc(DVAR06!28|JNQa}su!Qrt!|5!E83)8v}q zC;S(0%heZ`gjtccnSq`Z4}2*u(d!6j!YR8-iqu*iWkiIrNNZ9g=IKjwiZqEZpE7B4 z)kR`~x+F0&JUTM!HfyRW(PI)z^v1+#kwd~F!+|r3Sj7-UY=G6kuX!kX@%H7zDQAyQ#oJ9BnUw=F!1r!Ug# zG-^W_?@((t5N^iCMuEHyiHbC*NJOzq%+(tVAOj$B!2O~MoxWJBE<#>#5^|qWN5_W8 zCJc=p5*8H`9veGUF=S|XRAh8~?2s^+iw=#7iyZ@K60WS#*E%DUYDmSPh_&eJ7NMI+Y{C0iHdmJbSy@zOJs7u zld$YYsdHx(81$vOyw*~;BqABHK9=P)9)^E`L0v@iiL|YSx$cYva*2^qlopw^W7v30 zH>nM#L>ULt^je+CmLl3V4;h8N1PXy3hoK*9-QmFQp>PdR3=NOJnGwWT6ND)=F#Tuo zCz!hS5q!}uGwa&YIHR#WPgF9qDhV;YgqUV#6MWd>irH#`=W8+2HN{xeI=1}BklaZ3 z7D8zRnJkdSSSd&anfZ}P0hxcW>Ir$!85%m}OQZCi{m1qENWLBGe0K0dKAF#E4BxaE ze^f0Sy|5@`uoOD~qAxyb>M2S4*Q|b5+^r2LWa};0O$D;#P~r{ zSuQz0dJEY!(g!?{WC%~5G=YXmd5Hk5T0)`8R5C0gqO7beT&F27HR8-BTyH3duuQIu zWd0SAl2yW|Z)8qIvx9XaR~4ibKY_bSNI7K5!pl)mZw(1!yLm+C@g>ShzM!zT#+PfX z>TAUptx;}`LbsTO4ejOwa*yz%8)b!jXdYuXmN3G${JBfWVhyem zM1t4P!x-TqNNyTduy(&p&9fkIKf-`qj7VhndkYElh9f@@S=jS&oRY=ox0nylH;b)v z%bDCdlW%XEd@bsRKfqQ}j{ZOw6f=I~B_2Tt&ogJEZR@x!-Z}^(ME`KM< zjW=bZ`4371O!aOu-)i-T$nJK{YBkz?Gm!oI+}2!~+uWzm+b>8j@6&OFqAKxA{KmS>ip%>yWHJEiJ)c{n?FQr^sV$!(317pKN>oTn!CZ z5_c`L_9KE}*$^yhbh-LG@XwA2o}4i@EFoBVo&RvlY(azsI^&37s~J1a&SAB3E4bC@ zS_Zts5i~DKJgnTPwMkGGO{u^^r-%SQb9!!}rdSQu66ZE;%Ic$^M zZh0c+6amHKukdnXUa;sd5*P1?VCs7f7Qr73e&c+DzE~7RX!Fp>$goI7ShPZniXIj_ z6#fVMLyVmZQ=9ZOdPHy(c(vuJEh+tb_UsAUc&4yo;Ap;9lLrYR6_H^IMOb8vNH?Hi z4?6fdC~tV4CSMI6Gb0H=ut=jTFcpf#7c?T6`on|82o|T-6%=V$6gq`0aRyDk#sFQY zffhomF$LtOF4F4?!g4g~Vo_bLg$|r;P6M$e#1jX79#&eyqARSU3)SGF%+tYM0^#0> zV1u@x&}1eU9?@!{yhUNNw3;%SEByr}UmHwYGCac4W`A+`WgmfT2Utm+u|$&# z9LyEX+XF`G(I<)i)HFr8pgleQjyABc>_fw#-EdZq5C&(?AKp8Fd~l zUBnF!b46JinnczUntbRUEl6Gk)RcSJSs}yCv}`C^D1t>|b4LWDyPXaNkVm>_gR*Av z(Q~OWXLg-G893%3%iH3-Z!_=CbnavApgthS*7c7{fV}|N*a-vYbo9`;A@Sj{aZ#`> zpa_qPih+#+#n6N}+&YMkPl#qa2az%H31sIWHZCrP>>NPm$okSX4Itd zNn^z^N$H~}jZe!MpPC}3junaf-XM-oNza%xd16vZ#xOz-|H(Cu^!L;ekz`X1Mj`B_ zIR0?&PQj-DpG64;d{z>{Aag4gCph&AR z7KSqlhRDzoX}OSCG{Q!rCeK)?(U@2~)CLp-lnUBG&o&sr)Z6XXR(1DD!q)=;@ zu-uw3*8$;dB(&5{n@a`~*}Q~fTzqenk0VfgY#Y*8s3x2>6#`ocCHbjgxsVQsz;hm; zslXUObEu{OO!i-Szrk?L(O|p6W{a>HsRR9h-E6535`cv@mA1B@n^#J=WPw|yI#P}i z_NAZ!Ofj)+iu46UQHqmFbt!rk<`r%#Cp<^#gdbEKCyYv|ipb((u@KBI9T_ns zR0hK*oZ1*sOE<@H(UL<-0Wm7g(F_4w0k+4#C(SvxP!B>$L{Tl~R>1aY9u!IC52XdV zkO&Pec6f=#kP92!Vf1VPs2r--sqG&cYcc%hY_u@5p;@uEgB+0L22GegKP*RYGUQR{Y_lNPN)@z0CRI^f0<5J<5gi^s zl-3c)NVzxyCY<4sVX?4T&F!R>u+g3%#kLeTQlgXMMigK%9L*>$EvB{|1mmAbTLz5U z5IDgZf`UUN6GtLZc6t!BVo)0*2)MSW0_Hlo`U0I6dfi0K0UIk~83?5~OKU8Jc{s5M zpkpS|^D1dYdJ{}+(0FiaNN6lAfnySoi(V|!>t{fVazNmVv@>8zB_?a&Y=}-IGgJ|_ zM|El#6jX#eBF?2bdM#84gqaAdMV5;+`6jYrfC0gTnNFCQkb-d8h%-G05G-0rqg8rf zUKl2}lNu#io;U|K^=->0$w^6VmriHvtySNq2IkQyt3C`E$`)KnpmyLxh_VV=WZ_hs zqaKRkW8P-K$_G8Cqk|uGF)bKIgKW^lQ0T~@$7a}!e5#&?fsmE3EG@$ysO=5@=oW)N zy4ArS7apHL6(?jx>;fJ6k>N2>?Hu}~JnztVF!cRiN+HhM7dxWVPQ~8j4T*uG92JAVs2@X8rDu^{%uJo8mW_l z+{}adF>%9*)MG^H%EPF3&e534G#VYvh)}Yn2|6mkPMas{@Oy@itQA9{LB&^xizADS zdXf`al5tlDE+yD1434_Pxl&S1LV!LkBb&a`Di~l+0n0*ih?5juqK!}_M2-L>p@@%( zjgH1Muy~pReD+vHJ@``cv~V_-tgOhHPgb^OCQQTO2x?BL3FiugoF<{mR?Z`GCN&49 zFvYMaqthBP|0~jzi+QDVE<%~b*KsB_9QdSjb2jq?CKkYr9GKX{^qeh~$3wRjQV$gL zi$MdEAT9Ce&>0cQ4i;Fnhhecy3&wIGE66+?^;#yljnuGy%{9UN2_{)(Fm)nq%Oidx z)%rhd|$`&4z3XA>bOFS|MN*kjX2kzjRBZ5PzKjvESU4}v+?H%tx2iFiC!GzIsGpqRrLV4V(`Q)$55K}fEFOt6q^%zb*b zvqj+A6UwmljnF=Y*$ZDalGP1$7+FoIWy6))RxZZej*}q>?gnTtv=%sSEQKkq#g~u= zPaVP971pn~$_L?xv%%rwDDX9aTf$_*6qNHYZ8a|d>5>n}FIn^9AQ>XwS_+Fp=tnx+ zq)t$}wo`)-22#_tGtCO}Arhm3X)mnk@<1fYv_(a93>sj<56(R5xna&6qgbFJ3E)^L zE;#9ooMyzED~<=D16Rwe*5=PR1*FqG*)q>+YTL@x7^ZkFrpA#l53-uHS!K{-ZY)m@ zve8;<`;%jN2E@3@a%gLIj9EZBT&v1+u$>-*o4u{YBo#~GJb1j#qRAGNw$f;|u9Qc3 z&5GBooI7SE+G19mRryqNwPIB=$Q*-Pm3V4ZnC((r-2uyDo{art)52UfT-kbU3z?15 zUL5YVEuCvyfUVTLprb*&qV0=&A6wWX*hwfNYa5t>!nP*tT@xp(HV-xdigGIQwFcrz zhmB%Fpecc^bpA7^!k{lBVRRbVEPlunIb`vJd-AfUc=&|T*(s{kc#jT`x&{_5EoPBn zF>z$%M=D?lwqwd_Gva#!L#=0$l*87J*%HPnnEjGxi(vf)t1N@cJlvUqm$f#mL|aZ6 zOvgbv4L}BD!oe60^`-&BT=*S}2NNndWmF8fgWy3W+Bwh<@RLwp%bUx%4_j^E&Nsm> z8rycaxV4Edimv!$AhpAhPM@Nx_TEP&}|E(quhvI%H_^B%LvN|-G%@o-4Rkl91%I&%ow zBu|EN6-%EIa$bkN<+~puNNC3H7*fx0kg~ z6ZXUL*=ev{Ix@t;%RyZrW^a#Npv)=YY3pEK2ywhxoKEQq)s$rCrUASwY~}&>1evv{ z^}@h^hR!jZhD1csLzYfB&swd5oxucK&TUl!9zegAjZROL&OKiyfCBKPewkqKKbdO+3`(6b*To z0x=WjvoEv5#c}#FaElSoGdTCOx_rGz&g0<`8O#S9b`~L~u5@tL0WqPY{&(h?rAMFC zIyF3A4zXYu$@>|?Ef&eKOk-IxDT`{4NRwWp7mAUU{>Hws^_G%efd4Hg6S5wIElsC|e2WT?iHZHke6tz?RQhR~h^XenT7+)EkeLT{IGQ(f{+WQrw3pRwu^HkC z}LR-1(7s=%mBPhEi$m5+ zjyN0Cr6zdn2OgP*MKif4e{`Bm)9HQoh&6w8gh+0-a`8u}6WJ>frm^xm`slPJo$Fq0 zLE7ZJUU``570wA{g1hS#{_0LY)@ReEx6*l5xA>#-`_)!ATlvW!xqkVURwAu#@kh9~ zsjP0c@{{YUJ=v{9y1}jX*zbW*U+3j&Ig=}r%5u58T(yTEA40R7=f^9IA0(CKI+yr? zuL{DE(e|s|?j&yjf{VR57z4t&#E)mYwnsh|GJcR$mdpM5(fX_ES1<*c#hTLA{LWZ_ zgc76o&hHo_JOuIi-A2~lY=)Cd@rS)vFojfLJeM<;taVhCFVP4&hMU9>L*guJeHDGp zp;Z_UAJ7bJ=*<3p6}%#vMGGZ`u%`lN_sxfHj2L6S&s;w2Hq2A;5p15G&&Jp=;rM@DsohfS&=50vrQ44)6=WuK>RRoB;S8pb6k4z#jmA0{jK= zH^3=?(*Vr?H5nwpL2!QJVlmHUINPtlQqXEVM zBms;CNCp@OFdpD~fExfN089i(0Z0WPpWC?+U=lz&KnB2MfGGf(09gPx0Zav$1~47q zW`J7&Q~=okYJePoT!1_P4M09X0YD*u7T{KZ83089#Q-`0JwOS-OaKFb5x@jc3NQIX@EX7-fXx7}18f0!1K>@7w*cM- z*a}bw@E?G80JZ_pt7=Le!;&n_?|U&}jD=6G;)g_vfpWaq%LlIhYe-oDSgX`osx%k?bukrA1 z$N%!rJ@AZMe%9che!1o7Jgi;Ezf?ljGQ8dJ{!RmRb_kut0bAa+O*pE2`h)z$J68Ry+@M->WBH*Y%AfP**3XPP zqP%Ef*6v&9{iJ;KuDQzGkAGD5O`8@vP5e>$^wJTFC+Q9=6Ef$S#=rT4@}Xt-eXaEW zLAig}bGu@*4k?=!j=bU8rw=Np&s~=x{`S3cUqRy0extruKCPO3S-H)KEK9rp zG5;@=g;M(A+n=si-lZ7y+4NDLDIeTFV@l%JpD1&C9-n#f>^;hXH{?e&UHGx`_?Wwv zee&XNLoK2o0A z_QUTBq5eMOzh3eJwCB2`|Vt^56W+zE70N^&iLggZ6*AYT$%e;78EnsGlbT zeer)9T%7%Mudi?$C_sU84q@L;l@}XYC~k${xGs ze|goR6UwsiS3U?H`Mc8po~lWgt@>R#eu^~X;$MGP4jGwzVZRAY%BMa$l+t%ilXC5j z@{9aVH!0&jx&Bt4%#+Gjw!Jj&&kZM)jYZuy{^IwCa?|>yj~!P3q0Fdw<@|5A{Gs&u zV2l437yPMw@8v(|?JD|H`OytKE4Od|Q@Q8$vOl(5_Lp*dMb#@AF~KQ@j6C z>dFVCuDJSd<+p!5^76vDe=Cm&PcOdX%fFTLdoTRDB<7TI{ByOB=PWv< zl#eHEoIOT)S~-1l`l6T>r?S3BB}jP()T6fe`AFS< zeD;^{SRY9!^G|zH?IWGedhVv6#Xi!5C7b&$+~OlGdvdz&^!Gke^!|6sW?s-m8Wnoc zHQy<_NIPfUId4i)7ir+Wh6p(w zyFw>-lP;W=_};^Jc9TANI5DT&3*99BgqI$kxwo6Nf57|sU-#%PUGUP2|GPfAyL58L z1E0O7>Mp6TTy6@!zq?ej?8vi=Hg}gE_`R%ybZW@r`VU6*kfQ!* z$d9|Vha@h)<-VGSdq|4Q;zs&y>mjAS_TYUbM|(&I7S?J$AK)wH?_Kymhrj-blK*i2IGgm()3YNF8<;VU#VYs_{8h3@{_bZe(wF`BtPlk&F^IT zR{BY|?yVm(<2gU+&5&seKdSeWin~=96y17Cb&0opvox}&^z)PP^(UtHl;#bNO3%Ev zr&O_icE;vcdrEhYx^8d(Z+l9UjyA={V?*%Pv3d8 zmo!QF)u#jB>m`Lg5q@L&@4ck3Ypx&rad2SnA4;CtevSEoi!Fi!m`!I&t6hjFmSAN?W!i)V^I1D8;Jp zd368nfzsmeeK+_$6e#7N{^Z#q&jw0sp6k9Ptu9b{>Jr}y(`SLwPeW%OT>ev_@FP`oAmy(H+Gi}y)|Rju9TkAeK##$^)6s#!@GaI4*2KQ0jo9u zerK<)bPeEZ4}805HQ;Z$6zzWi@cs(_SqlIg7r&iU3HZ{x7EGE2`1uuuj}!wQ-dA;n z2Jlsv7ag1qxL2PghcW=~>Gl3q69KQEJn)Gmz&$UYKlM7mPd?$777w_*&l7Va0e|#h z`Y%@lj>s8Ua|PgApJ`q&5b&~x{@f4*xK~Qwe&+)&K0WN!-hiL@plYcv;7|88ywC-3 z`Q$9$(-V72qb47INzTIF%T@4PwegCl_7>=iTRFu6Z7dEi07Mcqp; z{|<1_zBhBe0i54^&^KQLzH`m$N4^65+2*KadrAD{@80_y@bLK?N7MtJJ9YVyPXQNy zzGCkufVca-+Ku3ckN-Gh58&A4BLWE?_V+Wu|DICSpSVr29eZ%SJ|3NNqdZs z+&!7J?{IzP`=q^t&U@$%(*ESIcXWgwdjtF_f0nPB(Sz`7?(^S2Px$xURdXIB{G6~q z^cBM2MQoUmK#5?j-&9%A}eU(x0cN zop%%I-z5W9*OLC;IDPn)r2mf``t5rn4;L?Z_W+TP3Bq%i6M6am!gZ^N{M@(jjWi-p zgM$x@Ci1m^#b6VWH|hC`Z;1Szxa7NqL>_xQl51Q8_{~F2%Za?M*;M-nk>BNS-MoUx z^9#?1n}~d0KlFk{djVe<*lYg*z<)PfIO{mz*vZjjPXSK6BsaZhYENl*{Zo%#2>9=q zlY@f+_pP7)Lpb0^)gK>D1bok|tgFWZKK$y>PfYyc=-*$v*vCJdLQtW*MGQqFW_GB`{9-vMX; zUU5@EdQYig@&9cN1zd2WZ|*3-d*>yNo=(ELoa|YE@4j))mL-7y(BFOIbAWgEth)05 z0O#L)Yuq=0v)7KE_c!1df_nw@&j5M%tNSb(@ZC$)U#0?{aqQK?C%Gfdt`x}&Auo18o=3sOrFkSyY4h@3k4i|ZF!#*z%j3kdB_O( zfxe$-t_1wzHHxgQfRme2mK^{*T^$+Fdn(j7e{q8dXUp&2E!%Dz)+xwk(2XI{e z`^i56ex+Z0{e>_e+4l65CzXIl9t&Ns1+3n-{`gYB&mLV)>+X91_q+e{sjmX= zZ2xpiKgM0?PBwpI8dvsmKZeCWaBh8Byd^(YpH=+eei+Msi|ygWbA7+1W&hpI{BpLZ zFWV!}-GQmx-}P_rxA-o{9_Fp_?zeD>_Y5pQTV2JPz3U15Ved2K$*H1qv(s`k=PPek@vO~;a%&q)_4bB zI0xtD^aVz8$DA)qz+Ply9)FSSep`s|OO-7_%H9&LEomI3g#LU?Js zNi~(-=HZbn%;p7o ztlunp#o5m`lNWu#`ECJQ;se^KHvqgujC?78p7XZdx5OH9d9lpfo!i%QdcPEk=|YPN zq<`DqhZo4HcDOJV{)Y4E&=zu$`bu{g)7|s)(A~}YT(z23*X|!Km%c0QlF*1y7Oj88 zG2J*8UHzD2I&LQ_A9YOkZ^gP!uDYC+a@96J+IQ}Zk9W)Ygddzd_fqw5iG)qLuII;F zUVZ?_E%LGb9ODOjb`lh@tvzJ+i4BmJhR=WCp zcvkX*%Q3v=TVv2#*5j}qP|=r%t8gVw7vVrm?;GHw>+rr>6}+_;-k41NpamLzu}YgK zPz-Oa&7Glx1p_<-NABYX%4ktE4Brtp6=KPJobmZLua7<4wmkn+dl+#$mJJHR>S{U8 ztE^)Gy`Qe(=TD+>Ph&6uX|Fz!Gw)0zLF6hW93)>h4qPK@dZbaUSejh;WrkK zh}GikMcjW>MK&|wTEN;F@*6UM`zHo{gz?JVh%J5w`~C@%C1azIk_Dbz2(JJ>lY2bh z4Nqf!yVfCgCSNiUv*cR44|; z)kURbBE;o#9FOQAM*nIzL1KDl>HR$C)-xQ(=(fJ*m@bXc#lPj4j@yH#cOBEUUK{th z%k|7Iw$F9+IjoyAdZsn~)%JYLkIDeq_rdi2X@PCOE6sN)){LaGTrKCF3oMat@C)UX zc$@KRX8VM0P_?tF3ikG0gI>mFq_NhtWv|L!K|nsPxr)1EhEAZ*QA*1#1^*g<8 z$mF~{t!~KmdLz758ouYJF3!nQ<7b(QwMN)IRm6skNg5pn-=bHDilM`zB8SDq!v`1? zmmmO7#@%}XwH?DsW({E0~{4aP0@s&xK?sd$k@jfiKE@YR@{o2uQM3eeT ze_}lvmsVnafg30tMDfdW`umHU;O&9{pFq=lfp!=TT4D}(U|xnrz~LVFM!l)=xREKzNvgD@N#j$;hzjy4o%US9 zKTV&WF>+FdYIN#^3Gf}E@u?}IxhBbD#Yk}y`I9_(CyYu;9-m@+uRS3l zJtH;EUhzW}Lx++Y3hT&sM{9(a9e=KSNbl9N$Oo^UWqe?Agdx}I z+0<=Vf}WMLYyBH?%0F#sA(UOwbujFR zIQb1M7)Utt6=_CoKVPV1CxOoH`EtSkkZ<0AiX!`QX*# z$cGRnM;LOQU*g~%EWwwR*HJz0Iz2o3oY1qoWc|te)r%c-z@DBx_$8)uR?jByLwc{C zMLu}-EaL-{BMiAt&!&EXCFogs?x$yiUc(xm-SgS_uXs;-aeFvmPtPv@7ISe{&o=Ex zdas^EK6v#k@}a2_G5_1yehL1Z({ADVH0T; zXk^9dD;$?=mBcN7@^c}ZzQ*d+HzIaFdo|#kuvZ6}esxP>aN|nZvscXrvC_`kE7cE3 z@3mLR2d}+CKCESOgdx|h3knWk3G-Qb?x$x5ofCRC^$_n#FK!P9?CIG}yD=AM^=$o7 zr1$Dsgd`Fa-D1(x?|W^UvqwT`)bHaysRJinX3rup^Zj_3O#JdH!H zrqzz=_(O{QkadXY%a!NA36-x#j)aJ`S|CZyIz0 z^W)>y`+fq{8=m&QDfx3VDt2asOIv6AnYe#s&~Yq5$;xxTd3*FZp+9|p<2~uc?cqRM z`m^RQ%+0Gmkq_SaIP#(9q^*>7w*KUP`Vv-52-_F6E!7e_#(vH}-|_spkvZ#t`I^*y|LmT=nB-{UR!t8D6KJFj+?o-ONwsfw|I*=X5t!{LDPI(=xNH4bQ&+8?}8`+KcHt5P(xy^mx(*_Q%DrRmn z$J^Q+2T9Io6!*Ub^~d_fvwm|wdzE-j*sJ7A-BS+EsL*wwFnjh&bvg1gjpfiU`dUk`XKY71;v11O{)3ZCS zYM-7B3H9n(!fEfi0OgIZ3-nBmxD>id&qfSJ`AcQxxu2dLeNO1vpb+FU?@upwjsy1e zY{ZcE>DlTqubw3w_v%@cJFaKzueBYQuF|v1uf}pVvGQD}XD#2KzW|!*{CAO)nVu!7 zELY3(#|tcxZtzR~yhkO|3vN)gv#JXA^z3p)`}Ay6lvmG^j`!+W6o0N~l}wKKpm3F* zZD#NF7{tnRKRrA3oY1oeW&O$f)r%c-z@DDnI<$Ryc2J^M&k|01^(@L8*RyNmP%gL> zcDA17&w;OC+lXb~*_Ox4<#-*VJ9^kL-9|=NaNIH7PM+VNj_G*$?uxmeyPCCk!>`yL z*V(Io`W*OLrlI(b5OTKV`k>0)SY8(z{^nMwR9$uQn_D^G3u2Jp^VxWD9p5|pywV2t z2CB3BJz4?7&hBygZwa%#c|wR1`I*Kl*494md#2Vzs(slJI zX6rKB7wO3DTW=whrX=rA^n-t;I<3hFcZk=l2LR_=uD(=9BLqHDX|hiHgY&R10-yKo z8p%s;y$C-3%b5OXoyzm>`UtL;E6pb4YFl!ZK*_jV8BJ<~3GNWNBEWk$DpH{cQ$&R+ zVlxy&hebsWi;SY_1VLi>pCNm8rzQz&z@@n@yVE=t>ABo_?T**(5Xnqta>S+7Rd&aB zG|FEHE6;uH&dr;V7j5YW`*w$%tmXQlbYvl8Egz|z)18Cmb|-lpFS+&n`S?F7>-W~F zJ?F0L?at)ak(+JFm3!Nrpb02nT$wpvOAUR`Gp!* zp6l$6bAF|k>zs*OP%qqui2d#8Iw#+tF4m9*kdS4QUuOs8c4upfZGXzk+H5W_37=iJMojfc8829?|vL=mi|n^#80x-Q=M&hP%rukwXB%xOxyBU zHOy!ui}uZTOm~Pqt{49i&L7Mf$bYbGjs`i-kH6-jhCSCI&xVIZUO#p&nctV=I!0Gn zoIhXKqAN6$kh2(fVlvV0=x!L4?vC@_6GAl7+@&CM1Wj?Qh>Vw9szg>;6ni0 z%X4^c+ip({c}{=BkP!YYu$3-P;(1rf^Ztwhf$TKXjt59j2m*x@A$#l29fh`aZ)?9YgeYjZ_`K7*?nI;G>E|=`OpZ|6EZ^7e zEZOGk&IslQPG#k}-@3DztqacXb*FxYt*+wz$}u1RL0ZRjoZeHg>(`xgRLJp@HY|15 zb*DYMqts(7ob`9slpsBqJFngG+8r_g4(e?6kE{HhYuUct4pyG~*&Smxa-!pQ2bSz~ zeoOdjc^-hzV#(dkzvTOD2WQ&$r@TZy{;Qe(kjHy!*!6bjD3hCMfq~p?gW(~ zJ(oML-SOHTqGMD{j<~*YmE9R+MEO&)@?2+k{^|2*2h~{9w)8_NWf|Xxw|*Xt?CoP7 zf@3jzwa!^bgid8ckjC1?lj~$CszrS$y~17?Rm6_ z+prbR+MVj#k)F$)*Y0@j4iWJBIkx)8Rd#221(vgkmFGIU)6w%C^|@HXj<0vz;e1E^ z9k%@`w-kK*S2Fz}kN4ED>+Mc@9`;OI^BMQHJ8Q{iI$X}$9p8CK&*jc*cf59o$WJPh zBl4SEuChA;RVaTEtUTA*oqxLCNxj=S{SZp|#pk8g>z%F;gL%MNmNWbubm}5rGOb>V zKYaW*$@;woq37LbT-If%1kL8SYRzLGDoMC>%(nzfZ;D4~_|NXY5nR`M<{vbCU*lQ8XhsV;p8ZhZ9B0D`5!*z*X^?z`lCihCTsfM6l_ zh6@RYJAXn#wY6KQ|f)?7{dJG;Q2 z_P1D3O8Yyz={wrrjYEcXksurCheq1pwXd$G{aqzYqW#^N(4F>o_7|IIe+%Jpw7;va zet`CO)#X3Z{ub|;K>NFD^g7z#(hXf`e@ib;r~REBxS95M_8sTb{;pb6MEhI(>Hlbd zi#^Vx{VXGf`dkVtC{(|sPFG1+uM-WEzg|m%t*l~TJAnZR+5P~ldgsJ@m;lT?9;k}Cl zp=*CZ7=AI(Tp|e14G@HHFBOD~FM~PRAVF9l!hpM65PlCPJz#x#&KM(>hybwrjDt1D z;iRfW!`^ezwruI-ki9bjzAqCgu&h<=oum8mex&2o>g>5F&lgKck;dx;_+PBnnY6Gb zZ0mWIe>$&Bz6Z-a$*V!JyPof8^St0vYz?1Jde@Ug%L#&~oEOA>mL5VHakjy=>m;@x zLoNT7FuM7^V0ax|hnNaDSjm3ap%qzvO$Qv8dy-{ygY1m1JX`+0fDNBG&QG51pN9GQ zN7Z7isFBsveb>jz`B>Ao^jIimjk~Rn^$$6gE3VIi9&}9iPy79BOYeI77{9|o`&&hB({KQQ86 ztYOFZ1Fg?L{#)+}JGjcWKjr$LkN;|>KjiVA8g{+id5+0fTk{$BwmX|1L-}&n?gZ5$ zJ(oML-SOHTqGMD{j<~*YmE9Ti2+E(5mFIqT=gIr9h8?#%WQmG-;JHWSX%=U#OK^+x zkB{>jv|bz^|GqVj=~_>H?%s91-5InHIevEAorpEq3TN$3_0vet<<4t&ymp6Zk@}}> z^^dFU&hjU)oK37e_p>`eY!{^CcE@_X^KU)xRlnA@KjoH!kN--hKjiVA8g{+iIk*mc z=IpRLwsPQ6`?%6KvrSuV+t25dDH7bTJ5e}<;M(MGt|ho}b_T`LH(RbDVe#&3DQ=wo z(A6YdcUgCetA2bSl!T>k{tO{FJ3pV|+Ld2iMZ$HLB~e_}?}aN#xN&wris2;EU>bh% z*cAi|S5K$7?!=*B5{B|A&aUo4G2G%9e$tEeUlqf`D2d*#Vptf>!VC*zSeRiUiG>*! z#616kEtty@MQf2t-*^rkQc!_v(d z&dxzB<|A&@GWuc+*OnkIF(6JeAr@yL7RnJfRv_Led#_v?d#~J*DvU3`6LI!j#N+Nl z961kh|GNi88x3zX_)z@Pqo>yH)*->vmXo7^JWmH=gR<#?0zuAgBiYx;ZTOD zeh~zL>LI`i$!a`FvDZZsy2im{gDGCKI;al9wZ}h>C0Kl6`6wFJJ$OCAbvwu2NU)ft z&Yq7S1ctes4`bm(hKIBM zWO_ijj)j#hUSeTB9&F@YYG|fV;$Uxa_|OQJ-KdO*S>RL*c;@%YM8F8&&%w4 z%7L_>_@9>Nz(Q$MYv(6Op4eJJC@$tXa1RU*cMg{O6F0odOKv@XJ`OY4nZMSlJnwF2 zuj^XM)ta}Et8K|u0wv>e<=puR_{3)nrUSFoDV=BUtZ3!yC|_Kf+tU9HTacd1omc;( zWO$1Hw|9Obgvk*XR#*8G50aM|!{y7$b6>mjBRg5xmVR(gyA$%Jb9QH!tlxS6dn$Il z-HB#T9JVD_?rnFJ|7oAysd>k1cgUFH=ccRw^4cB3kD9HvdaASS4$jBB300&pxT?QK zZ13+17P0oQJqoD(M=yZrgQgLzHU^#h5c2@`ptdqcf&JS)3)@id)n`V z+ib^$Tt4{xy_)G^dAz5FU2ngSIw@D~ZNE3|K>2cZ-5B&=q~~(yT{n8R{pMO##pH6qZg<-HzGwUVmAsu6f90#puf#_RHeBwngzbqAa-?&U z;rz(Q{2dG5oxDYzTh6(jn?3*BpbwFs&g$99kC2{Ak5|unww~?J2F{KTY{w)ib>> zv||@9*{1sD03ZK)ra#OP9{!`V=l3n;YVEVwGi}M0d(ZEe@4;3$Yj>JHL3%ECUc2M9 zJ4DqenH+Jo<0`w;yc^|j5G&7J?9Sz^;TF4-`Wzc6h**4k><&rD6W_oYYko7S`9`Pw zke^3Te#T2~J$pX>56b$zb!yMK+u3&Ka>hD~TxG7up7FEkpq6sg5xWx=IZP47N|ZXK z)9kHxGQY&?J8O3~eZ^YMYUQ;%Ub{m?Vbd2j!=TgOv&;8|N|4=ximiL>4UTd~SI_K} zJ-RAJmr6d^?BH6$=mHuX(>ch(Euy%8u8g&JIqNrfvEPi%R_6&-&m+gV2NT)YQqP9c z2!8I%dfiCU^IjWm?gg&#%r`pahunTQ@8c!6o;|nUYndKyoyzm>cDDU)DOY+Y<*Fn0 z`^=pu-1QC07nkO?&J#xLM|v)IUi*!b;i=~dxmGP>a>O+aUpI2?HI7Gg5Occ|&+KO= zE3e~r$JP5nf3fp~e57E*<#xwi_k{+1%X_Ya9p<6Q?5&gH54KOwE*eST<*N{d(WQVbGwttSJ|DQ zA5s3|S$Q3|J8jMH{isg|K3O7k1@PhL2D)JR+|FPKzt2J1&chZz{^&(`uLp@XUoGeP z<>t75a@lzEJ|r1jeH@!u@#_tvRB=dSDRPR;Y!Gkj%@yp_vSZ^6CoPI3aa!dbhs z_79}za_6->o^5xy^zZuBR!?!e!|#skB-LXm)v0u)#W@-SW=O(?8g(8I>x?CuT$4e~ zi__&6s&zU|k&)fdm1qoFeI5@Ad8L>UV7`?=DIu)NH)v+^eDaD*@P2WL%9;@F+tBee z1$n9xgGr~#Ei@F6geJYo=0<^DpOuvY?+OB`FEmtL%)WZB%`H)BW?2ZdMimsL)9Pqz1p&fkYOTo}hWctvdT3K= zv5GW8S3(Na>UsXyErI}*GeOg!*9--uN;Y9gQpOU%FYD^?cA82V$AI7JB9-N>fupZi zjZ22KfTvKLI&xBal4>e1e~iWia-(NbB?x23r_k7O#d_K!*OwNlbM&grQ7pj?nhK3B zS0hZ+gXpPA%Q7@XL?&W8g^8s_Canr`Ri$f+AZK1q+8D)1@*6N65^3Yc)2Os`#OVsG zCtzC7^e7gNV&P~Oj#j0lPRcM3tMq79dg^4Wa15i1Vd-L7IF^M+PE4DSq{^5yG9{f< zAbp}rtt%*EQb5Cnq|$I-t0UN?ro2rrg`O(b8Vrn88BoDdATJ~ja%B{1Ol0uo>UFuK zp#&425lr^v2p$8tu%swAzevx!lZK5NlQ2W4E+u2Rq!b1g2!cL8AE@EmbSAaIq~hKa zK>*pd3d!Xpr$WU9iVGzf2PUn_+(3*L&EtuQJ5MHHybAmwX>>2NK+sKDZCP!Re`8cdp+#fVIc6?%%-HX}0V7mg}@onzA*&Gx{Ac<2((U;GCgz zp_u~raJ1f0eEc`d`n`2(&$-*#>;IN=74ia(fVSkyz1ROC-B7-qwL9~>BR!Wp@A@D4 z;i>0J`ZJZXtE;V^a+Tew_Q7&Cu=3p3?$kJ`AMD#5(o$}(&-8O}yL#C6r`&Sz@n6RD zhdka>!>+eGK^x8myHn$j^5v}EY3_yeT<*Mf2l?UYb|;z15!W}avOB(h$nOwVp1atc zK-O@}dZ(J{hbqnziqDqyPI4dQvrXl#0(|@*mG!$7iAVnIY`fD^t^ziq-KnzSZ%esy z@AZ!Ae3UO|?atN9@y0-rOw24CBH zS&`76jVwB|uVcDHEIQ~S$8_@i-7U=hm6fc$HLTy<#eQ?{TI~0Rp{QrM21bsy)U%;9 z!rlCpz8CTqwJr%Y+<=%EDbr8ypvvy~Li1b|Uymklq;puj#=`vgW<0`we=~67Go|We= zcBea2sFr!@R;C}&u5f+Zp7joC>Az)nnl88PPhNkH`S`D4`h(y1blll?r=?u^UV%N+ zmRz}q-LaL28zdU8Vpy0Up?vf2Q(lMh@EuD^2Y;;MrTBa4_c}Sw&P&`wzpv?`n6e1@ z!@v8<_$aaO09W0Ne9X>4%)bL%$G!ucU5xjuN*J91aU}Z=aNsNqA1gy#$G!tx%f16# zay$0lKm88yp?ffY{vF`D1sGn(z5~4EJ`9&HM4Wv;D|Zp%gvI23)!WS@tTEiOm7j)6 z`W;n?VR?LZV)GRe+^o8&f?{!F)a4{Be3~$j;KsE*=y!O<7m_a^Ve#%6y$P;bw#|p& z?7m_2`>=KIJ^mq)OZYx`9>H~{rG*4rUlIoX`S)+F$449AbFF<>7);9Lm{!3meeKca z(KMc6c|7o!@`Yo0e6|ot<%45+JPphLSd}jYmNvf)@f_QvAFD1hY6Set^WbUIlQJf! ziJ~xRa!Shh6!H`VUOb+M<=84-ihg;t1o7~Vb&8?aD9+A*nqnT$F~83-zYpJxwn@k1 z>pr-j-j~PMeK5g>p2yd&yve3qo)2(`-Uq3($&cs5)ARD`KKQ^Ue@i~tKHg4_c{<7} zANscq-BOh!QL>KemPVOwS;BNnHq$K<`^NZ!DlDhuPQ+Pr5leR=4xNWM@NUE>8E#~{ zW%qo%znSTlTBchTFx^tZbW0Y~E#sJOiKM!vQIp?=q^}ElTOe4x;^=8Q#w&;aP4Sk+ ze-NDgzaziXv93t^jfU??J5F$2;vYu{uDa{L^c%{xKTX|F!qQJgdkGe|^+=}iKEHfJ z#(>ooC}F^*-vWmsZerzdY@<7|3bMZ_AKZ3ZBCW@&z2^dUgyAg4*>z_~1k&?)r+3|n z{P6U3r=H0Xmp)gmJ0q?|ey6hX+-2Q~wX*(xbp%@<1ag*8e73AR^^v?qHq|!=`1lVB zcT8ta;2}Rcd)>*oYw>3&os=v0Sa;g9JM&|)WzO22gKABo_?Kkqn)9v?KCP#d{ceefJcBg>Z&-tu8cd|8gly^gnt_oyxA<3Dw{V>;VZ=YFWO?GERzWj<5sq+GeT-6PyOVl7(sQ}<+8yMFr`w(7Opdsoah2W49E z**5%aDOc`ocQ&M9E1b1E0h5rP%bnNmAU{0a?gXSFANXMCY`eqv$pYDa)h4#?;pNG( z$mk-Nos!4%a3rH!JHfX8Jf7nOMpuyGn2yuCE9U;nU97!FQ?NbmV!t_eE%sZ_^z7N` zugpy6EoxmNxE^h0dbo8e&%4{%_M7*DMXoBHlq>hP-yxaUGH31g{4AvBa_6<*$PZ7q z-@B&p5rVp=v+XyxJJrm7ZeZoPuidG3Qa^-JhPj)+a@S3^{VBH~eEgR&{UML{)UfOA zPK}dt<=%Fu=4O;HXYEe&ElAJh&TDs&AD(V^l9?QFed8*-<2w!c9m2|UU%RuxN&VoS zb|*O-`ON!Mj`{dMD(iPSou`FeZ+EsjDOc`ocY^XzzMQo?Wg4XCa_6->$PZ7qJ6m&Y z^^~jZPNf>lsbS^0uie?@q<(NuyR$Xlwm;?egOC3Lra$EIo*H(&-Dz-AuH4)1)XzZq za@Ov|7b88FJFneAet5dwiNDoWPj$B4;rnC~+plVvYFnOM&y8brnaobf<9RrZ(d{a5 zoL@GhtJXWFKw}p*P|gtj_KT0o?KNg*W2%A zC*{h$?RTmH<;Ge2y}^j|T<*N~8~Nes_Pc4Ot^Vn3`_1jnCT2hDS$XbjcLG9?BY`$5 zuH`v6`*w#+8Th&WGyQ$iCX;P{+B5asK%LGMdv}<@lb>C>bfI^;vhW3PuLppS!0ZD?3%s@5F37`{^TVl3Pw*#$ zQ1i;yJ%Uh<5&zO(^apnl`0DK7oxDY@SBQ`QYNkJ0r}DhJuD3hW&I!BId=JW(vvxAJ!_)1K>TX*-)!BB3?~|3V{VHF!?y;xY${AfHvs3oysu*3^IRF9k<^zoYJ@MX1~|o>sVg69!;I^n9kkg$kp|6 zz5Sl!lsxqo+`vwb$nP>%p1atcVAgPppYl1bAGqnD6mmahZ|(;Luc#mVE7fUDMxZ2qQqoeM zxO5~<4uAMa<>Ai3a)0IWhmp_ra_8e;`H*8ed+E>B`<-ofTFTWMp~&$-E*g}TE#<0% zb|*H5b&b?1U1aY&F$Jrz6XQYyb?QBBR!WpuiZg@c)HyQU~PM!dbgB|4F3ha_6->$PZ7qJM(Li4_sI~ z+wSmvvK7qF6~Wd$ygWHx$LQ8FJ0*|j;f;)L&||js=kXkGW^@f}9Mf@ncg5UanatW- z!1~Qy>^JAG#eP4>^lYFFOWR|=$-;my4z4uk!Zn`xMyLFcuN!wg#aq;R_FRvaF+JQm zmFL~QVavEQx3z9;eg^5e+PaesE8_v-L&W{*>Df zKK=`s{*cFeYS{I5XV**EGi|M--NWv1Ily&$ip0Zm+}?Ow`eRDWk7Mp9NRh^>i;Nlp z|MD_<+Nel{B1{n#rijf@3>_8~IV>jL_EvP(q#V_@=r+15O)9B_G*)a_Xko0Y|oJ8=gO~=y220sYm)2t55%W`H#V$eigf0 znlo~BS;nFKH_HBR&f>wbkG*p&Xvk$>N58S}mqjTr{iWSI@Zyu_ebfBZ$$`%|pUV7F zd(h9|Kjx7&vp0WWPz_x@^S}Mx=)3Q;FL$J>YFGU+@8h5=mhEW>?ce>$?0)ypy;15T z2uD92JsK<9IQy22kma9WnRx5UpjR8d%Y5h)%^T0peeSp3E5qOU@WSw^PyIdTckLT% zetF}g;suF|_q?6ZYy0a{f~I`A=Cae}rfsJeW*FrC1_F-bQ|YtZY8H9C`+r#7j_8q~#_GQDAjI7MS1-9Jo>4p)SO zAjL$+Dx$&_@v$-fsp+B)$cBj%w7SxA5}airjtY+qi&KOZXmlEbHrJn(GqR{aZ_t_w zi)kt55M-fO=ZUiv{z>JU+)@)1D2`E^AZt=$*hFz_G4U}8 z(Qz^H?aya|)@U+k=PzHdmqy z5B>>#_}mpS?*j~9%Y6IJObPK(O;i*qSvtK*BM2zYg23}#{|x5q&+66DeA~r@F>E74 z&V($iD?3#s2oYP5S?so;E;WHY5`;XBG1s6iA!Cb15fw##a2`hT1a07URXUAvidUL* zl9t<*mffF~7s$>vSHET3*=_kdkG_rceBS9@cOpMLecc()gNI)oLnEc=eje#&Q`DSe&v{t{{~sV^LS6iu3vW^byBX}W8GKR)DQOUj`gIx zxG17nOQ*1WQc1Ypd6)cr$AvuVwr-fZ_cLtpkcBg4K%9pctC-Y;Z=W^$@JID`Dw>vdVj<}w2 zmEBQ&g#4~#<#pWdxZ2Ma;iP^Dr7UafT%pJrdxoBauGxcpHWw@V!N-5{{~XiFlAZHG z*V`SXlXB(W>m7YP%8j#jXV>RQ&*jc*caR^RZg+y19C5|sD!Wtv3G%z?GsGRYJ7;RW zlgjkO*|pvY+Kc?<{VB(M{BM=@yPVF`!mhVF)6NOIb8sKZm$P;!xdG|9+7e&-kGpFPa5ReE;N_b7i#R-WthZ2R7y-Ev<00Moa8MuMDaIj^naEc;ind_L>@ z1M>M_t<+gqxR21i)#nig{oFo1TY1#0XG!;a^(+noTulqYjw80?lIvNMwiq5UvOI?) zVX}7r<n|^xTMs?cAM$ul4Rin2{2!5jYuUK4yce9j72HqA(d&yeY8`zqIFT=IrxlEGuJ?Pd zbfMpyK2y$GA~F2WkiB(6$nVH!XZG*s^f3;&e z-hOw*eBD~vjEv;-2-n#w=hm&9tCs!l6Xzojc?^cm4tr(!F8dC~XM6I%^=QZ`CfN1} zJ?uW8S2dkPz63G-@^7zOxinhj^c|=C*B$#lELpe4v7VPYMFQ-tTN}FJgXPZ71C%|G zp3ARy-HLL`?L@&5>@JC|n;O`$CfR7t) zZ&-A@5zYg;3w5lRO!gj9dl~Iybh~8lX_C`tu?iLp=QWj6U^tugXT4zCPC0cU%ckM~ z+q)8YsJ^#vD@sY0RH(6UgRw6uhb(QDqEJZ_6S53rNobR_D`}OIrG>QkrL=1yiP9<} z6)lvdLTJ%DbMCzcHN&+0Uuy2B+-1J!d+vG8InO!IbCzq$oUePh|J6OFU%#R07>nlH zAMXcH6$T{B-hFlw(X2P5+A zZF_ZyAHlQRD@4F-yA_c`!=SG95^Jx1m)(l#+2g!OJVj`HKd)zdT2G1ETRrGm%-W#q z*_*xW$0|a>^?n^C)BuU9hX3@(uEFA%>6wF#Ut| zg8}w{#WUtFy@Q6c;ldbyOmqi*9ZPhdvmc{4IG&-nY;<25Mz}3#bVWAI<7E`SuRO=v zZv_D);g)E=(fv7t;QR?|M;BLbVn9d!(Z=U!D?+i-CrUhk8kTm+#f4-rH+5fM+Wq%Df{+MZX4Jt)Z~wU$ zB9#5x&f1CUXGCi3zrB?JBRlK37*g(SQKFvOyJ4dcJiEO^1op4nS&C@6aX`xvRvw|9 zMb(xh3WZFeo{1rz0kpYhw6iAljH)+OOJboIpD{fxCW@3lJv2VLo@K13JMVXC?TGBu z&PmnE@Ey<>>Cm&>n4axv-aFFLbE1Y8W^VzMkDmhv`RV$YrpGy{`^GQyrhZ0(s^yWR zLqBtIJB&t>Mq{ASz$(_=4@OTfFKkx=Jl%bX-al#&5PtM^sI3OlK5UjnBH54p-0>Id zPhkC*!ifm31JLaPhu)W)F~=dXa&Y9UF~?#0jLJy_c;>~6kZeukmtc#Ebal6_>j>5``n#x7Yqzj++mJIOLTZpDltNB9m3I0S{> z5`Vwgd-Sz8f#Unl9`PM;!DG#wxw96$lpAQ>c5>dW8-chK_t4GWvw4-3=hRe^$36Qz zCGHUA0JliczLLT1)_5cQ{aAc$R7y_3d2 z8~L$y;^pT`a}_qn&lvh9cT!xFBgt*-nO*sHOFt(N-=tK;Uup@sBOGU^SohV#K<40$ zLm!2fRV}cVcID>#e8aLVaG~@*!%QM^0^hy!4N;mBctug(+1?Eco(lx{zQ6cfFlyK4 zZ>>1JA#Zn?%Gf+2#<%Mj1hSTu2sS9FcQ#5n)pk9V`AMp`>>lbR`T#qLDlG^!p?(2)mSyT)sqE zLnHXDYSzkcDkpMFXFJ{)w&H|W@NVm6>o$B&O5TZ|2Mj8m%U3uX>$~nN$f(@sTD$3x zTx#Q}3$d?lUg1ApaasT5j>-99SsxSlx5~6st|^MwP-<3M@Pxmm?r6ixn=jp!t`s~u zV-SG5XO}Ks-njF2BhTWMKHfGj>fTs~8)}Ttm~ek(+48&9U&f8w@;E^!-tP8_trl&; zF(Csdl`8FMSxk8M#lrQ?n@75Mn=GH4eO{~1v{{wj&9ixCJ?p+tg~#eWyV?jYjw;cY zHot%KHfdFGhVGSbILVj<%DLE0b8wjlW;doB9+kcP_>_ZG9AbtKh?jX zjLe;yzUId1)1;^49l0XNZ_+Y?23hB}w0(#gk*wRoTUT7ny-W9klJm?Pwnb?t@Dww!NViT!Q|XIx35L)`jkp) zGm1!hI_r!FuhgQWn%C;<4a%FRY81R5c2#k*u5sxn33<8A6-$ZFhnZ>wysb$Zn;Dqe zO#blI&)7O`bCtfR%vaH)H_1!=TSFebSzWMf{_9giJ>);_my3I%X}gB&_{HR!Lgm4g ztMatBF1+BcHvWoh{a(HF!Gj;*8@_%Uw63($ME%7w$sPGNA5B|Jtqc5bY1uyeSU%0p zV3pU{4{I}5Yn^z0ata~G6R+~cVe|buS^E|za_FM4O4H=8L~?_$;=4IV&mVg==vwUc zRPm@Wcb>*w$k(cm-fSr2GU5LCj9Z#Yb7z(heX{h?wVm$H{%1nd-c8Kr4=r$+vb~;i zlldsWTXoqne~ybQCoC+eT9GL; zmuEYU_e5@!#sD6HE1|awU%y;7u6083U{9~Cl_{S0$9#1XztJ{)9`BhF+}knd-^p-` zmx#=pzh{5RirA-T4VOI}=5w2H2}OL?sHsAS2WM7)nK^Y^j79X@VyC2K6Kpcx z)R;VQdA=yo=w#GdE62!Muc=$=#^?^x+f$X8z7M}7Ut;3u>~T}ptcaIM)ZG2@)s3ef zYP8aW4m`xe*WSph2rG?iSAKp{Mt)tuB zSDqGdl+axnHSlrCT+c&G@b#+>mL-DI6-x!DjdGk`er%K5+gp}m|LKi;1{9UVEg5= z1-@6 zp&kA;+czYKk$6kzS#ueuswge9lsl3Br18Lp&HU?59a%*zGutx9KVA0Fjuqy!ub%ra zlOyDbdclz$6rxAN@&CM|^miFMMY~!gRgVl4zI%EO&(OTWROPLecWNdzX~_@5)qJfV zE1flnD?e}aG zMTX|D9lUORing}zjYZ0X_O1^Q@IMp&xuz}T>wx2j>OLkMJE|KI8%dmc)B2 zS@OBZ(gJehR570HBYLVE{a4?SXtq=;5_Q*mB|a`CJz`f{?V+bGvrN8~?K`)~O0RsY z2hqXttcl?fw~en~Mon(75?QoIJnABaH~7}s=es!1`=(V$<_VlDOCT-Tzr20ny1Ljg z1g8Z)!^>Z-%XRh5-RT>WI4?%1ab(4_2ZbVw$G*E>6!0X=<=w@YlE8^cauvLpF%#ae zTXISNK*7fgPSqPqbqZEX@50-@S-)Yzm-$zc+dtgit#2HeI(^<0t51p2Ri!Of$J(ne z?yTPT<GybPTBv}3L0GJ>JU+*y-aCcfJ-v9U%5pEAc=CwdCelI6tQ&rN4u-d7t_@hKU{JUnA>8K?9(vhQ5o-p*DjBW2Y=rG z!G6um$4kjMW9DXSDLoc{uXiTTMeBlwhnf&>%CaItU^}u8^p4K>Kz{8aGN{4t%F5PLuZ!i+?DzY;<>RpNV%l$Ynh47c zU7gpweP`^xcX*np_FKuyjqAcpw2PK0T$ujwu-eTaQ}cwSMdS9#3>j#cyJN;)zqu}j zpG{862swU?4jmJ{*0@P#Gs;v?Q&f z{q6`o7YR+x+b43r-aj`hOVnq$v$xj83!Ei+r_bst@`U&;ef4#cET0GYgNLxxowsTQ zULwxxuC)-y?Iy0ualN}IxX5YZRIl^*-!>MPP(BPAXZ~O`@A0O%oLO_8-x!$hU>&d{ zq*><@`6cI6{0WB>Uo1{Vz8rrlCp|^fFQ%xpm@t2(_?i?4<8sok>xv9Hcmu|RuEbaBecar}pM;B>NoIK<}V(7k6@kcHs7tXMf5?*?0n}YY? zug4Ns=}oorJL(weBIFY>`{ce_`6a@Ip``T-6EvdQmLJDYTC3qWWp~YcEsHY;s}6pA z6El2Ks;{0se$zWCQ;+8N(9^o7g3q1O>HN*s zyNRV)+V2f*Nh4Y^|=ye!aI<1I-~sQ4NX6aN#TImM-4Y}mr`CTJWNbaJ$o_qh@rR8qG^Un zH6;~uww5HAuUQyoUT{P}=UH)Up!b>4Z@8Z1L@%4Us^)##nXLNdb?W5klEn3=(o8qm z>`I$dtL8Vz-q!r$t;E9S3CbQrN5^jxo4FE{?sgcaly;+Wp1tWvt{LaXHRVTGjJ;*IT%Oyr(S`VS8cCzI$=K%WQ%%Ky`?F7d*)n8=kMdf+SvyRu zi$%9LwcLBRv~X>`P^^i0L59)WvKcpKyebQfn)&A{DSscEr~`hDS4;g#(Eu-)XCpdg<~4VXwM7SV zNDtN$SKZpS-R?$s{0JkNh;c%9%JYVYx6K_ApJn&KrO|x&IkJ|+5pxmIrEBA2x6> zvFLf@PTkpqk|&VISCNk5CN%8}`=T^ia75Uu@}nlX%^w9dtd4OM&mDWrZEg}!+#-~G zP5AO>1%)-Iwx#klUks3bk#_lMwrJYwgM9P##?R+fn8Hz}z3+{hf%J-z6_p1bng_V$ z7`*dX@DiVYZ10&etE$*H%Of5U7A?$wtJ5&eSfo&Jrb+&{+6wE~Z_cN)X2k51H)vb+ z^zf$eO0sa`gn;&88YQvMzG#O>ZM0r}>`keT`Ls`$UW5s}pS(D^FnL&LtZZGlV0m?{ z**#xEsY%$@+6CLgl&z)>_pK#)y^@?@a4A7De@C2b%&|{02mh-|xojS?Ea0C0lEXfa z+nq`437<|E>ZE;>;?6x3o1)#mrOm0}OL24Kq$|W##X|#xWlNtKID3UeY*Th{acuOB z52q~hnQgL1cH3R;;q435G`!|#rq~4JKdcz0nwlnTwn8Ds%(ZcC>(YfguL*7r%%5KI zuvStb=uO#9-C_Qd(|7y$e8g=wds>>8Zg@p%&)v)mUz$e7Gz}g4zW7zl5wQb1i-RbW z+S<&noY$22Pv*-*)phU2rrdrWnRlEdF(YTptj9vv<<72rWiZQH*loj|Wo6A``Y&!B zkO;1>&{*){&ea@?8ZoCUO*5)P^W`futrW)WjE>ppE>d9n#5l#);=bpB#*yo)o9tVi zHKu4sWp6B%r`!+|PTG|nwlRLs;l~;8#ny!6?cm*&x;q zx^9lB{HYaI?Zc8P!#C3wSwJ@&>Wk}`%-gYOqNmBcT^CQ7pgbLub2$sABF;g+!JWIZ zj3?&~g@fyEo&kXr&jmrWWg)b1w83?n^AK|x5@-*p2Ypa}V8@_5b*vuZX%S+02VyYE zo8;>r=s^obJFw}s$Q||Lollsaq7#o?(-n zvB}XFCLy`J1;zEW7-H@e1h0?c*^B>>Qt_{Dl7f{pH?$m~#ezENKag6$$rKk)UpG<+ z2mRiaHY=yoy*E{1Py?a$fsVu0meG^~^}rTG$XX!f&kT*PH;dLf>l5l?2=vVmUb-G) zbI}nK=%b>czof=FS`k(1>!DFvnqfE7FfSj?sJn>E|Kwu5R<^&*xdd!6CxIO}!&h z?*>rsj5r4S5PbtZ-H^XLbhm4@c@WxGQJ0KO~wfj*KF(!aUYEhAg;xDAjGvA--ozX@pO=S^ z=L8a2mJ_RzIY9)(ae-=x;{w(Y#|1JWjvI`IIBu{4;&{L-h~oj%AdUz82XOhkH;c=SMafFP(d8O-OXF9>i!23|p&7#Ia{VqhA?iGk%1CkFn5xRKx`#Ek?aA#Nm?3UMRB zGKd=qG9YdgcmZ*vfEdJ$0#hJv6j%yzqreG>8x5);ZZsGHaihUxh#L*UA#OA{4sqh3 z65_;xD8z|_Nf0Lv!XQo@9D_Is@EqbKfC$7%085CI0HF{k0gghPBzOjKl0X>ZB!LCQ zNrEL1CkfIaZVY$|abtiG#Ek*w5H|*dK-?H`1mebm3WysEhC|#~UT9uC0!oli3S5JH zQotGVNrM*1Ckvh>%YPe1?27 zU_0cK0qT%X2INCN8Q==}WWZO*Cj)juJ{h0^`D8!=F7zg>}!9&O=56F;D9t?tf@*o-V z$%FBbPaZsieDc5_@+km*$fp1fKt2Uv4EYp5DdbZC0gz7t4266O;1J|f049)60hB>L z1rP-J6u~garwCFZpCXtD`4qtu$fpPvLq0_?9P%lGBalxKm_t5A@D%bXf+dho2?#?z zC2$n-DFI8!rv#ouJ|z$a`ILYt3HeljIOJ0Sry!pSuz`Fkpa$}(fK`xB z1xP|Z6_5q_RKRq|rvlzWJ{7PU^5MZ)$cG1KAs-&tK|VaFgM4_f2J+#76y(E$^NmRKa`5rwTSeK2;zG`BXtRuHM z-85V@0W759;s`*ChC4(694%B_CIQ@{;jR!s91VAyK%L4<#XTkfZ5r-10dUfAO$5-m z#kW}fD*+%=zc{~Jd@I19qdFD!VqiaG_D6>Sf&IWfvn9Zm09yiV39u!=mcU;lfu5(% z|8c*ihzsI+>l1!UR{KvW=%^T0AlUsUOcLxfTLNqeuqD8j09yiouLSx)|HZ`*Huti9LSDpk%Qhvn9Zm09yiV39u#b z_e!AW{!>ruzK|LE-9O@h&4y=v9Rl}*PgF_K#!=qwzc12RE1jV63CuXyzp*92mH=Az?J}80&EHN9|o z&~{hG_CKJ043|Q7C3So)myv!6+=TFB)^JbydM(=Xf5bY!CW_Otq*q5rRA-zQ{WDB3l5Th)rVL{&o@ zr=er0rD3RvX8k0D_&5DU$|*PEbfj|Tp!$^&Jr4Z=AH%#nWBOKN3v(Q!c>3G(oZ-=LCXWnk&(2UO9#Tsb~xfxVZ<2vi=lQ1qkk%j3uGa3Jcp=xsY} zwvXKo({lYCs#Z3C{Yqe!IeKb`t>B)7Cf@F3if5pQkBb%>5VHfZ{vyVQ zosn?nzQLXpvab(`wk0S$y7Or;c#h5Q_zsW002cqRTAQrsW7gXF>;1T$=RrTg%)wE4 zri=PSbBlh${5aZsnYZ6KG)Vk@<~XcBurYx-j{XLH^NN*n#acUm3(b+gx1E16fR%PW zJrOA>v{3Y;ueb9Z8r2XtkwT(6+3YDq-vA%afB@>o>JDUzSAZYUm1GhWNX7+g3^orT zxxy{iab{GgA+C$}O&jsPbp{1dh_v0s4RHiDg0{9k)khaVawYq^1q`+&Qiwj(9g-;l zhJ$f9YwEQj&cv7Ky(GXhz>4ff!sBKUy@RL^ZONX#foAAl$`}HVGb1e|26+b>8{(Wu z0n}Sh3UwQ37}aE7zo5VlP76;;Kw#%I%?R@C;HGYj?n?{Y!DUTmLS+YEoe@`O8s@KL z6BI~&!w%VYyp266Ah0t_x0gYJbtDW5koxkdm<-f3HMO+#NGcloojI7liCrL(5@-`l zqIeViI+!%n^bGWL4YV}0wDom0wKR07q*??PSj~Oiemm!6f)&}a~!=j?B7?D%uS%#>xd>p5k0pa?wbCdY#GdEAoNlk zm`}0xA`(vt8sE?Q6n#4F?~eGI$YMA3No%8xEQZKs4hus78BK{n699D0*u?mI} zbUS19-=l~0b_>SvmX&hFnq7JimCWC3m%gS>ed)dbIXwd@QM6F>qp#bgSeuuQmbYPO zIsVx;kCpPqnjT9*<=emX7}5ve;OL$G|I4<&Mo+eXAGFiES=ha|2Y+Z*>#G^)>uc-k z=;~=}X;6)7eI1%v&4Ri51GD;Sw}tHk!If zm}y$*FVMv>rn;_l2we}Y&M(E>#lp;5?Q9k6bf#qbn#>q~F5$hkbbFtdOc^`BB%#;I z{xz>zCpBkFqAVm+e4r!A#*c)U_5r`D;Rptr`dUoAo3P@1@AYHN2l*T88zX^E^zig{ zqsj~Uok{+n4oPHW4A&uH9BnEvqiN~NXy?op?TIilsi$`9j{Yf=n&%DDIXZU}Isa_; zf+ZnrYeFK!gz&?_NCS=h<>2@sgprUlANHD`qo;XvTMi*yf@p@Z?SI6c`d8K+vC?m5 z%}!f`_UQj!J8cfthtzvJE%r20(`cdSM_;$odeR>fSJ?W4mYZzbw@RFLjDT;7scLf!|=}Y3b2NOfDtINl{%k&&`Z(=~8r)%fX%oAj8;Tb}5>v(}* zc43)#d%F9YdeY|cplQ%nNQQ9H>u2XwhkOI{+%78>uLt9To)FeHO&237ON*?^TP ziy&`rTD7+E^9CqbEpeY|*6j)DFj2Ab6~PvD;yGJ4`D&FUq^> z*+10|r=T9795lYZ*A5^2E85|Ws9vCJxUN??^tS0)*L?4aqU}?L950?S$8`_aU+@21 zJG>P2Y5u)-t`JLhE>9&=qG+M$M_+G;JB_CN-tkvW-Jcm?V{Ml0?;c5E54uu!WawNX ze(#{G=C6*(Q)l;g9@%0(F!j3&N0%|zUmgzcG8FsEY|I8|d%sA8$@pw%vG+JsPxN*T z@}}-PVnO{w-)7*~$7!{+HGf8@bQ-61bNzoTKroXWJH|*gdOu1_&6rN%x{Q(kFf*{R z*{-AQ(>!VWmY|a_y2ybkNtbCP(>#4iL<-KrlgdQjj-@vhu?vk|&;qKacMZhRi%0MI z?7Tev(1k1X5$i7L`SJU(G~%3suJ6U{P)7c~Y2DTV|0z4;1s}336pzODvvvl3Vr zK|p@!j@Ljp6#VWvx}hNERGW|T{_Ybi_8Dvb_XDV(w14~GBkP#k={Ph)YO#s?3^EAQ zU*!$V`4|N6caK>qSFHKp8_~H~f3MxI%aYwc;ssKoXrbswU$^^vYWJI(+3h|pH!-#H zukQzp?Pp_zu8GA;dQbfVto=lrUo05IGd8~cA-@_*Vpv)i1XFjTD1_WnDibzf;cVu6p)QwZoBZNIWTMe0{GS zHvcQ^TyIn_&^27wD;#?J;9J*x?~0<2Z|Af#$8`_aU+@21JKRu>Nbv8qb5mKGXZC^v z@j%l;(T~2~4tIDY4RLU_pgp-`P~?{fq%^2Y7MTu6bwp)PhLLxSzFO{CYyf0o!eRs!qArY1{2z&Nxj2-JhDB@Uz+W zyQMsX=<80JMqW&!bQFNz@A(D;&-A12sMZl!qf3clIvU7qq`3>rkH_G!a>rz-nT4gm z7~5oDSMMM<5_KVLpeGToM(s#iFW#xAl4nN@CRvk0f&$P@-AHafDu5aWdIZ%eL|;{c z297{5g#Ui{i49c^raFVcV&fh@I?;9MzlEna$(Q=6jt(iPdysud>aHFE8v2_0I_hSm z0Ixu@pE`|H%{PQPib@~LWt#i;o`K$U*3QA0XLpC*f@{Y+FJA9O{$RP>jil33c2<^; z|Cp`I*m&>LWkRh+zVuBJSV+vzD@rT@6Ujb))YaPouxNJVbT3|k-gy55S3TL+B14c~ z4cop(3d6tV=VrxzV9h@~^{=o?dHB0*NB*70z@bmP1(@To`ZaebbKG|k^wS5dlq=T! z!<)De3I4ryDTyWja1tsHS}6L_*X>e9{$V2_BzJr3AC4DB@L2s~`-j>7VOlMCF}$mu z{Zszolwn9bIcR)+&p+IR&Y0}q Date: Wed, 14 May 2014 17:04:22 +0100 Subject: [PATCH 026/126] Refs #8922 Remove commented out code in LoadNexusProcessed It looks like history was loaded here at some point in the past. May as well remove this while I'm here. --- .../DataHandling/src/LoadNexusProcessed.cpp | 98 ------------------- 1 file changed, 98 deletions(-) diff --git a/Code/Mantid/Framework/DataHandling/src/LoadNexusProcessed.cpp b/Code/Mantid/Framework/DataHandling/src/LoadNexusProcessed.cpp index 6c7d3a54aba2..a82ceb441456 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadNexusProcessed.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadNexusProcessed.cpp @@ -1377,104 +1377,6 @@ bool UDlesserExecCount(NXClassInfo elem1,NXClassInfo elem2) return false; } -// -////------------------------------------------------------------------------------------------------- -///** -// * Read the algorithm history from the "mantid_workspace_i/process" group -// * @param mtd_entry :: The node for the current workspace -// * @param local_workspace :: The workspace to attach the history to -// * @throw out_of_range an algorithm history entry doesn't have the excepted number of entries -// */ -//void LoadNexusProcessed::readAlgorithmHistory(NXEntry & mtd_entry, API::MatrixWorkspace_sptr local_workspace) -//{ -// -// NXMainClass history = mtd_entry.openNXClass("process"); -// //Group will contain a class for each algorithm, called MantidAlgorithm_i and then an -// //environment class -// //const std::vector & classes = history.groups(); -// std::vector& classes = history.groups(); -// //sort by execution order - to execute the script generated by algorithmhistory in proper order -// sort(classes.begin(),classes.end(),UDlesserExecCount); -// std::vector::const_iterator iend = classes.end(); -// for( std::vector::const_iterator itr = classes.begin(); itr != iend; ++itr ) -// { -// if( itr->nxname.find("MantidAlgorithm") != std::string::npos ) -// { -// NXNote entry(history,itr->nxname); -// entry.openLocal(); -// const std::vector & info = entry.data(); -// const size_t nlines = info.size(); -// if( nlines < 4 ) -// {// ignore badly formed history entries -// continue; -// } -// -// std::string algName, dummy, temp; -// // get the name and version of the algorithm -// getWordsInString(info[NAME], dummy, algName, temp); -// -// //Chop of the v from the version string -// size_t numStart = temp.find('v'); -// // this doesn't abort if the version string doesn't contain a v -// numStart = numStart != 1 ? 1 : 0; -// temp = std::string(temp.begin() + numStart, temp.end()); -// const int version = boost::lexical_cast(temp); -// -// //Get the execution date/time -// std::string date, time; -// getWordsInString(info[EXEC_TIME], dummy, dummy, date, time); -// Poco::DateTime start_timedate; -// //This is needed by the Poco parsing function -// int tzdiff(-1); -// if( !Poco::DateTimeParser::tryParse(Mantid::NeXus::g_processed_datetime, date + " " + time, start_timedate, tzdiff)) -// { -// g_log.warning() << "Error parsing start time in algorithm history entry." << "\n"; -// return; -// } -// //Get the duration -// getWordsInString(info[EXEC_DUR], dummy, dummy, temp, dummy); -// double dur = boost::lexical_cast(temp); -// if ( dur < 0.0 ) -// { -// g_log.warning() << "Error parsing start time in algorithm history entry." << "\n"; -// return; -// } -// //Convert the timestamp to time_t to DateAndTime -// Mantid::Kernel::DateAndTime utc_start; -// utc_start.set_from_time_t( start_timedate.timestamp().epochTime() ); -// //Create the algorithm history -// API::AlgorithmHistory alg_hist(algName, version, utc_start, dur,Algorithm::g_execCount); -// // Simulate running an algorithm -// ++Algorithm::g_execCount; -// -// //Add property information -// for( size_t index = static_cast(PARAMS)+1;index < nlines;++index ) -// { -// const std::string line = info[index]; -// std::string::size_type colon = line.find(":"); -// std::string::size_type comma = line.find(","); -// //Each colon has a space after it -// std::string prop_name = line.substr(colon + 2, comma - colon - 2); -// colon = line.find(":", comma); -// comma = line.find(", Default?", colon); -// std::string prop_value = line.substr(colon + 2, comma - colon - 2); -// colon = line.find(":", comma); -// comma = line.find(", Direction", colon); -// std::string is_def = line.substr(colon + 2, comma - colon - 2); -// colon = line.find(":", comma); -// comma = line.find(",", colon); -// std::string direction = line.substr(colon + 2, comma - colon - 2); -// unsigned int direc(Mantid::Kernel::Direction::asEnum(direction)); -// alg_hist.addProperty(prop_name, prop_value, (is_def[0] == 'Y'), direc); -// } -// local_workspace->history().addHistory(alg_hist); -// entry.close(); -// } -// } -// -//} - - //------------------------------------------------------------------------------------------------- /** If the first string contains exactly three words separated by spaces * these words will be copied into each of the following strings that were passed From a8b2aea6ac369c224ae17719c89fa1bdf12166c0 Mon Sep 17 00:00:00 2001 From: Arturs Bekasovs Date: Tue, 20 May 2014 12:43:54 +0100 Subject: [PATCH 027/126] Refs #9494. Store the current label instead of a pointer to ws group The label gets updated when new data is loaded and is used for workspace naming and grouping. This seems to be more robust than storing a shared pointer and fixed the problem. --- .../Muon/MuonAnalysis.h | 10 +--- .../Muon/MuonAnalysisFitDataTab.h | 4 +- .../Muon/MuonAnalysisHelper.h | 4 ++ .../src/Muon/MuonAnalysis.cpp | 58 +++++-------------- .../src/Muon/MuonAnalysisFitDataTab.cpp | 48 +++++---------- .../src/Muon/MuonAnalysisHelper.cpp | 21 +++++++ 6 files changed, 57 insertions(+), 88 deletions(-) diff --git a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysis.h b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysis.h index 753820aadcbd..dffd9fe4a6f5 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysis.h +++ b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysis.h @@ -297,8 +297,7 @@ private slots: PlotType parsePlotType(QComboBox* selector); /// Finds a name for new analysis workspace - std::string getNewAnalysisWSName(const std::string& runLabel, ItemType itemType, int tableRow, - PlotType plotType); + std::string getNewAnalysisWSName(ItemType itemType, int tableRow, PlotType plotType); /// Selects a workspace from the group according to what is selected on the interface for the period MatrixWorkspace_sptr getPeriodWorkspace(PeriodType periodType, WorkspaceGroup_sptr group); @@ -492,9 +491,6 @@ private slots: /// When data loaded set various buttons etc to active void nowDataAvailable(); - /// Updates m_currentGroup given the new loaded label - void updateCurrentGroup(const std::string& newGroupName); - /// handles option tab work MantidQt::CustomInterfaces::Muon::MuonAnalysisOptionTab* m_optionTab; /// handles fit data work @@ -508,8 +504,8 @@ private slots: /// First Good Data time as loaded from Data file double m_dataFirstGoodData; - /// The group we should add new plot workspaces to - WorkspaceGroup_sptr m_currentGroup; + /// The label to use for naming / grouping all the new workspaces + std::string m_currentLabel; /// Default widget values static const QString TIME_ZERO_DEFAULT; diff --git a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisFitDataTab.h b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisFitDataTab.h index 0ee04f30ee48..adbfb3f4c280 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisFitDataTab.h +++ b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisFitDataTab.h @@ -60,8 +60,6 @@ class MuonAnalysisFitDataTab : MantidQt::API::UserSubWindow void init(); /// Copy the given raw workspace and keep for later. void makeRawWorkspace(const std::string & wsName); - /// Group the list of workspaces given to the workspace name given. - void groupWorkspaces(const std::vector & inputWorkspaces, const std::string & groupName); signals: @@ -83,4 +81,4 @@ private slots: } } -#endif //MANTIDQTCUSTOMINTERFACES_MUONANALYSISFITDATATAB_H_ \ No newline at end of file +#endif //MANTIDQTCUSTOMINTERFACES_MUONANALYSISFITDATATAB_H_ diff --git a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisHelper.h b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisHelper.h index cd0635df7537..881d4caa929a 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisHelper.h +++ b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisHelper.h @@ -48,6 +48,10 @@ MANTIDQT_CUSTOMINTERFACES_DLL Workspace_sptr sumWorkspaces(const std::vector inputWorkspaces); + /** * A class which deals with auto-saving the widget values. Widgets are registered and then on any * change, their value is stored using QSettings. diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysis.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysis.cpp index 745b1a0211dc..793bcecab7a3 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysis.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysis.cpp @@ -34,7 +34,9 @@ #include #include #include + #include +#include #include @@ -98,7 +100,8 @@ MuonAnalysis::MuonAnalysis(QWidget *parent) : m_updating(false), m_updatingGrouping(false), m_loaded(false), m_deadTimesChanged(false), m_textToDisplay(""), m_optionTab(NULL), m_fitDataTab(NULL), m_resultTableTab(NULL), // Will be created in initLayout() - m_dataTimeZero(0.0), m_dataFirstGoodData(0.0) + m_dataTimeZero(0.0), m_dataFirstGoodData(0.0), + m_currentLabel("NoLabelSet") {} /** @@ -376,21 +379,17 @@ void MuonAnalysis::plotItem(ItemType itemType, int tableRow, PlotType plotType) MatrixWorkspace_sptr wsRaw = createAnalysisWorkspace(itemType, tableRow, plotType, true); // Find names for new workspaces - const std::string wsName = getNewAnalysisWSName(m_currentGroup->getName(), itemType, tableRow, - plotType); + const std::string wsName = getNewAnalysisWSName(itemType, tableRow, plotType); const std::string wsRawName = wsName + "_Raw"; - // Make sure they are in the current group - if ( ! m_currentGroup->contains(wsName) ) - { - m_currentGroup->addWorkspace(ws); - m_currentGroup->addWorkspace(wsRaw); - } - // Make sure they end up in the ADS ads.addOrReplace(wsName, ws); ads.addOrReplace(wsRawName, wsRaw); + // Make sure they are grouped + std::vector wsNames = boost::assign::list_of(wsName)(wsRawName); + MuonAnalysisHelper::groupWorkspaces(m_currentLabel, wsNames); + QString wsNameQ = QString::fromStdString(wsName); // Plot the workspace @@ -409,14 +408,12 @@ void MuonAnalysis::plotItem(ItemType itemType, int tableRow, PlotType plotType) /** * Finds a name for new analysis workspace. - * @param runLabel :: String describing the run we are working with * @param itemType :: Whether it's a group or pair * @param tableRow :: Row in the group/pair table which contains the item * @param plotType :: What kind of plot we want to analyse * @return New name */ -std::string MuonAnalysis::getNewAnalysisWSName(const std::string& runLabel, ItemType itemType, int tableRow, - PlotType plotType) +std::string MuonAnalysis::getNewAnalysisWSName(ItemType itemType, int tableRow, PlotType plotType) { std::string plotTypeName; @@ -444,7 +441,8 @@ std::string MuonAnalysis::getNewAnalysisWSName(const std::string& runLabel, Item itemName = m_uiForm.groupTable->item(tableRow,0)->text().toStdString(); } - const std::string firstPart = runLabel + "; " + itemTypeName + "; " + itemName + "; " + plotTypeName + "; #"; + const std::string firstPart = (m_currentLabel + "; " + itemTypeName + "; " + itemName + "; " + + plotTypeName + "; #"); std::string newName; @@ -1661,8 +1659,7 @@ void MuonAnalysis::inputFileChanged(const QStringList& files) // Make the options available nowDataAvailable(); - // Use label as a name for the group we will place plots to - updateCurrentGroup(loadResult->label); + m_currentLabel = loadResult->label; if(m_uiForm.frontPlotButton->isEnabled()) plotSelectedItem(); @@ -2565,7 +2562,7 @@ void MuonAnalysis::changeRun(int amountToChange) if (currentFile.contains("auto") || currentFile.contains("argus0000000")) { separateMuonFile(filePath, currentFile, run, runSize); - currentFile = filePath + QString::fromStdString(m_currentGroup->getName()) + ".nxs"; + currentFile = filePath + QString::fromStdString(m_currentLabel) + ".nxs"; } separateMuonFile(filePath, currentFile, run, runSize); @@ -3326,33 +3323,6 @@ void MuonAnalysis::nowDataAvailable() m_uiForm.guessAlphaButton->setEnabled(true); } -/** - * Updates the m_currentGroup given the name of the new group we want to store plot workspace to. - * @param newGroupName :: Name of the group m_currentGroup should have - */ -void MuonAnalysis::updateCurrentGroup(const std::string& newGroupName) -{ - if ( AnalysisDataService::Instance().doesExist(newGroupName) ) - { - auto existingGroup = AnalysisDataService::Instance().retrieveWS(newGroupName); - - if (existingGroup) - { - m_currentGroup = existingGroup; - return; - } - else - { - g_log.warning() << "Workspace with name '" << newGroupName << "' "; - g_log.warning() << "was replaced with the group used by MuonAnalysis." << "\n"; - } - } - - m_currentGroup = boost::make_shared(); - AnalysisDataService::Instance().addOrReplace(newGroupName, m_currentGroup); -} - - void MuonAnalysis::openDirectoryDialog() { MantidQt::API::ManageUserDirectories *ad = new MantidQt::API::ManageUserDirectories(this); diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisFitDataTab.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisFitDataTab.cpp index 83c59a1bd6b4..7da5bb45e314 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisFitDataTab.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisFitDataTab.cpp @@ -6,6 +6,8 @@ #include "MantidAPI/Algorithm.h" #include "MantidAPI/AlgorithmManager.h" +#include "MantidQtCustomInterfaces/MuonAnalysisHelper.h" + #include #include @@ -53,23 +55,6 @@ void MuonAnalysisFitDataTab::makeRawWorkspace(const std::string& wsName) duplicate->execute(); } - -/** -* Groups the given workspace group with the raw workspace that is associated with -* the workspace name which is also given. -* -* @param inputWorkspaces :: The name of the workspace the raw file is associated to. -* @param groupName :: The name of the workspaceGroup to join with and what to call the output. -*/ -void MuonAnalysisFitDataTab::groupWorkspaces(const std::vector & inputWorkspaces, const std::string & groupName) -{ - Mantid::API::IAlgorithm_sptr groupingAlg = Mantid::API::AlgorithmManager::Instance().create("GroupWorkspaces"); - groupingAlg->setProperty("InputWorkspaces", inputWorkspaces); - groupingAlg->setPropertyValue("OutputWorkspace", groupName); - groupingAlg->execute(); -} - - /** * Group the fitted workspaces that are created from the 'fit' algorithm * @@ -77,33 +62,28 @@ void MuonAnalysisFitDataTab::groupWorkspaces(const std::vector & in */ void MuonAnalysisFitDataTab::groupFittedWorkspaces(QString workspaceName) { - std::string groupName = workspaceName.left(workspaceName.find(';')).toStdString(); std::string wsNormalised = workspaceName.toStdString() + "_NormalisedCovarianceMatrix"; std::string wsParameters = workspaceName.toStdString() + "_Parameters"; std::string wsWorkspace = workspaceName.toStdString() + "_Workspace"; std::vector inputWorkspaces; - if ( Mantid::API::AnalysisDataService::Instance().doesExist(groupName) ) + if ( Mantid::API::AnalysisDataService::Instance().doesExist(wsNormalised) ) { - inputWorkspaces.push_back(groupName); - - if ( Mantid::API::AnalysisDataService::Instance().doesExist(wsNormalised) ) - { - inputWorkspaces.push_back(wsNormalised); - } - if ( Mantid::API::AnalysisDataService::Instance().doesExist(wsParameters) ) - { - inputWorkspaces.push_back(wsParameters); - } - if ( Mantid::API::AnalysisDataService::Instance().doesExist(wsWorkspace) ) - { - inputWorkspaces.push_back(wsWorkspace); - } + inputWorkspaces.push_back(wsNormalised); + } + if ( Mantid::API::AnalysisDataService::Instance().doesExist(wsParameters) ) + { + inputWorkspaces.push_back(wsParameters); + } + if ( Mantid::API::AnalysisDataService::Instance().doesExist(wsWorkspace) ) + { + inputWorkspaces.push_back(wsWorkspace); } if (inputWorkspaces.size() > 1) { - groupWorkspaces(inputWorkspaces, groupName); + std::string groupName = workspaceName.left(workspaceName.find(';')).toStdString(); + MuonAnalysisHelper::groupWorkspaces(groupName, inputWorkspaces); } } diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisHelper.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisHelper.cpp index ae9ab13184ac..dac3bbf074c7 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisHelper.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisHelper.cpp @@ -497,6 +497,27 @@ bool compareByRunNumber(Workspace_sptr ws1, Workspace_sptr ws2) return firstPeriod(ws1)->getRunNumber() < firstPeriod(ws2)->getRunNumber(); } +/** + * Makes sure the specified workspaces are in specified group. If ws under the given group name + * exists already - it (or its children if it's a group) end up in the new group as well. + * @param groupName :: Name of the group workspaces should be in + * @param inputWorkspaces :: Names of the workspaces to group + */ +void groupWorkspaces(const std::string& groupName, std::vector inputWorkspaces) +{ + if (AnalysisDataService::Instance().doesExist(groupName)) + { + // If ws exists under the group name, add it to the list, so it (or its children if a group) end + // up in the new group + inputWorkspaces.push_back(groupName); + } + + IAlgorithm_sptr groupingAlg = AlgorithmManager::Instance().create("GroupWorkspaces"); + groupingAlg->setProperty("InputWorkspaces", inputWorkspaces); + groupingAlg->setPropertyValue("OutputWorkspace", groupName); + groupingAlg->execute(); +} + } // namespace MuonAnalysisHelper } // namespace CustomInterfaces } // namespace Mantid From f314dbdd4b2436b220307fba28ddd406fc6cb18f Mon Sep 17 00:00:00 2001 From: Arturs Bekasovs Date: Tue, 20 May 2014 15:38:31 +0100 Subject: [PATCH 028/126] Refs #9494. Make the grouping function add to group if it exists It makes it potentially faster and we can check for duplicates to avoid endless warnings. --- .../Muon/MuonAnalysisHelper.h | 2 +- .../src/Muon/MuonAnalysisHelper.cpp | 39 +++++++++++++------ 2 files changed, 29 insertions(+), 12 deletions(-) diff --git a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisHelper.h b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisHelper.h index 881d4caa929a..01e629b101e6 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisHelper.h +++ b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/Muon/MuonAnalysisHelper.h @@ -50,7 +50,7 @@ MANTIDQT_CUSTOMINTERFACES_DLL bool compareByRunNumber(Workspace_sptr ws1, Worksp /// Makes sure the specified workspaces are in specified group MANTIDQT_CUSTOMINTERFACES_DLL void groupWorkspaces(const std::string& groupName, - std::vector inputWorkspaces); + const std::vector& inputWorkspaces); /** * A class which deals with auto-saving the widget values. Widgets are registered and then on any diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisHelper.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisHelper.cpp index dac3bbf074c7..c3bcb5898535 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisHelper.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisHelper.cpp @@ -498,24 +498,41 @@ bool compareByRunNumber(Workspace_sptr ws1, Workspace_sptr ws2) } /** - * Makes sure the specified workspaces are in specified group. If ws under the given group name - * exists already - it (or its children if it's a group) end up in the new group as well. + * Makes sure the specified workspaces are in specified group. If group exists already - missing + * workspaces are added to it, otherwise new group is created. If ws exists in ADS under groupName, + * and it is not a group - it's overwritten. * @param groupName :: Name of the group workspaces should be in * @param inputWorkspaces :: Names of the workspaces to group */ -void groupWorkspaces(const std::string& groupName, std::vector inputWorkspaces) +void groupWorkspaces(const std::string& groupName, const std::vector& inputWorkspaces) { - if (AnalysisDataService::Instance().doesExist(groupName)) + auto& ads = AnalysisDataService::Instance(); + + WorkspaceGroup_sptr group; + if (ads.doesExist(groupName)) { - // If ws exists under the group name, add it to the list, so it (or its children if a group) end - // up in the new group - inputWorkspaces.push_back(groupName); + group = ads.retrieveWS(groupName); } - IAlgorithm_sptr groupingAlg = AlgorithmManager::Instance().create("GroupWorkspaces"); - groupingAlg->setProperty("InputWorkspaces", inputWorkspaces); - groupingAlg->setPropertyValue("OutputWorkspace", groupName); - groupingAlg->execute(); + if(group) + { + // Exists and is a group -> add missing workspaces to it + for (auto it = inputWorkspaces.begin(); it != inputWorkspaces.end(); ++it) + { + if (!group->contains(*it)) + { + group->add(*it); + } + } + } + else + { + // Doesn't exist or isn't a group -> create/overwrite + IAlgorithm_sptr groupingAlg = AlgorithmManager::Instance().create("GroupWorkspaces"); + groupingAlg->setProperty("InputWorkspaces", inputWorkspaces); + groupingAlg->setPropertyValue("OutputWorkspace", groupName); + groupingAlg->execute(); + } } } // namespace MuonAnalysisHelper From 1d2bd53d51c3e87a1120a97141a2d3a15bf27a6b Mon Sep 17 00:00:00 2001 From: Arturs Bekasovs Date: Wed, 21 May 2014 12:33:47 +0100 Subject: [PATCH 029/126] Refs #9494. Set the correct include path Forgot to fix that when rebased the ticket onto the master --- .../CustomInterfaces/src/Muon/MuonAnalysisFitDataTab.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisFitDataTab.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisFitDataTab.cpp index 7da5bb45e314..725099dc5cc5 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisFitDataTab.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/MuonAnalysisFitDataTab.cpp @@ -6,7 +6,7 @@ #include "MantidAPI/Algorithm.h" #include "MantidAPI/AlgorithmManager.h" -#include "MantidQtCustomInterfaces/MuonAnalysisHelper.h" +#include "MantidQtCustomInterfaces/Muon/MuonAnalysisHelper.h" #include From 9f6bd7cd79f288f0e17f9c708894ea9ce57758b4 Mon Sep 17 00:00:00 2001 From: Arturs Bekasovs Date: Thu, 22 May 2014 11:41:06 +0100 Subject: [PATCH 030/126] Refs #9516. Create models in the constructor --- .../MantidQt/CustomInterfaces/src/Muon/ALCInterface.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/ALCInterface.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/ALCInterface.cpp index b5259637ec32..cfcce6e7aaef 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/ALCInterface.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/Muon/ALCInterface.cpp @@ -24,8 +24,10 @@ namespace CustomInterfaces const QString ALCInterface::LABEL_FORMAT = "Step %1/%2 - %3"; ALCInterface::ALCInterface(QWidget* parent) - : UserSubWindow(parent), m_ui(), m_dataLoading(NULL), m_baselineModelling(NULL), - m_peakFitting(NULL) + : UserSubWindow(parent), m_ui(), + m_dataLoading(NULL), m_baselineModelling(NULL), m_peakFitting(NULL), + m_baselineModellingModel(new ALCBaselineModellingModel()), + m_peakFittingModel(new ALCPeakFittingModel()) {} void ALCInterface::initLayout() @@ -40,12 +42,10 @@ namespace CustomInterfaces m_dataLoading = new ALCDataLoadingPresenter(dataLoadingView); m_dataLoading->initialize(); - m_baselineModellingModel = new ALCBaselineModellingModel(); auto baselineModellingView = new ALCBaselineModellingView(m_ui.baselineModellingView); m_baselineModelling = new ALCBaselineModellingPresenter(baselineModellingView, m_baselineModellingModel); m_baselineModelling->initialize(); - m_peakFittingModel = new ALCPeakFittingModel(); auto peakFittingView = new ALCPeakFittingView(m_ui.peakFittingView); m_peakFitting = new ALCPeakFittingPresenter(peakFittingView, m_peakFittingModel); m_peakFitting->initialize(); From eb3bb6cd7b95ae0b9b7b88d7b514dbe72ef1d0c6 Mon Sep 17 00:00:00 2001 From: Arturs Bekasovs Date: Thu, 22 May 2014 11:43:39 +0100 Subject: [PATCH 031/126] Refs #9516. Use static casts instead of dynamic We are sure those will succeed and were not checking the result anyway --- Code/Mantid/MantidQt/MantidWidgets/src/PeakPicker.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Code/Mantid/MantidQt/MantidWidgets/src/PeakPicker.cpp b/Code/Mantid/MantidQt/MantidWidgets/src/PeakPicker.cpp index f1a9c5dd6f33..17805724456a 100644 --- a/Code/Mantid/MantidQt/MantidWidgets/src/PeakPicker.cpp +++ b/Code/Mantid/MantidQt/MantidWidgets/src/PeakPicker.cpp @@ -41,7 +41,7 @@ bool PeakPicker::eventFilter(QObject* object, QEvent* event) { case QEvent::MouseButtonPress: { - auto mouseEvent = dynamic_cast(event); + auto mouseEvent = static_cast(event); Qt::KeyboardModifiers mod = mouseEvent->modifiers(); QPoint p = mouseEvent->pos(); @@ -74,7 +74,7 @@ bool PeakPicker::eventFilter(QObject* object, QEvent* event) } case QEvent::MouseMove: { - QPoint p = dynamic_cast(event)->pos(); + QPoint p = static_cast(event)->pos(); // Move, if moving in process if (m_isMoving) From a05de98a39bc3ac1d4cc0272c5152b3be1ea7f54 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Thu, 22 May 2014 16:17:11 +0100 Subject: [PATCH 032/126] Refs #8842 Ignore OSIRIS diffraction reduction for other instruments. --- .../CustomInterfaces/src/IndirectDiffractionReduction.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/IndirectDiffractionReduction.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/IndirectDiffractionReduction.cpp index 9f54a63f20fc..45009aa65346 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/IndirectDiffractionReduction.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/IndirectDiffractionReduction.cpp @@ -57,7 +57,7 @@ void IndirectDiffractionReduction::demonRun() QString instName=m_uiForm.cbInst->currentText(); QString mode = m_uiForm.cbReflection->currentText(); - if ( mode == "diffspec" ) + if ( instName != "OSIRIS" || mode == "diffspec" ) { // MSGDiffractionReduction QString pfile = instName + "_diffraction_" + mode + "_Parameters.xml"; From 4134b6cac545505d422d2c775877489a62377178 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Thu, 22 May 2014 16:18:52 +0100 Subject: [PATCH 033/126] Refs #8842 Update instrument parameter files. This adds support for TOSCA and VESUVIO in the IP files. VESUVIO still doesn't work with the standard reducer, but the interface will at least be fixed. --- Code/Mantid/instrument/TOSCA_Parameters.xml | 6 +++++- ...ters.xml => TOSCA_diffraction_diffspec_Parameters.xml} | 0 Code/Mantid/instrument/VESUVIO_Parameters.xml | 8 ++++++++ ...rs.xml => VESUVIO_diffraction_diffspec_Parameters.xml} | 0 4 files changed, 13 insertions(+), 1 deletion(-) rename Code/Mantid/instrument/{TOSCA_diffraction__Parameters.xml => TOSCA_diffraction_diffspec_Parameters.xml} (100%) rename Code/Mantid/instrument/{VESUVIO_diffraction__Parameters.xml => VESUVIO_diffraction_diffspec_Parameters.xml} (100%) diff --git a/Code/Mantid/instrument/TOSCA_Parameters.xml b/Code/Mantid/instrument/TOSCA_Parameters.xml index 96c2bb7b75da..a219995aff05 100644 --- a/Code/Mantid/instrument/TOSCA_Parameters.xml +++ b/Code/Mantid/instrument/TOSCA_Parameters.xml @@ -9,11 +9,15 @@ - + + + + + diff --git a/Code/Mantid/instrument/TOSCA_diffraction__Parameters.xml b/Code/Mantid/instrument/TOSCA_diffraction_diffspec_Parameters.xml similarity index 100% rename from Code/Mantid/instrument/TOSCA_diffraction__Parameters.xml rename to Code/Mantid/instrument/TOSCA_diffraction_diffspec_Parameters.xml diff --git a/Code/Mantid/instrument/VESUVIO_Parameters.xml b/Code/Mantid/instrument/VESUVIO_Parameters.xml index 8ddb64a8325b..d1fcdc31ad6a 100644 --- a/Code/Mantid/instrument/VESUVIO_Parameters.xml +++ b/Code/Mantid/instrument/VESUVIO_Parameters.xml @@ -124,6 +124,14 @@ + + + + + + + + diff --git a/Code/Mantid/instrument/VESUVIO_diffraction__Parameters.xml b/Code/Mantid/instrument/VESUVIO_diffraction_diffspec_Parameters.xml similarity index 100% rename from Code/Mantid/instrument/VESUVIO_diffraction__Parameters.xml rename to Code/Mantid/instrument/VESUVIO_diffraction_diffspec_Parameters.xml From 3f1fe4f738e4b1f440e49044648f944e5cac6a11 Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Thu, 22 May 2014 16:19:19 +0100 Subject: [PATCH 034/126] Refs #8842 Fix incorrect instrument name in parameter file. --- .../instrument/OSIRIS_diffraction_diffspec_Parameters.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/instrument/OSIRIS_diffraction_diffspec_Parameters.xml b/Code/Mantid/instrument/OSIRIS_diffraction_diffspec_Parameters.xml index 7887df6d0eb8..37242eec08d4 100644 --- a/Code/Mantid/instrument/OSIRIS_diffraction_diffspec_Parameters.xml +++ b/Code/Mantid/instrument/OSIRIS_diffraction_diffspec_Parameters.xml @@ -1,5 +1,5 @@ - + From caae3a81e1b779ec3bfd68be79f2126377a94b56 Mon Sep 17 00:00:00 2001 From: Russell Taylor Date: Thu, 22 May 2014 11:49:37 -0400 Subject: [PATCH 035/126] Re #9419. Remove no-op statement. The getWorkspace method will throw if the workspace is going to be null so this line is pointless. --- .../MantidPlot/src/Mantid/InstrumentWidget/InstrumentActor.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentActor.cpp b/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentActor.cpp index 79c16a180c73..b6ece5990613 100644 --- a/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentActor.cpp +++ b/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentActor.cpp @@ -1066,8 +1066,6 @@ void InstrumentActor::setDataMinMaxRange(double vmin, double vmax) void InstrumentActor::setDataIntegrationRange(const double& xmin,const double& xmax) { - if (!getWorkspace()) return; - m_BinMinValue = xmin; m_BinMaxValue = xmax; From 7ae5e42f33e20b9d7876d8eb7877b8b588ee1074 Mon Sep 17 00:00:00 2001 From: Russell Taylor Date: Thu, 22 May 2014 11:51:30 -0400 Subject: [PATCH 036/126] Re #9419. Consolidate code that uses the workspace pointer. --- .../src/Mantid/InstrumentWidget/InstrumentActor.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentActor.cpp b/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentActor.cpp index b6ece5990613..3cb93b5c1d02 100644 --- a/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentActor.cpp +++ b/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentActor.cpp @@ -79,9 +79,6 @@ m_failedColor(200,200,200) // set up data ranges and colours setUpWorkspace(sharedWorkspace, scaleMin, scaleMax); - /// Keep the pointer to the detid2index map - m_detid2index_map = sharedWorkspace->getDetectorIDToWorkspaceIndexMap(); - Instrument_const_sptr instrument = getInstrument(); // If the instrument is empty, maybe only having the sample and source @@ -172,6 +169,9 @@ void InstrumentActor::setUpWorkspace(boost::shared_ptrgetDetectorIDToWorkspaceIndexMap(); + } /** Used to set visibility of an actor corresponding to a particular component From 53fdf98d105a780ab196e366e81efc8a7cfbf331 Mon Sep 17 00:00:00 2001 From: Russell Taylor Date: Thu, 22 May 2014 15:50:53 -0400 Subject: [PATCH 037/126] Re #9419. Check whether workspace is actually the same one. The code before was OK if the 'new' workspace was actually still the same one, but led to an exception if it was a different workspace just having the same name. In the latter case we need to recreate the InstrumentActor (as the code always did in the past). --- .../Mantid/InstrumentWidget/InstrumentWindow.cpp | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentWindow.cpp b/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentWindow.cpp index 25d7483ef763..bc347e6f8dcc 100644 --- a/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentWindow.cpp +++ b/Code/Mantid/MantidPlot/src/Mantid/InstrumentWidget/InstrumentWindow.cpp @@ -720,12 +720,20 @@ void InstrumentWindow::afterReplaceHandle(const std::string& wsName, { if (m_instrumentActor) { - // try to detect if the instrument changes with the workspace + // Check if it's still the same workspace underneath (as well as having the same name) auto matrixWS = boost::dynamic_pointer_cast( workspace ); + bool sameWS = false; + try { + sameWS = ( matrixWS == m_instrumentActor->getWorkspace() ); + } catch (std::runtime_error&) { + // Carry on, sameWS should stay false + } + + // try to detect if the instrument changes (unlikely if the workspace hasn't, but theoretically possible) bool resetGeometry = matrixWS->getInstrument()->getNumberDetectors() != m_instrumentActor->ndetectors(); - // if instrument doesn't change keep the scaling - if ( !resetGeometry ) + // if workspace and instrument don't change keep the scaling + if ( sameWS && !resetGeometry ) { m_instrumentActor->updateColors(); } From 36e8f20aa30e1aa8adb0caea01eee973145d5aac Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Fri, 23 May 2014 10:18:58 +0100 Subject: [PATCH 038/126] Add working set of Sphinx extensions. Refs #9521 --- .../docs/sphinxext/mantiddoc/__init__.py | 0 .../mantiddoc/directives/__init__.py | 0 .../mantiddoc/directives/algorithm.py | 54 ++++++ .../sphinxext/mantiddoc/directives/aliases.py | 32 ++++ .../sphinxext/mantiddoc/directives/base.py | 54 ++++++ .../mantiddoc/directives/categories.py | 42 +++++ .../mantiddoc/directives/properties.py | 159 ++++++++++++++++++ .../sphinxext/mantiddoc/directives/summary.py | 32 ++++ 8 files changed, 373 insertions(+) create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/__init__.py create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/directives/__init__.py create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/__init__.py b/Code/Mantid/docs/sphinxext/mantiddoc/__init__.py new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/__init__.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/__init__.py new file mode 100644 index 000000000000..e69de29bb2d1 diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py new file mode 100644 index 000000000000..a2bf960c5941 --- /dev/null +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -0,0 +1,54 @@ +from base import BaseDirective + + +class AlgorithmDirective(BaseDirective): + + """ + Adds a referenceable link for a given algorithm, a title, + and a screenshot of the algorithm to an rst file. + """ + + required_arguments, optional_arguments = 1, 0 + + def run(self): + """ + Called by Sphinx when the ..algorithm:: directive is encountered + """ + algorithm_name = str(self.arguments[0]) + + # Seperate methods for each unique piece of functionality. + reference = self._make_reference_link(algorithm_name) + title = self._make_header(algorithm_name, True) + screenshot = self._get_algorithm_screenshot(algorithm_name) + + return self._insert_rest(reference + title + screenshot) + + def _make_reference_link(self, algorithm_name): + """ + Outputs a reference to the top of the algorithm's rst file. + + Args: + algorithm_name (str): The name of the algorithm to reference. + + Returns: + str: A ReST formatted reference. + """ + return ".. _" + algorithm_name.title() + ":" + "\n" + + def _get_algorithm_screenshot(self, algorithm_name): + """ + Obtains the location of the screenshot for a given algorithm. + + Args: + algorithm_name (str): The name of the algorithm. + + Returns: + str: The location of the screenshot for the given algorithm. + """ + images_dir = self.state.document.settings.env.config["mantid_images"] + return ".. image:: " + images_dir + algorithm_name + ".png" + + +def setup(app): + app.add_config_value('mantid_images', 'mantid_images', 'env') + app.add_directive('algorithm', AlgorithmDirective) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py new file mode 100644 index 000000000000..55895f5ead34 --- /dev/null +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py @@ -0,0 +1,32 @@ +from base import BaseDirective + + +class AliasesDirective(BaseDirective): + + """ + Obtains the aliases for a given algorithm based on it's name. + """ + + required_arguments, optional_arguments = 1, 0 + + def run(self): + """ + Called by Sphinx when the ..aliases:: directive is encountered. + """ + title = self._make_header(__name__.title()) + alias = self._get_alias(str(self.arguments[0])) + return self._insert_rest(title + alias) + + def _get_alias(self, algorithm_name): + """ + Return the alias for the named algorithm. + + Args: + algorithm_name (str): The name of the algorithm to get the alias for. + """ + alg = self._create_mantid_algorithm(algorithm_name) + return "This algorithm is also known as: " + "**" + alg.alias() + "**" + + +def setup(app): + app.add_directive('aliases', AliasesDirective) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py new file mode 100644 index 000000000000..ac76ddcfeb6f --- /dev/null +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py @@ -0,0 +1,54 @@ +from docutils import statemachine +from docutils.parsers.rst import Directive + + +class BaseDirective(Directive): + + """ + Contains shared functionality for Mantid custom directives. + """ + + def _make_header(self, name, title=False): + """ + Makes a ReStructuredText title from the algorithm's name. + + Args: + algorithm_name (str): The name of the algorithm to use for the title. + title (bool): If True, line is inserted above & below algorithm name. + + Returns: + str: ReST formatted header with algorithm_name as content. + """ + line = "\n" + "-" * len(name) + "\n" + if title: + return line + name + line + else: + return name + line + + def _insert_rest(self, text): + """ + Inserts ReStructuredText into the algorithm file. + + Args: + text (str): Inserts ReStructuredText into the algorithm file. + + Returns: + list: Empty list. This is required by the inherited run method. + """ + self.state_machine.insert_input(statemachine.string2lines(text), "") + return [] + + def _create_mantid_algorithm(self, algorithm_name): + """ + Create and initializes a Mantid algorithm. + + Args: + algorithm_name (str): The name of the algorithm to use for the title. + + Returns: + algorithm: An instance of a Mantid algorithm. + """ + from mantid.api import AlgorithmManager + alg = AlgorithmManager.createUnmanaged(algorithm_name) + alg.initialize() + return alg diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py new file mode 100644 index 000000000000..c51a145b5f77 --- /dev/null +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py @@ -0,0 +1,42 @@ +from base import BaseDirective + + +class CategoriesDirective(BaseDirective): + + """ + Obtains the categories for a given algorithm based on it's name. + """ + + required_arguments, optional_arguments = 1, 0 + + def run(self): + """ + Called by Sphinx when the ..categories:: directive is encountered. + """ + title = self._make_header(__name__.title()) + categories = self._get_categories(str(self.arguments[0])) + return self._insert_rest(title + categories) + + def _get_categories(self, algorithm_name): + """ + Return the categories for the named algorithm. + + Args: + algorithm_name (str): The name of the algorithm. + """ + alg = self._create_mantid_algorithm(algorithm_name) + + # Create a list containing each category. + categories = alg.category().split("\\") + + if len(categories) >= 2: + # Add a cross reference for each catagory. + links = (":ref:`%s` | " * len(categories)) % tuple(categories) + # Remove last three characters to remove last | + return ("`Categories: `_ " + links)[:-3] + else: + return "`Category: `_ :ref:`%s`" % (categories) + + +def setup(app): + app.add_directive('categories', CategoriesDirective) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py new file mode 100644 index 000000000000..64d5de49c748 --- /dev/null +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py @@ -0,0 +1,159 @@ +from base import BaseDirective + + +class PropertiesDirective(BaseDirective): + + """ + Outputs the given algorithm's properties into a ReST formatted table. + """ + # Accept one required argument and no optional arguments. + required_arguments, optional_arguments = 1, 0 + + def run(self): + """ + Called by Sphinx when the ..properties:: directive is encountered. + """ + alg_name = str(self.arguments[0]) + title = self._make_header(__name__.title()) + properties_table = self._populate_properties_table(alg_name) + return self._insert_rest(title + properties_table) + + def _populate_properties_table(self, algorithm_name): + """ + Populates the ReST table with algorithm properties. + + Args: + algorithm_name (str): The name of the algorithm. + """ + alg = self._create_mantid_algorithm(algorithm_name) + alg_properties = alg.getProperties() + + # Stores each property of the algorithm in a tuple. + properties = [] + + # Used to obtain the name for the direction property rather than an + # int. + direction_string = ["Input", "Output", "InOut", "None"] + + for prop in alg_properties: + # Append a tuple of properties to the list. + properties.append(( + str(prop.name), + str(direction_string[prop.direction]), + str(prop.type), + str(self._get_default_prop(prop)), + str(prop.documentation) + )) + + # Build and add the properties to the ReST table. + return self._build_table(properties) + + def _build_table(self, table_content): + """ + Build the ReST format + + Args: + table_content (list of tuples): Each tuple (row) container + property values for a unique property of that algorithm. + + Returns: + str: ReST formatted table containing algorithm properties. + """ + # Default values for the table headers. + header_content = ( + 'Name', 'Direction', 'Type', 'Default', 'Description') + # The width of the columns. Multiply row length by 10 to ensure small + # properties format correctly. + col_sizes = [max(len(row[i] * 10) for row in table_content) + for i in range(len(header_content))] + # Use the column widths as a means to formatting columns. + formatter = ' '.join('{:<%d}' % col for col in col_sizes) + # Add whitespace to each column. This depends on the values returned by + # col_sizes. + table_content_formatted = [ + formatter.format(*item) for item in table_content] + # Create a seperator for each column + seperator = formatter.format(*['=' * col for col in col_sizes]) + # Build the table. + header = '\n' + seperator + '\n' + formatter.format(*header_content) + '\n' + content = seperator + '\n' + \ + '\n'.join(table_content_formatted) + '\n' + seperator + # Join the header and footer. + return header + content + + def _get_default_prop(self, prop): + """ + Converts the default value of the property to a more use-friendly one. + + Args: + prop (str): The algorithm property to use. + + Returns: + str: The default value of the property. + """ + from mantid.api import IWorkspaceProperty + + # Used to obtain the name for the direction property rather than + # outputting an int. + direction_string = ["Input", "Output", "InOut", "None"] + + # Nothing to show under the default section for an output properties + # that are not workspace properties. + if (direction_string[prop.direction] == "Output") and \ + (not isinstance(prop, IWorkspaceProperty)): + default_prop = "" + elif (prop.isValid == ""): + default_prop = self._create_property_default_string(prop) + else: + default_prop = "Mandatory" + return default_prop + + def _create_property_default_string(self, prop): + """ + Converts the default value of the property to a more use-friendly one. + + Args: + prop. The property to find the default value of. + + Returns: + str: The string to add to the property table default section. + """ + + default = prop.getDefault + defaultstr = "" + + # Convert to int, then float, then any string + try: + val = int(default) + if (val >= 2147483647): + defaultstr = "Optional" + else: + defaultstr = str(val) + except: + try: + val = float(default) + if (val >= 1e+307): + defaultstr = "Optional" + else: + defaultstr = str(val) + except: + # Fall-back default for anything + defaultstr = str(default) + + # Replace the ugly default values with "Optional" + if (defaultstr == "8.9884656743115785e+307") or \ + (defaultstr == "1.7976931348623157e+308") or \ + (defaultstr == "2147483647"): + defaultstr = "Optional" + + if str(prop.type) == "boolean": + if defaultstr == "1": + defaultstr = "True" + else: + defaultstr = "False" + + return defaultstr + + +def setup(app): + app.add_directive('properties', PropertiesDirective) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py new file mode 100644 index 000000000000..c66fc706a064 --- /dev/null +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py @@ -0,0 +1,32 @@ +from base import BaseDirective + + +class SummaryDirective(BaseDirective): + + """ + Obtains the summary for a given algorithm based on it's name. + """ + + required_arguments, optional_arguments = 1, 0 + + def run(self): + """ + Called by Sphinx when the ..summary:: directive is encountered. + """ + title = self._make_header(__name__.title()) + summary = self._get_summary(str(self.arguments[0])) + return self._insert_rest(title + summary) + + def _get_summary(self, algorithm_name): + """ + Return the summary for the named algorithm. + + Args: + algorithm_name (str): The name of the algorithm. + """ + alg = self._create_mantid_algorithm(algorithm_name) + return alg.getWikiSummary() + + +def setup(app): + app.add_directive('summary', SummaryDirective) From 5cd6fe34979badbf9535cafa1fbd0acc2c280603 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 23 May 2014 10:21:42 +0100 Subject: [PATCH 039/126] Add README and initial start on style guide text. Refs #9521 --- Code/Mantid/docs/DocumentationStyleGuide.md | 10 ++++++++++ Code/Mantid/docs/README.md | 5 +++++ 2 files changed, 15 insertions(+) create mode 100644 Code/Mantid/docs/DocumentationStyleGuide.md create mode 100644 Code/Mantid/docs/README.md diff --git a/Code/Mantid/docs/DocumentationStyleGuide.md b/Code/Mantid/docs/DocumentationStyleGuide.md new file mode 100644 index 000000000000..75a0ac64a70c --- /dev/null +++ b/Code/Mantid/docs/DocumentationStyleGuide.md @@ -0,0 +1,10 @@ +Documentation Style Guide +========================= + +This guide describes the formatting that should be followed when documenting Mantid functionality. The documentation is built using [Sphinx](http://sphinx.pocoo.org/) and when using Sphinx most of what you type is reStructuredText. For more information on reStructeredText see: + +* https://pythonhosted.org/an_example_pypi_project/sphinx.html +* http://docutils.sourceforge.net/rst.html +* http://docutils.sourceforge.net/docs/user/rst/quickref.html +* http://docutils.sourceforge.net/docs/user/rst/cheatsheet.txt + diff --git a/Code/Mantid/docs/README.md b/Code/Mantid/docs/README.md new file mode 100644 index 000000000000..12654d178542 --- /dev/null +++ b/Code/Mantid/docs/README.md @@ -0,0 +1,5 @@ +The Mantid documentation is written in [reStructuredText](http://docutils.sourceforge.net/rst.html) and processed using [Sphinx](http://sphinx.pocoo.org/). To install Sphinx type + + easy_install -U Sphinx + +CMake produces a `doc-html` target that is used to build the documentation. The output files will appear in a `html` sub directory of the main `build/docs` directory. \ No newline at end of file From 7e598c2cfaa0f64e96b916001ef48b40c2b133a5 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Fri, 23 May 2014 11:47:14 +0100 Subject: [PATCH 040/126] Update screenshot method to add CSS class to image. Refs #9521. - This is required to easily style the image, e.g. alignment. --- Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index a2bf960c5941..3f7b33fe2eab 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -46,7 +46,8 @@ def _get_algorithm_screenshot(self, algorithm_name): str: The location of the screenshot for the given algorithm. """ images_dir = self.state.document.settings.env.config["mantid_images"] - return ".. image:: " + images_dir + algorithm_name + ".png" + screenshot = images_dir + algorithm_name + ".png" + return ".. image:: " + screenshot + "\n" + " :class: screenshot" def setup(app): From 28b419cbc2d37ade1ef7e164851e9e2fede1b862 Mon Sep 17 00:00:00 2001 From: Arturs Bekasovs Date: Fri, 23 May 2014 13:03:07 +0100 Subject: [PATCH 041/126] Refs #9526. Change the way tooltips are updated Connect to the FitPropertyBrowsers onFunctionChanged() signal and update all the function tooltips at once. --- .../FitPropertyBrowser.h | 2 + .../MantidQtMantidWidgets/PropertyHandler.h | 9 +- .../MantidWidgets/src/FitPropertyBrowser.cpp | 11 +++ .../MantidWidgets/src/PropertyHandler.cpp | 94 ++++++++++--------- 4 files changed, 64 insertions(+), 52 deletions(-) diff --git a/Code/Mantid/MantidQt/MantidWidgets/inc/MantidQtMantidWidgets/FitPropertyBrowser.h b/Code/Mantid/MantidQt/MantidWidgets/inc/MantidQtMantidWidgets/FitPropertyBrowser.h index b22ca81cc849..eff7bd9daff5 100644 --- a/Code/Mantid/MantidQt/MantidWidgets/inc/MantidQtMantidWidgets/FitPropertyBrowser.h +++ b/Code/Mantid/MantidQt/MantidWidgets/inc/MantidQtMantidWidgets/FitPropertyBrowser.h @@ -325,6 +325,8 @@ private slots: void executeCustomSetupLoad(const QString& name); void executeCustomSetupRemove(const QString& name); + /// Update structure tooltips for all functions + void updateStructureTooltips(); protected: /// actions to do before the browser made visible diff --git a/Code/Mantid/MantidQt/MantidWidgets/inc/MantidQtMantidWidgets/PropertyHandler.h b/Code/Mantid/MantidQt/MantidWidgets/inc/MantidQtMantidWidgets/PropertyHandler.h index 6efc72d474c7..56330fc59d83 100644 --- a/Code/Mantid/MantidQt/MantidWidgets/inc/MantidQtMantidWidgets/PropertyHandler.h +++ b/Code/Mantid/MantidQt/MantidWidgets/inc/MantidQtMantidWidgets/PropertyHandler.h @@ -64,9 +64,6 @@ class EXPORT_OPT_MANTIDQT_MANTIDWIDGETS PropertyHandler:public QObject, public M QString functionPrefix()const; - /// High level structure representation of the string - QString functionStructure() const; - // Return composite function boost::shared_ptr cfun()const{return m_cf;} // Return peak function @@ -190,14 +187,14 @@ class EXPORT_OPT_MANTIDQT_MANTIDWIDGETS PropertyHandler:public QObject, public M // set workspace in workspace property to the function void setFunctionWorkspace(); + /// Update high-level structure tooltip and return it + QString updateStructureTooltip(); + protected slots: // void plotRemoved(); - /// Run when function structure is changed, i.e. children function added/removed - void onFunctionStructChanged(); - protected: void initAttributes(); diff --git a/Code/Mantid/MantidQt/MantidWidgets/src/FitPropertyBrowser.cpp b/Code/Mantid/MantidQt/MantidWidgets/src/FitPropertyBrowser.cpp index 6e48c5865d0c..3eb8bed8bcf8 100644 --- a/Code/Mantid/MantidQt/MantidWidgets/src/FitPropertyBrowser.cpp +++ b/Code/Mantid/MantidQt/MantidWidgets/src/FitPropertyBrowser.cpp @@ -395,6 +395,8 @@ void FitPropertyBrowser::initLayout(QWidget *w) createCompositeFunction(); + connect(this, SIGNAL(functionChanged()), SLOT(updateStructureTooltips())); + m_changeSlotsEnabled = true; populateFunctionNames(); @@ -479,6 +481,15 @@ void FitPropertyBrowser::executeCustomSetupRemove(const QString& name) updateSetupMenus(); } +/** + * Recursively updates structure tooltips for all the functions + */ +void FitPropertyBrowser::updateStructureTooltips() +{ + // Call tooltip update func on the root handler - it goes down recursively + getHandler()->updateStructureTooltip(); +} + void FitPropertyBrowser::executeFitMenu(const QString& item) { if (item == "Fit") diff --git a/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp b/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp index 8beda4585245..74e2c2e51fbb 100644 --- a/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp +++ b/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp @@ -142,8 +142,6 @@ void PropertyHandler::init() } } - onFunctionStructChanged(); - m_browser->m_changeSlotsEnabled = true; } @@ -480,8 +478,6 @@ PropertyHandler* PropertyHandler::addFunction(const std::string& fnName) m_browser->setFocus(); m_browser->setCurrentFunction(h); - onFunctionStructChanged(); - return h; } @@ -508,7 +504,6 @@ void PropertyHandler::removeFunction() } } ph->renameChildren(); - ph->onFunctionStructChanged(); } } @@ -575,41 +570,6 @@ QString PropertyHandler::functionPrefix()const return ""; } -/** - * For non-composite functions is equal to function()->name(). - * @return High-level structure string, e.g. ((Gaussian * Lorentzian) + FlatBackground) - */ -QString PropertyHandler::functionStructure() const -{ - if ( m_cf && (m_cf->name() == "CompositeFunction" || m_cf->name() == "ProductFunction") ) - { - QStringList children; - - for (size_t i = 0; i < m_cf->nFunctions(); ++i) - { - children << getHandler(i)->functionStructure(); - } - - if ( children.empty() ) - { - return QString::fromStdString("Empty " + m_cf->name()); - } - - QChar op('+'); - - if (m_cf->name() == "ProductFunction") - { - op = '*'; - } - - return QString("(%1)").arg(children.join(' ' + op + ' ')); - } - else - { - return QString::fromStdString(function()->name()); - } -} - // Return the parent handler PropertyHandler* PropertyHandler::parentHandler()const { @@ -1523,16 +1483,58 @@ void PropertyHandler::plotRemoved() m_hasPlot = false; } -void PropertyHandler::onFunctionStructChanged() +/** + * Updates the high-level structure tooltip of this handler's property, updating those of + * sub-properties recursively first. + * + * For non-empty composite functions: something like ((Gaussian * Lorentzian) + FlatBackground) + * + * For non-composite functions: function()->name(). + * + * @return The new tooltip + */ +QString PropertyHandler::updateStructureTooltip() { - // Update structural tooltip of oneself - m_item->property()->setToolTip(functionStructure()); + QString newTooltip; - // If is handler of child function, make sure ancestors are updated as well - if (PropertyHandler* h = parentHandler()) + if ( m_cf && (m_cf->name() == "CompositeFunction" || m_cf->name() == "ProductFunction") ) { - h->onFunctionStructChanged(); + QStringList childrenTooltips; + + // Update tooltips for all the children first, and use them to build this tooltip + for (size_t i = 0; i < m_cf->nFunctions(); ++i) + { + if (auto childHandler = getHandler(i)) + { + childrenTooltips << childHandler->updateStructureTooltip(); + } + else + { + throw std::runtime_error("Error while building structure tooltip: no handler for child"); + } + } + + if ( childrenTooltips.empty() ) + { + newTooltip = QString::fromStdString("Empty " + m_cf->name()); + } + + QChar op('+'); + + if (m_cf->name() == "ProductFunction") + { + op = '*'; + } + + newTooltip = QString("(%1)").arg(childrenTooltips.join(' ' + op + ' ')); + } + else + { + newTooltip = QString::fromStdString(function()->name()); } + + m_item->property()->setToolTip(newTooltip); + return newTooltip; } /** From 7d4f0e32972a563c8870da7cb23b0d42340b8812 Mon Sep 17 00:00:00 2001 From: Arturs Bekasovs Date: Fri, 23 May 2014 13:12:53 +0100 Subject: [PATCH 042/126] Refs #9526. Set correct tooltips on creation, and fix empty comp func. --- .../MantidWidgets/src/FitPropertyBrowser.cpp | 4 ++++ .../MantidQt/MantidWidgets/src/PropertyHandler.cpp | 14 ++++++++------ 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/Code/Mantid/MantidQt/MantidWidgets/src/FitPropertyBrowser.cpp b/Code/Mantid/MantidQt/MantidWidgets/src/FitPropertyBrowser.cpp index 3eb8bed8bcf8..bb232aefcf4a 100644 --- a/Code/Mantid/MantidQt/MantidWidgets/src/FitPropertyBrowser.cpp +++ b/Code/Mantid/MantidQt/MantidWidgets/src/FitPropertyBrowser.cpp @@ -395,8 +395,12 @@ void FitPropertyBrowser::initLayout(QWidget *w) createCompositeFunction(); + // Update tooltips when function structure is (or might've been) changed in any way connect(this, SIGNAL(functionChanged()), SLOT(updateStructureTooltips())); + // Initial call, as function is not changed when it's created for the first time + updateStructureTooltips(); + m_changeSlotsEnabled = true; populateFunctionNames(); diff --git a/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp b/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp index 74e2c2e51fbb..72bd55b076a1 100644 --- a/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp +++ b/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp @@ -1518,15 +1518,17 @@ QString PropertyHandler::updateStructureTooltip() { newTooltip = QString::fromStdString("Empty " + m_cf->name()); } + else + { + QChar op('+'); - QChar op('+'); + if (m_cf->name() == "ProductFunction") + { + op = '*'; + } - if (m_cf->name() == "ProductFunction") - { - op = '*'; + newTooltip = QString("(%1)").arg(childrenTooltips.join(' ' + op + ' ')); } - - newTooltip = QString("(%1)").arg(childrenTooltips.join(' ' + op + ' ')); } else { From c57778437f19f50c81890a6032b65dfcb3b2a3c0 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Fri, 23 May 2014 16:01:51 +0100 Subject: [PATCH 043/126] Removed title from categories. Refs #9521. --- Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py index c51a145b5f77..f53b98a090bd 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py @@ -13,9 +13,8 @@ def run(self): """ Called by Sphinx when the ..categories:: directive is encountered. """ - title = self._make_header(__name__.title()) categories = self._get_categories(str(self.arguments[0])) - return self._insert_rest(title + categories) + return self._insert_rest(categories) def _get_categories(self, algorithm_name): """ From a7c12f3fdb4117ef8925c8191876abafde8094b8 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Fri, 23 May 2014 16:02:55 +0100 Subject: [PATCH 044/126] Added local table of content to algorithm. Refs #9521. --- .../Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index 3f7b33fe2eab..4af0b912d0b7 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -19,9 +19,10 @@ def run(self): # Seperate methods for each unique piece of functionality. reference = self._make_reference_link(algorithm_name) title = self._make_header(algorithm_name, True) + toc = self._make_local_toc() screenshot = self._get_algorithm_screenshot(algorithm_name) - return self._insert_rest(reference + title + screenshot) + return self._insert_rest(reference + title + screenshot + toc) def _make_reference_link(self, algorithm_name): """ @@ -35,6 +36,9 @@ def _make_reference_link(self, algorithm_name): """ return ".. _" + algorithm_name.title() + ":" + "\n" + def _make_local_toc(self): + return ".. contents:: Table of Contents\n :local:\n" + def _get_algorithm_screenshot(self, algorithm_name): """ Obtains the location of the screenshot for a given algorithm. From 48610385b4b9f53d157ee007421039eeb01b4e0a Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Fri, 23 May 2014 16:03:40 +0100 Subject: [PATCH 045/126] Use figure rather than image. Refs #9521. - This allows a caption to be added that contains the algorithms name, to make the screenshot's purpose clearer. --- Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index 4af0b912d0b7..1f0de157bf66 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -51,7 +51,8 @@ def _get_algorithm_screenshot(self, algorithm_name): """ images_dir = self.state.document.settings.env.config["mantid_images"] screenshot = images_dir + algorithm_name + ".png" - return ".. image:: " + screenshot + "\n" + " :class: screenshot" + caption = "A screenshot of the **" + algorithm_name + "** dialog." + return ".. figure:: " + screenshot + "\n" + " :class: screenshot\n\n " + caption + "\n" def setup(app): From b6b077513881c40c06730f474395c23653ca61bb Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 23 May 2014 11:59:36 +0100 Subject: [PATCH 046/126] Hard code section header names rather than using the module titles It's clearer where the section names come from and avoids any unwanted module qualifications when the directives become part of a package. Refs #9521 --- .../mantiddoc/directives/__init__.py | 23 +++++++++++++++++++ .../mantiddoc/directives/algorithm.py | 7 +++++- .../sphinxext/mantiddoc/directives/aliases.py | 8 ++++++- .../mantiddoc/directives/categories.py | 8 ++++++- .../mantiddoc/directives/properties.py | 8 ++++++- .../sphinxext/mantiddoc/directives/summary.py | 8 ++++++- 6 files changed, 57 insertions(+), 5 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/__init__.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/__init__.py index e69de29bb2d1..10dcf75288c5 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/__init__.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/__init__.py @@ -0,0 +1,23 @@ +""" + Defines custom directives for Mantid documentation + + Each directive should be defined in a different module and have its own + setup(app) function. The setup function defined here is used to tie them + all together in the case where all directives are required, allowing + 'mantiddoc.directives' to be added to the Sphinx extensions configuration. +""" + +import algorithm, aliases, categories, properties, summary + +def setup(app): + """ + Setup the directives when the extension is activated + + Args: + app: The main Sphinx application object + """ + algorithm.setup(app) + aliases.setup(app) + categories.setup(app) + properties.setup(app) + summary.setup(app) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index 1f0de157bf66..e07eb9ce853b 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -1,6 +1,5 @@ from base import BaseDirective - class AlgorithmDirective(BaseDirective): """ @@ -56,5 +55,11 @@ def _get_algorithm_screenshot(self, algorithm_name): def setup(app): + """ + Setup the directives when the extension is activated + + Args: + app: The main Sphinx application object + """ app.add_config_value('mantid_images', 'mantid_images', 'env') app.add_directive('algorithm', AlgorithmDirective) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py index 55895f5ead34..fed689708822 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py @@ -13,7 +13,7 @@ def run(self): """ Called by Sphinx when the ..aliases:: directive is encountered. """ - title = self._make_header(__name__.title()) + title = self._make_header("Aliases") alias = self._get_alias(str(self.arguments[0])) return self._insert_rest(title + alias) @@ -29,4 +29,10 @@ def _get_alias(self, algorithm_name): def setup(app): + """ + Setup the directives when the extension is activated + + Args: + app: The main Sphinx application object + """ app.add_directive('aliases', AliasesDirective) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py index f53b98a090bd..0a4d147a5e43 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py @@ -14,7 +14,7 @@ def run(self): Called by Sphinx when the ..categories:: directive is encountered. """ categories = self._get_categories(str(self.arguments[0])) - return self._insert_rest(categories) + return self._insert_rest("\n" + categories) def _get_categories(self, algorithm_name): """ @@ -38,4 +38,10 @@ def _get_categories(self, algorithm_name): def setup(app): + """ + Setup the directives when the extension is activated + + Args: + app: The main Sphinx application object + """ app.add_directive('categories', CategoriesDirective) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py index 64d5de49c748..2e3b67a92e3c 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py @@ -14,7 +14,7 @@ def run(self): Called by Sphinx when the ..properties:: directive is encountered. """ alg_name = str(self.arguments[0]) - title = self._make_header(__name__.title()) + title = self._make_header("Properties") properties_table = self._populate_properties_table(alg_name) return self._insert_rest(title + properties_table) @@ -156,4 +156,10 @@ def _create_property_default_string(self, prop): def setup(app): + """ + Setup the directives when the extension is activated + + Args: + app: The main Sphinx application object + """ app.add_directive('properties', PropertiesDirective) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py index c66fc706a064..22a8f73c695d 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py @@ -13,7 +13,7 @@ def run(self): """ Called by Sphinx when the ..summary:: directive is encountered. """ - title = self._make_header(__name__.title()) + title = self._make_header("Summary") summary = self._get_summary(str(self.arguments[0])) return self._insert_rest(title + summary) @@ -29,4 +29,10 @@ def _get_summary(self, algorithm_name): def setup(app): + """ + Setup the directives when the extension is activated + + Args: + app: The main Sphinx application object + """ app.add_directive('summary', SummaryDirective) From 844db760888c7851322ace3eed1d4bd84ca02b33 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 23 May 2014 17:46:43 +0100 Subject: [PATCH 047/126] Add supporting code to generate screenshot in algorithm directive Refs #9521 --- Code/Mantid/MantidPlot/mantidplot.py | 8 +- .../mantiddoc/directives/algorithm.py | 76 ++++++++++++++++--- .../sphinxext/mantiddoc/directives/base.py | 3 + .../sphinxext/mantiddoc/tools/__init__.py | 3 + .../sphinxext/mantiddoc/tools/screenshot.py | 38 ++++++++++ 5 files changed, 116 insertions(+), 12 deletions(-) create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/tools/__init__.py create mode 100644 Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py diff --git a/Code/Mantid/MantidPlot/mantidplot.py b/Code/Mantid/MantidPlot/mantidplot.py index 3468089e37f7..663ac35bd24f 100644 --- a/Code/Mantid/MantidPlot/mantidplot.py +++ b/Code/Mantid/MantidPlot/mantidplot.py @@ -915,13 +915,17 @@ def screenshot_to_dir(widget, filename, screenshot_dir): @param filename :: Destination filename for that image @param screenshot_dir :: Directory to put the screenshots into. """ - # Find the widget if handled with a proxy + # Find the widget if handled with a proxy if hasattr(widget, "_getHeldObject"): widget = widget._getHeldObject() if widget is not None: camera = Screenshot() - threadsafe_call(camera.take_picture, widget, os.path.join(screenshot_dir, filename+".png")) + imgpath = os.path.join(screenshot_dir, filename) + threadsafe_call(camera.take_picture, widget, imgpath) + return imgpath + else: + raise RuntimeError("Unable to retrieve widget. Has it been deleted?") #============================================================================= diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index e07eb9ce853b..50382f959978 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -1,4 +1,5 @@ from base import BaseDirective +import os class AlgorithmDirective(BaseDirective): @@ -19,13 +20,15 @@ def run(self): reference = self._make_reference_link(algorithm_name) title = self._make_header(algorithm_name, True) toc = self._make_local_toc() - screenshot = self._get_algorithm_screenshot(algorithm_name) + imgpath = self._create_screenshot(algorithm_name) + screenshot = self._make_screenshot_link(algorithm_name, imgpath) return self._insert_rest(reference + title + screenshot + toc) def _make_reference_link(self, algorithm_name): """ - Outputs a reference to the top of the algorithm's rst file. + Outputs a reference to the top of the algorithm's rst + of the form .. _AlgorithmName: Args: algorithm_name (str): The name of the algorithm to reference. @@ -33,26 +36,80 @@ def _make_reference_link(self, algorithm_name): Returns: str: A ReST formatted reference. """ - return ".. _" + algorithm_name.title() + ":" + "\n" + return ".. _%s:\n" % algorithm_name def _make_local_toc(self): return ".. contents:: Table of Contents\n :local:\n" - def _get_algorithm_screenshot(self, algorithm_name): + def _create_screenshot(self, algorithm_name): """ - Obtains the location of the screenshot for a given algorithm. + Creates a screenshot for the named algorithm in an "images/screenshots" + subdirectory of the currently processed document + + The file will be named "algorithmname_dlg.png", e.g. Rebin_dlg.png Args: algorithm_name (str): The name of the algorithm. Returns: - str: The location of the screenshot for the given algorithm. + str: The full path to the created image + """ + from mantiddoc.tools.screenshot import algorithm_screenshot + + env = self.state.document.settings.env + screenshots_dir = self._screenshot_directory(env) + if not os.path.exists(screenshots_dir): + os.makedirs(screenshots_dir) + + try: + imgpath = algorithm_screenshot(algorithm_name, screenshots_dir) + except Exception, exc: + env.warn(env.docname, "Unable to generate screenshot for '%s' - %s" % (algorithm_name, str(exc))) + imgpath = os.path.join(screenshots_dir, "failed_dialog.png") + + return imgpath + + def _make_screenshot_link(self, algorithm_name, img_path): """ - images_dir = self.state.document.settings.env.config["mantid_images"] - screenshot = images_dir + algorithm_name + ".png" + Outputs an image link with a custom :class: style. The filename is + extracted from the path given and then a link to /images/screenshots/filename.png + is created. Sphinx handles copying the files over to the build directory + and reformatting the links + + Args: + algorithm_name (str): The name of the algorithm that the screenshot represents + img_path (str): The full path as on the filesystem to the image + + Returns: + str: A ReST formatted reference. + """ + format_str = ".. figure:: %s\n"\ + " :class: screenshot\n\n"\ + " %s\n" + + filename = os.path.split(img_path)[1] + path = "/images/screenshots/" + filename caption = "A screenshot of the **" + algorithm_name + "** dialog." - return ".. figure:: " + screenshot + "\n" + " :class: screenshot\n\n " + caption + "\n" + return format_str % (path, caption) + + def _screenshot_directory(self, env): + """ + Returns a full path where the screenshots should be generated. They are + put in a screenshots subdirectory of the main images directory in the source + tree. Sphinx then handles copying them to the final location + + Arguments: + env (BuildEnvironment): Allows access to find the source directory + + Returns: + str: A string containing a path to where the screenshots should be created. This will + be a filesystem path + """ + cfg_dir = env.app.srcdir + return os.path.join(cfg_dir, "images", "screenshots") + +############################################################################################################ def setup(app): """ @@ -61,5 +118,4 @@ def setup(app): Args: app: The main Sphinx application object """ - app.add_config_value('mantid_images', 'mantid_images', 'env') app.add_directive('algorithm', AlgorithmDirective) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py index ac76ddcfeb6f..d3e911ed8b7e 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py @@ -8,6 +8,9 @@ class BaseDirective(Directive): Contains shared functionality for Mantid custom directives. """ + has_content = True + final_argument_whitespace = True + def _make_header(self, name, title=False): """ Makes a ReStructuredText title from the algorithm's name. diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/tools/__init__.py b/Code/Mantid/docs/sphinxext/mantiddoc/tools/__init__.py new file mode 100644 index 000000000000..f5c662ab970a --- /dev/null +++ b/Code/Mantid/docs/sphinxext/mantiddoc/tools/__init__.py @@ -0,0 +1,3 @@ +""" + Subpackage containing tools to help in constructing the documentation +""" diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py b/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py new file mode 100644 index 000000000000..692517d62ec9 --- /dev/null +++ b/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py @@ -0,0 +1,38 @@ +""" + mantiddoc.tools.screenshot + ~~~~~~~~~~~~~~~~~~~~~~~~~~ + + Provides functions to take a screenshot of a QWidgets. + + It currently assumes that the functions are called within the + MantidPlot Python environment + + :copyright: Copyright 2014 + ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory +""" + +def algorithm_screenshot(name, directory, ext=".png"): + """ + Takes a snapshot of an algorithm dialog and saves it as an image + named "name_dlg.png" + + Args: + name (str): The name of the algorithm + directory (str): An directory path where the image should be saved + ext (str): An optional extension (including the period). Default=.png + + Returns: + str: A full path to the image file + """ + import mantidqtpython as mantidqt + from mantidplot import screenshot_to_dir, threadsafe_call + + iface_mgr = mantidqt.MantidQt.API.InterfaceManager() + # threadsafe_call required for MantidPlot + dlg = threadsafe_call(iface_mgr.createDialogFromName, name, True) + + filename = name + "_dlg" + ext + img_path = screenshot_to_dir(widget=dlg, filename=filename, screenshot_dir=directory) + threadsafe_call(dlg.close) + + return img_path From 67a2c8a142cf1c0cef19674bdc378991a06641e7 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 23 May 2014 18:02:10 +0100 Subject: [PATCH 048/126] Add gitignore & README for images directory. Refs #9521 --- Code/Mantid/docs/source/images/.gitignore | 1 + Code/Mantid/docs/source/images/README.md | 3 +++ 2 files changed, 4 insertions(+) create mode 100644 Code/Mantid/docs/source/images/.gitignore create mode 100644 Code/Mantid/docs/source/images/README.md diff --git a/Code/Mantid/docs/source/images/.gitignore b/Code/Mantid/docs/source/images/.gitignore new file mode 100644 index 000000000000..b15bc0b3837d --- /dev/null +++ b/Code/Mantid/docs/source/images/.gitignore @@ -0,0 +1 @@ +screenshots/* diff --git a/Code/Mantid/docs/source/images/README.md b/Code/Mantid/docs/source/images/README.md new file mode 100644 index 000000000000..74c28ac24b79 --- /dev/null +++ b/Code/Mantid/docs/source/images/README.md @@ -0,0 +1,3 @@ +Contains images for the documentation + +The algorithm screenshots are automatically generated into a `screenshots` subdirectory and this subdirectory has been added to the `.gitignore` in this directory From 22ad91bb4eec29e18f84356bc7c4908a4d52c059 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Tue, 27 May 2014 09:36:40 +0100 Subject: [PATCH 049/126] Add initial config file. Refs #9521. --- Code/Mantid/docs/conf.py | 116 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 116 insertions(+) create mode 100644 Code/Mantid/docs/conf.py diff --git a/Code/Mantid/docs/conf.py b/Code/Mantid/docs/conf.py new file mode 100644 index 000000000000..d60b94a6d2c7 --- /dev/null +++ b/Code/Mantid/docs/conf.py @@ -0,0 +1,116 @@ +# -*- coding: utf-8 -*- +# All configuration values have a default; values that are commented out +# serve to show the default. + +import sys +import os +import sphinx_bootstrap_theme + +# If extensions (or modules to document with autodoc) are in another directory, +# add these directories to sys.path here. If the directory is relative to the +# documentation root, use os.path.abspath to make it absolute, like shown here. +sys.path.insert(0, os.path.abspath('sphinxext/mantiddoc/directives')) + +# -- General configuration ------------------------------------------------ + +# Add any Sphinx extension module names here, as strings. They can be +# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom +# ones. +extensions = [ + 'sphinx.ext.pngmath', + 'sphinx.ext.autodoc', + 'sphinx.ext.intersphinx', + 'summary', + 'aliases', + 'properties', + 'categories', + 'algorithm' +] + +# The location of the root of the Mantid images folder. +mantid_images = "/" + os.path.abspath('_static/images') + "/" + +# Add any paths that contain templates here, relative to this directory. +templates_path = ['_templates'] + +# The suffix of source filenames. +source_suffix = '.rst' + +# The master toctree document. +master_doc = 'index' + +# General information about the project. +project = u'MantidProject' +copyright = u'2014, Mantid' + +# The version info for the project you're documenting, acts as replacement for +# |version| and |release|, also used in various other places throughout the +# built documents. +# +# The short X.Y version. +version = '0.01' +# The full version, including alpha/beta/rc tags. +release = '0.01' + +# The name of the Pygments (syntax highlighting) style to use. +pygments_style = 'sphinx' + +# -- Options for HTML output ---------------------------------------------- + +# The theme to use for HTML and HTML Help pages. See the documentation for +# a list of builtin themes. +html_theme = 'bootstrap' + +# Theme-specific options to customize the look and feel of a theme. +# We config the bootstrap settings here, and apply CSS changes in +# custom.css rather than here. +html_theme_options = { + # Navigation bar title. + 'navbar_title': "mantidproject", + # Tab name for entire site. + 'navbar_site_name': "Mantid", + # Add links to the nav bar. Second param of tuple is true to create absolute url. + 'navbar_links': [ + ("Home", "/"), + ("Download", "http://download.mantidproject.org", True), + ("Documentation", "/documentation"), + ("Contact Us", "/contact-us"), + ], + # Do not show the "Show source" button. + 'source_link_position': "no", + # Remove the local TOC from the nav bar + 'navbar_pagenav': False, + # Hide the next/previous in the nav bar. + 'navbar_sidebarrel': False, + # Use the latest version. + 'bootstrap_version': "3", + # Ensure the nav bar always stays on top of page. + 'navbar_fixed_top': "true", +} + +# Add any paths that contain custom themes here, relative to this directory. +html_theme_path = sphinx_bootstrap_theme.get_html_theme_path() + +# The name of an image file (relative to this directory) to place at the top +# of the sidebar. +#html_logo = None + +# Add any paths that contain custom static files (such as style sheets) here, +# relative to this directory. They are copied after the builtin static files, +# so a file named "default.css" will overwrite the builtin "default.css". +html_static_path = ['_static'] + +# Add any extra paths that contain custom files (such as robots.txt or +# .htaccess) here, relative to this directory. These files are copied +# directly to the root of the documentation. +#html_extra_path = [] + +# If true, SmartyPants will be used to convert quotes and dashes to +# typographically correct entities. +html_use_smartypants = True + +# Hide the Sphinx usage as we reference it on github instead. +html_show_sphinx = False + +# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True. +html_show_copyright = True From 447cfb33636868a16cf55893373bc4e694ee7f28 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Tue, 27 May 2014 09:37:22 +0100 Subject: [PATCH 050/126] Add custom styles to sphinx-bootstrap theme. Refs #9521. --- Code/Mantid/docs/_static/custom.css | 85 +++++++++++++++++++++++++ Code/Mantid/docs/_templates/layout.html | 3 + 2 files changed, 88 insertions(+) create mode 100644 Code/Mantid/docs/_static/custom.css create mode 100644 Code/Mantid/docs/_templates/layout.html diff --git a/Code/Mantid/docs/_static/custom.css b/Code/Mantid/docs/_static/custom.css new file mode 100644 index 000000000000..b21258686d13 --- /dev/null +++ b/Code/Mantid/docs/_static/custom.css @@ -0,0 +1,85 @@ +/*-------------------- $GENERAL --------------------*/ + +#table-of-contents { border: none; } + +/*-------------------- $NAV --------------------*/ + +.navbar-version { display: none; } + +/*-------------------- $LINKS --------------------*/ + +a { + color: #009933; + text-decoration: none; +} + +a:hover { + color: #009933; + text-decoration: underline; +} + +/*-------------------- $SPACING --------------------*/ + +body { font-size: 1.6em; } /* 16px */ +dl dd { margin: .5em 0 .5em 1.6em; } +h1,h2 { margin-bottom: .5em; } + +/*-------------------- $IMAGES --------------------*/ + +.figure { + border: 1px solid #CCC; + padding: 10px 10px 0 10px; + background-color: whiteSmoke; + text-align: center; + width: 300px; + float: right; +} + +.screenshot { + height: 240px; + padding-bottom: 1em; +} + +.figure { margin: 0; } + +/*-------------------- $TABLES --------------------*/ + +table { + width: 100%; + border-collapse: collapse; + margin: 1.6em 0; +} + +/* Zebra striping */ +tr:nth-of-type(odd) { background: white; } + +tr:hover { background-color: whiteSmoke; } + +th { + background: #E0DFDE; + font-size: 1.3em; +} + +td, th { + padding: .75em; + border: 1px solid #CCC; + text-align: left; +} + +/*-------------------- $MEDIA-QUERIES --------------------*/ + +@media (min-width: 1200px) { + #table-of-contents { + width: auto; + max-width: 40%; + } +} + +/* - Hide the screenshot image as it does not have a relevant header. TOC should be first. + * - Hide the properties table as it's contents are too large for mobile display. + * - Hide properties title since the table is also hidden. */ +@media (max-width: 767px) { + .figure, .table, #properties { + display: none; + } +} diff --git a/Code/Mantid/docs/_templates/layout.html b/Code/Mantid/docs/_templates/layout.html new file mode 100644 index 000000000000..e4f5bcfc89aa --- /dev/null +++ b/Code/Mantid/docs/_templates/layout.html @@ -0,0 +1,3 @@ +{% extends "!layout.html" %} +{# Custom CSS overrides #} +{% set bootswatch_css_custom = ['_static/custom.css'] %} From d8c9f62fffe483b422b21a9032e27a5984cc82be Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Tue, 27 May 2014 09:37:44 +0100 Subject: [PATCH 051/126] Create empty globaltoc template to remove button in nav. Refs #9521. --- Code/Mantid/docs/_templates/globaltoc.html | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 Code/Mantid/docs/_templates/globaltoc.html diff --git a/Code/Mantid/docs/_templates/globaltoc.html b/Code/Mantid/docs/_templates/globaltoc.html new file mode 100644 index 000000000000..e69de29bb2d1 From 98c9929576b2190928e93f68414bb0a8e6f310c1 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Tue, 27 May 2014 09:40:13 +0100 Subject: [PATCH 052/126] Moved static and template folder to source. Refs #9521. --- Code/Mantid/docs/{ => source}/_static/custom.css | 0 Code/Mantid/docs/{ => source}/_templates/globaltoc.html | 0 Code/Mantid/docs/{ => source}/_templates/layout.html | 0 Code/Mantid/docs/{ => source}/conf.py | 2 +- 4 files changed, 1 insertion(+), 1 deletion(-) rename Code/Mantid/docs/{ => source}/_static/custom.css (100%) rename Code/Mantid/docs/{ => source}/_templates/globaltoc.html (100%) rename Code/Mantid/docs/{ => source}/_templates/layout.html (100%) rename Code/Mantid/docs/{ => source}/conf.py (98%) diff --git a/Code/Mantid/docs/_static/custom.css b/Code/Mantid/docs/source/_static/custom.css similarity index 100% rename from Code/Mantid/docs/_static/custom.css rename to Code/Mantid/docs/source/_static/custom.css diff --git a/Code/Mantid/docs/_templates/globaltoc.html b/Code/Mantid/docs/source/_templates/globaltoc.html similarity index 100% rename from Code/Mantid/docs/_templates/globaltoc.html rename to Code/Mantid/docs/source/_templates/globaltoc.html diff --git a/Code/Mantid/docs/_templates/layout.html b/Code/Mantid/docs/source/_templates/layout.html similarity index 100% rename from Code/Mantid/docs/_templates/layout.html rename to Code/Mantid/docs/source/_templates/layout.html diff --git a/Code/Mantid/docs/conf.py b/Code/Mantid/docs/source/conf.py similarity index 98% rename from Code/Mantid/docs/conf.py rename to Code/Mantid/docs/source/conf.py index d60b94a6d2c7..18bc986720b8 100644 --- a/Code/Mantid/docs/conf.py +++ b/Code/Mantid/docs/source/conf.py @@ -9,7 +9,7 @@ # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -sys.path.insert(0, os.path.abspath('sphinxext/mantiddoc/directives')) +sys.path.insert(0, os.path.abspath('../sphinxext/mantiddoc/directives')) # -- General configuration ------------------------------------------------ From 3a32cf1fb48194b225f90e01919b45c75048b9c0 Mon Sep 17 00:00:00 2001 From: Peter Parker Date: Tue, 27 May 2014 11:11:35 +0100 Subject: [PATCH 053/126] Refs #9245 - Output correct unit string in CanSAS format. Also, the CanSAS format expects "A" rather than "Angstrom". --- Code/Mantid/Framework/DataHandling/src/SaveCanSAS1D2.cpp | 4 ++-- Code/Mantid/Framework/DataHandling/test/SaveCanSAS1dTest2.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Code/Mantid/Framework/DataHandling/src/SaveCanSAS1D2.cpp b/Code/Mantid/Framework/DataHandling/src/SaveCanSAS1D2.cpp index 3dc7b0739040..6c600662ecb8 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveCanSAS1D2.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveCanSAS1D2.cpp @@ -221,10 +221,10 @@ void SaveCanSAS1D2::createSASTransElement(std::string& sasTrans, const std::stri << name << "\">"; std::string t_unit = m_ws->YUnitLabel(); - std::string lambda_unit = m_ws->getAxis(0)->unit()->caption(); + std::string lambda_unit = m_ws->getAxis(0)->unit()->label(); if (t_unit.empty()) t_unit = "none"; - if (lambda_unit.empty()) + if (lambda_unit.empty() || lambda_unit == "Angstrom") lambda_unit = "A"; const MantidVec& xdata = m_ws->readX(0); diff --git a/Code/Mantid/Framework/DataHandling/test/SaveCanSAS1dTest2.h b/Code/Mantid/Framework/DataHandling/test/SaveCanSAS1dTest2.h index a61b72c98764..f3ade3185891 100644 --- a/Code/Mantid/Framework/DataHandling/test/SaveCanSAS1dTest2.h +++ b/Code/Mantid/Framework/DataHandling/test/SaveCanSAS1dTest2.h @@ -178,7 +178,7 @@ class SaveCanSAS1dTest2 : public CxxTest::TestSuite std::getline(testFile, fileLine);// transmission spectrum start TS_ASSERT_EQUALS(fileLine, "\t\t"); - idataline="\t\t\t3543.75111430333.811"; + idataline="\t\t\t3543.75111430333.811"; std::getline(testFile, fileLine);// transmission spectrum data TS_ASSERT_EQUALS(fileLine, idataline); From fe9ccc22e1fabefa236e9e688cb27a54bddf5c4b Mon Sep 17 00:00:00 2001 From: Nick Draper Date: Tue, 27 May 2014 12:16:19 +0100 Subject: [PATCH 054/126] re #9525 CreateSampleWorkspace added --- .../Framework/Algorithms/CMakeLists.txt | 3 + .../MantidAlgorithms/CreateSampleWorkspace.h | 72 +++ .../Algorithms/src/CreateSampleWorkspace.cpp | 467 ++++++++++++++++++ .../test/CreateSampleWorkspaceTest.h | 237 +++++++++ 4 files changed, 779 insertions(+) create mode 100644 Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h create mode 100644 Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp create mode 100644 Code/Mantid/Framework/Algorithms/test/CreateSampleWorkspaceTest.h diff --git a/Code/Mantid/Framework/Algorithms/CMakeLists.txt b/Code/Mantid/Framework/Algorithms/CMakeLists.txt index b3fb242f06cd..424b621fc8b7 100644 --- a/Code/Mantid/Framework/Algorithms/CMakeLists.txt +++ b/Code/Mantid/Framework/Algorithms/CMakeLists.txt @@ -60,6 +60,7 @@ set ( SRC_FILES src/CreateLogTimeCorrection.cpp src/CreatePSDBleedMask.cpp src/CreatePeaksWorkspace.cpp + src/CreateSampleWorkspace.cpp src/CreateSingleValuedWorkspace.cpp src/CreateTransmissionWorkspace.cpp src/CreateWorkspace.cpp @@ -291,6 +292,7 @@ set ( INC_FILES inc/MantidAlgorithms/CreateLogTimeCorrection.h inc/MantidAlgorithms/CreatePSDBleedMask.h inc/MantidAlgorithms/CreatePeaksWorkspace.h + inc/MantidAlgorithms/CreateSampleWorkspace.h inc/MantidAlgorithms/CreateSingleValuedWorkspace.h inc/MantidAlgorithms/CreateTransmissionWorkspace.h inc/MantidAlgorithms/CreateWorkspace.h @@ -535,6 +537,7 @@ set ( TEST_FILES CreateLogTimeCorrectionTest.h CreatePSDBleedMaskTest.h CreatePeaksWorkspaceTest.h + CreateSampleWorkspaceTest.h CreateSingleValuedWorkspaceTest.h CreateWorkspaceTest.h CropWorkspaceTest.h diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h new file mode 100644 index 000000000000..706fcb676c84 --- /dev/null +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h @@ -0,0 +1,72 @@ +#ifndef MANTID_ALGORITHMS_CREATESAMPLEWORKSPACE_H_ +#define MANTID_ALGORITHMS_CREATESAMPLEWORKSPACE_H_ + +#include "MantidKernel/System.h" +#include "MantidAPI/Algorithm.h" +#include "MantidDataObjects/EventWorkspace.h" +#include "MantidAPI/MatrixWorkspace.h" +#include "MantidGeometry/Instrument.h" +#include "MantidKernel/PseudoRandomNumberGenerator.h" + +namespace Mantid +{ +namespace Algorithms +{ + + /** CreateSampleWorkspace : This algorithm is intended for the creation of sample workspaces for usage examples and other situations + + Copyright © 2014 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory + + This file is part of Mantid. + + Mantid is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + Mantid is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + + File change history is stored at: + Code Documentation is available at: + */ + class DLLExport CreateSampleWorkspace : public API::Algorithm + { + public: + CreateSampleWorkspace(); + virtual ~CreateSampleWorkspace(); + + virtual const std::string name() const; + virtual int version() const; + virtual const std::string category() const; + + private: + virtual void initDocs(); + void init(); + void exec(); + + DataObjects::EventWorkspace_sptr createEventWorkspace(int numPixels, + int numBins, int numEvents, double x0, double binDelta, int start_at_pixelID, Geometry::Instrument_sptr inst, const std::string& functionString, bool isRandom); + API::MatrixWorkspace_sptr createHistogramWorkspace(int numPixels, + int numBins, int numEvents, double x0, double binDelta, int start_at_pixelID, Geometry::Instrument_sptr inst, const std::string& functionString, bool isRandom); + Geometry::Instrument_sptr createTestInstrumentRectangular(int num_banks, int pixels, double pixelSpacing = 0.008); + Geometry::Object_sptr createCappedCylinder(double radius, double height, const Kernel::V3D & baseCentre, const Kernel::V3D & axis, const std::string & id); + Geometry::Object_sptr createSphere(double radius, const Kernel::V3D & centre, const std::string & id); + std::vector evalFunction(const std::string& functionString, const std::vector& xVal, double noiseScale); + void replaceAll(std::string& str, const std::string& from, const std::string& to) ; + + /// A pointer to the random number generator + Kernel::PseudoRandomNumberGenerator *m_randGen; + std::map m_preDefinedFunctionmap; + }; + + +} // namespace Algorithms +} // namespace Mantid + +#endif /* MANTID_ALGORITHMS_CREATESAMPLEWORKSPACE_H_ */ \ No newline at end of file diff --git a/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp new file mode 100644 index 000000000000..cfd117cedf88 --- /dev/null +++ b/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp @@ -0,0 +1,467 @@ +/*WIKI* +Creates sample workspaces for usage examples and other situations. + +You can select a predefined function for the data or enter your own by selecting User Defined in the drop down. + +The data will be the same for each spectrum, and is defined by the function selected, and a little noise if Random is selected. +For event workspaces the intensity of the graph will be affected by the number of events selected. + +Here is an example of a user defined formula containing two peaks and a background. + name=LinearBackground, A0=0.5;name=Gaussian, PeakCentre=10000, Height=50, Sigma=0.5;name=Gaussian, PeakCentre=1000, Height=80, Sigma=0.5 + +Random also affects the distribution of events within bins for event workspaces. +If Random is selected the results will differ between runs of the algorithm and will not be comparable. +If comparing the output is important set Random to false or uncheck the box. +*WIKI*/ + +#include "MantidAlgorithms/CreateSampleWorkspace.h" +#include "MantidAlgorithms/CreateSampleWorkspace.h" +#include "MantidDataObjects/Workspace2D.h" +#include "MantidDataObjects/EventWorkspace.h" +#include "MantidAPI/FunctionProperty.h" +#include "MantidAPI/SpectraAxis.h" +#include "MantidAPI/NumericAxis.h" +#include "MantidGeometry/Objects/ShapeFactory.h" +#include "MantidGeometry/Instrument/ReferenceFrame.h" +#include "MantidGeometry/Instrument/RectangularDetector.h" +#include "MantidKernel/BoundedValidator.h" +#include "MantidKernel/ArrayProperty.h" +#include "MantidKernel/RebinParamsValidator.h" +#include "MantidKernel/ListValidator.h" +#include "MantidKernel/VectorHelper.h" +#include "MantidKernel/UnitFactory.h" +#include "MantidKernel/MersenneTwister.h" +#include "MantidAPI/FunctionFactory.h" +#include "MantidAPI/FunctionDomain1D.h" +#include +#include +#include + +namespace Mantid +{ +namespace Algorithms +{ + using namespace Kernel; + using namespace API; + using namespace Geometry; + using namespace DataObjects; + using Mantid::MantidVec; + using Mantid::MantidVecPtr; + + // Register the algorithm into the AlgorithmFactory + DECLARE_ALGORITHM(CreateSampleWorkspace) + + + + //---------------------------------------------------------------------------------------------- + /** Constructor + */ + CreateSampleWorkspace::CreateSampleWorkspace(): m_randGen(NULL) + { + } + + //---------------------------------------------------------------------------------------------- + /** Destructor + */ + CreateSampleWorkspace::~CreateSampleWorkspace() + { + delete m_randGen; + } + + + //---------------------------------------------------------------------------------------------- + /// Algorithm's name for identification. @see Algorithm::name + const std::string CreateSampleWorkspace::name() const { return "CreateSampleWorkspace";}; + + /// Algorithm's version for identification. @see Algorithm::version + int CreateSampleWorkspace::version() const { return 1;}; + + /// Algorithm's category for identification. @see Algorithm::category + const std::string CreateSampleWorkspace::category() const { return "Utility\\Workspaces";} + + //---------------------------------------------------------------------------------------------- + /// Sets documentation strings for this algorithm + void CreateSampleWorkspace::initDocs() + { + std::string message = "Creates sample workspaces for usage examples and other situations."; + this->setWikiSummary(message); + this->setOptionalMessage(message); + } + + //---------------------------------------------------------------------------------------------- + /** Initialize the algorithm's properties. + */ + void CreateSampleWorkspace::init() + { + declareProperty(new WorkspaceProperty<>("OutputWorkspace","",Direction::Output), "An output workspace."); + std::vector typeOptions; + typeOptions.push_back("Histogram"); + typeOptions.push_back("Event"); + declareProperty("WorkspaceType","Histogram",boost::make_shared(typeOptions), + "The type of workspace to create (default: Histogram)"); + + //pre-defined function strings these use $PCx$ to define peak centres values that will be replaced before use + //$PC0$ is the far left of the data, and $PC10$ is the far right, and therefore will often not be used + //$PC5$ is the centre of the data + m_preDefinedFunctionmap.insert(std::pair("One Peak","name=LinearBackground, A0=0.3; name=Gaussian, PeakCentre=$PC5$, Height=10, Sigma=0.7;")); + m_preDefinedFunctionmap.insert(std::pair("Multiple Peaks","name=LinearBackground, A0=0.3;name=Gaussian, PeakCentre=$PC3$, Height=10, Sigma=0.7;name=Gaussian, PeakCentre=$PC6$, Height=8, Sigma=0.5")); + m_preDefinedFunctionmap.insert(std::pair("Flat background","name=LinearBackground, A0=1;")); + m_preDefinedFunctionmap.insert(std::pair("Exp Decay","name=ExpDecay, Height=100, Lifetime=1000;")); + m_preDefinedFunctionmap.insert(std::pair("User Defined","")); + std::vector functionOptions; + for(auto iterator = m_preDefinedFunctionmap.begin(); iterator != m_preDefinedFunctionmap.end(); iterator++) { + functionOptions.push_back(iterator->first); + } + declareProperty("Function","One Peak",boost::make_shared(functionOptions), + "The type of workspace to create (default: Histogram)"); + declareProperty("UserDefinedFunction","","Parameters defining the fitting function and its initial values"); + + declareProperty("NumBanks", 2,boost::make_shared >(0,100), "The Number of banks in the instrument (default:2)"); + declareProperty("BankPixelWidth", 10,boost::make_shared >(0,1000), "The width & height of each bank in pixels (default:10)."); + declareProperty("NumEvents", 1000,boost::make_shared >(0,100000), "The number of events per detector, this is only used for EventWorkspaces (default:1000)."); + declareProperty("Random", false, "Whether to randomise the placement of events and data (default:false)."); + + declareProperty("XUnit","TOF", "The unit to assign to the XAxis (default:\"TOF\")"); + declareProperty("XMin", 0.0, "The minimum X axis value (default:0)"); + declareProperty("XMax", 20000.0, "The maximum X axis value (default:20000)"); + declareProperty("BinWidth",200.0, boost::make_shared >(0,100000,true), + "The bin width of the X axis (default:200)."); +} + + //---------------------------------------------------------------------------------------------- + /** Execute the algorithm. + */ + void CreateSampleWorkspace::exec() + { + const std::string wsType = getProperty("WorkspaceType"); + const std::string preDefinedFunction = getProperty("Function"); + const std::string userDefinedFunction = getProperty("UserDefinedFunction"); + const int numBanks = getProperty("NumBanks"); + const int bankPixelWidth = getProperty("BankPixelWidth"); + const int numEvents = getProperty("NumEvents"); + const bool isRandom = getProperty("Random"); + const std::string xUnit = getProperty("XUnit"); + const double xMin = getProperty("XMin"); + const double xMax = getProperty("XMax"); + const double binWidth = getProperty("BinWidth"); + + std::string functionString = ""; + if (m_preDefinedFunctionmap.find(preDefinedFunction) != m_preDefinedFunctionmap.end()) + { + //extract pre-defined string + functionString = m_preDefinedFunctionmap[preDefinedFunction]; + } + if (functionString.empty()) + { + functionString = userDefinedFunction; + } + + if( !m_randGen ) + { + int seedValue = 0; + if (isRandom) + { + seedValue = static_cast( std::time(0)); + } + m_randGen = new Kernel::MersenneTwister(seedValue); + } + + + + Instrument_sptr inst = createTestInstrumentRectangular(numBanks, bankPixelWidth); + int num_bins = static_cast((xMax-xMin)/binWidth); + MatrixWorkspace_sptr ws; + if (wsType=="Event") + { + ws = createEventWorkspace(numBanks*bankPixelWidth*bankPixelWidth, num_bins,numEvents, + xMin, binWidth, bankPixelWidth*bankPixelWidth, inst, functionString, isRandom); + } + else + { + ws = createHistogramWorkspace(numBanks*bankPixelWidth*bankPixelWidth, num_bins,numEvents, + xMin, binWidth, bankPixelWidth*bankPixelWidth, inst, functionString, isRandom); + } + + // Set the Unit of the X Axis + try + { + ws->getAxis(0)->unit() = UnitFactory::Instance().create(xUnit); + } + catch ( Exception::NotFoundError & ) + { + ws->getAxis(0)->unit() = UnitFactory::Instance().create("Label"); + Unit_sptr unit = ws->getAxis(0)->unit(); + boost::shared_ptr label = boost::dynamic_pointer_cast(unit); + label->setLabel(xUnit, xUnit); + } + + ws->setYUnit("Counts"); + ws->setTitle("Test Workspace"); + + // Assign it to the output workspace property + setProperty("OutputWorkspace",ws);; + } + + /** Create histogram workspace + */ + MatrixWorkspace_sptr CreateSampleWorkspace::createHistogramWorkspace(int numPixels, + int numBins, int numEvents, double x0, double binDelta, + int start_at_pixelID, Geometry::Instrument_sptr inst, + const std::string& functionString, bool isRandom) + { + MantidVecPtr x,y,e; + x.access().resize(numBins+1); + e.access().resize(numBins); + for (int i =0; i < numBins+1; ++i) + { + x.access()[i] = x0+i*binDelta; + } + + std::vector xValues (x.access().begin(),x.access().end()-1); + y.access() = evalFunction(functionString,xValues, isRandom?1:0); + e.access().resize(numBins); + + //calculate e as sqrt(y) + typedef double (*uf)(double); + uf dblSqrt = std::sqrt; + std::transform(y.access().begin(), y.access().end(), e.access().begin(), dblSqrt); + + MatrixWorkspace_sptr retVal(new DataObjects::Workspace2D); + retVal->initialize(numPixels,numBins+1,numBins); + retVal->setInstrument(inst); + + for (size_t wi=0; wisetX(wi,x); + retVal->setData(wi,y,e); + retVal->getSpectrum(wi)->setDetectorID(detid_t(start_at_pixelID + wi)); + retVal->getSpectrum(wi)->setSpectrumNo(specid_t(wi+1)); + } + + return retVal; + } + + /** Create event workspace + */ + EventWorkspace_sptr CreateSampleWorkspace::createEventWorkspace(int numPixels, + int numBins, int numEvents, double x0, double binDelta, + int start_at_pixelID, Geometry::Instrument_sptr inst, + const std::string& functionString, bool isRandom) + { + DateAndTime run_start("2010-01-01T00:00:00"); + + //add one to the number of bins as this is histogram + int numXBins = numBins+1; + + EventWorkspace_sptr retVal(new EventWorkspace); + retVal->initialize(numPixels,1,1); + + retVal->setInstrument(inst); + + + //Create the x-axis for histogramming. + MantidVecPtr x1; + MantidVec& xRef = x1.access(); + xRef.resize(numXBins); + for (int i = 0; i < numXBins; ++i) + { + xRef[i] = x0+i*binDelta; + } + + //Set all the histograms at once. + retVal->setAllX(x1); + + std::vector xValues (xRef.begin(),xRef.end()-1); + std::vector yValues = evalFunction(functionString,xValues,isRandom?1:0); + + //we need to normalise the results and then multiply by the number of events to find the events per bin + double sum_of_elems = std::accumulate(yValues.begin(),yValues.end(),0); + double event_distrib_factor = numEvents/sum_of_elems; + std::transform(yValues.begin(), yValues.end(), yValues.begin(), + std::bind1st(std::multiplies(),event_distrib_factor)); + //the array should now contain the number of events required per bin + + //Make fake events + size_t workspaceIndex = 0; + + for (int wi= 0; wi < numPixels; wi++) + { + EventList & el = retVal->getEventList(workspaceIndex); + el.setSpectrumNo(wi+1); + el.setDetectorID(wi+start_at_pixelID); + + //for each bin + for (int i=0; i(yValues[i]); + for (int q=0; qnextValue()*3,600.0); + el += TofEvent((i+m_randGen->nextValue())*binDelta, pulseTime); + } + } + workspaceIndex++; + } + + return retVal; + } + //---------------------------------------------------------------------------------------------- + /** + * Evaluates a function and returns the values as a vector + * + * + * @param functionString :: the function string + * @param xVal :: A vector of the x values + * @param noiseScale :: A scaling factor for niose to be added to the data, 0= no noise + * @returns the calculated values + */ + std::vector CreateSampleWorkspace::evalFunction(const std::string& functionString, const std::vector& xVal, double noiseScale = 0) + { + size_t xSize=xVal.size(); + //replace $PCx$ values + std::string parsedFuncString = functionString; + for(int x=0; x<=10;++x) + { + //get the rough peak centre value + int index = static_cast((xSize/10)*x); + if (x==10) --index; + double replace_val = xVal[index]; + std::ostringstream tokenStream; + tokenStream << "$PC" << x << "$"; + std::string token = tokenStream.str(); + std::string replaceStr = boost::lexical_cast(replace_val); + replaceAll( parsedFuncString, token, replaceStr); + } + + IFunction_sptr func_sptr = FunctionFactory::Instance().createInitialized(parsedFuncString); + FunctionDomain1DVector fd(xVal); + FunctionValues fv(fd); + func_sptr->function(fd,fv); + + std::vector results; + results.resize(xSize); + for(int x=0; xnextValue()-0.5)*noiseScale); + } + //no negative values please - it messes up the error calculation + results[x] = abs(results[x]); + } + return results; + } + + void CreateSampleWorkspace::replaceAll(std::string& str, const std::string& from, const std::string& to) + { + if(from.empty()) + return; + size_t start_pos = 0; + while((start_pos = str.find(from, start_pos)) != std::string::npos) { + str.replace(start_pos, from.length(), to); + start_pos += to.length(); // In case 'to' contains 'from', like replacing 'x' with 'yx' + } + } + + //---------------------------------------------------------------------------------------------- + /** + * Create an test instrument with n panels of rectangular detectors, pixels*pixels in size, + * a source and spherical sample shape. + * + * Banks' lower-left corner is at position (0,0,5*banknum) and they go up to (pixels*0.008, pixels*0.008, Z) + * Pixels are 4 mm wide. + * + * @param num_banks :: number of rectangular banks to create + * @param pixels :: number of pixels in each direction. + * @param pixelSpacing :: padding between pixels + */ + Instrument_sptr CreateSampleWorkspace::createTestInstrumentRectangular(int num_banks, int pixels, double pixelSpacing) + { + boost::shared_ptr testInst(new Instrument("basic_rect")); + testInst->setReferenceFrame(boost::shared_ptr(new ReferenceFrame(Y,X,Left,""))); + + const double cylRadius(pixelSpacing/2); + const double cylHeight(0.0002); + // One object + Object_sptr pixelShape = createCappedCylinder(cylRadius, cylHeight, V3D(0.0,-cylHeight/2.0,0.0), V3D(0.,1.0,0.), "pixel-shape"); + + for (int banknum=1; banknum <= num_banks; banknum++) + { + //Make a new bank + std::ostringstream bankname; + bankname << "bank" << banknum; + + RectangularDetector * bank = new RectangularDetector(bankname.str()); + bank->initialize(pixelShape, + pixels, 0.0, pixelSpacing, + pixels, 0.0, pixelSpacing, + banknum*pixels*pixels, true, pixels); + + // Mark them all as detectors + for (int x=0; x detector = bank->getAtXY(x,y); + if (detector) + //Mark it as a detector (add to the instrument cache) + testInst->markAsDetector(detector.get()); + } + + testInst->add(bank); + bank->setPos(V3D(0.0, 0.0, 5.0*banknum)); + } + + //Define a source component + ObjComponent *source = new ObjComponent("moderator", Object_sptr(new Object), testInst.get()); + source->setPos(V3D(0.0, 0.0, -10.)); + testInst->add(source); + testInst->markAsSource(source); + + // Define a sample as a simple sphere + Object_sptr sampleSphere = createSphere(0.001, V3D(0.0, 0.0, 0.0), "sample-shape"); + ObjComponent *sample = new ObjComponent("sample", sampleSphere, testInst.get()); + testInst->setPos(0.0, 0.0, 0.0); + testInst->add(sample); + testInst->markAsSamplePos(sample); + + return testInst; + } + + //---------------------------------------------------------------------------------------------- + /** + * Create a capped cylinder object + */ + Object_sptr CreateSampleWorkspace::createCappedCylinder(double radius, double height, const V3D & baseCentre, const V3D & axis, const std::string & id) + { + std::ostringstream xml; + xml << "" + << "" + << "" + << "" + << "" + << ""; + + ShapeFactory shapeMaker; + return shapeMaker.createShape(xml.str()); + } + + //---------------------------------------------------------------------------------------------- + + /** + * Create a sphere object + */ + Object_sptr CreateSampleWorkspace::createSphere(double radius, const V3D & centre, const std::string & id) + { + ShapeFactory shapeMaker; + std::ostringstream xml; + xml << "" + << "" + << "" + << ""; + return shapeMaker.createShape(xml.str()); + } + +} // namespace Algorithms +} // namespace Mantid \ No newline at end of file diff --git a/Code/Mantid/Framework/Algorithms/test/CreateSampleWorkspaceTest.h b/Code/Mantid/Framework/Algorithms/test/CreateSampleWorkspaceTest.h new file mode 100644 index 000000000000..63890427e91c --- /dev/null +++ b/Code/Mantid/Framework/Algorithms/test/CreateSampleWorkspaceTest.h @@ -0,0 +1,237 @@ +#ifndef MANTID_ALGORITHMS_CREATESAMPLEWORKSPACETEST_H_ +#define MANTID_ALGORITHMS_CREATESAMPLEWORKSPACETEST_H_ + +#include + +#include "MantidAlgorithms/CreateSampleWorkspace.h" +#include "MantidDataObjects/Workspace2D.h" +#include "MantidDataObjects/EventWorkspace.h" + +using Mantid::Algorithms::CreateSampleWorkspace; +using namespace Mantid::Kernel; +using namespace Mantid::API; +using namespace Mantid::Geometry; +using namespace Mantid::DataObjects; + +class CreateSampleWorkspaceTest : public CxxTest::TestSuite +{ +public: + // This pair of boilerplate methods prevent the suite being created statically + // This means the constructor isn't called when running other tests + static CreateSampleWorkspaceTest *createSuite() { return new CreateSampleWorkspaceTest(); } + static void destroySuite( CreateSampleWorkspaceTest *suite ) { delete suite; } + + + void test_Init() + { + CreateSampleWorkspace alg; + TS_ASSERT_THROWS_NOTHING( alg.initialize() ) + TS_ASSERT( alg.isInitialized() ) + } + + MatrixWorkspace_sptr createSampleWorkspace(std::string outWSName, std::string wsType = "", std::string function = "", + std::string userFunction = "", int numBanks = 2, int bankPixelWidth = 10, int numEvents = 1000, bool isRandom = false, + std::string xUnit = "TOF", double xMin = 0.0, double xMax = 20000.0, double binWidth = 200.0) + { + + CreateSampleWorkspace alg; + TS_ASSERT_THROWS_NOTHING( alg.initialize() ); + TS_ASSERT( alg.isInitialized() ); + alg.setPropertyValue("OutputWorkspace", outWSName); + if (!wsType.empty()) TS_ASSERT_THROWS_NOTHING( alg.setPropertyValue("WorkspaceType", wsType) ); + if (!function.empty()) TS_ASSERT_THROWS_NOTHING( alg.setPropertyValue("Function", function) ); + if (!userFunction.empty()) TS_ASSERT_THROWS_NOTHING( alg.setPropertyValue("UserDefinedFunction", userFunction) ); + if (numBanks != 2) TS_ASSERT_THROWS_NOTHING( alg.setProperty("NumBanks", numBanks) ); + if (bankPixelWidth != 10) TS_ASSERT_THROWS_NOTHING( alg.setProperty("BankPixelWidth", bankPixelWidth) ); + if (numEvents != 1000) TS_ASSERT_THROWS_NOTHING( alg.setProperty("NumEvents", numEvents) ); + TS_ASSERT_THROWS_NOTHING( alg.setProperty("Random", isRandom) ); + if (xUnit!="TOF") TS_ASSERT_THROWS_NOTHING( alg.setPropertyValue("XUnit", xUnit) ); + if (xMin != 0.0) TS_ASSERT_THROWS_NOTHING( alg.setProperty("XMin", xMin) ); + if (xMax != 20000.0) TS_ASSERT_THROWS_NOTHING( alg.setProperty("XMax", xMax) ); + if (binWidth != 200.0) TS_ASSERT_THROWS_NOTHING( alg.setProperty("BinWidth", binWidth) ); + + TS_ASSERT_THROWS_NOTHING( alg.execute(); ); + TS_ASSERT( alg.isExecuted() ); + + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws; + TS_ASSERT_THROWS_NOTHING( ws = AnalysisDataService::Instance().retrieveWS(outWSName) ); + TS_ASSERT(ws); + + //check the basics + int numBins = static_cast((xMax-xMin)/binWidth); + int numHist = numBanks * bankPixelWidth * bankPixelWidth; + TS_ASSERT_EQUALS(ws->getNumberHistograms(),numHist); + TS_ASSERT_EQUALS(ws->blocksize(),numBins); + + TS_ASSERT_EQUALS(ws->getAxis(0)->unit()->unitID(), xUnit); + TS_ASSERT_EQUALS(ws->readX(0)[0], xMin); + if (ws->blocksize()==numBins) + { + TS_ASSERT_DELTA(ws->readX(0)[numBins], xMax,binWidth); + } + + if (wsType == "Event") + { + EventWorkspace_sptr ews = boost::dynamic_pointer_cast(ws); + TS_ASSERT(ews); + } + + return ws; + } + + void test_histogram_defaults() + { + // Name of the output workspace. + std::string outWSName("CreateSampleWorkspaceTest_OutputWS"); + + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws = createSampleWorkspace(outWSName); + if (!ws) return; + TS_ASSERT_DELTA(ws->readY(0)[20], 0.3,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[40], 0.3,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[50], 10.3,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[60], 0.3,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[80], 0.3,0.0001); + + // Remove workspace from the data service. + AnalysisDataService::Instance().remove(outWSName); + } + + void test_event_defaults() + { + // Name of the output workspace. + std::string outWSName("CreateSampleWorkspaceTest_OutputWS_event"); + + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws = createSampleWorkspace(outWSName, "Event"); + if (!ws) return; + TS_ASSERT_DELTA(ws->readY(0)[20], 30,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[40], 30,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[50], 1030,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[60], 30,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[80], 30,0.0001); + + // Remove workspace from the data service. + AnalysisDataService::Instance().remove(outWSName); + } + + void test_event_MoreBanksMoreDetectorsLessEvents() + { + // Name of the output workspace. + std::string outWSName("CreateSampleWorkspaceTest_OutputWS_MoreBanksMoreDetectors"); + + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws = createSampleWorkspace(outWSName, "Event","","",4,30,100); + if (!ws) return; + + // Remove workspace from the data service. + AnalysisDataService::Instance().remove(outWSName); + } + + void test_histo_Multiple_Peaks() + { + // Name of the output workspace. + std::string outWSName("CreateSampleWorkspaceTest_OutputWS_Multiple_Peaks"); + + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws = createSampleWorkspace(outWSName, "Histogram","Multiple Peaks"); + if (!ws) return; + TS_ASSERT_DELTA(ws->readY(0)[20], 0.3,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[40], 0.3,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[60], 8.3,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[80], 0.3,0.0001); + + // Remove workspace from the data service. + AnalysisDataService::Instance().remove(outWSName); + } + + void test_event_Flat_background() + { + // Name of the output workspace. + std::string outWSName("CreateSampleWorkspaceTest_OutputWS_Flat_background"); + + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws = createSampleWorkspace(outWSName, "Event","Flat background"); + if (!ws) return; + TS_ASSERT_DELTA(ws->readY(0)[20], 10.0,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[40], 10.0,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[60], 10.0,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[80], 10.0,0.0001); + + // Remove workspace from the data service. + AnalysisDataService::Instance().remove(outWSName); + } + + void test_event_Exp_Decay() + { + // Name of the output workspace. + std::string outWSName("CreateSampleWorkspaceTest_OutputWS_Exp_Decay"); + + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws = createSampleWorkspace(outWSName, "Event","Exp Decay"); + if (!ws) return; + TS_ASSERT_DELTA(ws->readY(0)[20], 3.0,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[40], 0.0,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[60], 0.0,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[80], 0.0,0.0001); + + // Remove workspace from the data service. + AnalysisDataService::Instance().remove(outWSName); + } + + void test_event_User_Defined() + { + // Name of the output workspace. + std::string outWSName("CreateSampleWorkspaceTest_OutputWS_User_Defined"); + std::string myFunc = "name=LinearBackground, A0=0.5;name=Gaussian, PeakCentre=10000, Height=50, Sigma=0.5;name=Gaussian, PeakCentre=1000, Height=80, Sigma=0.5"; + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws = createSampleWorkspace(outWSName, "Histogram","User Defined",myFunc); + if (!ws) return; + TS_ASSERT_DELTA(ws->readY(0)[5], 80.5,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[20], 0.5,0.0001); + TS_ASSERT_DELTA(ws->readY(0)[50], 50.5,0.0001); + + // Remove workspace from the data service. + AnalysisDataService::Instance().remove(outWSName); + } + + void test_histogram_random() + { + // Name of the output workspace. + std::string outWSName("CreateSampleWorkspaceTest_Hist_random"); + + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws = createSampleWorkspace(outWSName); + if (!ws) return; + TS_ASSERT_DELTA(ws->readY(0)[20], 0.3,0.5); + TS_ASSERT_DELTA(ws->readY(0)[40], 0.3,0.5); + TS_ASSERT_DELTA(ws->readY(0)[50], 10.3,0.5); + TS_ASSERT_DELTA(ws->readY(0)[60], 0.3,0.5); + TS_ASSERT_DELTA(ws->readY(0)[80], 0.3,0.5); + + // Remove workspace from the data service. + AnalysisDataService::Instance().remove(outWSName); + } + + void test_event_random() + { + // Name of the output workspace. + std::string outWSName("CreateSampleWorkspaceTest_event_random"); + + // Retrieve the workspace from data service. TODO: Change to your desired type + MatrixWorkspace_sptr ws = createSampleWorkspace(outWSName,"Event"); + if (!ws) return; + TS_ASSERT_DELTA(ws->readY(0)[20], 30,50); + TS_ASSERT_DELTA(ws->readY(0)[40], 30,50); + TS_ASSERT_DELTA(ws->readY(0)[50], 1030,50); + TS_ASSERT_DELTA(ws->readY(0)[60], 30,50); + TS_ASSERT_DELTA(ws->readY(0)[80], 3,50); + + // Remove workspace from the data service. + AnalysisDataService::Instance().remove(outWSName); + } +}; + + +#endif /* MANTID_ALGORITHMS_CREATESAMPLEWORKSPACETEST_H_ */ \ No newline at end of file From 5b185f34ebaf734806e60a7413adc7f32474c143 Mon Sep 17 00:00:00 2001 From: Nick Draper Date: Tue, 27 May 2014 12:37:32 +0100 Subject: [PATCH 055/126] re #9525 resolve warnings --- .../inc/MantidAlgorithms/CreateSampleWorkspace.h | 2 +- .../Algorithms/src/CreateSampleWorkspace.cpp | 14 +++++++------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h index 706fcb676c84..0eedf4661211 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h @@ -53,7 +53,7 @@ namespace Algorithms DataObjects::EventWorkspace_sptr createEventWorkspace(int numPixels, int numBins, int numEvents, double x0, double binDelta, int start_at_pixelID, Geometry::Instrument_sptr inst, const std::string& functionString, bool isRandom); API::MatrixWorkspace_sptr createHistogramWorkspace(int numPixels, - int numBins, int numEvents, double x0, double binDelta, int start_at_pixelID, Geometry::Instrument_sptr inst, const std::string& functionString, bool isRandom); + int numBins, double x0, double binDelta, int start_at_pixelID, Geometry::Instrument_sptr inst, const std::string& functionString, bool isRandom); Geometry::Instrument_sptr createTestInstrumentRectangular(int num_banks, int pixels, double pixelSpacing = 0.008); Geometry::Object_sptr createCappedCylinder(double radius, double height, const Kernel::V3D & baseCentre, const Kernel::V3D & axis, const std::string & id); Geometry::Object_sptr createSphere(double radius, const Kernel::V3D & centre, const std::string & id); diff --git a/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp index cfd117cedf88..b481522d4d1e 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp @@ -3,7 +3,7 @@ Creates sample workspaces for usage examples and other situations. You can select a predefined function for the data or enter your own by selecting User Defined in the drop down. -The data will be the same for each spectrum, and is defined by the function selected, and a little noise if Random is selected. +The data will be the same for each spectrum, and is defined by the function selected, and a little noise if Random is selected. All values are taken converted to absolute values at present so negative values will become positive. For event workspaces the intensity of the graph will be affected by the number of events selected. Here is an example of a user defined formula containing two peaks and a background. @@ -178,7 +178,7 @@ namespace Algorithms } else { - ws = createHistogramWorkspace(numBanks*bankPixelWidth*bankPixelWidth, num_bins,numEvents, + ws = createHistogramWorkspace(numBanks*bankPixelWidth*bankPixelWidth, num_bins, xMin, binWidth, bankPixelWidth*bankPixelWidth, inst, functionString, isRandom); } @@ -205,7 +205,7 @@ namespace Algorithms /** Create histogram workspace */ MatrixWorkspace_sptr CreateSampleWorkspace::createHistogramWorkspace(int numPixels, - int numBins, int numEvents, double x0, double binDelta, + int numBins, double x0, double binDelta, int start_at_pixelID, Geometry::Instrument_sptr inst, const std::string& functionString, bool isRandom) { @@ -230,7 +230,7 @@ namespace Algorithms retVal->initialize(numPixels,numBins+1,numBins); retVal->setInstrument(inst); - for (size_t wi=0; wi(numPixels); wi++) { retVal->setX(wi,x); retVal->setData(wi,y,e); @@ -297,7 +297,7 @@ namespace Algorithms int eventsInBin = static_cast(yValues[i]); for (int q=0; qnextValue()*3,600.0); + DateAndTime pulseTime = run_start + (m_randGen->nextValue()*3600.0); el += TofEvent((i+m_randGen->nextValue())*binDelta, pulseTime); } } @@ -341,7 +341,7 @@ namespace Algorithms std::vector results; results.resize(xSize); - for(int x=0; xnextValue()-0.5)*noiseScale); } //no negative values please - it messes up the error calculation - results[x] = abs(results[x]); + results[x] = fabs(results[x]); } return results; } From a0eb1b2111df3bddac03982a24fa2488527dd1ae Mon Sep 17 00:00:00 2001 From: Nick Draper Date: Tue, 27 May 2014 12:57:54 +0100 Subject: [PATCH 056/126] re #9525 resolve warnings --- .../Framework/Algorithms/test/CreateSampleWorkspaceTest.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/Framework/Algorithms/test/CreateSampleWorkspaceTest.h b/Code/Mantid/Framework/Algorithms/test/CreateSampleWorkspaceTest.h index 63890427e91c..b0cb8a89fc05 100644 --- a/Code/Mantid/Framework/Algorithms/test/CreateSampleWorkspaceTest.h +++ b/Code/Mantid/Framework/Algorithms/test/CreateSampleWorkspaceTest.h @@ -66,7 +66,7 @@ class CreateSampleWorkspaceTest : public CxxTest::TestSuite TS_ASSERT_EQUALS(ws->getAxis(0)->unit()->unitID(), xUnit); TS_ASSERT_EQUALS(ws->readX(0)[0], xMin); - if (ws->blocksize()==numBins) + if (ws->blocksize()==static_cast(numBins)) { TS_ASSERT_DELTA(ws->readX(0)[numBins], xMax,binWidth); } From 8af1ffe4b1df31b2bf21333223b428e0745a08d0 Mon Sep 17 00:00:00 2001 From: Wenduo Zhou Date: Tue, 27 May 2014 10:08:16 -0400 Subject: [PATCH 057/126] Modifed default value of properties. Refs #6999. --- .../MantidAlgorithms/GenerateEventsFilter.h | 4 ++-- .../Algorithms/src/GenerateEventsFilter.cpp | 19 ++++++++++++------- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GenerateEventsFilter.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GenerateEventsFilter.h index 7b12d7f23dfa..62ab4f661566 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GenerateEventsFilter.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GenerateEventsFilter.h @@ -89,8 +89,8 @@ namespace Algorithms void processSingleValueFilter(double minvalue, double maxvalue, bool filterincrease, bool filterdecrease); - void processMultipleValueFilters(double minvalue, double maxvalue, - bool filterincrease, bool filterdecrease); + void processMultipleValueFilters(double minvalue, double valueinterval, double maxvalue, + bool filterincrease, bool filterdecrease); void makeFilterByValue(Kernel::TimeSplitterType& split, double min, double max, double TimeTolerance, bool centre, bool filterIncrease, bool filterDecrease, Kernel::DateAndTime startTime, Kernel::DateAndTime stopTime, diff --git a/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp b/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp index 6bf4de2af6bf..f41d4cc5035c 100644 --- a/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp @@ -133,8 +133,8 @@ namespace Algorithms "Events at or after this time are filtered out."); // Split by time (only) in steps - declareProperty("TimeInterval", -1.0, - "Length of the time splices if filtered in time only."); + declareProperty("TimeInterval", EMPTY_DBL(), + "Length of the time splices if filtered in time only."); setPropertySettings("TimeInterval", new VisibleWhenProperty("LogName", IS_EQUAL_TO, "")); @@ -440,20 +440,26 @@ namespace Algorithms { double timeinterval = this->getProperty("TimeInterval"); + bool singleslot = false; + if (timeinterval == EMPTY_DBL()) singleslot = true; + // Progress int64_t totaltime = m_stopTime.totalNanoseconds()-m_startTime.totalNanoseconds(); - int64_t timeslot = 0; - if (timeinterval <= 0.0) + if (singleslot) { int wsindex = 0; + // Default and thus just one interval std::stringstream ss; ss << "Time Interval From " << m_startTime << " to " << m_stopTime; + addNewTimeFilterSplitter(m_startTime, m_stopTime, wsindex, ss.str()); } else { + int64_t timeslot = 0; + // Explicitly N time intervals int64_t deltatime_ns = static_cast(timeinterval*m_timeUnitConvertFactorToNS); @@ -590,7 +596,7 @@ namespace Algorithms else { // Generate filters for a series of log value - processMultipleValueFilters(minvalue, maxvalue, filterIncrease, filterDecrease); + processMultipleValueFilters(minvalue, deltaValue, maxvalue, filterIncrease, filterDecrease); } } else @@ -699,12 +705,11 @@ namespace Algorithms * @param filterincrease :: if true, log value in the increasing curve should be included; * @param filterdecrease :: if true, log value in the decreasing curve should be included; */ - void GenerateEventsFilter::processMultipleValueFilters(double minvalue, double maxvalue, + void GenerateEventsFilter::processMultipleValueFilters(double minvalue, double valueinterval, double maxvalue, bool filterincrease, bool filterdecrease) { // Read more input - double valueinterval = this->getProperty("LogValueInterval"); if (valueinterval <= 0) throw std::invalid_argument("Multiple values filter must have LogValueInterval larger than ZERO."); double valuetolerance = this->getProperty("LogValueTolerance"); From a2c37bbd947a00ce414e7f005e4d2fd3cb11a04c Mon Sep 17 00:00:00 2001 From: Wenduo Zhou Date: Tue, 27 May 2014 10:20:01 -0400 Subject: [PATCH 058/126] Fixed doxygen error. Refs #6999. --- Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp b/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp index f41d4cc5035c..50330ee08222 100644 --- a/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp @@ -701,6 +701,7 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- /** Generate filters from multiple values * @param minvalue :: minimum value of the allowed log value; + * @param valueinterval :: step of the log value for a series of filter * @param maxvalue :: maximum value of the allowed log value; * @param filterincrease :: if true, log value in the increasing curve should be included; * @param filterdecrease :: if true, log value in the decreasing curve should be included; From dfae6838887624deca01b217b8ef14bb32f240ca Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Tue, 27 May 2014 17:48:50 +0100 Subject: [PATCH 059/126] Add in html logo and tweak css Refs #9521 --- Code/Mantid/docs/source/_static/custom.css | 5 +++++ Code/Mantid/docs/source/conf.py | 16 +++++----------- 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/Code/Mantid/docs/source/_static/custom.css b/Code/Mantid/docs/source/_static/custom.css index b21258686d13..1ca764fa6eab 100644 --- a/Code/Mantid/docs/source/_static/custom.css +++ b/Code/Mantid/docs/source/_static/custom.css @@ -5,6 +5,11 @@ /*-------------------- $NAV --------------------*/ .navbar-version { display: none; } +.navbar-brand { + margin-bottom: 15px; + width: 190px; + height: 100px; +} /*-------------------- $LINKS --------------------*/ diff --git a/Code/Mantid/docs/source/conf.py b/Code/Mantid/docs/source/conf.py index 18bc986720b8..dc8828ce39c6 100644 --- a/Code/Mantid/docs/source/conf.py +++ b/Code/Mantid/docs/source/conf.py @@ -9,7 +9,7 @@ # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. -sys.path.insert(0, os.path.abspath('../sphinxext/mantiddoc/directives')) +sys.path.insert(0, os.path.abspath('../sphinxext')) # -- General configuration ------------------------------------------------ @@ -20,16 +20,10 @@ 'sphinx.ext.pngmath', 'sphinx.ext.autodoc', 'sphinx.ext.intersphinx', - 'summary', - 'aliases', - 'properties', - 'categories', - 'algorithm' + 'sphinx.ext.doctest', + 'mantiddoc.directives' ] -# The location of the root of the Mantid images folder. -mantid_images = "/" + os.path.abspath('_static/images') + "/" - # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] @@ -66,7 +60,7 @@ # custom.css rather than here. html_theme_options = { # Navigation bar title. - 'navbar_title': "mantidproject", + 'navbar_title': " ", # Tab name for entire site. 'navbar_site_name': "Mantid", # Add links to the nav bar. Second param of tuple is true to create absolute url. @@ -93,7 +87,7 @@ # The name of an image file (relative to this directory) to place at the top # of the sidebar. -#html_logo = None +html_logo = os.path.relpath('../../Images/Mantid_Logo_Transparent.png') # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, From ca642c60af0897107d209556799f34e4744a067d Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Tue, 27 May 2014 17:50:25 +0100 Subject: [PATCH 060/126] Require versioned algorithm files Implements a test for a simple redirect system to the highest version Refs #9521 --- .../mantiddoc/directives/algorithm.py | 35 ++- .../sphinxext/mantiddoc/directives/aliases.py | 9 +- .../sphinxext/mantiddoc/directives/base.py | 34 ++- .../mantiddoc/directives/categories.py | 279 ++++++++++++++++-- .../mantiddoc/directives/properties.py | 14 +- .../sphinxext/mantiddoc/directives/summary.py | 9 +- .../sphinxext/mantiddoc/tools/screenshot.py | 9 +- 7 files changed, 333 insertions(+), 56 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index 50382f959978..26726079b1b3 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -1,6 +1,8 @@ from base import BaseDirective import os +REDIRECT_TEMPLATE = "redirect.html" + class AlgorithmDirective(BaseDirective): """ @@ -8,19 +10,19 @@ class AlgorithmDirective(BaseDirective): and a screenshot of the algorithm to an rst file. """ - required_arguments, optional_arguments = 1, 0 + required_arguments, optional_arguments = 0, 0 def run(self): """ Called by Sphinx when the ..algorithm:: directive is encountered """ - algorithm_name = str(self.arguments[0]) + algorithm_name, version = self._algorithm_name_and_version() # Seperate methods for each unique piece of functionality. reference = self._make_reference_link(algorithm_name) title = self._make_header(algorithm_name, True) toc = self._make_local_toc() - imgpath = self._create_screenshot(algorithm_name) + imgpath = self._create_screenshot(algorithm_name, version) screenshot = self._make_screenshot_link(algorithm_name, imgpath) return self._insert_rest(reference + title + screenshot + toc) @@ -36,20 +38,21 @@ def _make_reference_link(self, algorithm_name): Returns: str: A ReST formatted reference. """ - return ".. _%s:\n" % algorithm_name + return ".. _algorithm|%s:\n" % algorithm_name def _make_local_toc(self): return ".. contents:: Table of Contents\n :local:\n" - def _create_screenshot(self, algorithm_name): + def _create_screenshot(self, algorithm_name, version): """ Creates a screenshot for the named algorithm in an "images/screenshots" subdirectory of the currently processed document - The file will be named "algorithmname_dlg.png", e.g. Rebin_dlg.png + The file will be named "algorithmname-vX_dlg.png", e.g. Rebin-v1_dlg.png Args: algorithm_name (str): The name of the algorithm. + version (int): The version of the algorithm Returns: str: The full path to the created image @@ -62,7 +65,7 @@ def _create_screenshot(self, algorithm_name): os.makedirs(screenshots_dir) try: - imgpath = algorithm_screenshot(algorithm_name, screenshots_dir) + imgpath = algorithm_screenshot(algorithm_name, screenshots_dir, version=version) except Exception, exc: env.warn(env.docname, "Unable to generate screenshot for '%s' - %s" % (algorithm_name, str(exc))) imgpath = os.path.join(screenshots_dir, "failed_dialog.png") @@ -85,7 +88,7 @@ def _make_screenshot_link(self, algorithm_name, img_path): """ format_str = ".. figure:: %s\n"\ " :class: screenshot\n\n"\ - " %s\n" + " %s\n\n" filename = os.path.split(img_path)[1] path = "/images/screenshots/" + filename @@ -111,6 +114,18 @@ def _screenshot_directory(self, env): ############################################################################################################ +def html_collect_pages(app): + """ + Write out unversioned algorithm pages that redirect to the highest version of the algorithm + """ + name = "algorithms/Rebin" + context = {"name" : "Rebin", "target" : "Rebin-v1.html"} + template = REDIRECT_TEMPLATE + + return [(name, context, template)] + +############################################################################################################ + def setup(app): """ Setup the directives when the extension is activated @@ -119,3 +134,7 @@ def setup(app): app: The main Sphinx application object """ app.add_directive('algorithm', AlgorithmDirective) + + # connect event html collection to handler + app.connect("html-collect-pages", html_collect_pages) + diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py index fed689708822..494181945a7c 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py @@ -7,24 +7,25 @@ class AliasesDirective(BaseDirective): Obtains the aliases for a given algorithm based on it's name. """ - required_arguments, optional_arguments = 1, 0 + required_arguments, optional_arguments = 0, 0 def run(self): """ Called by Sphinx when the ..aliases:: directive is encountered. """ title = self._make_header("Aliases") - alias = self._get_alias(str(self.arguments[0])) + alias = self._get_alias() return self._insert_rest(title + alias) - def _get_alias(self, algorithm_name): + def _get_alias(self): """ Return the alias for the named algorithm. Args: algorithm_name (str): The name of the algorithm to get the alias for. """ - alg = self._create_mantid_algorithm(algorithm_name) + name, version = self._algorithm_name_and_version() + alg = self._create_mantid_algorithm(name, version) return "This algorithm is also known as: " + "**" + alg.alias() + "**" diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py index d3e911ed8b7e..349b1fede17b 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py @@ -1,6 +1,6 @@ from docutils import statemachine from docutils.parsers.rst import Directive - +import re class BaseDirective(Directive): @@ -11,21 +11,40 @@ class BaseDirective(Directive): has_content = True final_argument_whitespace = True - def _make_header(self, name, title=False): + alg_docname_re = re.compile(r'^([A-Z][a-zA-Z0-9]+)-v([0-9][0-9]*)$') + + def _algorithm_name_and_version(self): + """ + Returns the name and version of an algorithm based on the name of the + document. The expected name of the document is "AlgorithmName-v?", which + is the name of the file with the extension removed + """ + env = self.state.document.settings.env + # env.docname includes path, using forward slashes, from root of documentation directory + docname = env.docname.split("/")[-1] + match = self.alg_docname_re.match(docname) + if not match or len(match.groups()) != 2: + raise RuntimeError("Document filename '%s.rst' does not match the expected format: AlgorithmName-vX.rst" % docname) + + grps = match.groups() + return (str(grps[0]), int(grps[1])) + + def _make_header(self, name, pagetitle=False): """ Makes a ReStructuredText title from the algorithm's name. Args: algorithm_name (str): The name of the algorithm to use for the title. - title (bool): If True, line is inserted above & below algorithm name. + pagetitle (bool): If True, line is inserted above & below algorithm name. Returns: str: ReST formatted header with algorithm_name as content. """ - line = "\n" + "-" * len(name) + "\n" - if title: + if pagetitle: + line = "\n" + "=" * len(name) + "\n" return line + name + line else: + line = "\n" + "-" * len(name) + "\n" return name + line def _insert_rest(self, text): @@ -41,17 +60,18 @@ def _insert_rest(self, text): self.state_machine.insert_input(statemachine.string2lines(text), "") return [] - def _create_mantid_algorithm(self, algorithm_name): + def _create_mantid_algorithm(self, algorithm_name, version): """ Create and initializes a Mantid algorithm. Args: algorithm_name (str): The name of the algorithm to use for the title. + version (int): Version of the algorithm to create Returns: algorithm: An instance of a Mantid algorithm. """ from mantid.api import AlgorithmManager - alg = AlgorithmManager.createUnmanaged(algorithm_name) + alg = AlgorithmManager.createUnmanaged(algorithm_name, version) alg.initialize() return alg diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py index 0a4d147a5e43..30deab430ec8 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py @@ -1,47 +1,282 @@ +""" + Provides directives for dealing with category pages. + + While parsing the directives a list of the categories and associated pages/subcategories + is tracked. When the final set of html pages is collected, a processing function + creates "index" pages that lists the contents of each category. The display of each + "index" page is controlled by a jinja2 template. +""" from base import BaseDirective +CATEGORY_INDEX_TEMPLATE = "category.html" +# relative to the "root" directory +CATEGORIES_HTML_DIR = "categories" -class CategoriesDirective(BaseDirective): +class LinkItem(object): + """ + Defines a linkable item with a name and html reference + """ + # Name displayed on listing page + name = None + # html link + link = None + + def __init__(self, name, env): + """ + Arguments: + env (Sphinx.BuildEnvironment): The current environment processing object + """ + self.name = str(name) + + rel_path = env.docname # no suffix + # Assumes the link is for the current document and that the + # page that will use this reference is in a single + # subdirectory from root + self.link = "../%s.html" % rel_path + + def __eq__(self, other): + """ + Define comparison for two objects as the comparison of their names + + Arguments: + other (PageRef): Another PageRef object to compare + """ + return self.name == other.name + + def __hash__(self): + return hash(self.name) + + def __repr__(self): + return self.name + + def html_link(self): + """ + Returns a link for use as a href to refer to this document from a + categories page. It assumes that the category pages are in a subdirectory + of the root and that the item to be referenced is in the algorithms directory + under the root. + + Returns: + str: A string containing the link + """ + return self.link +# endclass +class PageRef(LinkItem): """ - Obtains the categories for a given algorithm based on it's name. + Store details of a single page reference """ - required_arguments, optional_arguments = 1, 0 + def __init__(self, name, env): + super(PageRef, self).__init__(name, env) + +#endclass + +class Category(LinkItem): + """ + Store information about a single category + """ + # Collection of PageRef objects that link to members of the category + pages = None + # Collection of PageRef objects that form subcategories of this category + subcategories = None + + def __init__(self, name, env): + super(Category, self).__init__(name, env) + + # override default link + self.link = "../categories/%s.html" % name + self.pages = set([]) + self.subcategories = set([]) + +#endclass + +class CategoriesDirective(BaseDirective): + """ + Records the page as part of the given categories. Index pages for each + category are then automatically created after all pages are collected + together. + + Subcategories can be given using the "\\" separator, e.g. Algorithms\\Transforms + """ + + # requires at least 1 category + required_arguments = 1 + # it can be in many categories and we put an arbitrary upper limit here + optional_arguments = 25 def run(self): """ - Called by Sphinx when the ..categories:: directive is encountered. + Called by Sphinx when the defined directive is encountered. """ - categories = self._get_categories(str(self.arguments[0])) - return self._insert_rest("\n" + categories) + categories = self._get_categories_list() + display_name = self._get_display_name() + links = self._create_links_and_track(display_name, categories) + + return self._insert_rest("\n" + links) - def _get_categories(self, algorithm_name): + def _get_categories_list(self): """ - Return the categories for the named algorithm. + Returns a list of the category strings + + Returns: + list: A list of strings containing the required categories + """ + # Simply return all of the arguments as strings + return self.arguments + + def _get_display_name(self): + """ + Returns the name of the item as it should appear in the category + """ + env = self.state.document.settings.env + # env.docname returns relative path from doc root. Use name after last "/" separator + return env.docname.split("/")[-1] + + def _create_links_and_track(self, page_name, category_list): + """ + Return the reST text required to link to the given + categories. As the categories are parsed they are + stored within the current environment for use in the + "html_collect_pages" function. Args: - algorithm_name (str): The name of the algorithm. + page_name (str): Name to use to refer to this page on the category index page + category_list (list): List of category strings + + Returns: + str: A string of reST that will define the links """ - alg = self._create_mantid_algorithm(algorithm_name) + env = self.state.document.settings.env + if not hasattr(env, "categories"): + env.categories = {} + + link_rst = "" + ncategs = 0 + for item in category_list: + if r"\\" in item: + categs = item.split(r"\\") + else: + categs = [item] + # endif - # Create a list containing each category. - categories = alg.category().split("\\") + parent = None + for index, categ_name in enumerate(categs): + if categ_name not in env.categories: + category = Category(categ_name, env) + env.categories[categ_name] = category + else: + category = env.categories[categ_name] + #endif - if len(categories) >= 2: - # Add a cross reference for each catagory. - links = (":ref:`%s` | " * len(categories)) % tuple(categories) - # Remove last three characters to remove last | - return ("`Categories: `_ " + links)[:-3] + category.pages.add(PageRef(page_name, env)) + if index > 0: # first is never a child + parent.subcategories.add(Category(categ_name, env)) + #endif + + link_rst += "`%s <../%s/%s.html>`_ | " % (categ_name, CATEGORIES_HTML_DIR, categ_name) + ncategs += 1 + parent = category + # endfor + # endfor + + link_rst = "**%s**: " + link_rst.rstrip(" | ") # remove final separator + if ncategs == 1: + link_rst = link_rst % "Category" else: - return "`Category: `_ :ref:`%s`" % (categories) + link_rst = link_rst % "Categories" + #endif + return link_rst + #end def -def setup(app): +#--------------------------------------------------------------------------------- + +class AlgorithmCategoryDirective(CategoriesDirective): """ - Setup the directives when the extension is activated + Supports the "algm_categories" directive that takes a single + argument and pulls the categories from an algorithm object. - Args: - app: The main Sphinx application object + In addition to adding the named page to the requested category, it + also appends it to the "Algorithms" category """ + # requires at least 1 argument + required_arguments = 0 + # no other arguments + optional_arguments = 0 + + def _get_categories_list(self): + """ + Returns a list of the category strings + + Returns: + list: A list of strings containing the required categories + """ + category_list = ["Algorithms"] + algname, version = self._algorithm_name_and_version() + alg_cats = self._create_mantid_algorithm(algname, version).categories() + for cat in alg_cats: + # double up the category separators so they are not treated as escape characters + category_list.append(cat.replace("\\", "\\\\")) + + return category_list + + def _get_display_name(self): + """ + Returns the name of the item as it should appear in the category + """ + return self._algorithm_name_and_version()[0] + +#--------------------------------------------------------------------------------- + +def html_collect_pages(app): + """ + Callback for the 'html-collect-pages' Sphinx event. Adds category + pages + a global Categories.html page that lists the pages included. + + Function returns an iterable (pagename, context, html_template), + where context is a dictionary defining the content that will fill the template + + Arguments: + app: A Sphinx application object + """ + if not hasattr(app.builder.env, "categories"): + return # nothing to do + + for name, context, template in create_category_pages(app): + yield (name, context, template) +# enddef + +def create_category_pages(app): + """ + Returns an iterable of (category_name, context, "category.html") + + Arguments: + app: A Sphinx application object + """ + env = app.builder.env + + # jinja2 html template + template = CATEGORY_INDEX_TEMPLATE + + categories = env.categories + for name, category in categories.iteritems(): + context = {} + context["title"] = category.name + # sort subcategories & pages by first letter + context["subcategories"] = sorted(category.subcategories, key = lambda x: x.name[0]) + context["pages"] = sorted(category.pages, key = lambda x: x.name[0]) + + yield (CATEGORIES_HTML_DIR + "/" + name, context, template) +# enddef + +#------------------------------------------------------------------------------ +def setup(app): + # Add categories directive app.add_directive('categories', CategoriesDirective) + # Add algm_categories directive + app.add_directive('algm_categories', AlgorithmCategoryDirective) + + # connect event html collection to handler + app.connect("html-collect-pages", html_collect_pages) + diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py index 2e3b67a92e3c..440e11d4bd7a 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py @@ -7,25 +7,23 @@ class PropertiesDirective(BaseDirective): Outputs the given algorithm's properties into a ReST formatted table. """ # Accept one required argument and no optional arguments. - required_arguments, optional_arguments = 1, 0 + required_arguments, optional_arguments = 0, 0 def run(self): """ Called by Sphinx when the ..properties:: directive is encountered. """ - alg_name = str(self.arguments[0]) title = self._make_header("Properties") - properties_table = self._populate_properties_table(alg_name) + properties_table = self._populate_properties_table() return self._insert_rest(title + properties_table) - def _populate_properties_table(self, algorithm_name): + def _populate_properties_table(self): """ Populates the ReST table with algorithm properties. - - Args: - algorithm_name (str): The name of the algorithm. """ - alg = self._create_mantid_algorithm(algorithm_name) + name, version = self._algorithm_name_and_version() + + alg = self._create_mantid_algorithm(name, version) alg_properties = alg.getProperties() # Stores each property of the algorithm in a tuple. diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py index 22a8f73c695d..2432a2fc4076 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py @@ -7,24 +7,25 @@ class SummaryDirective(BaseDirective): Obtains the summary for a given algorithm based on it's name. """ - required_arguments, optional_arguments = 1, 0 + required_arguments, optional_arguments = 0, 0 def run(self): """ Called by Sphinx when the ..summary:: directive is encountered. """ title = self._make_header("Summary") - summary = self._get_summary(str(self.arguments[0])) + summary = self._get_summary() return self._insert_rest(title + summary) - def _get_summary(self, algorithm_name): + def _get_summary(self): """ Return the summary for the named algorithm. Args: algorithm_name (str): The name of the algorithm. """ - alg = self._create_mantid_algorithm(algorithm_name) + name, version = self._algorithm_name_and_version() + alg = self._create_mantid_algorithm(name, version) return alg.getWikiSummary() diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py b/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py index 692517d62ec9..67dd69a47775 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py @@ -11,7 +11,7 @@ ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory """ -def algorithm_screenshot(name, directory, ext=".png"): +def algorithm_screenshot(name, directory, version = -1, ext = ".png"): """ Takes a snapshot of an algorithm dialog and saves it as an image named "name_dlg.png" @@ -19,6 +19,7 @@ def algorithm_screenshot(name, directory, ext=".png"): Args: name (str): The name of the algorithm directory (str): An directory path where the image should be saved + version (str): A version of the algorithm to use (default=latest) ext (str): An optional extension (including the period). Default=.png Returns: @@ -29,9 +30,11 @@ def algorithm_screenshot(name, directory, ext=".png"): iface_mgr = mantidqt.MantidQt.API.InterfaceManager() # threadsafe_call required for MantidPlot - dlg = threadsafe_call(iface_mgr.createDialogFromName, name, True) + dlg = threadsafe_call(iface_mgr.createDialogFromName, name, True, None) + + suffix = ("-v%d" % version) if version != -1 else "" + filename = "%s%s_dlg%s" % (name, suffix, ext) - filename = name + "_dlg" + ext img_path = screenshot_to_dir(widget=dlg, filename=filename, screenshot_dir=directory) threadsafe_call(dlg.close) From db26bfe12078e0fad461cb7e0b9e3702223f3879 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Tue, 27 May 2014 17:54:28 +0100 Subject: [PATCH 061/126] Protect screenshot capture if the GUI is not present. Refs #9521 --- Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py b/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py index 67dd69a47775..8d57701f19aa 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/tools/screenshot.py @@ -25,6 +25,10 @@ def algorithm_screenshot(name, directory, version = -1, ext = ".png"): Returns: str: A full path to the image file """ + import mantid + if not mantid.__gui__: + return "NoGUI-ImageNotGenerated.png" + import mantidqtpython as mantidqt from mantidplot import screenshot_to_dir, threadsafe_call From 72808a0405c0eb370d1bd6f58810e3978c7d0a6d Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Tue, 27 May 2014 21:16:59 +0100 Subject: [PATCH 062/126] Forget to add category & redirect templates Refs #9521 --- .../docs/source/_templates/category.html | 42 +++++++++++++++++++ .../docs/source/_templates/redirect.html | 15 +++++++ 2 files changed, 57 insertions(+) create mode 100644 Code/Mantid/docs/source/_templates/category.html create mode 100644 Code/Mantid/docs/source/_templates/redirect.html diff --git a/Code/Mantid/docs/source/_templates/category.html b/Code/Mantid/docs/source/_templates/category.html new file mode 100644 index 000000000000..c78f7644003b --- /dev/null +++ b/Code/Mantid/docs/source/_templates/category.html @@ -0,0 +1,42 @@ +{# Import the theme's layout. #} +{% extends "!layout.html" %} + +{% macro split_to_three_columns(item_list) -%} +{# Split list into 3 columns #} +{# Uses bootstrap col-md-4 for each column along with slice(3) to divide input list #} +{# It currently assumes the items in the list are mantiddoc.directives.categories.PageRef classes #} + +{%- endmacro %} + +{%- block body -%} +

Category: {{ title }}

+ {% if subcategories %} +
+

Subcategories

+ {{ split_to_three_columns(subcategories) }} +
+ {% endif %} + +

Pages

+ {{ split_to_three_columns(pages) }} + +{%- endblock -%} \ No newline at end of file diff --git a/Code/Mantid/docs/source/_templates/redirect.html b/Code/Mantid/docs/source/_templates/redirect.html new file mode 100644 index 000000000000..e73ecf33d325 --- /dev/null +++ b/Code/Mantid/docs/source/_templates/redirect.html @@ -0,0 +1,15 @@ + + + + + + + Page Redirection + + + + If you are not redirected automatically, follow the link to {{ name }} + + \ No newline at end of file From a082fb2675541f88b2d77051c72291136fcc6260 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Tue, 27 May 2014 21:33:55 +0100 Subject: [PATCH 063/126] Track highest versions of algorithms encountered Redirect pages are created that point from a page using the plain name to the highest version page Refs #9521 --- .../mantiddoc/directives/algorithm.py | 34 +++++++++++++++++-- 1 file changed, 31 insertions(+), 3 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index 26726079b1b3..c29a49b32775 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -17,6 +17,7 @@ def run(self): Called by Sphinx when the ..algorithm:: directive is encountered """ algorithm_name, version = self._algorithm_name_and_version() + self._track_algorithm(algorithm_name, version) # Seperate methods for each unique piece of functionality. reference = self._make_reference_link(algorithm_name) @@ -27,6 +28,26 @@ def run(self): return self._insert_rest(reference + title + screenshot + toc) + def _track_algorithm(self, name, version): + """ + Keep a track of the highest versions of algorithms encountered + + Arguments: + name (str): Name of the algorithm + version (int): Integer version number + """ + env = self.state.document.settings.env + if not hasattr(env, "algorithm"): + env.algorithms = {} + #endif + algorithms = env.algorithms + if name in algorithms: + prev_version = algorithms[name][1] + if version > prev_version: + algorithms[name][1] = version + else: + algorithms[name] = (name, version) + def _make_reference_link(self, algorithm_name): """ Outputs a reference to the top of the algorithm's rst @@ -118,11 +139,18 @@ def html_collect_pages(app): """ Write out unversioned algorithm pages that redirect to the highest version of the algorithm """ - name = "algorithms/Rebin" - context = {"name" : "Rebin", "target" : "Rebin-v1.html"} + env = app.builder.env + if not hasattr(env, "algorithms"): + return # nothing to do + template = REDIRECT_TEMPLATE - return [(name, context, template)] + algorithms = env.algorithms + for name, highest_version in algorithms.itervalues(): + redirect_pagename = "algorithms/%s" % name + target = "%s-v%d.html" % (name, highest_version) + context = {"name" : name, "target" : target} + yield (redirect_pagename, context, template) ############################################################################################################ From dea64e60a9ff778e07a0c6bef49acbf923e59ca7 Mon Sep 17 00:00:00 2001 From: Wenduo Zhou Date: Tue, 27 May 2014 16:53:09 -0400 Subject: [PATCH 064/126] Added new properties. Refs #9459. --- .../CalibrateRectangularDetectors.py | 34 ++++++++++++++++++- 1 file changed, 33 insertions(+), 1 deletion(-) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py index b2867bd74024..16efdc5f5022 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py @@ -84,7 +84,15 @@ def PyInit(self): "Comma delimited d-space positions of reference peaks. Use 1-3 for Cross Correlation. Unlimited for many peaks option.") self.declareProperty("PeakWindowMax", 0., "Maximum window around a peak to search for it. Optional.") + self.declareProperty(ITableWorkspaceProperty("FitwindowTableWorkspace", "", Direction.Input, PropertyMode.Optional), + "Name of input table workspace containing the fit window information for each spectrum. ") self.declareProperty("MinimumPeakHeight", 2., "Minimum value allowed for peak height") + + self.declareProperty(MatrixWorkspaceProperty("DetectorResolutionWorkspace", "", Direction.Input, PropertyMode.Optional), + "Name of optional input matrix workspace for each detector's resolution (D(d)/d).") + self.declareProperty(FloatArrayProperty("AllowedResRange", [0.25, 4.0], direction=Direction.Input), + "Range of allowed individual peak's resolution factor to input detector's resolution.") + self.declareProperty("PeakFunction", "Gaussian", StringListValidator(["BackToBackExponential", "Gaussian", "Lorentzian"]), "Type of peak to fit. Used only with CrossCorrelation=False") self.declareProperty("BackgroundType", "Flat", StringListValidator(['Flat', 'Linear', 'Quadratic']), @@ -383,6 +391,25 @@ def _multicalibrate(self, wksp, calib): # Remove old calibration files cmd = "rm "+calib os.system(cmd) + + # Get the fit window input workspace + fitwinws = self.getProperty("FitwindowTableWorkspace").value + + # Set up resolution workspace + resws = self.getProperty("DetectorResolutionWorkspace").value + if resws is not None: + resrange = self.getProperty("AllowedResRange").value + if len(resrange) < 2: + raise NotImplementedError("With input of 'DetectorResolutionWorkspace', number of allowed resolution range must be equal to 2.") + reslowf = resrange[0] + resupf = resrange[1] + if reslowf >= resupf: + raise NotImplementedError("Allowed resolution range factor, lower boundary (%f) must be smaller than upper boundary (%f)." + % (reslowf, resupf)) + else: + reslowf = 0.0 + resupf = 0.0 + # Get offsets for pixels using interval around cross correlations center and peak at peakpos (d-Spacing) GetDetOffsetsMultiPeaks(InputWorkspace=str(wksp), OutputWorkspace=str(wksp)+"offset", DReference=self._peakpos, @@ -390,7 +417,12 @@ def _multicalibrate(self, wksp, calib): MinimumPeakHeight=self.getProperty("MinimumPeakHeight").value, BackgroundType=self.getProperty("BackgroundType").value, MaxOffset=self._maxoffset, NumberPeaksWorkspace=str(wksp)+"peaks", - MaskWorkspace=str(wksp)+"mask") + MaskWorkspace=str(wksp)+"mask", + FitwindowTableWorkspace = fitwinws, + InputResolutionWorkspace=resws, + MinimumResolutionFactor = reslowf, + MaximumResolutionFactor = resupf) + #Fixed SmoothNeighbours for non-rectangular and rectangular if self._smoothoffsets and self._xpixelbin*self._ypixelbin>1: # Smooth data if it was summed SmoothNeighbours(InputWorkspace=str(wksp)+"offset", OutputWorkspace=str(wksp)+"offset", From 26b4db4ce226983487b3f878eee3ea1b92a2b0c5 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 09:21:18 +0100 Subject: [PATCH 065/126] Purge category information before parsing document. Refs #9521 --- .../sphinxext/mantiddoc/directives/base.py | 36 ++++++++++---- .../mantiddoc/directives/categories.py | 49 +++++++++++++++---- 2 files changed, 65 insertions(+), 20 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py index 349b1fede17b..c080f4aeb4fa 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py @@ -2,6 +2,31 @@ from docutils.parsers.rst import Directive import re +ALG_DOCNAME_RE = re.compile(r'^([A-Z][a-zA-Z0-9]+)-v([0-9][0-9]*)$') + +#---------------------------------------------------------------------------------------- +def algorithm_name_and_version(docname): + """ + Returns the name and version of an algorithm based on the name of the + document supplied. The expected name of the document is "AlgorithmName-v?", which + is the name of the file with the extension removed + + Arguments: + docname (str): The name of the document as supplied by docutils. Can contain slashes to indicate a path + + Returns: + tuple: A tuple containing two elements (name, version) + """ + # docname includes path, using forward slashes, from root of documentation directory + docname = docname.split("/")[-1] + match = ALG_DOCNAME_RE.match(docname) + if not match or len(match.groups()) != 2: + raise RuntimeError("Document filename '%s.rst' does not match the expected format: AlgorithmName-vX.rst" % docname) + + grps = match.groups() + return (str(grps[0]), int(grps[1])) + +#---------------------------------------------------------------------------------------- class BaseDirective(Directive): """ @@ -11,8 +36,6 @@ class BaseDirective(Directive): has_content = True final_argument_whitespace = True - alg_docname_re = re.compile(r'^([A-Z][a-zA-Z0-9]+)-v([0-9][0-9]*)$') - def _algorithm_name_and_version(self): """ Returns the name and version of an algorithm based on the name of the @@ -20,14 +43,7 @@ def _algorithm_name_and_version(self): is the name of the file with the extension removed """ env = self.state.document.settings.env - # env.docname includes path, using forward slashes, from root of documentation directory - docname = env.docname.split("/")[-1] - match = self.alg_docname_re.match(docname) - if not match or len(match.groups()) != 2: - raise RuntimeError("Document filename '%s.rst' does not match the expected format: AlgorithmName-vX.rst" % docname) - - grps = match.groups() - return (str(grps[0]), int(grps[1])) + return algorithm_name_and_version(env.docname) def _make_header(self, name, pagetitle=False): """ diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py index 30deab430ec8..ec76149057cb 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py @@ -6,7 +6,7 @@ creates "index" pages that lists the contents of each category. The display of each "index" page is controlled by a jinja2 template. """ -from base import BaseDirective +from base import BaseDirective, algorithm_name_and_version CATEGORY_INDEX_TEMPLATE = "category.html" # relative to the "root" directory @@ -21,14 +21,15 @@ class LinkItem(object): # html link link = None - def __init__(self, name, env): + def __init__(self, name, docname): """ Arguments: - env (Sphinx.BuildEnvironment): The current environment processing object + name (str): Display name of document + docname (str): Name of document as referred to by docutils (can contain directory separators) """ self.name = str(name) - rel_path = env.docname # no suffix + rel_path = docname # no suffix # Assumes the link is for the current document and that the # page that will use this reference is in a single # subdirectory from root @@ -67,8 +68,8 @@ class PageRef(LinkItem): Store details of a single page reference """ - def __init__(self, name, env): - super(PageRef, self).__init__(name, env) + def __init__(self, name, docname): + super(PageRef, self).__init__(name, docname) #endclass @@ -81,8 +82,8 @@ class Category(LinkItem): # Collection of PageRef objects that form subcategories of this category subcategories = None - def __init__(self, name, env): - super(Category, self).__init__(name, env) + def __init__(self, name, docname): + super(Category, self).__init__(name, docname) # override default link self.link = "../categories/%s.html" % name @@ -169,9 +170,9 @@ def _create_links_and_track(self, page_name, category_list): category = env.categories[categ_name] #endif - category.pages.add(PageRef(page_name, env)) + category.pages.add(PageRef(page_name, env.docname)) if index > 0: # first is never a child - parent.subcategories.add(Category(categ_name, env)) + parent.subcategories.add(Category(categ_name, env.docname)) #endif link_rst += "`%s <../%s/%s.html>`_ | " % (categ_name, CATEGORIES_HTML_DIR, categ_name) @@ -270,6 +271,32 @@ def create_category_pages(app): yield (CATEGORIES_HTML_DIR + "/" + name, context, template) # enddef +#----------------------------------------------------------------------------------------------------------- + +def purge_categories(app, env, docname): + """ + Purge information about the given document name from the tracked algorithms + + Arguments: + app (Sphinx.application): Application object + env (Sphinx.BuildEnvironment): + docname (str): Name of the document + """ + if not hasattr(env, "categories"): + return # nothing to do + + categories = env.categories + try: + name, version = algorithm_name_and_version(docname) + except RuntimeError: # not an algorithm page + return + + deadref = PageRef(name, docname) + for category in categories.itervalues(): + pages = category.pages + if deadref in pages: + pages.remove(deadref) + #------------------------------------------------------------------------------ def setup(app): # Add categories directive @@ -280,3 +307,5 @@ def setup(app): # connect event html collection to handler app.connect("html-collect-pages", html_collect_pages) + # connect document clean up to purge information about this page + app.connect('env-purge-doc', purge_categories) \ No newline at end of file From 3d92c9a1b0d8d5ec36c86156c74a5350dd7f6577 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 09:54:18 +0100 Subject: [PATCH 066/126] Only insert alias section if one exists. Refs #9521 --- .../docs/sphinxext/mantiddoc/directives/aliases.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py index 494181945a7c..b44255753ae2 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py @@ -13,8 +13,11 @@ def run(self): """ Called by Sphinx when the ..aliases:: directive is encountered. """ - title = self._make_header("Aliases") alias = self._get_alias() + if len(alias) == 0: + return [] + + title = self._make_header("Aliases") return self._insert_rest(title + alias) def _get_alias(self): @@ -26,8 +29,11 @@ def _get_alias(self): """ name, version = self._algorithm_name_and_version() alg = self._create_mantid_algorithm(name, version) - return "This algorithm is also known as: " + "**" + alg.alias() + "**" - + alias_name = alg.alias() + if len(alias_name) == 0: + return "" + else: + return "This algorithm is also known as: " + "**" + alias_name + "**" def setup(app): """ From f016cc04bb4b06b04c36a92a477a3c83d597b92a Mon Sep 17 00:00:00 2001 From: Samuel Jackson Date: Wed, 28 May 2014 10:43:09 +0100 Subject: [PATCH 067/126] Refs #8842 Fix broken unit test. TOSCA has an additional parameter now. --- Code/Mantid/Framework/DataHandling/test/LoadRaw3Test.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/Framework/DataHandling/test/LoadRaw3Test.h b/Code/Mantid/Framework/DataHandling/test/LoadRaw3Test.h index e49beb4e38e8..b9134f092aac 100644 --- a/Code/Mantid/Framework/DataHandling/test/LoadRaw3Test.h +++ b/Code/Mantid/Framework/DataHandling/test/LoadRaw3Test.h @@ -400,7 +400,7 @@ class LoadRaw3Test : public CxxTest::TestSuite TS_ASSERT_EQUALS( ptrDet->getID(), 60); Mantid::Geometry::ParameterMap& pmap = output2D->instrumentParameters(); - TS_ASSERT_EQUALS( static_cast(pmap.size()), 157); + TS_ASSERT_EQUALS( static_cast(pmap.size()), 158); AnalysisDataService::Instance().remove("parameterIDF"); } From dd2043aaf2f08730fa7581ae7b38525020d05a63 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 13:38:51 +0100 Subject: [PATCH 068/126] Add deprecation message if neccesary Also regorganised to base to give easier access to algorithm name/version. Refs #9521 --- .../mantiddoc/directives/algorithm.py | 109 +++++++++++------- .../sphinxext/mantiddoc/directives/aliases.py | 3 +- .../sphinxext/mantiddoc/directives/base.py | 47 +++++++- .../mantiddoc/directives/categories.py | 5 +- .../mantiddoc/directives/properties.py | 4 +- .../sphinxext/mantiddoc/directives/summary.py | 3 +- 6 files changed, 118 insertions(+), 53 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index c29a49b32775..ac80154a4f72 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -1,13 +1,28 @@ from base import BaseDirective +from docutils import nodes +from sphinx.locale import _ +from sphinx.util.compat import make_admonition import os +import re REDIRECT_TEMPLATE = "redirect.html" +DEPRECATE_USE_ALG_RE = re.compile(r'Use\s([A-Z][a-zA-Z0-9]+)\sinstead') + +#-------------------------------------------------------------------------- class AlgorithmDirective(BaseDirective): """ - Adds a referenceable link for a given algorithm, a title, - and a screenshot of the algorithm to an rst file. + Inserts details of an algorithm by querying Mantid + + Adds: + - A referenceable link for use with Sphinx ":ref:`` tags", if this is + the highest version of the algorithm being processed + - A title + - A screenshot of the algorithm + - Table of contents + + If the algorithms is deprecated then a warning is inserted. """ required_arguments, optional_arguments = 0, 0 @@ -16,30 +31,30 @@ def run(self): """ Called by Sphinx when the ..algorithm:: directive is encountered """ - algorithm_name, version = self._algorithm_name_and_version() - self._track_algorithm(algorithm_name, version) + self._track_algorithm() - # Seperate methods for each unique piece of functionality. - reference = self._make_reference_link(algorithm_name) - title = self._make_header(algorithm_name, True) - toc = self._make_local_toc() - imgpath = self._create_screenshot(algorithm_name, version) - screenshot = self._make_screenshot_link(algorithm_name, imgpath) + self._insert_reference_link() + self._insert_pagetitle() + imgpath = self._create_screenshot() + self._insert_screenshot_link(imgpath) + self._insert_toc() + self._insert_deprecation_warning() - return self._insert_rest(reference + title + screenshot + toc) + self.commit_rst() + return [] - def _track_algorithm(self, name, version): + def _track_algorithm(self): """ - Keep a track of the highest versions of algorithms encountered - - Arguments: - name (str): Name of the algorithm - version (int): Integer version number + Keep a track of the highest versions of algorithms encountered. + The algorithm name and version are retrieved from the document name. + See BaseDirective::set_algorithm_and_version() """ env = self.state.document.settings.env if not hasattr(env, "algorithm"): env.algorithms = {} #endif + + name, version = self.algorithm_name(), self.algorithm_version() algorithms = env.algorithms if name in algorithms: prev_version = algorithms[name][1] @@ -48,33 +63,32 @@ def _track_algorithm(self, name, version): else: algorithms[name] = (name, version) - def _make_reference_link(self, algorithm_name): + def _insert_reference_link(self): """ Outputs a reference to the top of the algorithm's rst of the form .. _AlgorithmName: + """ + self.add_rst(".. _algorithm|%s:\n" % self.algorithm_name()) - Args: - algorithm_name (str): The name of the algorithm to reference. - - Returns: - str: A ReST formatted reference. + def _insert_pagetitle(self): """ - return ".. _algorithm|%s:\n" % algorithm_name + Outputs a title for the page + """ + self.add_rst(self._make_header(self.algorithm_name(), True)) - def _make_local_toc(self): - return ".. contents:: Table of Contents\n :local:\n" + def _insert_toc(self): + """ + Outputs a title for the page + """ + self.add_rst(".. contents:: Table of Contents\n :local:\n") - def _create_screenshot(self, algorithm_name, version): + def _create_screenshot(self): """ Creates a screenshot for the named algorithm in an "images/screenshots" subdirectory of the currently processed document The file will be named "algorithmname-vX_dlg.png", e.g. Rebin-v1_dlg.png - Args: - algorithm_name (str): The name of the algorithm. - version (int): The version of the algorithm - Returns: str: The full path to the created image """ @@ -86,14 +100,14 @@ def _create_screenshot(self, algorithm_name, version): os.makedirs(screenshots_dir) try: - imgpath = algorithm_screenshot(algorithm_name, screenshots_dir, version=version) + imgpath = algorithm_screenshot(self.algorithm_name(), screenshots_dir, version=self.algorithm_version()) except Exception, exc: env.warn(env.docname, "Unable to generate screenshot for '%s' - %s" % (algorithm_name, str(exc))) imgpath = os.path.join(screenshots_dir, "failed_dialog.png") return imgpath - def _make_screenshot_link(self, algorithm_name, img_path): + def _insert_screenshot_link(self, img_path): """ Outputs an image link with a custom :class: style. The filename is extracted from the path given and then a link to /images/screenshots/filename.png @@ -101,11 +115,7 @@ def _make_screenshot_link(self, algorithm_name, img_path): and reformatting the links Args: - algorithm_name (str): The name of the algorithm that the screenshot represents img_path (str): The full path as on the filesystem to the image - - Returns: - str: A ReST formatted reference. """ format_str = ".. figure:: %s\n"\ " :class: screenshot\n\n"\ @@ -113,9 +123,9 @@ def _make_screenshot_link(self, algorithm_name, img_path): filename = os.path.split(img_path)[1] path = "/images/screenshots/" + filename - caption = "A screenshot of the **" + algorithm_name + "** dialog." + caption = "A screenshot of the **" + self.algorithm_name() + "** dialog." - return format_str % (path, caption) + self.add_rst(format_str % (path, caption)) def _screenshot_directory(self, env): """ @@ -133,6 +143,27 @@ def _screenshot_directory(self, env): cfg_dir = env.app.srcdir return os.path.join(cfg_dir, "images", "screenshots") + def _insert_deprecation_warning(self): + """ + If the algorithm version is deprecated then construct a warning message + """ + from mantid.api import DeprecatedAlgorithmChecker + + checker = DeprecatedAlgorithmChecker(self.algorithm_name(), self.algorithm_version()) + msg = checker.isDeprecated() + if len(msg) == 0: + return + + # Check for message to use another algorithm an insert a link + match = DEPRECATE_USE_ALG_RE.search(msg) + print "TESTING",msg + print "TESTING",match,match.groups() + if match is not None and len(match.groups()) == 1: + name = match.group(0) + msg = DEPRECATE_USE_ALG_RE.sub(r"Use :ref:`algorithm|\1` instead.", msg) + print "TESTING",msg + self.add_rst(".. warning:: %s" % msg) + ############################################################################################################ def html_collect_pages(app): diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py index b44255753ae2..9ee58c7fe807 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py @@ -27,8 +27,7 @@ def _get_alias(self): Args: algorithm_name (str): The name of the algorithm to get the alias for. """ - name, version = self._algorithm_name_and_version() - alg = self._create_mantid_algorithm(name, version) + alg = self._create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) alias_name = alg.alias() if len(alias_name) == 0: return "" diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py index c080f4aeb4fa..b6980693d7be 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py @@ -32,18 +32,57 @@ class BaseDirective(Directive): """ Contains shared functionality for Mantid custom directives. """ - - has_content = True + has_content = False final_argument_whitespace = True - def _algorithm_name_and_version(self): + algm_name = None + algm_version = None + rst_lines = None + + def algorithm_name(self): + """ + Returns the algorithm name as parsed from the document name + """ + if self.algm_name is None: + self._set_algorithm_name_and_version() + return self.algm_name + + def algorithm_version(self): + """ + Returns the algorithm version as parsed from the document name + """ + if self.algm_version is None: + self._set_algorithm_name_and_version() + return self.algm_version + + def _set_algorithm_name_and_version(self): """ Returns the name and version of an algorithm based on the name of the document. The expected name of the document is "AlgorithmName-v?", which is the name of the file with the extension removed """ env = self.state.document.settings.env - return algorithm_name_and_version(env.docname) + self.algm_name, self.algm_version = algorithm_name_and_version(env.docname) + + def add_rst(self, text): + """ + Appends given reST into a managed list. It is NOT inserted into the + document until commit_rst() is called + + Args: + text (str): reST to track + """ + if self.rst_lines is None: + self.rst_lines = [] + + self.rst_lines.extend(statemachine.string2lines(text)) + + def commit_rst(self): + """ + Inserts the currently tracked rst lines into the state_machine + """ + self.state_machine.insert_input(self.rst_lines, "") + self.rst_lines = [] def _make_header(self, name, pagetitle=False): """ diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py index ec76149057cb..4c829f8680cb 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py @@ -214,8 +214,7 @@ def _get_categories_list(self): list: A list of strings containing the required categories """ category_list = ["Algorithms"] - algname, version = self._algorithm_name_and_version() - alg_cats = self._create_mantid_algorithm(algname, version).categories() + alg_cats = self._create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()).categories() for cat in alg_cats: # double up the category separators so they are not treated as escape characters category_list.append(cat.replace("\\", "\\\\")) @@ -226,7 +225,7 @@ def _get_display_name(self): """ Returns the name of the item as it should appear in the category """ - return self._algorithm_name_and_version()[0] + return self.algorithm_name() #--------------------------------------------------------------------------------- diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py index 440e11d4bd7a..35455462ed9d 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py @@ -21,9 +21,7 @@ def _populate_properties_table(self): """ Populates the ReST table with algorithm properties. """ - name, version = self._algorithm_name_and_version() - - alg = self._create_mantid_algorithm(name, version) + alg = self._create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) alg_properties = alg.getProperties() # Stores each property of the algorithm in a tuple. diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py index 2432a2fc4076..6b3bdb4ec9ba 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py @@ -24,8 +24,7 @@ def _get_summary(self): Args: algorithm_name (str): The name of the algorithm. """ - name, version = self._algorithm_name_and_version() - alg = self._create_mantid_algorithm(name, version) + alg = self._create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) return alg.getWikiSummary() From 8727d697ed4694ad07006900e907e58700a94f6b Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 13:50:49 +0100 Subject: [PATCH 069/126] Update style of directives to be more similar to each other. Refs #9521 --- .../mantiddoc/directives/algorithm.py | 6 ++--- .../sphinxext/mantiddoc/directives/aliases.py | 23 ++++++------------- .../sphinxext/mantiddoc/directives/base.py | 17 ++------------ .../mantiddoc/directives/categories.py | 6 +++-- .../mantiddoc/directives/properties.py | 10 ++++---- .../sphinxext/mantiddoc/directives/summary.py | 18 ++++----------- 6 files changed, 26 insertions(+), 54 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index ac80154a4f72..c159c06398a4 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -74,7 +74,7 @@ def _insert_pagetitle(self): """ Outputs a title for the page """ - self.add_rst(self._make_header(self.algorithm_name(), True)) + self.add_rst(self.make_header(self.algorithm_name(), True)) def _insert_toc(self): """ @@ -156,12 +156,10 @@ def _insert_deprecation_warning(self): # Check for message to use another algorithm an insert a link match = DEPRECATE_USE_ALG_RE.search(msg) - print "TESTING",msg - print "TESTING",match,match.groups() if match is not None and len(match.groups()) == 1: name = match.group(0) msg = DEPRECATE_USE_ALG_RE.sub(r"Use :ref:`algorithm|\1` instead.", msg) - print "TESTING",msg + self.add_rst(".. warning:: %s" % msg) ############################################################################################################ diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py index 9ee58c7fe807..2481e4ca734f 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/aliases.py @@ -13,26 +13,17 @@ def run(self): """ Called by Sphinx when the ..aliases:: directive is encountered. """ - alias = self._get_alias() + alg = self.create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) + alias = alg.alias() if len(alias) == 0: return [] - title = self._make_header("Aliases") - return self._insert_rest(title + alias) + self.add_rst(self.make_header("Aliases")) + format_str = "This algorithm is also known as: **%s**" + self.add_rst(format_str % alias) + self.commit_rst() - def _get_alias(self): - """ - Return the alias for the named algorithm. - - Args: - algorithm_name (str): The name of the algorithm to get the alias for. - """ - alg = self._create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) - alias_name = alg.alias() - if len(alias_name) == 0: - return "" - else: - return "This algorithm is also known as: " + "**" + alias_name + "**" + return [] def setup(app): """ diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py index b6980693d7be..f52f4c635420 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/base.py @@ -84,7 +84,7 @@ def commit_rst(self): self.state_machine.insert_input(self.rst_lines, "") self.rst_lines = [] - def _make_header(self, name, pagetitle=False): + def make_header(self, name, pagetitle=False): """ Makes a ReStructuredText title from the algorithm's name. @@ -102,20 +102,7 @@ def _make_header(self, name, pagetitle=False): line = "\n" + "-" * len(name) + "\n" return name + line - def _insert_rest(self, text): - """ - Inserts ReStructuredText into the algorithm file. - - Args: - text (str): Inserts ReStructuredText into the algorithm file. - - Returns: - list: Empty list. This is required by the inherited run method. - """ - self.state_machine.insert_input(statemachine.string2lines(text), "") - return [] - - def _create_mantid_algorithm(self, algorithm_name, version): + def create_mantid_algorithm(self, algorithm_name, version): """ Create and initializes a Mantid algorithm. diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py index 4c829f8680cb..c0ce2864e709 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py @@ -114,7 +114,9 @@ def run(self): display_name = self._get_display_name() links = self._create_links_and_track(display_name, categories) - return self._insert_rest("\n" + links) + self.add_rst("\n" + links) + self.commit_rst() + return [] def _get_categories_list(self): """ @@ -214,7 +216,7 @@ def _get_categories_list(self): list: A list of strings containing the required categories """ category_list = ["Algorithms"] - alg_cats = self._create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()).categories() + alg_cats = self.create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()).categories() for cat in alg_cats: # double up the category separators so they are not treated as escape characters category_list.append(cat.replace("\\", "\\\\")) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py index 35455462ed9d..3eb955bffc7b 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py @@ -13,15 +13,17 @@ def run(self): """ Called by Sphinx when the ..properties:: directive is encountered. """ - title = self._make_header("Properties") - properties_table = self._populate_properties_table() - return self._insert_rest(title + properties_table) + self.add_rst(self.make_header("Properties")) + self.add_rst(self._populate_properties_table()) + self.commit_rst() + + return [] def _populate_properties_table(self): """ Populates the ReST table with algorithm properties. """ - alg = self._create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) + alg = self.create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) alg_properties = alg.getProperties() # Stores each property of the algorithm in a tuple. diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py index 6b3bdb4ec9ba..3d92a9071bd8 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py @@ -13,20 +13,12 @@ def run(self): """ Called by Sphinx when the ..summary:: directive is encountered. """ - title = self._make_header("Summary") - summary = self._get_summary() - return self._insert_rest(title + summary) - - def _get_summary(self): - """ - Return the summary for the named algorithm. - - Args: - algorithm_name (str): The name of the algorithm. - """ - alg = self._create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) - return alg.getWikiSummary() + self.add_rst(self.make_header("Summary")) + alg = self.create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) + self.add_rst(alg.getWikiSummary()) + self.commit_rst() + return [] def setup(app): """ From 920a2dbb90b5ee9e150b9e3ac83b1b553d477b36 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 14:25:23 +0100 Subject: [PATCH 070/126] Add highestVersion() method to AlgorithmFactory It provides easy access to the highest version of an algorithm currently registered. Refs #9521 --- .../API/inc/MantidAPI/AlgorithmFactory.h | 3 +++ .../Framework/API/src/AlgorithmFactory.cpp | 15 +++++++++++++++ .../Framework/API/test/AlgorithmFactoryTest.h | 19 ++++++++++++++++++- .../api/src/Exports/AlgorithmFactory.cpp | 3 ++- 4 files changed, 38 insertions(+), 2 deletions(-) diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmFactory.h b/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmFactory.h index 2a9d43cbe57e..9762c2995a48 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmFactory.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmFactory.h @@ -125,6 +125,9 @@ class MANTID_API_DLL AlgorithmFactoryImpl : public Kernel::DynamicFactory getKeys() const; const std::vector getKeys(bool includeHidden) const; + + /// Returns the highest version of the algorithm currently registered + int highestVersion(const std::string & algorithmName) const; ///Get the algorithm categories const std::set getCategories(bool includeHidden=false) const; diff --git a/Code/Mantid/Framework/API/src/AlgorithmFactory.cpp b/Code/Mantid/Framework/API/src/AlgorithmFactory.cpp index 152a3215f422..79b39269797f 100644 --- a/Code/Mantid/Framework/API/src/AlgorithmFactory.cpp +++ b/Code/Mantid/Framework/API/src/AlgorithmFactory.cpp @@ -227,6 +227,21 @@ namespace Mantid } } + /** + * @param algorithmName The name of an algorithm registered with the factory + * @return An integer corresponding to the highest version registered + * @throw std::invalid_argument if the algorithm cannot be found + */ + int AlgorithmFactoryImpl::highestVersion(const std::string &algorithmName) const + { + VersionMap::const_iterator viter = m_vmap.find(algorithmName); + if(viter != m_vmap.end()) return viter->second; + else + { + throw std::invalid_argument("AlgorithmFactory::highestVersion() - Unknown algorithm '" + algorithmName + "'"); + } + } + /** * Return the categories of the algorithms. This includes those within the Factory itself and * any cleanly constructed algorithms stored here. diff --git a/Code/Mantid/Framework/API/test/AlgorithmFactoryTest.h b/Code/Mantid/Framework/API/test/AlgorithmFactoryTest.h index 34806408aee4..1314ee8fc8fa 100644 --- a/Code/Mantid/Framework/API/test/AlgorithmFactoryTest.h +++ b/Code/Mantid/Framework/API/test/AlgorithmFactoryTest.h @@ -106,6 +106,23 @@ class AlgorithmFactoryTest : public CxxTest::TestSuite TS_ASSERT_THROWS_NOTHING(keys = AlgorithmFactory::Instance().getKeys()); TS_ASSERT_EQUALS(noOfAlgs - 1, keys.size()); } + + void test_HighestVersion() + { + auto & factory = AlgorithmFactory::Instance(); + + TS_ASSERT_THROWS(factory.highestVersion("ToyAlgorithm"), std::invalid_argument); + + AlgorithmFactory::Instance().subscribe(); + TS_ASSERT_EQUALS(1, factory.highestVersion("ToyAlgorithm")); + + Mantid::Kernel::Instantiator* newTwo = new Mantid::Kernel::Instantiator; + AlgorithmFactory::Instance().subscribe(newTwo); + TS_ASSERT_EQUALS(2, factory.highestVersion("ToyAlgorithm")); + + AlgorithmFactory::Instance().unsubscribe("ToyAlgorithm",1); + AlgorithmFactory::Instance().unsubscribe("ToyAlgorithm",2); + } void testCreate() { @@ -201,4 +218,4 @@ class AlgorithmFactoryTest : public CxxTest::TestSuite }; -#endif \ No newline at end of file +#endif diff --git a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/AlgorithmFactory.cpp b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/AlgorithmFactory.cpp index 4b9b34ab283c..12bfc84afbc6 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/AlgorithmFactory.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/AlgorithmFactory.cpp @@ -112,7 +112,8 @@ void export_AlgorithmFactory() "Returns true if the given algorithm exists with an option to specify the version")) .def("getRegisteredAlgorithms", &getRegisteredAlgorithms, "Returns a Python dictionary of currently registered algorithms") - + .def("highestVersion", &AlgorithmFactoryImpl::highestVersion, + "Returns the highest version of the named algorithm. Throws ValueError if no algorithm can be found") .def("subscribe", &subscribe, "Register a Python class derived from PythonAlgorithm into the factory") .def("Instance", &AlgorithmFactory::Instance, return_value_policy(), From 20815b842504b9436c1a8c0b2ccc60c677d2ec14 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 14:26:12 +0100 Subject: [PATCH 071/126] Only add Sphinx ref link if algorithm is highest version Refs #9521 --- .../docs/sphinxext/mantiddoc/directives/algorithm.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index c159c06398a4..ebe179bb3142 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -66,15 +66,20 @@ def _track_algorithm(self): def _insert_reference_link(self): """ Outputs a reference to the top of the algorithm's rst - of the form .. _AlgorithmName: + of the form .. _AlgorithmName: if this is the highest version """ - self.add_rst(".. _algorithm|%s:\n" % self.algorithm_name()) + from mantid.api import AlgorithmFactory + + alg_name = self.algorithm_name() + if AlgorithmFactory.highestVersion(alg_name) == self.algorithm_version(): + self.add_rst(".. _algorithm|%s:\n" % alg_name) def _insert_pagetitle(self): """ Outputs a title for the page """ - self.add_rst(self.make_header(self.algorithm_name(), True)) + title = "%s v%d" % (self.algorithm_name(), self.algorithm_version()) + self.add_rst(self.make_header(title, True)) def _insert_toc(self): """ From 152593258835669b696fd677539b83033686d7a2 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 15:05:39 +0100 Subject: [PATCH 072/126] Fix bootstrap navbar size issue. Also replace logo with cropped version to take up less space. Refs #9521 --- Code/Mantid/docs/source/_static/custom.css | 5 ----- Code/Mantid/docs/source/_templates/layout.html | 1 + Code/Mantid/docs/source/_templates/navbar.html | 8 ++++++++ Code/Mantid/docs/source/conf.py | 4 ++-- 4 files changed, 11 insertions(+), 7 deletions(-) create mode 100644 Code/Mantid/docs/source/_templates/navbar.html diff --git a/Code/Mantid/docs/source/_static/custom.css b/Code/Mantid/docs/source/_static/custom.css index 1ca764fa6eab..b21258686d13 100644 --- a/Code/Mantid/docs/source/_static/custom.css +++ b/Code/Mantid/docs/source/_static/custom.css @@ -5,11 +5,6 @@ /*-------------------- $NAV --------------------*/ .navbar-version { display: none; } -.navbar-brand { - margin-bottom: 15px; - width: 190px; - height: 100px; -} /*-------------------- $LINKS --------------------*/ diff --git a/Code/Mantid/docs/source/_templates/layout.html b/Code/Mantid/docs/source/_templates/layout.html index e4f5bcfc89aa..6f66bf7ba4d5 100644 --- a/Code/Mantid/docs/source/_templates/layout.html +++ b/Code/Mantid/docs/source/_templates/layout.html @@ -1,3 +1,4 @@ {% extends "!layout.html" %} + {# Custom CSS overrides #} {% set bootswatch_css_custom = ['_static/custom.css'] %} diff --git a/Code/Mantid/docs/source/_templates/navbar.html b/Code/Mantid/docs/source/_templates/navbar.html new file mode 100644 index 000000000000..bf3b51f08e01 --- /dev/null +++ b/Code/Mantid/docs/source/_templates/navbar.html @@ -0,0 +1,8 @@ +{% extends "!navbar.html" %} + +{%- block sidebarlogo %} +{%- if logo -%} + +{%- endif %} +{%- endblock -%} + diff --git a/Code/Mantid/docs/source/conf.py b/Code/Mantid/docs/source/conf.py index dc8828ce39c6..ea20dcc36f4a 100644 --- a/Code/Mantid/docs/source/conf.py +++ b/Code/Mantid/docs/source/conf.py @@ -60,7 +60,7 @@ # custom.css rather than here. html_theme_options = { # Navigation bar title. - 'navbar_title': " ", + 'navbar_title': " ", # deliberate single space so it's not visible # Tab name for entire site. 'navbar_site_name': "Mantid", # Add links to the nav bar. Second param of tuple is true to create absolute url. @@ -87,7 +87,7 @@ # The name of an image file (relative to this directory) to place at the top # of the sidebar. -html_logo = os.path.relpath('../../Images/Mantid_Logo_Transparent.png') +html_logo = os.path.relpath('../../Images/Mantid_Logo_Transparent_Cropped.png') # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, From a8ac85b64e2b28e9a3e3d2d5c7483854a1e15777 Mon Sep 17 00:00:00 2001 From: Wenduo Zhou Date: Wed, 28 May 2014 10:34:00 -0400 Subject: [PATCH 073/126] Added contents to wiki. Refs #9459. --- .../CalibrateRectangularDetectors.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py index 16efdc5f5022..6171ae9aeeab 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py @@ -16,6 +16,24 @@ the CrossCorrelationPoints and/or PeakHalfWidth should be increased or decreased. Also plot the reference spectra from the cc workspace. +== Features to improve performance of peak finding == + +=== Define peak fit-window === +There are two exclusive approaches to define peak's fit-window. + +1. ''PeakWindowMax'': All peaks will use this value to define their fitting range. + +2. ''FitwindowTableWorkspace'': This is a table workspace by which each peak will have its individual fit window defined. + +=== Define accepted range of peak's width === +Optional input property ''DetectorResolutionWorkspace'' is a matrix workspace containing the detector resolution +\Delta(d)/d for each spectrum. +Combining with property ''AllowedResRange'', it defines the lower and upper limit for accepted fitted peak width. + +Let c_l = AllowedResRange[0] , c_h = AllowedResRange[1] and fwhm as the peak's fitted width. +Then, +: c_l\times\frac{\Delta(d)}{d} < fwhm < c_h\times\frac{\Delta(d)}{d} + *WIKI*""" from mantid.api import * From 8373eb4d8a8076c202fd62962b9e5409f908d95f Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 15:34:26 +0100 Subject: [PATCH 074/126] Extend our layout class in category not the default. Refs #9521 --- Code/Mantid/docs/source/_templates/category.html | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Code/Mantid/docs/source/_templates/category.html b/Code/Mantid/docs/source/_templates/category.html index c78f7644003b..0d9249d9b59b 100644 --- a/Code/Mantid/docs/source/_templates/category.html +++ b/Code/Mantid/docs/source/_templates/category.html @@ -1,5 +1,6 @@ -{# Import the theme's layout. #} -{% extends "!layout.html" %} +{# Generates a better view for category pages #} + +{% extends "layout.html" %} {% macro split_to_three_columns(item_list) -%} {# Split list into 3 columns #} From afbdb0365f51a5ad8d7cfe7636b403e1f80f03b3 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 15:35:12 +0100 Subject: [PATCH 075/126] Add docs-html target to CMake Only added if Sphinx can be found. Refs #9521 --- Code/Mantid/docs/CMakeLists.txt | 28 ++++++++++++++++++++++++++++ Code/Mantid/docs/runsphinx.py.in | 21 +++++++++++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 Code/Mantid/docs/runsphinx.py.in diff --git a/Code/Mantid/docs/CMakeLists.txt b/Code/Mantid/docs/CMakeLists.txt index 6bb594dc56c8..b6a1bed99409 100644 --- a/Code/Mantid/docs/CMakeLists.txt +++ b/Code/Mantid/docs/CMakeLists.txt @@ -1,3 +1,31 @@ +############################################################################### +# Sphinx documentation +############################################################################### +find_package ( Sphinx ) + +if ( SPHINX_FOUND ) + # Fill in the config file and autogen file with build information + + # We generate a target per build type, i.e docs-html + set ( SPHINX_BUILD ${CMAKE_BINARY_DIR}/docs ) + set ( BUILDER html ) + configure_file ( runsphinx.py.in runsphinx_html.py @ONLY ) + + # targets + set ( TARGET_PREFIX docs) + + # HTML target + add_custom_target ( ${TARGET_PREFIX}-html + COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MantidPlot -xq runsphinx_html.py + COMMENT "Build Sphinx html documentation" + ) + +endif () + + +############################################################################### +# QtAssistant +############################################################################### if ( APPLE ) set ( ENABLE_QTASSISTANT False CACHE BOOL "Build qt-assistant documentation" ) else () diff --git a/Code/Mantid/docs/runsphinx.py.in b/Code/Mantid/docs/runsphinx.py.in new file mode 100644 index 000000000000..d675706b9819 --- /dev/null +++ b/Code/Mantid/docs/runsphinx.py.in @@ -0,0 +1,21 @@ +"""We need to run Sphinx inside MantidPlot to document the internal + module. This script calls the sphinx entry point with the necessary + arguments +""" + +__requires__ = 'Sphinx' +import sys +import os +from pkg_resources import load_entry_point + +mantidplot = "@CMAKE_RUNTIME_OUTPUT_DIRECTORY@/MantidPlot" +builder = "@BUILDER@" +src_dir = "@CMAKE_CURRENT_SOURCE_DIR@/source" +output_dir = os.path.join("@SPHINX_BUILD@", builder) +argv = [mantidplot,'-b', builder, src_dir, output_dir] + +if __name__ == '__main__': + sys.exit( + load_entry_point(__requires__, 'console_scripts', 'sphinx-build')(argv) + ) + From 0f669bf033552a1a0bf4afe4c504b6445b1075e4 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 15:40:57 +0100 Subject: [PATCH 076/126] Update docs README to include package requirements Refs #9521 --- Code/Mantid/docs/README.md | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/Code/Mantid/docs/README.md b/Code/Mantid/docs/README.md index 12654d178542..393d032b3b2a 100644 --- a/Code/Mantid/docs/README.md +++ b/Code/Mantid/docs/README.md @@ -1,5 +1,16 @@ -The Mantid documentation is written in [reStructuredText](http://docutils.sourceforge.net/rst.html) and processed using [Sphinx](http://sphinx.pocoo.org/). To install Sphinx type +The Mantid documentation is written in [reStructuredText](http://docutils.sourceforge.net/rst.html) and processed using [Sphinx](http://sphinx.pocoo.org/). It uses a custom +boostrap theme for Sphinx and both are required to build the documentation. + +To install Sphinx and the bootstrap theme use `easy_install`: easy_install -U Sphinx + easy_install -U sphinx-bootstrap-theme + +or `pip`: + + pip install Sphinx + pip install sphinx-bootstrap-theme + +This may require admin privileges on some environments. -CMake produces a `doc-html` target that is used to build the documentation. The output files will appear in a `html` sub directory of the main `build/docs` directory. \ No newline at end of file +CMake produces a `docs-html` target that is used to build the documentation. The output files will appear in a `html` sub directory of the main `build/docs` directory. \ No newline at end of file From be9f0c2cee84281d66953653b4991ede6305ca4e Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 15:43:08 +0100 Subject: [PATCH 077/126] Use reST for the style guide. Refs #9521 --- ...{DocumentationStyleGuide.md => DocumentationStyleGuide.rst} | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) rename Code/Mantid/docs/{DocumentationStyleGuide.md => DocumentationStyleGuide.rst} (70%) diff --git a/Code/Mantid/docs/DocumentationStyleGuide.md b/Code/Mantid/docs/DocumentationStyleGuide.rst similarity index 70% rename from Code/Mantid/docs/DocumentationStyleGuide.md rename to Code/Mantid/docs/DocumentationStyleGuide.rst index 75a0ac64a70c..7d171234020f 100644 --- a/Code/Mantid/docs/DocumentationStyleGuide.md +++ b/Code/Mantid/docs/DocumentationStyleGuide.rst @@ -1,7 +1,8 @@ +========================= Documentation Style Guide ========================= -This guide describes the formatting that should be followed when documenting Mantid functionality. The documentation is built using [Sphinx](http://sphinx.pocoo.org/) and when using Sphinx most of what you type is reStructuredText. For more information on reStructeredText see: +This guide describes the formatting that should be followed when documenting Mantid functionality. The documentation is built using `Sphinx ` and when using Sphinx most of what you type is reStructuredText. For more information on reStructeredText see: * https://pythonhosted.org/an_example_pypi_project/sphinx.html * http://docutils.sourceforge.net/rst.html From 83961ad9baa5a96f02c1fb4be664e4d32a5180ed Mon Sep 17 00:00:00 2001 From: Nick Draper Date: Wed, 28 May 2014 15:50:04 +0100 Subject: [PATCH 078/126] re #9523 Algorithms and API changed --- .../Framework/API/inc/MantidAPI/Algorithm.h | 29 +---- .../API/inc/MantidAPI/AlgorithmProxy.h | 13 +- .../Framework/API/inc/MantidAPI/IAlgorithm.h | 14 +-- Code/Mantid/Framework/API/src/Algorithm.cpp | 3 - .../Framework/API/src/AlgorithmProxy.cpp | 5 +- .../MantidAlgorithms/AbsorptionCorrection.h | 4 +- .../inc/MantidAlgorithms/AddLogDerivative.h | 6 +- .../Algorithms/inc/MantidAlgorithms/AddPeak.h | 6 +- .../inc/MantidAlgorithms/AddSampleLog.h | 6 +- .../inc/MantidAlgorithms/AddTimeSeriesLog.h | 4 +- .../inc/MantidAlgorithms/AlignDetectors.h | 6 +- .../inc/MantidAlgorithms/AlphaCalc.h | 3 + .../inc/MantidAlgorithms/AnyShapeAbsorption.h | 6 +- .../inc/MantidAlgorithms/ApplyCalibration.h | 6 +- .../inc/MantidAlgorithms/ApplyDeadTimeCorr.h | 3 + .../MantidAlgorithms/ApplyDetailedBalance.h | 6 +- .../ApplyTransmissionCorrection.h | 6 +- .../inc/MantidAlgorithms/AsymmetryCalc.h | 3 + .../inc/MantidAlgorithms/AverageLogData.h | 5 +- .../inc/MantidAlgorithms/BinaryOperateMasks.h | 6 +- .../inc/MantidAlgorithms/CalMuonDeadTime.h | 3 + .../MantidAlgorithms/CalculateEfficiency.h | 6 +- .../CalculateFlatBackground.h | 6 +- .../MantidAlgorithms/CalculateTransmission.h | 6 +- .../CalculateTransmissionBeamSpreader.h | 6 +- .../inc/MantidAlgorithms/CalculateZscore.h | 6 +- .../inc/MantidAlgorithms/ChangeBinOffset.h | 6 +- .../inc/MantidAlgorithms/ChangeLogTime.h | 4 +- .../inc/MantidAlgorithms/ChangePulsetime.h | 6 +- .../MantidAlgorithms/CheckWorkspacesMatch.h | 6 +- .../inc/MantidAlgorithms/ChopData.h | 4 + .../inc/MantidAlgorithms/ClearMaskFlag.h | 4 +- .../inc/MantidAlgorithms/CloneWorkspace.h | 6 +- .../MantidAlgorithms/ConvertAxisByFormula.h | 6 +- .../ConvertFromDistribution.h | 6 +- .../ConvertMDHistoToMatrixWorkspace.h | 10 +- .../MantidAlgorithms/ConvertSpectrumAxis.h | 6 +- .../MantidAlgorithms/ConvertSpectrumAxis2.h | 6 +- .../ConvertTableToMatrixWorkspace.h | 10 +- .../MantidAlgorithms/ConvertToDistribution.h | 6 +- .../ConvertToEventWorkspace.h | 6 +- .../inc/MantidAlgorithms/ConvertToHistogram.h | 6 +- .../ConvertToMatrixWorkspace.h | 10 +- .../inc/MantidAlgorithms/ConvertToPointData.h | 6 +- .../inc/MantidAlgorithms/ConvertUnits.h | 6 +- .../CopyInstrumentParameters.h | 6 +- .../inc/MantidAlgorithms/CopyLogs.h | 6 +- .../inc/MantidAlgorithms/CopySample.h | 6 +- .../inc/MantidAlgorithms/CorrectFlightPaths.h | 9 +- .../inc/MantidAlgorithms/CorrectKiKf.h | 6 +- .../inc/MantidAlgorithms/CorrectToFile.h | 6 +- .../MantidAlgorithms/CreateCalFileByNames.h | 6 +- .../inc/MantidAlgorithms/CreateDummyCalFile.h | 6 +- .../CreateFlatEventWorkspace.h | 5 +- .../CreateGroupingWorkspace.h | 6 +- .../MantidAlgorithms/CreateLogPropertyTable.h | 7 +- .../CreateLogTimeCorrection.h | 6 +- .../inc/MantidAlgorithms/CreatePSDBleedMask.h | 6 +- .../MantidAlgorithms/CreatePeaksWorkspace.h | 6 +- .../MantidAlgorithms/CreateSampleWorkspace.h | 6 +- .../CreateSingleValuedWorkspace.h | 6 +- .../CreateTransmissionWorkspace.h | 5 +- .../inc/MantidAlgorithms/CreateWorkspace.h | 6 +- .../inc/MantidAlgorithms/CropWorkspace.h | 6 +- .../inc/MantidAlgorithms/CrossCorrelate.h | 6 +- .../CuboidGaugeVolumeAbsorption.h | 6 +- .../inc/MantidAlgorithms/CylinderAbsorption.h | 6 +- .../inc/MantidAlgorithms/DeleteLog.h | 5 +- .../inc/MantidAlgorithms/DeleteWorkspace.h | 6 +- .../inc/MantidAlgorithms/DetectorDiagnostic.h | 6 +- .../MantidAlgorithms/DetectorEfficiencyCor.h | 6 +- .../DetectorEfficiencyCorUser.h | 4 +- .../DetectorEfficiencyVariation.h | 6 +- .../DiffractionEventCalibrateDetectors.h | 6 +- .../MantidAlgorithms/DiffractionFocussing.h | 6 +- .../MantidAlgorithms/DiffractionFocussing2.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Divide.h | 6 +- .../inc/MantidAlgorithms/EQSANSResolution.h | 6 +- .../inc/MantidAlgorithms/EQSANSTofStructure.h | 6 +- .../MantidAlgorithms/EditInstrumentGeometry.h | 6 +- .../inc/MantidAlgorithms/ElasticWindow.h | 6 +- .../EstimatePDDetectorResolution.h | 6 +- .../inc/MantidAlgorithms/Exponential.h | 6 +- .../MantidAlgorithms/ExponentialCorrection.h | 6 +- .../MantidAlgorithms/ExportTimeSeriesLog.h | 5 +- .../inc/MantidAlgorithms/ExtractFFTSpectrum.h | 6 +- .../inc/MantidAlgorithms/ExtractMask.h | 6 +- .../inc/MantidAlgorithms/ExtractMaskToTable.h | 6 +- .../MantidAlgorithms/ExtractSingleSpectrum.h | 6 +- .../Algorithms/inc/MantidAlgorithms/FFT.h | 6 +- .../inc/MantidAlgorithms/FFTDerivative.h | 6 +- .../inc/MantidAlgorithms/FFTSmooth.h | 6 +- .../inc/MantidAlgorithms/FFTSmooth2.h | 6 +- .../inc/MantidAlgorithms/FilterBadPulses.h | 6 +- .../inc/MantidAlgorithms/FilterByLogValue.h | 6 +- .../inc/MantidAlgorithms/FilterByTime.h | 6 +- .../inc/MantidAlgorithms/FilterByTime2.h | 2 +- .../inc/MantidAlgorithms/FilterByXValue.h | 5 +- .../inc/MantidAlgorithms/FilterEvents.h | 6 +- .../FindCenterOfMassPosition.h | 6 +- .../FindCenterOfMassPosition2.h | 6 +- .../inc/MantidAlgorithms/FindDeadDetectors.h | 6 +- .../FindDetectorsOutsideLimits.h | 6 +- .../inc/MantidAlgorithms/FindPeakBackground.h | 6 +- .../inc/MantidAlgorithms/FindPeaks.h | 6 +- .../Algorithms/inc/MantidAlgorithms/FitPeak.h | 12 +- .../MantidAlgorithms/FixGSASInstrumentFile.h | 6 +- .../MantidAlgorithms/FlatPlateAbsorption.h | 6 +- .../GeneralisedSecondDifference.h | 6 +- .../MantidAlgorithms/GenerateEventsFilter.h | 6 +- .../inc/MantidAlgorithms/GeneratePeaks.h | 6 +- .../MantidAlgorithms/GeneratePythonScript.h | 6 +- .../GetDetOffsetsMultiPeaks.h | 6 +- .../inc/MantidAlgorithms/GetDetectorOffsets.h | 6 +- .../Algorithms/inc/MantidAlgorithms/GetEi.h | 6 +- .../Algorithms/inc/MantidAlgorithms/GetEi2.h | 6 +- .../GetTimeSeriesLogInformation.h | 5 +- .../inc/MantidAlgorithms/GroupWorkspaces.h | 3 + .../MantidAlgorithms/HRPDSlabCanAbsorption.h | 6 +- .../inc/MantidAlgorithms/He3TubeEfficiency.h | 6 +- .../inc/MantidAlgorithms/IQTransform.h | 6 +- .../MantidAlgorithms/IdentifyNoisyDetectors.h | 6 +- .../MantidAlgorithms/IntegrateByComponent.h | 5 +- .../inc/MantidAlgorithms/Integration.h | 6 +- .../inc/MantidAlgorithms/InterpolatingRebin.h | 8 +- .../inc/MantidAlgorithms/InvertMask.h | 6 +- .../inc/MantidAlgorithms/Logarithm.h | 6 +- .../inc/MantidAlgorithms/MaskBins.h | 6 +- .../inc/MantidAlgorithms/MaskBinsFromTable.h | 6 +- .../inc/MantidAlgorithms/MaskDetectorsIf.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Max.h | 3 + .../Algorithms/inc/MantidAlgorithms/MaxMin.h | 3 + .../inc/MantidAlgorithms/MergeRuns.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Min.h | 3 + .../Algorithms/inc/MantidAlgorithms/Minus.h | 6 +- .../inc/MantidAlgorithms/ModeratorTzero.h | 6 +- .../MantidAlgorithms/ModeratorTzeroLinear.h | 6 +- .../MantidAlgorithms/MonteCarloAbsorption.h | 3 + .../MultipleScatteringCylinderAbsorption.h | 3 + .../inc/MantidAlgorithms/Multiply.h | 6 +- .../inc/MantidAlgorithms/MultiplyRange.h | 6 +- .../inc/MantidAlgorithms/MuonGroupDetectors.h | 5 +- .../inc/MantidAlgorithms/NormaliseByCurrent.h | 6 +- .../MantidAlgorithms/NormaliseByDetector.h | 5 +- .../inc/MantidAlgorithms/NormaliseToMonitor.h | 4 +- .../inc/MantidAlgorithms/NormaliseToUnity.h | 6 +- .../MantidAlgorithms/OneMinusExponentialCor.h | 6 +- .../MantidAlgorithms/PDFFourierTransform.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Pause.h | 5 +- .../MantidAlgorithms/PerformIndexOperations.h | 5 +- .../PlotAsymmetryByLogValue.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Plus.h | 6 +- .../PointByPointVCorrection.h | 6 +- .../inc/MantidAlgorithms/PoissonErrors.h | 6 +- .../MantidAlgorithms/PolynomialCorrection.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Power.h | 6 +- .../inc/MantidAlgorithms/PowerLawCorrection.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Q1D2.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Q1DTOF.h | 6 +- .../inc/MantidAlgorithms/Q1DWeighted.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Qxy.h | 6 +- .../inc/MantidAlgorithms/RadiusSum.h | 5 +- .../inc/MantidAlgorithms/RayTracerTester.h | 6 +- .../inc/MantidAlgorithms/ReadGroupsFromFile.h | 6 +- .../Algorithms/inc/MantidAlgorithms/RealFFT.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Rebin.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Rebin2D.h | 6 +- .../inc/MantidAlgorithms/RebinByPulseTimes.h | 5 +- .../inc/MantidAlgorithms/RebinToWorkspace.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Rebunch.h | 6 +- .../inc/MantidAlgorithms/RecordPythonScript.h | 6 +- .../ReflectometryReductionOne.h | 5 +- .../Algorithms/inc/MantidAlgorithms/Regroup.h | 6 +- .../inc/MantidAlgorithms/RemoveBins.h | 6 +- .../inc/MantidAlgorithms/RemoveExpDecay.h | 6 +- .../inc/MantidAlgorithms/RemoveLowResTOF.h | 2 + .../inc/MantidAlgorithms/RemovePromptPulse.h | 6 +- .../inc/MantidAlgorithms/RenameWorkspace.h | 6 +- .../inc/MantidAlgorithms/RenameWorkspaces.h | 6 +- .../MantidAlgorithms/ReplaceSpecialValues.h | 6 +- .../inc/MantidAlgorithms/ResampleX.h | 6 +- .../inc/MantidAlgorithms/ResetNegatives.h | 5 +- .../ResizeRectangularDetector.h | 5 +- .../inc/MantidAlgorithms/RingProfile.h | 5 +- .../MantidAlgorithms/SANSDirectBeamScaling.h | 6 +- .../inc/MantidAlgorithms/SassenaFFT.h | 6 +- .../MantidAlgorithms/SaveGSASInstrumentFile.h | 6 +- .../Algorithms/inc/MantidAlgorithms/Scale.h | 6 +- .../Algorithms/inc/MantidAlgorithms/ScaleX.h | 6 +- .../MantidAlgorithms/SetInstrumentParameter.h | 5 +- .../inc/MantidAlgorithms/SetUncertainties.h | 6 +- .../inc/MantidAlgorithms/ShiftLogTime.h | 5 +- .../inc/MantidAlgorithms/SignalOverError.h | 5 +- .../inc/MantidAlgorithms/SmoothData.h | 6 +- .../inc/MantidAlgorithms/SmoothNeighbours.h | 6 +- .../Algorithms/inc/MantidAlgorithms/SofQW.h | 6 +- .../Algorithms/inc/MantidAlgorithms/SofQW2.h | 6 +- .../Algorithms/inc/MantidAlgorithms/SofQW3.h | 6 +- .../inc/MantidAlgorithms/SolidAngle.h | 6 +- .../inc/MantidAlgorithms/SortEvents.h | 6 +- .../inc/MantidAlgorithms/SpatialGrouping.h | 6 +- .../SpecularReflectionCalculateTheta.h | 5 +- .../SpecularReflectionPositionCorrect.h | 5 +- .../MantidAlgorithms/SphericalAbsorption.h | 6 +- .../inc/MantidAlgorithms/StripPeaks.h | 6 +- .../inc/MantidAlgorithms/StripVanadiumPeaks.h | 6 +- .../MantidAlgorithms/StripVanadiumPeaks2.h | 5 + .../MantidAlgorithms/SumEventsByLogValue.h | 3 + .../inc/MantidAlgorithms/SumNeighbours.h | 6 +- .../inc/MantidAlgorithms/SumRowColumn.h | 6 +- .../inc/MantidAlgorithms/SumSpectra.h | 6 +- .../inc/MantidAlgorithms/TOFSANSResolution.h | 6 +- .../inc/MantidAlgorithms/Transpose.h | 6 +- .../inc/MantidAlgorithms/UnGroupWorkspace.h | 6 +- .../inc/MantidAlgorithms/UnwrapMonitor.h | 6 +- .../inc/MantidAlgorithms/UnwrapSNS.h | 6 +- .../MantidAlgorithms/UpdateScriptRepository.h | 5 +- .../inc/MantidAlgorithms/WeightedMean.h | 6 +- .../WeightedMeanOfWorkspace.h | 5 +- .../inc/MantidAlgorithms/WorkspaceJoiners.h | 4 + .../Algorithms/src/AbsorptionCorrection.cpp | 1 - .../Algorithms/src/AddLogDerivative.cpp | 6 - .../Framework/Algorithms/src/AddPeak.cpp | 6 - .../Framework/Algorithms/src/AddSampleLog.cpp | 7 -- .../Algorithms/src/AddTimeSeriesLog.cpp | 6 - .../Algorithms/src/AlignDetectors.cpp | 7 -- .../Framework/Algorithms/src/AlphaCalc.cpp | 2 +- .../Algorithms/src/AnyShapeAbsorption.cpp | 7 -- .../Algorithms/src/ApplyCalibration.cpp | 7 -- .../Algorithms/src/ApplyDeadTimeCorr.cpp | 2 +- .../Algorithms/src/ApplyDetailedBalance.cpp | 6 - .../src/ApplyTransmissionCorrection.cpp | 7 -- .../Algorithms/src/AsymmetryCalc.cpp | 2 +- .../Algorithms/src/AverageLogData.cpp | 9 -- .../Algorithms/src/BinaryOperateMasks.cpp | 7 +- .../Algorithms/src/CalMuonDeadTime.cpp | 2 +- .../Algorithms/src/CalculateEfficiency.cpp | 7 -- .../src/CalculateFlatBackground.cpp | 7 -- .../Algorithms/src/CalculateTransmission.cpp | 7 -- .../src/CalculateTransmissionBeamSpreader.cpp | 7 -- .../Algorithms/src/CalculateZscore.cpp | 7 +- .../Algorithms/src/ChangeBinOffset.cpp | 7 -- .../Algorithms/src/ChangeLogTime.cpp | 7 -- .../Algorithms/src/ChangePulsetime.cpp | 6 - .../Algorithms/src/CheckWorkspacesMatch.cpp | 7 -- .../Framework/Algorithms/src/ChopData.cpp | 3 - .../Algorithms/src/ClearMaskFlag.cpp | 8 -- .../Algorithms/src/CloneWorkspace.cpp | 7 -- .../Algorithms/src/ConvertAxisByFormula.cpp | 7 -- .../src/ConvertFromDistribution.cpp | 7 -- .../src/ConvertMDHistoToMatrixWorkspace.cpp | 7 -- .../Algorithms/src/ConvertSpectrumAxis.cpp | 7 -- .../Algorithms/src/ConvertSpectrumAxis2.cpp | 9 +- .../src/ConvertTableToMatrixWorkspace.cpp | 7 -- .../Algorithms/src/ConvertToDistribution.cpp | 7 -- .../src/ConvertToEventWorkspace.cpp | 6 - .../Algorithms/src/ConvertToHistogram.cpp | 7 -- .../src/ConvertToMatrixWorkspace.cpp | 7 -- .../Algorithms/src/ConvertToPointData.cpp | 7 -- .../Framework/Algorithms/src/ConvertUnits.cpp | 7 -- .../src/CopyInstrumentParameters.cpp | 7 -- .../Framework/Algorithms/src/CopyLogs.cpp | 6 - .../Framework/Algorithms/src/CopySample.cpp | 6 - .../Algorithms/src/CorrectFlightPaths.cpp | 8 -- .../Framework/Algorithms/src/CorrectKiKf.cpp | 8 -- .../Algorithms/src/CorrectToFile.cpp | 7 -- .../Algorithms/src/CreateCalFileByNames.cpp | 7 -- .../Algorithms/src/CreateDummyCalFile.cpp | 7 -- .../src/CreateFlatEventWorkspace.cpp | 6 - .../src/CreateGroupingWorkspace.cpp | 6 - .../Algorithms/src/CreateLogPropertyTable.cpp | 9 -- .../src/CreateLogTimeCorrection.cpp | 11 +- .../Algorithms/src/CreatePSDBleedMask.cpp | 7 -- .../Algorithms/src/CreatePeaksWorkspace.cpp | 6 - .../Algorithms/src/CreateSampleWorkspace.cpp | 10 -- .../src/CreateSingleValuedWorkspace.cpp | 7 -- .../src/CreateTransmissionWorkspace.cpp | 7 -- .../Algorithms/src/CreateWorkspace.cpp | 7 -- .../Algorithms/src/CropWorkspace.cpp | 7 -- .../Algorithms/src/CrossCorrelate.cpp | 7 -- .../src/CuboidGaugeVolumeAbsorption.cpp | 7 -- .../Algorithms/src/CylinderAbsorption.cpp | 7 -- .../Framework/Algorithms/src/DeleteLog.cpp | 6 - .../Algorithms/src/DeleteWorkspace.cpp | 7 -- .../Algorithms/src/DetectorDiagnostic.cpp | 6 - .../Algorithms/src/DetectorEfficiencyCor.cpp | 7 -- .../src/DetectorEfficiencyCorUser.cpp | 7 -- .../src/DetectorEfficiencyVariation.cpp | 7 -- .../DiffractionEventCalibrateDetectors.cpp | 7 -- .../Algorithms/src/DiffractionFocussing.cpp | 7 -- .../Algorithms/src/DiffractionFocussing2.cpp | 7 -- .../Framework/Algorithms/src/Divide.cpp | 10 -- .../Algorithms/src/EQSANSResolution.cpp | 7 -- .../Algorithms/src/EQSANSTofStructure.cpp | 7 -- .../Algorithms/src/EditInstrumentGeometry.cpp | 6 - .../Algorithms/src/ElasticWindow.cpp | 7 -- .../src/EstimatePDDetectorResolution.cpp | 8 -- .../Framework/Algorithms/src/Exponential.cpp | 6 - .../Algorithms/src/ExponentialCorrection.cpp | 7 -- .../Algorithms/src/ExportTimeSeriesLog.cpp | 4 - .../Algorithms/src/ExtractFFTSpectrum.cpp | 7 -- .../Framework/Algorithms/src/ExtractMask.cpp | 7 -- .../Algorithms/src/ExtractMaskToTable.cpp | 7 +- .../Algorithms/src/ExtractSingleSpectrum.cpp | 7 -- Code/Mantid/Framework/Algorithms/src/FFT.cpp | 7 -- .../Algorithms/src/FFTDerivative.cpp | 7 -- .../Framework/Algorithms/src/FFTSmooth.cpp | 7 -- .../Framework/Algorithms/src/FFTSmooth2.cpp | 7 -- .../Algorithms/src/FilterBadPulses.cpp | 7 -- .../Algorithms/src/FilterByLogValue.cpp | 7 -- .../Framework/Algorithms/src/FilterByTime.cpp | 7 -- .../Algorithms/src/FilterByTime2.cpp | 5 - .../Algorithms/src/FilterByXValue.cpp | 7 -- .../Framework/Algorithms/src/FilterEvents.cpp | 5 - .../src/FindCenterOfMassPosition.cpp | 7 -- .../src/FindCenterOfMassPosition2.cpp | 7 -- .../Algorithms/src/FindDeadDetectors.cpp | 7 -- .../src/FindDetectorsOutsideLimits.cpp | 7 -- .../Algorithms/src/FindPeakBackground.cpp | 7 +- .../Framework/Algorithms/src/FindPeaks.cpp | 7 +- .../Framework/Algorithms/src/FitPeak.cpp | 9 +- .../Algorithms/src/FixGSASInstrumentFile.cpp | 9 +- .../Algorithms/src/FlatPlateAbsorption.cpp | 7 -- .../src/GeneralisedSecondDifference.cpp | 9 -- .../Algorithms/src/GenerateEventsFilter.cpp | 5 - .../Algorithms/src/GeneratePeaks.cpp | 6 +- .../Algorithms/src/GeneratePythonScript.cpp | 6 - .../src/GetDetOffsetsMultiPeaks.cpp | 11 -- .../Algorithms/src/GetDetectorOffsets.cpp | 7 -- .../Mantid/Framework/Algorithms/src/GetEi.cpp | 7 -- .../Framework/Algorithms/src/GetEi2.cpp | 7 -- .../src/GetTimeSeriesLogInformation.cpp | 6 - .../Algorithms/src/GroupWorkspaces.cpp | 2 +- .../Algorithms/src/HRPDSlabCanAbsorption.cpp | 7 -- .../Algorithms/src/He3TubeEfficiency.cpp | 7 -- .../Framework/Algorithms/src/IQTransform.cpp | 7 -- .../Algorithms/src/IdentifyNoisyDetectors.cpp | 7 -- .../Algorithms/src/IntegrateByComponent.cpp | 6 - .../Framework/Algorithms/src/Integration.cpp | 7 -- .../Algorithms/src/InterpolatingRebin.cpp | 7 -- .../Framework/Algorithms/src/InvertMask.cpp | 8 -- .../Framework/Algorithms/src/Logarithm.cpp | 5 - .../Framework/Algorithms/src/MaskBins.cpp | 7 -- .../Algorithms/src/MaskBinsFromTable.cpp | 5 - .../Algorithms/src/MaskDetectorsIf.cpp | 7 -- Code/Mantid/Framework/Algorithms/src/Max.cpp | 7 -- .../Framework/Algorithms/src/MaxMin.cpp | 7 -- .../Framework/Algorithms/src/MergeRuns.cpp | 7 -- Code/Mantid/Framework/Algorithms/src/Min.cpp | 7 -- .../Mantid/Framework/Algorithms/src/Minus.cpp | 7 -- .../Algorithms/src/ModeratorTzero.cpp | 7 -- .../Algorithms/src/ModeratorTzeroLinear.cpp | 7 -- .../Framework/Algorithms/src/Multiply.cpp | 7 -- .../Algorithms/src/MultiplyRange.cpp | 7 -- .../Algorithms/src/MuonGroupDetectors.cpp | 6 - .../Algorithms/src/NormaliseByCurrent.cpp | 7 -- .../Algorithms/src/NormaliseByDetector.cpp | 6 - .../Algorithms/src/NormaliseToMonitor.cpp | 8 -- .../Algorithms/src/NormaliseToUnity.cpp | 7 -- .../Algorithms/src/OneMinusExponentialCor.cpp | 7 -- .../Algorithms/src/PDFFourierTransform.cpp | 6 - .../Mantid/Framework/Algorithms/src/Pause.cpp | 6 - .../Algorithms/src/PerformIndexOperations.cpp | 6 - .../src/PlotAsymmetryByLogValue.cpp | 7 -- Code/Mantid/Framework/Algorithms/src/Plus.cpp | 7 -- .../src/PointByPointVCorrection.cpp | 7 -- .../Algorithms/src/PoissonErrors.cpp | 7 -- .../Algorithms/src/PolynomialCorrection.cpp | 7 -- .../Mantid/Framework/Algorithms/src/Power.cpp | 6 - .../Algorithms/src/PowerLawCorrection.cpp | 7 -- Code/Mantid/Framework/Algorithms/src/Q1D2.cpp | 7 -- .../Framework/Algorithms/src/Q1DTOF.cpp | 7 -- .../Framework/Algorithms/src/Q1DWeighted.cpp | 7 -- Code/Mantid/Framework/Algorithms/src/Qxy.cpp | 7 -- .../Framework/Algorithms/src/RadiusSum.cpp | 6 - .../Algorithms/src/RayTracerTester.cpp | 6 - .../Algorithms/src/ReadGroupsFromFile.cpp | 8 -- .../Framework/Algorithms/src/RealFFT.cpp | 7 -- .../Mantid/Framework/Algorithms/src/Rebin.cpp | 7 -- .../Framework/Algorithms/src/Rebin2D.cpp | 7 +- .../Algorithms/src/RebinByPulseTimes.cpp | 6 - .../Algorithms/src/RebinToWorkspace.cpp | 7 -- .../Framework/Algorithms/src/Rebunch.cpp | 7 -- .../Algorithms/src/RecordPythonScript.cpp | 6 - .../src/ReflectometryReductionOne.cpp | 6 - .../Framework/Algorithms/src/Regroup.cpp | 7 -- .../Framework/Algorithms/src/RemoveBins.cpp | 7 -- .../Algorithms/src/RemoveExpDecay.cpp | 7 -- .../Algorithms/src/RemovePromptPulse.cpp | 8 -- .../Algorithms/src/RenameWorkspace.cpp | 6 - .../Algorithms/src/RenameWorkspaces.cpp | 6 - .../Algorithms/src/ReplaceSpecialValues.cpp | 7 -- .../Framework/Algorithms/src/ResampleX.cpp | 8 -- .../Algorithms/src/ResetNegatives.cpp | 7 +- .../src/ResizeRectangularDetector.cpp | 6 - .../Framework/Algorithms/src/RingProfile.cpp | 6 - .../Algorithms/src/SANSDirectBeamScaling.cpp | 7 -- .../Framework/Algorithms/src/SassenaFFT.cpp | 7 -- .../Algorithms/src/SaveGSASInstrumentFile.cpp | 5 - .../Mantid/Framework/Algorithms/src/Scale.cpp | 7 -- .../Framework/Algorithms/src/ScaleX.cpp | 7 -- .../Algorithms/src/SetInstrumentParameter.cpp | 6 - .../Algorithms/src/SetUncertainties.cpp | 7 -- .../Framework/Algorithms/src/ShiftLogTime.cpp | 9 -- .../Algorithms/src/SignalOverError.cpp | 6 - .../Framework/Algorithms/src/SmoothData.cpp | 7 -- .../Algorithms/src/SmoothNeighbours.cpp | 7 -- .../Mantid/Framework/Algorithms/src/SofQW.cpp | 7 -- .../Framework/Algorithms/src/SofQW2.cpp | 6 - .../Framework/Algorithms/src/SofQW3.cpp | 6 - .../Framework/Algorithms/src/SolidAngle.cpp | 7 -- .../Framework/Algorithms/src/SortEvents.cpp | 7 -- .../Algorithms/src/SpatialGrouping.cpp | 7 -- .../src/SpecularReflectionCalculateTheta.cpp | 7 -- .../src/SpecularReflectionPositionCorrect.cpp | 7 -- .../Algorithms/src/SphericalAbsorption.cpp | 7 -- .../Framework/Algorithms/src/StripPeaks.cpp | 7 -- .../Algorithms/src/StripVanadiumPeaks.cpp | 7 -- .../Algorithms/src/StripVanadiumPeaks2.cpp | 5 - .../Algorithms/src/SumEventsByLogValue.cpp | 7 -- .../Algorithms/src/SumNeighbours.cpp | 7 -- .../Framework/Algorithms/src/SumRowColumn.cpp | 7 -- .../Framework/Algorithms/src/SumSpectra.cpp | 7 -- .../Algorithms/src/TOFSANSResolution.cpp | 7 -- .../Framework/Algorithms/src/Transpose.cpp | 7 -- .../Algorithms/src/UnGroupWorkspace.cpp | 7 -- .../Algorithms/src/UnwrapMonitor.cpp | 7 -- .../Framework/Algorithms/src/UnwrapSNS.cpp | 7 -- .../Algorithms/src/UpdateScriptRepository.cpp | 6 - .../Framework/Algorithms/src/WeightedMean.cpp | 7 -- .../src/WeightedMeanOfWorkspace.cpp | 6 - .../Algorithms/src/WorkspaceJoiners.cpp | 7 -- Code/Tools/DocMigration/MigrateOptMessage.py | 118 ++++++++++++++++++ 433 files changed, 997 insertions(+), 1845 deletions(-) create mode 100644 Code/Tools/DocMigration/MigrateOptMessage.py diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/Algorithm.h b/Code/Mantid/Framework/API/inc/MantidAPI/Algorithm.h index e91c534a62cf..c0aafc87d5f4 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/Algorithm.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/Algorithm.h @@ -177,15 +177,18 @@ class MANTID_API_DLL Algorithm : public IAlgorithm, public Kernel::PropertyManag virtual const std::string name() const = 0; /// function to return a version of the algorithm, must be overridden in all algorithms virtual int version() const = 0; + /// function returns a summary message that will be displayed in the default GUI, and in the help. + virtual const std::string summary() const = 0; /// function to return a category of the algorithm. A default implementation is provided virtual const std::string category() const {return "Misc";} /// Function to return all of the categories that contain this algorithm virtual const std::vector categories() const; - /// Function to return the sperator token for the category string. A default implementation ';' is provided + /// Function to return the separator token for the category string. A default implementation ';' is provided virtual const std::string categorySeparator() const {return ";";} /// function to return any aliases to the algorithm; A default implementation is provided virtual const std::string alias() const {return "";} + const std::string workspaceMethodName() const; const std::vector workspaceMethodOn() const; const std::string workspaceMethodInputProperty() const; @@ -237,25 +240,6 @@ class MANTID_API_DLL Algorithm : public IAlgorithm, public Kernel::PropertyManag ///returns the logging priority offset int getLoggingOffset() const { return g_log.getLevelOffset(); } - - /// function returns an optional message that will be displayed in the default GUI, at the top. - const std::string getOptionalMessage() const { return m_OptionalMessage;} - - /// Set an optional message that will be displayed in the default GUI, at the top. - void setOptionalMessage(const std::string optionalMessage) { m_OptionalMessage = optionalMessage;} - - /// Get a summary to be used in the wiki page. - const std::string getWikiSummary() const { return m_WikiSummary;} - - /// Set a summary to be used in the wiki page. Normally, this is approx. the same as the optional message. - void setWikiSummary(const std::string WikiSummary) { m_WikiSummary = WikiSummary;} - - /// Get a description to be used in the wiki page. - const std::string getWikiDescription() const { return m_WikiDescription;} - - /// Set a string to be used as the Description field in the wiki page. - void setWikiDescription(const std::string WikiDescription) { m_WikiDescription = WikiDescription;} - ///setting the child start progress void setChildStartProgress(const double startProgress)const{m_startChildProgress=startProgress;} /// setting the child end progress @@ -283,8 +267,6 @@ class MANTID_API_DLL Algorithm : public IAlgorithm, public Kernel::PropertyManag virtual void init() = 0; /// Virtual method - must be overridden by concrete algorithm virtual void exec() = 0; - /// Method defining summary, optional - virtual void initDocs() {}; /// Returns a semi-colon separated list of workspace types to attach this algorithm virtual const std::string workspaceMethodOnTypes() const { return ""; } @@ -386,9 +368,6 @@ class MANTID_API_DLL Algorithm : public IAlgorithm, public Kernel::PropertyManag mutable double m_startChildProgress; ///< Keeps value for algorithm's progress at start of an Child Algorithm mutable double m_endChildProgress; ///< Keeps value for algorithm's progress at Child Algorithm's finish AlgorithmID m_algorithmID; ///< Algorithm ID for managed algorithms - std::string m_OptionalMessage; ///< An optional message string to be displayed in the GUI. - std::string m_WikiSummary; ///< A summary line for the wiki page. - std::string m_WikiDescription; ///< Description in the wiki page. std::vector> m_ChildAlgorithms; ///< A list of weak pointers to any child algorithms created /// Vector of all the workspaces that have been read-locked diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmProxy.h b/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmProxy.h index a76373341f74..182878ba1ebe 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmProxy.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/AlgorithmProxy.h @@ -81,14 +81,12 @@ namespace Mantid const std::string categorySeparator() const {return m_categorySeparator;} /// Aliases to the algorithm const std::string alias() const {return m_alias;} + /// function returns a summary message that will be displayed in the default GUI, and in the help. + const std::string summary() const {return m_summary;} /// The algorithmID AlgorithmID getAlgorithmID() const; - virtual const std::string getOptionalMessage() const { return m_OptionalMessage; } - virtual const std::string getWikiSummary() const { return m_WikiSummary; } - virtual const std::string getWikiDescription() const { return m_WikiDescription; } - void initialize(); std::map validateInputs(); bool execute(); @@ -145,9 +143,6 @@ namespace Mantid virtual std::string toString() const; //@} - /// Set the wiki summary. - virtual void setWikiSummary(const std::string wikiSummary){m_WikiSummary = wikiSummary;} - private: /// Private Copy constructor: NO COPY ALLOWED AlgorithmProxy(const AlgorithmProxy&); @@ -169,9 +164,7 @@ namespace Mantid const std::string m_category; ///< category of the real algorithm const std::string m_categorySeparator; ///< category seperator of the real algorithm const std::string m_alias; ///< alias to the algorithm - std::string m_OptionalMessage; /// m_alg; ///< Shared pointer to a real algorithm. Created on demand diff --git a/Code/Mantid/Framework/API/inc/MantidAPI/IAlgorithm.h b/Code/Mantid/Framework/API/inc/MantidAPI/IAlgorithm.h index 5d01a1f65bd6..ec14a1fea681 100644 --- a/Code/Mantid/Framework/API/inc/MantidAPI/IAlgorithm.h +++ b/Code/Mantid/Framework/API/inc/MantidAPI/IAlgorithm.h @@ -64,6 +64,9 @@ class MANTID_API_DLL IAlgorithm : virtual public Kernel::IPropertyManager /// function to return a version of the algorithm, must be overridden in all algorithms virtual int version() const = 0; + + /// function returns a summary message that will be displayed in the default GUI, and in the help. + virtual const std::string summary() const = 0; /// function to return a category of the algorithm. virtual const std::string category() const = 0; @@ -90,15 +93,6 @@ class MANTID_API_DLL IAlgorithm : virtual public Kernel::IPropertyManager /// Algorithm ID. Unmanaged algorithms return 0 (or NULL?) values. Managed ones have non-zero. virtual AlgorithmID getAlgorithmID()const = 0; - /// function returns an optional message that will be displayed in the default GUI, at the top. - virtual const std::string getOptionalMessage() const = 0; - - /// Get a summary to be used in the wiki page. - virtual const std::string getWikiSummary() const = 0; - - /// Get a description to be used in the wiki page. - virtual const std::string getWikiDescription() const = 0; - /** Initialization method invoked by the framework. This method is responsible * for any bookkeeping of initialization required by the framework itself. * It will in turn invoke the init() method of the derived algorithm, @@ -168,8 +162,6 @@ class MANTID_API_DLL IAlgorithm : virtual public Kernel::IPropertyManager virtual void setChildEndProgress(const double endProgress)const = 0; /// Serialize an algorithm virtual std::string toString() const = 0; - /// Set the wiki summary. - virtual void setWikiSummary(const std::string WikiSummary) = 0; }; typedef boost::shared_ptr IAlgorithm_sptr; diff --git a/Code/Mantid/Framework/API/src/Algorithm.cpp b/Code/Mantid/Framework/API/src/Algorithm.cpp index f9a4c1dffd41..37098430e5d8 100644 --- a/Code/Mantid/Framework/API/src/Algorithm.cpp +++ b/Code/Mantid/Framework/API/src/Algorithm.cpp @@ -320,9 +320,6 @@ namespace Mantid getLogger().fatal("UNKNOWN Exception is caught in initialize()"); throw; } - - // Set the documentation. This virtual method is overridden by (nearly) all algorithms and gives documentation summary. - initDocs(); } //--------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/API/src/AlgorithmProxy.cpp b/Code/Mantid/Framework/API/src/AlgorithmProxy.cpp index a75396630a3b..28253008fce8 100644 --- a/Code/Mantid/Framework/API/src/AlgorithmProxy.cpp +++ b/Code/Mantid/Framework/API/src/AlgorithmProxy.cpp @@ -25,7 +25,7 @@ namespace Mantid AlgorithmProxy::AlgorithmProxy(Algorithm_sptr alg) : PropertyManagerOwner(), m_executeAsync(new Poco::ActiveMethod(this,&AlgorithmProxy::executeAsyncImpl)), m_name(alg->name()),m_category(alg->category()), m_categorySeparator(alg->categorySeparator()), - m_alias(alg->alias()), m_version(alg->version()), m_alg(alg), + m_alias(alg->alias()),m_summary(alg->summary()), m_version(alg->version()), m_alg(alg), m_isExecuted(),m_isLoggingEnabled(true), m_loggingOffset(0), m_rethrow(false), m_isChild(false) { @@ -34,9 +34,6 @@ namespace Mantid throw std::logic_error("Unable to create a proxy algorithm."); } alg->initialize(); - m_OptionalMessage = alg->getOptionalMessage(); - m_WikiSummary = alg->getWikiSummary(); - m_WikiDescription = alg->getWikiDescription(); copyPropertiesFrom(*alg); } diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AbsorptionCorrection.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AbsorptionCorrection.h index 198eb7fe48e8..bfe66264123d 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AbsorptionCorrection.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AbsorptionCorrection.h @@ -65,7 +65,9 @@ class DLLExport AbsorptionCorrection : public API::Algorithm virtual ~AbsorptionCorrection() {} /// Algorithm's category for identification virtual const std::string category() const { return "CorrectionFunctions\\AbsorptionCorrections"; } - + /// Algorithm's summary + virtual const std::string summary() const { return "Calculates an approximation of the attenuation due to absorption and single scattering in a generic sample shape. The sample shape can be defined by the CreateSampleShape algorithm."; } + protected: /** A virtual function in which additional properties of an algorithm should be declared. * Called by init(). diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddLogDerivative.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddLogDerivative.h index f2dd801fcbef..d63af02e7a2e 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddLogDerivative.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddLogDerivative.h @@ -44,6 +44,9 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const { return "AddLogDerivative";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Add a sample log that is the first or second derivative of an existing sample log.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification @@ -53,8 +56,7 @@ namespace Algorithms const std::string & name, int numDerivatives); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddPeak.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddPeak.h index 903bc0627e70..971de6b046fc 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddPeak.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddPeak.h @@ -42,14 +42,16 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const { return "AddPeak";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Adds a peak to a PeaksWorkspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal;Utility\\Workspaces";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddSampleLog.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddSampleLog.h index 078273f1aca6..01059c5517ec 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddSampleLog.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddSampleLog.h @@ -54,14 +54,16 @@ class DLLExport AddSampleLog : public API::Algorithm virtual ~AddSampleLog() {} /// Algorithm's name virtual const std::string name() const { return "AddSampleLog"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Used to insert a value into the sample logs in a workspace.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "DataHandling\\Logs"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddTimeSeriesLog.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddTimeSeriesLog.h index ab5171845f3f..1b09d95c080a 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddTimeSeriesLog.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AddTimeSeriesLog.h @@ -33,11 +33,13 @@ namespace Mantid { public: virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates/updates a time-series log";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AlignDetectors.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AlignDetectors.h index ba6eb61c9d3b..f8fd7741ff7e 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AlignDetectors.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AlignDetectors.h @@ -53,6 +53,9 @@ class DLLExport AlignDetectors : public API::Algorithm /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "AlignDetectors";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs a unit change from TOF to dSpacing, correcting the X values to account for small errors in the detector positions.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method @@ -63,8 +66,7 @@ class DLLExport AlignDetectors : public API::Algorithm Mantid::DataObjects::OffsetsWorkspace_sptr offsetsWS); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AlphaCalc.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AlphaCalc.h index 9580bc6324ff..3984a0650b80 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AlphaCalc.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AlphaCalc.h @@ -55,6 +55,9 @@ namespace Mantid virtual ~AlphaCalc() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "AlphaCalc";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Muon algorithm for calculating the detector efficiency between two groups of detectors.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AnyShapeAbsorption.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AnyShapeAbsorption.h index e890fd64f034..e752094f8c8c 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AnyShapeAbsorption.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AnyShapeAbsorption.h @@ -73,12 +73,14 @@ class DLLExport AnyShapeAbsorption : public AbsorptionCorrection virtual ~AnyShapeAbsorption() {} /// Algorithm's name virtual const std::string name() const { return "AbsorptionCorrection"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates an approximation of the attenuation due to absorption and single scattering in a generic sample shape. The sample shape can be defined by, e.g., the CreateSampleShape algorithm.\nNote that if your sample is of cuboid or cylinder geometry, you will get a more accurate result from the FlatPlateAbsorption or CylinderAbsorption algorithms respectively.";} + /// Algorithm's version virtual int version() const { return (1); } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void defineProperties(); void retrieveProperties(); std::string sampleXML(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyCalibration.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyCalibration.h index 3b201342b267..ff2ff8ed3bab 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyCalibration.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyCalibration.h @@ -55,6 +55,9 @@ namespace Mantid /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "ApplyCalibration"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Update detector positions from input table workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; @@ -63,8 +66,7 @@ namespace Mantid virtual const std::string category() const { return "DataHandling\\Instrument";} // Needs to change private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. Does nothing at present void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyDeadTimeCorr.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyDeadTimeCorr.h index 95c16ad96153..d2d85a9be27b 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyDeadTimeCorr.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyDeadTimeCorr.h @@ -43,6 +43,9 @@ namespace Algorithms virtual ~ApplyDeadTimeCorr() {}; /// Algorithm's name for identification virtual const std::string name() const { return "ApplyDeadTimeCorr";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Apply deadtime correction to each spectra of a workspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyDetailedBalance.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyDetailedBalance.h index 4b4ea50cec1d..55c13b20742c 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyDetailedBalance.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyDetailedBalance.h @@ -42,14 +42,16 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const { return "ApplyDetailedBalance";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Transform scattering intensity to dynamic susceptibility.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Inelastic";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyTransmissionCorrection.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyTransmissionCorrection.h index afeec0c1f573..d08f6ee4f0b5 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyTransmissionCorrection.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ApplyTransmissionCorrection.h @@ -44,14 +44,16 @@ class DLLExport ApplyTransmissionCorrection : public API::Algorithm virtual ~ApplyTransmissionCorrection() {} /// Algorithm's name virtual const std::string name() const { return "ApplyTransmissionCorrection"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Apply a transmission correction to 2D SANS data.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS;CorrectionFunctions\\TransmissionCorrections"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AsymmetryCalc.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AsymmetryCalc.h index 4c88756a7aa5..deb9582eb9d7 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AsymmetryCalc.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AsymmetryCalc.h @@ -56,6 +56,9 @@ namespace Mantid virtual ~AsymmetryCalc() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "AsymmetryCalc";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates the asymmetry between two groups of detectors for a muon workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AverageLogData.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AverageLogData.h index f97ad70ad15f..26464630c553 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AverageLogData.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/AverageLogData.h @@ -40,9 +40,12 @@ namespace Algorithms virtual const std::string name() const; virtual int version() const; virtual const std::string category() const; + /// Algorithm's summary + virtual const std::string summary() const { return "Computes the proton charge averaged value of a given log."; } + private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/BinaryOperateMasks.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/BinaryOperateMasks.h index 17d15df9532c..2fac6babc983 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/BinaryOperateMasks.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/BinaryOperateMasks.h @@ -39,14 +39,16 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "BinaryOperateMasks";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs binary operation, including and, or and xor, on two mask Workspaces, i.e., SpecialWorkspace2D.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Masking";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalMuonDeadTime.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalMuonDeadTime.h index 846772d0b56e..68d86c3da0d9 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalMuonDeadTime.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalMuonDeadTime.h @@ -44,6 +44,9 @@ namespace Mantid virtual ~CalMuonDeadTime() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CalMuonDeadTime";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate Muon deadtime for each spectra in a workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateEfficiency.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateEfficiency.h index 8e2ee2151924..3fb76796bc39 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateEfficiency.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateEfficiency.h @@ -46,14 +46,16 @@ class DLLExport CalculateEfficiency : public API::Algorithm virtual ~CalculateEfficiency() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CalculateEfficiency";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates the detector efficiency for a SANS instrument.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "SANS;CorrectionFunctions\\EfficiencyCorrections";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateFlatBackground.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateFlatBackground.h index b11b2bc490b3..c97ac3a4aa56 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateFlatBackground.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateFlatBackground.h @@ -56,14 +56,16 @@ class DLLExport CalculateFlatBackground : public API::Algorithm virtual ~CalculateFlatBackground() {if(m_progress) delete m_progress;m_progress=NULL;} /// Algorithm's name virtual const std::string name() const { return "CalculateFlatBackground"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Finds a constant value fit to an appropriate range of each desired spectrum and subtracts that value from the entire spectrum.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS;CorrectionFunctions\\BackgroundCorrections"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateTransmission.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateTransmission.h index a60c4e2b9941..b8dfb5f54bb0 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateTransmission.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateTransmission.h @@ -66,6 +66,9 @@ class DLLExport CalculateTransmission : public API::Algorithm virtual ~CalculateTransmission(); /// Algorithm's name virtual const std::string name() const { return "CalculateTransmission"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates the transmission correction, as a function of wavelength, for a SANS instrument.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -74,8 +77,7 @@ class DLLExport CalculateTransmission : public API::Algorithm private: /// stores an estimate of the progress so far as a proportion (starts at zero goes to 1.0) mutable double m_done; - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateTransmissionBeamSpreader.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateTransmissionBeamSpreader.h index a07e59d5e9b8..a0035c3cc36a 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateTransmissionBeamSpreader.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateTransmissionBeamSpreader.h @@ -68,14 +68,16 @@ class DLLExport CalculateTransmissionBeamSpreader : public API::Algorithm virtual ~CalculateTransmissionBeamSpreader(); /// Algorithm's name virtual const std::string name() const { return "CalculateTransmissionBeamSpreader"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates the sample transmission using the beam spreader (aka glass carbon) method.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS;CorrectionFunctions\\TransmissionCorrections"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateZscore.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateZscore.h index 9ecbb7f11762..921161617b45 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateZscore.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CalculateZscore.h @@ -39,6 +39,9 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CalculateZscore";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate Z-score for Y and E of MatrixWorkspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} @@ -47,8 +50,7 @@ namespace Algorithms virtual const std::string category() const { return "Utility";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); /// Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangeBinOffset.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangeBinOffset.h index 013d339265c1..3688d7eafecd 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangeBinOffset.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangeBinOffset.h @@ -52,6 +52,9 @@ namespace Mantid virtual ~ChangeBinOffset(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "ChangeBinOffset";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Adjusts all the time bin values in a workspace by a specified amount.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method @@ -60,8 +63,7 @@ namespace Mantid virtual const std::string alias() const { return "OffsetX"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangeLogTime.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangeLogTime.h index 1f77456686e3..b14f79e12e94 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangeLogTime.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangeLogTime.h @@ -17,10 +17,10 @@ class DLLExport ChangeLogTime : public API::Algorithm const std::string name() const; int version() const; const std::string category() const; + /// Algorithm's summary + virtual const std::string summary() const { return "Adds a constant to the times for the requested log."; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangePulsetime.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangePulsetime.h index 8691d4298e7f..3827093ae7e6 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangePulsetime.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChangePulsetime.h @@ -22,14 +22,16 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const { return "ChangePulsetime";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Adds a constant time value, in seconds, to the pulse time of events in an EventWorkspace. ";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Events;Transforms\\Axes";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CheckWorkspacesMatch.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CheckWorkspacesMatch.h index dce03429686f..dd3f2a1ed243 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CheckWorkspacesMatch.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CheckWorkspacesMatch.h @@ -67,6 +67,9 @@ class DLLExport CheckWorkspacesMatch : public API::Algorithm virtual ~CheckWorkspacesMatch(); /// Algorithm's name virtual const std::string name() const { return "CheckWorkspacesMatch"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Compares two workspaces for equality. This algorithm is mainly intended for use by the Mantid development team as part of the testing process.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -84,8 +87,7 @@ class DLLExport CheckWorkspacesMatch : public API::Algorithm virtual bool processGroups(); // Process the two groups void processGroups(boost::shared_ptr groupOne, boost::shared_ptr groupTwo); - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChopData.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChopData.h index 98f340d3266d..74f17b354995 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChopData.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ChopData.h @@ -44,6 +44,10 @@ namespace Algorithms virtual const std::string name() const { return "ChopData"; } ///< @return the algorithms name virtual const std::string category() const { return "Transforms\\Splitting"; } ///< @return the algorithms category virtual int version() const { return (1); } ///< @return version number of algorithm + /// Algorithm's summary + virtual const std::string summary() const { return "Splits an input workspace into a grouped workspace, where each spectra " + "if 'chopped' at a certain point (given in 'Step' input value) " + "and the X values adjusted to give all the workspace in the group the same binning."; } private: void init(); ///< Initialise the algorithm. Declare properties, etc. diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ClearMaskFlag.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ClearMaskFlag.h index 6ce9c688b843..9361f4589476 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ClearMaskFlag.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ClearMaskFlag.h @@ -40,9 +40,11 @@ namespace Algorithms virtual const std::string name() const; virtual int version() const; virtual const std::string category() const; + /// Algorithm's summary + virtual const std::string summary() const { return "Delete the mask flag/bit on all spectra in a workspace."; } private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CloneWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CloneWorkspace.h index 210f6e2fac30..0a2a65cc0cdf 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CloneWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CloneWorkspace.h @@ -51,6 +51,9 @@ class DLLExport CloneWorkspace : public API::Algorithm virtual ~CloneWorkspace() {} /// Algorithm's name virtual const std::string name() const { return "CloneWorkspace"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Copies an existing workspace into a new one.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -60,8 +63,7 @@ class DLLExport CloneWorkspace : public API::Algorithm const std::string workspaceMethodName() const { return "clone"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertAxisByFormula.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertAxisByFormula.h index 2f9fbfac46e3..6574b7551251 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertAxisByFormula.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertAxisByFormula.h @@ -38,14 +38,16 @@ namespace Algorithms virtual ~ConvertAxisByFormula(); const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts the X or Y axis of a MatrixWorkspace via a user defined math formula.";} + int version() const; const std::string category() const; private: void init(); void exec(); - /// Sets documentation strings for this algorithm - void initDocs(); + }; diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertFromDistribution.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertFromDistribution.h index a5d87a2f3b4a..14878320cb73 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertFromDistribution.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertFromDistribution.h @@ -49,14 +49,16 @@ class DLLExport ConvertFromDistribution : public API::Algorithm virtual ~ConvertFromDistribution() {} /// Algorithm's name virtual const std::string name() const { return "ConvertFromDistribution"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts a histogram workspace from a distribution i.e. multiplies by the bin width.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Distribution"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertMDHistoToMatrixWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertMDHistoToMatrixWorkspace.h index e9bd0c8f5116..02dad640d15f 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertMDHistoToMatrixWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertMDHistoToMatrixWorkspace.h @@ -52,8 +52,11 @@ class DLLExport ConvertMDHistoToMatrixWorkspace : public API::Algorithm virtual ~ConvertMDHistoToMatrixWorkspace() {} /// Algorithm's name - virtual const std::string name() const - { return "ConvertMDHistoToMatrixWorkspace";} + virtual const std::string name() const { return "ConvertMDHistoToMatrixWorkspace";}; + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates a single spectrum Workspace2D with X,Y, and E copied from an first non-integrated dimension of a IMDHistoWorkspace.";} + /// Algorithm's version virtual int version() const { return (1);} @@ -62,8 +65,7 @@ class DLLExport ConvertMDHistoToMatrixWorkspace : public API::Algorithm { return "Utility\\Workspaces";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertSpectrumAxis.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertSpectrumAxis.h index 5639baaff84f..5091493ba104 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertSpectrumAxis.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertSpectrumAxis.h @@ -57,14 +57,16 @@ class DLLExport ConvertSpectrumAxis : public API::Algorithm virtual ~ConvertSpectrumAxis() {} /// Algorithm's name virtual const std::string name() const { return "ConvertSpectrumAxis"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts the axis of a Workspace2D which normally holds spectrum numbers to some other unit, which will normally be some physical value about the instrument such as Q, Q^2 or theta. 'Note': After running this algorithm, some features will be unavailable on the workspace as it will have lost all connection to the instrument. This includes things like the 3D Instrument Display.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Units;Transforms\\Axes"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertSpectrumAxis2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertSpectrumAxis2.h index 1484fb44bdd9..86cf7edf30ff 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertSpectrumAxis2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertSpectrumAxis2.h @@ -37,14 +37,16 @@ class DLLExport ConvertSpectrumAxis2 : public API::Algorithm virtual ~ConvertSpectrumAxis2() {} /// Algorithm's name virtual const std::string name() const { return "ConvertSpectrumAxis"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts the axis of a Workspace2D which normally holds spectrum numbers to one of Q, Q^2 or theta. 'Note': After running this algorithm, some features will be unavailable on the workspace as it will have lost all connection to the instrument. This includes things like the 3D Instrument Display.";} + /// Algorithm's version virtual int version() const { return (2); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Units;Transforms\\Axes"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertTableToMatrixWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertTableToMatrixWorkspace.h index 0f8828644a6a..cd4aa1b8c863 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertTableToMatrixWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertTableToMatrixWorkspace.h @@ -54,8 +54,11 @@ class DLLExport ConvertTableToMatrixWorkspace : public API::Algorithm virtual ~ConvertTableToMatrixWorkspace() {} /// Algorithm's name - virtual const std::string name() const - { return "ConvertTableToMatrixWorkspace";} + virtual const std::string name() const { return "ConvertTableToMatrixWorkspace";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates a single spectrum matrix workspace from some columns of a table workspace.";} + + /// Algorithm's version virtual int version() const { return (1);} @@ -64,8 +67,7 @@ class DLLExport ConvertTableToMatrixWorkspace : public API::Algorithm { return "Utility\\Workspaces";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToDistribution.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToDistribution.h index 4258fee26db5..e2fdf722b994 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToDistribution.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToDistribution.h @@ -49,14 +49,16 @@ class DLLExport ConvertToDistribution : public API::Algorithm virtual ~ConvertToDistribution() {} /// Algorithm's name virtual const std::string name() const { return "ConvertToDistribution"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Makes a histogram workspace a distribution i.e. divides by the bin width.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Distribution"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToEventWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToEventWorkspace.h index 8036e6cd7768..659633125546 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToEventWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToEventWorkspace.h @@ -43,14 +43,16 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const { return "ConvertToEventWorkspace";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts a Workspace2D from histograms to events in an EventWorkspace by converting each bin to an equivalent weighted event.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Events";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToHistogram.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToHistogram.h index 05ec36e18204..13a8b73691da 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToHistogram.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToHistogram.h @@ -42,13 +42,15 @@ namespace Mantid public: /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "ConvertToHistogram"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts a workspace containing point data into one containing histograms.";} + /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Axes";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Returns true if the algorithm needs to be run. bool isProcessingRequired(const API::MatrixWorkspace_sptr inputWS) const; /// Checks the input workspace is consistent, throwing if not diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToMatrixWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToMatrixWorkspace.h index 38dd2f89f11c..084e7977d4be 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToMatrixWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToMatrixWorkspace.h @@ -52,8 +52,11 @@ class DLLExport ConvertToMatrixWorkspace : public API::Algorithm virtual ~ConvertToMatrixWorkspace() {} /// Algorithm's name - virtual const std::string name() const - { return "ConvertToMatrixWorkspace";} + virtual const std::string name() const { return "ConvertToMatrixWorkspace";} + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts an EventWorkspace into a Workspace2D, using the input workspace's current X bin values.";} + /// Algorithm's version virtual int version() const { return (1);} @@ -62,8 +65,7 @@ class DLLExport ConvertToMatrixWorkspace : public API::Algorithm { return "Events";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToPointData.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToPointData.h index 321fddcab563..10a64f94c1b4 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToPointData.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertToPointData.h @@ -42,13 +42,15 @@ namespace Mantid public: /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "ConvertToPointData"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts a workspace containing histogram data into one containing point data.";} + /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Axes";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Returns true if the algorithm needs to be run. bool isProcessingRequired(const API::MatrixWorkspace_sptr inputWS) const; /// Checks the input workspace is consistent, throwing if not diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertUnits.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertUnits.h index ad82a90e7ba9..9996ed2687bd 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertUnits.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ConvertUnits.h @@ -67,6 +67,9 @@ class DLLExport ConvertUnits : public API::Algorithm virtual ~ConvertUnits(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "ConvertUnits"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs a unit change on the X values of a workspace";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -76,8 +79,7 @@ class DLLExport ConvertUnits : public API::Algorithm const std::string workspaceMethodName() const { return "convertUnits"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopyInstrumentParameters.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopyInstrumentParameters.h index d194c21e7c40..7b07d60187b6 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopyInstrumentParameters.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopyInstrumentParameters.h @@ -57,6 +57,9 @@ class DLLExport CopyInstrumentParameters : public API::Algorithm virtual ~CopyInstrumentParameters(); /// Algorithm's name virtual const std::string name() const { return "CopyInstrumentParameters"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Transfers an instrument from on workspace to another workspace with same base instrument.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -64,8 +67,7 @@ class DLLExport CopyInstrumentParameters : public API::Algorithm /// method indicates that base source instrument is the same or different from base target instrument (mainly used in testing) bool isInstrumentDifferent()const{return m_different_instrument_sp;} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopyLogs.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopyLogs.h index 4d5a37579b4a..1347e3d84a3b 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopyLogs.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopyLogs.h @@ -44,12 +44,14 @@ namespace Algorithms virtual ~CopyLogs(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Copies the sample logs from one workspace to another.";} + virtual int version() const; virtual const std::string category() const; private: - /// Functions inherited from algorithm - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopySample.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopySample.h index 5b9df6ab7865..3e7a67066078 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopySample.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CopySample.h @@ -51,14 +51,16 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const { return "CopySample";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Copy some/all the sample information from one workspace to another.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Sample;Utility\\Workspaces;DataHandling";} virtual std::map validateInputs(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectFlightPaths.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectFlightPaths.h index 99f11cc62055..c963aca4dfa6 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectFlightPaths.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectFlightPaths.h @@ -50,9 +50,9 @@ class DLLExport CorrectFlightPaths: public API::Algorithm { } ; /// Algorithm's name for identification overriding a virtual method - virtual const std::string name() const { - return "CorrectFlightPaths"; - } + virtual const std::string name() const { return "CorrectFlightPaths"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Used to correct flight paths in 2D shaped detectors.";} /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; @@ -63,8 +63,7 @@ class DLLExport CorrectFlightPaths: public API::Algorithm { } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectKiKf.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectKiKf.h index 36569799246e..8acf8121f4a8 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectKiKf.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectKiKf.h @@ -62,14 +62,16 @@ class DLLExport CorrectKiKf : public API::Algorithm virtual ~CorrectKiKf(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CorrectKiKf"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs k_i/k_f multiplication, in order to transform differential scattering cross section into dynamic structure factor.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Inelastic;CorrectionFunctions";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectToFile.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectToFile.h index 5222d6828d9c..3e0bcfdd6132 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectToFile.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CorrectToFile.h @@ -52,14 +52,16 @@ class DLLExport CorrectToFile : public Mantid::API::Algorithm virtual ~CorrectToFile() {} /// Algorithm's name virtual const std::string name() const { return "CorrectToFile"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Correct data using a file in the LOQ RKH format";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS;CorrectionFunctions"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// used for the progress bar: the, approximate, fraction of processing time that taken up with loading the file static const double LOAD_TIME; /// Initialisation code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateCalFileByNames.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateCalFileByNames.h index 36372f1e3053..f9ab49fbb54c 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateCalFileByNames.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateCalFileByNames.h @@ -62,14 +62,16 @@ class DLLExport CreateCalFileByNames : public API::Algorithm virtual ~CreateCalFileByNames() {} /// Algorithm's name virtual const std::string name() const { return "CreateCalFileByNames"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create a calibration file (extension *.cal) for diffraction focusing based on the names of the components in the instrument tree.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Diffraction"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Calibration entries map typedef std::map > instrcalmap; /// Initialisation code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateDummyCalFile.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateDummyCalFile.h index 059ad18b9e98..da21549a8420 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateDummyCalFile.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateDummyCalFile.h @@ -58,14 +58,16 @@ class DLLExport CreateDummyCalFile : public API::Algorithm virtual ~CreateDummyCalFile() {} /// Algorithm's name virtual const std::string name() const { return "CreateDummyCalFile"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create a calibration file (extension *.cal) from a workspace by harvesting the detector ids from the instrument. All of the offsets will be zero, and the pixels will be all grouped into group one and the final column should be one. This will allow generating powder patterns from instruments that have not done a proper calibration.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Diffraction"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Calibration entries map typedef std::map > instrcalmap; /// Initialisation code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateFlatEventWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateFlatEventWorkspace.h index 9cd8fa5632c2..77d059d95e31 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateFlatEventWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateFlatEventWorkspace.h @@ -38,11 +38,14 @@ namespace Algorithms virtual ~CreateFlatEventWorkspace(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates a flat event workspace that can be used for background removal.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateGroupingWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateGroupingWorkspace.h index 4e609d070dcc..e7f4b69f0919 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateGroupingWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateGroupingWorkspace.h @@ -24,14 +24,16 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates a new GroupingWorkspace using an instrument from one of: an input workspace, an instrument name, or an instrument IDF file.\nOptionally uses bank names to create the groups.";} + /// Algorithm's version for identification virtual int version() const; /// Algorithm's category for identification virtual const std::string category() const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateLogPropertyTable.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateLogPropertyTable.h index a3d666e4640d..4249988b2dcc 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateLogPropertyTable.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateLogPropertyTable.h @@ -49,10 +49,13 @@ class DLLExport CreateLogPropertyTable : public API::Algorithm virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Utility;PythonAlgorithms";} + + /// Algorithm's summary + virtual const std::string summary() const { return " Takes a list of workspaces and a list of log property names. For each workspace, the Run info is inspected and " + "all log property values are used to populate a resulting output TableWorkspace."; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateLogTimeCorrection.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateLogTimeCorrection.h index 5b839694ef81..b0fd6cbfe585 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateLogTimeCorrection.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateLogTimeCorrection.h @@ -45,12 +45,14 @@ namespace Algorithms virtual ~CreateLogTimeCorrection(); virtual const std::string name() const {return "CreateLogTimeCorrection"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create log time correction table. Correction for each pixel is based on L1 and L2.";} + virtual int version() const {return 1; } virtual const std::string category() const {return "Events\\EventFiltering"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); /// Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreatePSDBleedMask.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreatePSDBleedMask.h index fa75b1ae6df8..bc3727848bbb 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreatePSDBleedMask.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreatePSDBleedMask.h @@ -51,11 +51,13 @@ namespace Mantid CreatePSDBleedMask(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CreatePSDBleedMask";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Runs a diagnostic test for saturation of PSD tubes and creates a MaskWorkspace marking the failed tube spectra.";} + virtual const std::string category() const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreatePeaksWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreatePeaksWorkspace.h index c61432ba4a32..d4527b8933af 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreatePeaksWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreatePeaksWorkspace.h @@ -22,14 +22,16 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const { return "CreatePeaksWorkspace";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create an empty PeaksWorkspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal;Utility\\Workspaces";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h index 0eedf4661211..0190f8d92285 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSampleWorkspace.h @@ -44,9 +44,11 @@ namespace Algorithms virtual const std::string name() const; virtual int version() const; virtual const std::string category() const; - + /// Algorithm's summary + virtual const std::string summary() const { return "Creates sample workspaces for usage examples and other situations."; } + private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSingleValuedWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSingleValuedWorkspace.h index 8f3ed31a4bd6..e7b5c662c972 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSingleValuedWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateSingleValuedWorkspace.h @@ -54,14 +54,16 @@ class DLLExport CreateSingleValuedWorkspace : public Mantid::API::Algorithm virtual ~CreateSingleValuedWorkspace() {} /// Algorithm's name virtual const std::string name() const { return "CreateSingleValuedWorkspace"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates a 2D workspace with a single value contained in it.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Utility\\Workspaces"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateTransmissionWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateTransmissionWorkspace.h index 830af898cffc..c5225c0bd799 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateTransmissionWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateTransmissionWorkspace.h @@ -38,6 +38,9 @@ namespace Mantid virtual ~CreateTransmissionWorkspace(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates a transmission run workspace in Wavelength from input TOF workspaces.";} + virtual int version() const; virtual const std::string category() const; @@ -53,7 +56,7 @@ namespace Mantid const OptionalDouble& stitchingStartOverlapQ, const OptionalDouble& stitchingEndOverlapQ, const double& wavelengthStep); - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateWorkspace.h index 6c197338ffbe..f5231572457a 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CreateWorkspace.h @@ -51,12 +51,14 @@ class DLLExport CreateWorkspace : public API::Algorithm virtual ~CreateWorkspace(); virtual const std::string name() const { return "CreateWorkspace"; } ///< @return the algorithms name + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm constructs a MatrixWorkspace when passed a vector for each of the X, Y, and E data values. The unit for the X Axis can optionally be specified as any of the units in the Kernel's UnitFactory. Multiple spectra may be created by supplying the NSpec Property (integer, default 1). When this is provided the vectors are split into equal-sized spectra (all X, Y, E values must still be in a single vector for input).";} + virtual const std::string category() const { return "Utility\\Workspaces"; } ///< @return the algorithms category virtual int version() const { return (1); } ///< @return version number of algorithm private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the Algorithm (declare properties) void init(); /// Execute the Algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CropWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CropWorkspace.h index 91aa7d3b1f7a..527f7c88864c 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CropWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CropWorkspace.h @@ -69,14 +69,16 @@ class DLLExport CropWorkspace : public API::Algorithm virtual ~CropWorkspace(); /// Algorithm's name virtual const std::string name() const { return "CropWorkspace"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Extracts a 'block' from a workspace and places it in a new workspace.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Splitting"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CrossCorrelate.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CrossCorrelate.h index 1b7f9fb25782..b4d9cba17516 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CrossCorrelate.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CrossCorrelate.h @@ -58,14 +58,16 @@ class DLLExport CrossCorrelate : public API::Algorithm virtual ~CrossCorrelate() {if(m_progress) delete m_progress;m_progress=NULL;} /// Algorithm's name virtual const std::string name() const { return "CrossCorrelate"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Cross-correlates a range of spectra against one reference spectra in the same workspace.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Utility;Arithmetic"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CuboidGaugeVolumeAbsorption.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CuboidGaugeVolumeAbsorption.h index 0319a2290667..185a23fa7c2f 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CuboidGaugeVolumeAbsorption.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CuboidGaugeVolumeAbsorption.h @@ -48,12 +48,14 @@ class DLLExport CuboidGaugeVolumeAbsorption : public FlatPlateAbsorption virtual ~CuboidGaugeVolumeAbsorption() {} /// Algorithm's name virtual const std::string name() const { return "CuboidGaugeVolumeAbsorption"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates bin-by-bin correction factors for attenuation due to absorption and (single) scattering within a cuboid shaped 'gauge volume' of a generic sample. The sample shape can be defined by, e.g., the CreateSampleShape algorithm.";} + /// Algorithm's version virtual int version() const { return (1); } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + std::string sampleXML(); void initialiseCachedDistances(); }; diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CylinderAbsorption.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CylinderAbsorption.h index ef6efc633f21..c2c5443847a7 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CylinderAbsorption.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CylinderAbsorption.h @@ -74,12 +74,14 @@ class DLLExport CylinderAbsorption : public AbsorptionCorrection virtual ~CylinderAbsorption() {} /// Algorithm's name virtual const std::string name() const { return "CylinderAbsorption"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates bin-by-bin correction factors for attenuation due to absorption and single scattering in a 'cylindrical' sample.";} + /// Algorithm's version virtual int version() const { return (1); } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void defineProperties(); void retrieveProperties(); std::string sampleXML(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DeleteLog.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DeleteLog.h index c657578faa06..e6407719bf55 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DeleteLog.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DeleteLog.h @@ -33,11 +33,14 @@ namespace Mantid { public: virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Removes a named log from a run";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); }; diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DeleteWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DeleteWorkspace.h index a638a2a794a6..dbfe7fbfae59 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DeleteWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DeleteWorkspace.h @@ -42,14 +42,16 @@ namespace Mantid public: /// Algorithm's name virtual const std::string name() const { return "DeleteWorkspace"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Removes a workspace from memory.";} + /// Algorithm's category for identification virtual const std::string category() const { return "Utility\\Workspaces"; } /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overridden init void init(); /// Overridden exec diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorDiagnostic.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorDiagnostic.h index fba991472244..d321186e539b 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorDiagnostic.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorDiagnostic.h @@ -53,10 +53,12 @@ namespace Mantid virtual const std::string category() const; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Identifies histograms and their detectors that have total numbers of counts over a user defined maximum or less than the user define minimum.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const; - /// Sets documentation strings for this algorithm - virtual void initDocs(); + private: // Overridden Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyCor.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyCor.h index ed5f6a00979a..4a741ce8c174 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyCor.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyCor.h @@ -89,14 +89,16 @@ class DLLExport DetectorEfficiencyCor : public API::Algorithm DetectorEfficiencyCor(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "DetectorEfficiencyCor"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm adjusts the binned data in a workspace for detector efficiency, calculated from the neutrons' kinetic energy, the gas filled detector's geometry and gas pressure. The data are then multiplied by k_i/k_f.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const{return "CorrectionFunctions\\EfficiencyCorrections;Inelastic";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Retrieve algorithm properties void retrieveProperties(); /// Correct the given spectra index for efficiency diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyCorUser.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyCorUser.h index d385ef4d8303..99c1a08a8106 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyCorUser.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyCorUser.h @@ -41,11 +41,13 @@ class DLLExport DetectorEfficiencyCorUser: public API::Algorithm { virtual ~DetectorEfficiencyCorUser(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm calculates the detector efficiency according the formula set in the instrument definition file/parameters.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); void retrieveProperties(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyVariation.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyVariation.h index 7ff697dd4d82..49af2fa90e90 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyVariation.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DetectorEfficiencyVariation.h @@ -59,6 +59,9 @@ namespace Mantid virtual ~DetectorEfficiencyVariation() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "DetectorEfficiencyVariation";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Compares two white beam vanadium workspaces from the same instrument to find detectors whose efficiencies have changed beyond a threshold.";} + virtual const std::string category() const; /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} @@ -78,8 +81,7 @@ namespace Mantid const double average, double variation); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + }; } // namespace Algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionEventCalibrateDetectors.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionEventCalibrateDetectors.h index 2d6a4dd96dd1..86aa0d5cf3c7 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionEventCalibrateDetectors.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionEventCalibrateDetectors.h @@ -48,6 +48,9 @@ class DLLExport DiffractionEventCalibrateDetectors: public API::Algorithm virtual ~DiffractionEventCalibrateDetectors(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "DiffractionEventCalibrateDetectors"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm optimizes the position and angles of all of the detector panels. The target instruments for this feature are SNAP and TOPAZ.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -57,8 +60,7 @@ class DLLExport DiffractionEventCalibrateDetectors: public API::Algorithm void movedetector(double x, double y, double z, double rotx, double roty, double rotz, std::string detname, Mantid::DataObjects::EventWorkspace_sptr inputW); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionFocussing.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionFocussing.h index 536f52447732..3baab2f393a4 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionFocussing.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionFocussing.h @@ -69,14 +69,16 @@ namespace Mantid virtual ~DiffractionFocussing() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "DiffractionFocussing";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Algorithm to focus powder diffraction data into a number of histograms according to a grouping scheme defined in a CalFile.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diffraction";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionFocussing2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionFocussing2.h index 986e1c2c88fc..edf8124dac2e 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionFocussing2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/DiffractionFocussing2.h @@ -87,14 +87,16 @@ class DLLExport DiffractionFocussing2: public API::Algorithm virtual ~DiffractionFocussing2(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "DiffractionFocussing"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Algorithm to focus powder diffraction data into a number of histograms according to a grouping scheme defined in a CalFile.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 2; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diffraction"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Divide.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Divide.h index a4a0fa377784..fa848da48f09 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Divide.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Divide.h @@ -53,12 +53,14 @@ namespace Mantid virtual ~Divide() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Divide";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The Divide algorithm will divide the data values and calculate the corresponding error values of two compatible workspaces.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + virtual void init(); virtual void exec(); // Overridden BinaryOperation methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EQSANSResolution.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EQSANSResolution.h index e2dabe69434f..815e5aeec57c 100755 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EQSANSResolution.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EQSANSResolution.h @@ -43,14 +43,16 @@ class DLLExport EQSANSResolution : public Algorithms::TOFSANSResolution virtual ~EQSANSResolution() {} /// Algorithm's name virtual const std::string name() const { return "EQSANSResolution"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the Q resolution for EQSANS data.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code //void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EQSANSTofStructure.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EQSANSTofStructure.h index 7526e70c2154..1967b18bfa80 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EQSANSTofStructure.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EQSANSTofStructure.h @@ -39,14 +39,16 @@ class DLLExport EQSANSTofStructure : public API::Algorithm virtual ~EQSANSTofStructure() {} /// Algorithm's name virtual const std::string name() const { return "EQSANSTofStructure"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Corrects the Time of Flight binning of raw EQSANS data. This algorithm needs to be run once on every data set.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EditInstrumentGeometry.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EditInstrumentGeometry.h index 820899488d1b..ecd1afd837e1 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EditInstrumentGeometry.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EditInstrumentGeometry.h @@ -40,6 +40,9 @@ namespace Algorithms EditInstrumentGeometry(); ~EditInstrumentGeometry(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The edit or added information will be attached to a Workspace. Currently it is in an overwrite mode only.";} + /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const; /// Algorithm's version for identification overriding a virtual method @@ -47,8 +50,7 @@ namespace Algorithms /// Validate the inputs that must be parallel virtual std::map validateInputs(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ElasticWindow.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ElasticWindow.h index fef805e3fc9a..e2e7f5e668e3 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ElasticWindow.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ElasticWindow.h @@ -45,14 +45,16 @@ class DLLExport ElasticWindow : public API::Algorithm virtual ~ElasticWindow() {} /// Algorithm's name virtual const std::string name() const { return "ElasticWindow"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm performs an integration over an energy range, with the option to subtract a background over a second range, then transposes the result into a single-spectrum workspace with units in Q and Q^2.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Inelastic"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EstimatePDDetectorResolution.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EstimatePDDetectorResolution.h index 4f7ef720a782..72bee2409fa9 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EstimatePDDetectorResolution.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/EstimatePDDetectorResolution.h @@ -40,14 +40,16 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "EstimatePDDetectorResolution";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Estimate the resolution of each detector for a powder diffractometer. ";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diffraction";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); /// Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Exponential.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Exponential.h index 7af91494bd2e..c6fbb7200063 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Exponential.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Exponential.h @@ -53,12 +53,14 @@ namespace Mantid virtual ~Exponential() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Exponential";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The Exponential algorithm will transform the signal values 'y' into e^y. The corresponding error values will be updated using E_{new}=E_{old}.e^y, assuming errors are Gaussian and small compared to the signal.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden UnaryOperation methods void performUnaryOperation(const double XIn, const double YIn, const double EIn, double& YOut, double& EOut); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExponentialCorrection.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExponentialCorrection.h index e3e1dc8f8d99..a620944b846e 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExponentialCorrection.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExponentialCorrection.h @@ -55,14 +55,16 @@ namespace Mantid virtual ~ExponentialCorrection() {}; /// Algorithm's name for identification virtual const std::string name() const { return "ExponentialCorrection";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Corrects the data in a workspace by the value of an exponential function which is evaluated at the X value of each data point.";} + /// Algorithm's version for identification virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const{ return "CorrectionFunctions;Arithmetic"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden UnaryOperation methods void defineProperties(); void retrieveProperties(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExportTimeSeriesLog.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExportTimeSeriesLog.h index be72ec711deb..e181b176a829 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExportTimeSeriesLog.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExportTimeSeriesLog.h @@ -45,6 +45,9 @@ namespace Algorithms virtual const std::string name() const {return "ExportTimeSeriesLog"; }; virtual int version() const {return 1; }; virtual const std::string category() const {return "Diffraction;Events\\EventFiltering"; }; + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Read a TimeSeries log and return information";} private: API::MatrixWorkspace_sptr m_dataWS; @@ -57,7 +60,7 @@ namespace Algorithms Kernel::DateAndTime mFilterT0; Kernel::DateAndTime mFilterTf; - virtual void initDocs(); + void init(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractFFTSpectrum.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractFFTSpectrum.h index 3b541d51f483..6bfc36c9afa7 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractFFTSpectrum.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractFFTSpectrum.h @@ -48,14 +48,16 @@ class DLLExport ExtractFFTSpectrum : public API::Algorithm virtual ~ExtractFFTSpectrum() {} /// Algorithm's name virtual const std::string name() const { return "ExtractFFTSpectrum"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm performs a Fast Fourier Transform on each spectrum in a workspace, and from the result takes the indicated spectrum and places it into the OutputWorkspace, so that you end up with one result spectrum for each input spectrum in the same workspace.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Arithmetic\\FFT"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractMask.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractMask.h index 5e3e06ed1561..e86d2a1e78cf 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractMask.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractMask.h @@ -57,14 +57,16 @@ namespace Mantid virtual ~ExtractMask() {} /// Algorithm's name virtual const std::string name() const { return "ExtractMask"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Extracts the masking from a given workspace and places it in a new workspace.";} + /// Algorithm's version virtual int version() const { return 1; } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Masking"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractMaskToTable.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractMaskToTable.h index 35c8de8b1f84..548baf63a559 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractMaskToTable.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractMaskToTable.h @@ -43,6 +43,9 @@ namespace Algorithms /// Algorithm's name virtual const std::string name() const { return "ExtractMaskToTable"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The output TableWorkspace should be compatible to MaskBinsFromTable.";} + /// Algorithm's version virtual int version() const { return 1; } /// Algorithm's category for identification @@ -52,8 +55,7 @@ namespace Algorithms std::vector subtractVector(std::vector minuend, std::vector subtrahend); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractSingleSpectrum.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractSingleSpectrum.h index 6e218b95097c..8c06b46cc185 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractSingleSpectrum.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ExtractSingleSpectrum.h @@ -51,14 +51,16 @@ class DLLExport ExtractSingleSpectrum : public API::Algorithm virtual ~ExtractSingleSpectrum() {} /// Algorithm's name virtual const std::string name() const { return "ExtractSingleSpectrum"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Extracts the specified spectrum from a workspace and places it in a new single-spectrum workspace.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Splitting"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFT.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFT.h index 0913bef193db..1b63a1f1eba4 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFT.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFT.h @@ -46,14 +46,16 @@ class DLLExport FFT : public API::Algorithm virtual ~FFT() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FFT";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs complex Fast Fourier Transform";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic\\FFT";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTDerivative.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTDerivative.h index 782cc8c5afe4..56c3c2f48709 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTDerivative.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTDerivative.h @@ -42,14 +42,16 @@ class FFTDerivative : public Mantid::API::Algorithm virtual ~FFTDerivative() {} /// Algorithm's name virtual const std::string name() const { return "FFTDerivative"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculated derivatives of a spectra in the MatrixWorkspace using Fast Fourier Transform (FFT).";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Arithmetic\\FFT"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTSmooth.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTSmooth.h index 2dd8adc7b934..469e86ad2d1b 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTSmooth.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTSmooth.h @@ -45,14 +45,16 @@ class DLLExport FFTSmooth : public API::Algorithm virtual ~FFTSmooth() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FFTSmooth";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs smoothing of a spectrum using various filters.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic\\FFT;Transforms\\Smoothing";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTSmooth2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTSmooth2.h index 2531cc9d6da5..d3fbba862900 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTSmooth2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FFTSmooth2.h @@ -45,14 +45,16 @@ class DLLExport FFTSmooth2 : public API::Algorithm virtual ~FFTSmooth2() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FFTSmooth";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs smoothing of a spectrum using various filters.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 2;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic\\FFT;Transforms\\Smoothing";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterBadPulses.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterBadPulses.h index afc33d0ac100..1c403711ba79 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterBadPulses.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterBadPulses.h @@ -55,14 +55,16 @@ class DLLExport FilterBadPulses : public API::Algorithm virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Filters out events associated with pulses that happen when proton charge is lower than a given percentage of the average.";} + virtual int version() const; virtual const std::string category() const; private: - // Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByLogValue.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByLogValue.h index c565e60bd1c5..ef4fe41c3c55 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByLogValue.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByLogValue.h @@ -42,6 +42,9 @@ class DLLExport FilterByLogValue : public API::Algorithm /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FilterByLogValue";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Filter out events from an EventWorkspace based on a sample log value satisfying filter criteria.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method @@ -50,8 +53,7 @@ class DLLExport FilterByLogValue : public API::Algorithm std::map validateInputs(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime.h index 9e7b98fd520a..eb78aa1cc5eb 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime.h @@ -49,14 +49,16 @@ class DLLExport FilterByTime : public API::Algorithm /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FilterByTime";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm filters out events from an EventWorkspace that are not between given start and stop times.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Events\\EventFiltering";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime2.h index eca167d0fab7..2a892ef786ab 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime2.h @@ -49,7 +49,7 @@ namespace Algorithms private: /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByXValue.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByXValue.h index d888371186e4..8cb2adfab9a5 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByXValue.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByXValue.h @@ -40,13 +40,16 @@ namespace Algorithms virtual ~FilterByXValue(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Filters events according to a min and/or max value of X.";} + virtual int version() const; virtual const std::string category() const; std::map validateInputs(); private: - virtual void initDocs(); + void init(); void exec(); }; diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterEvents.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterEvents.h index 9efd72c0db58..b23a29aa59f6 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterEvents.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterEvents.h @@ -48,14 +48,16 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FilterEvents";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Filter events from an EventWorkspace to one or multiple EventWorkspaces according to a series of splitters.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Events\\EventFiltering";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); // Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindCenterOfMassPosition.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindCenterOfMassPosition.h index 39624c31708d..f8ec076c8b7a 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindCenterOfMassPosition.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindCenterOfMassPosition.h @@ -40,14 +40,16 @@ class DLLExport FindCenterOfMassPosition : public API::Algorithm virtual ~FindCenterOfMassPosition() {} /// Algorithm's name virtual const std::string name() const { return "FindCenterOfMassPosition"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Finds the beam center in a 2D SANS data set.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindCenterOfMassPosition2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindCenterOfMassPosition2.h index b4b1aed0a014..a7dbd0caa515 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindCenterOfMassPosition2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindCenterOfMassPosition2.h @@ -40,14 +40,16 @@ class DLLExport FindCenterOfMassPosition2 : public API::Algorithm virtual ~FindCenterOfMassPosition2() {} /// Algorithm's name virtual const std::string name() const { return "FindCenterOfMassPosition"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Finds the beam center in a 2D SANS data set.";} + /// Algorithm's version virtual int version() const { return (2); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindDeadDetectors.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindDeadDetectors.h index 415ca534c3c4..00042a3c78a9 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindDeadDetectors.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindDeadDetectors.h @@ -67,14 +67,16 @@ namespace Mantid virtual ~FindDeadDetectors() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FindDeadDetectors";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Identifies and flags empty spectra caused by 'dead' detectors.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diagnostics";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindDetectorsOutsideLimits.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindDetectorsOutsideLimits.h index 993cae342071..4b70d21f44c6 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindDetectorsOutsideLimits.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindDetectorsOutsideLimits.h @@ -67,13 +67,15 @@ namespace Mantid virtual ~FindDetectorsOutsideLimits() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FindDetectorsOutsideLimits";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Identifies histograms and their detectors that have total numbers of counts over a user defined maximum or less than the user define minimum.";} + virtual const std::string category() const; /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overridden init void init(); /// Overridden exec diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindPeakBackground.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindPeakBackground.h index 5fdcca3134df..8374afb70f2d 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindPeakBackground.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindPeakBackground.h @@ -39,6 +39,9 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FindPeakBackground";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Separates background from signal for spectra of a workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} @@ -48,8 +51,7 @@ namespace Algorithms private: std::string m_backgroundType; //< The type of background to fit - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); /// Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindPeaks.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindPeaks.h index 562248860c8a..1109b72f90c9 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindPeaks.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FindPeaks.h @@ -64,6 +64,9 @@ class DLLExport FindPeaks : public API::Algorithm virtual ~FindPeaks() {if(m_progress) delete m_progress; m_progress=NULL;} /// Algorithm's name virtual const std::string name() const { return "FindPeaks"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Searches for peaks in a dataset.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -72,8 +75,7 @@ class DLLExport FindPeaks : public API::Algorithm int getVectorIndex(const MantidVec &vecX, double x); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FitPeak.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FitPeak.h index 52254f823f51..cf2bf46f5625 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FitPeak.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FitPeak.h @@ -27,6 +27,9 @@ namespace Algorithms /// Desctructor virtual ~FitOneSinglePeak(); + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fit a single peak with checking mechanism. ";} + /// Set workspaces void setWorskpace(API::MatrixWorkspace_sptr dataws, size_t wsindex); @@ -70,8 +73,7 @@ namespace Algorithms /// Generate a partial workspace at fit window API::MatrixWorkspace_sptr genFitWindowWS(); - - + // void setPeakParameterValues(); // void setBackgroundParameterValues(); @@ -83,6 +85,7 @@ namespace Algorithms { return "FitOneSinglePeak"; } + /// Version virtual int version() const { @@ -246,14 +249,15 @@ namespace Algorithms /// Algorithm's name virtual const std::string name() const { return "FitPeak"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fit a single peak with checking mechanism. ";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Optimization"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FixGSASInstrumentFile.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FixGSASInstrumentFile.h index 3a2b00ccc1eb..0e82888ed32f 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FixGSASInstrumentFile.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FixGSASInstrumentFile.h @@ -41,6 +41,9 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FixGSASInstrumentFile";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fix format error in an GSAS instrument file.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} @@ -49,8 +52,7 @@ namespace Algorithms virtual const std::string category() const { return "Diffraction";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); /// Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FlatPlateAbsorption.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FlatPlateAbsorption.h index 64efbab29e59..8a369303929c 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FlatPlateAbsorption.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FlatPlateAbsorption.h @@ -69,6 +69,9 @@ class DLLExport FlatPlateAbsorption : public AbsorptionCorrection virtual ~FlatPlateAbsorption() {} /// Algorithm's name virtual const std::string name() const { return "FlatPlateAbsorption"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates bin-by-bin correction factors for attenuation due to absorption and scattering in a sample of 'flat plate' geometry.";} + /// Algorithm's version virtual int version() const { return (1); } @@ -76,8 +79,7 @@ class DLLExport FlatPlateAbsorption : public AbsorptionCorrection void initialiseCachedDistances(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void defineProperties(); void retrieveProperties(); std::string sampleXML(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneralisedSecondDifference.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneralisedSecondDifference.h index 0444e8bf46fc..5ff559a361dc 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneralisedSecondDifference.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneralisedSecondDifference.h @@ -56,14 +56,16 @@ class DLLExport GeneralisedSecondDifference : public API::Algorithm virtual ~GeneralisedSecondDifference(); /// Algorithm's name virtual const std::string name() const { return "GeneralisedSecondDifference"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Computes the generalised second difference of a spectrum or several spectra.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Arithmetic"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GenerateEventsFilter.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GenerateEventsFilter.h index 7b12d7f23dfa..f38e04f9a9aa 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GenerateEventsFilter.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GenerateEventsFilter.h @@ -66,14 +66,16 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "GenerateEventsFilter";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Generate one or a set of event filters according to time or specified log's value.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Events\\EventFiltering";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); /// Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneratePeaks.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneratePeaks.h index 88fbe5a460a9..62f39a6dbed5 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneratePeaks.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneratePeaks.h @@ -46,14 +46,16 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "GeneratePeaks";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Generate peaks in an output workspace according to a TableWorkspace containing a list of peak's parameters.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Crystal";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); // Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneratePythonScript.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneratePythonScript.h index e189621704b3..c9d18fe537b1 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneratePythonScript.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GeneratePythonScript.h @@ -50,14 +50,16 @@ class DLLExport GeneratePythonScript : public API::Algorithm /// Algorithm's name for identification virtual const std::string name() const { return "GeneratePythonScript";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "An Algorithm to generate a Python script file to reproduce the history of a workspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Utility\\Development";} protected: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetDetOffsetsMultiPeaks.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetDetOffsetsMultiPeaks.h index 80a0e1a82bf0..bb560f12c4cb 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetDetOffsetsMultiPeaks.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetDetOffsetsMultiPeaks.h @@ -81,10 +81,12 @@ class DLLExport GetDetOffsetsMultiPeaks: public API::Algorithm virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diffraction"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates an OffsetsWorkspace containing offsets for each detector. " + "You can then save these to a .cal file using SaveCalFile.";} + private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetDetectorOffsets.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetDetectorOffsets.h index 31b566f36486..8922044942ab 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetDetectorOffsets.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetDetectorOffsets.h @@ -45,14 +45,16 @@ class DLLExport GetDetectorOffsets: public API::Algorithm virtual ~GetDetectorOffsets(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "GetDetectorOffsets"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates an OffsetsWorkspace containing offsets for each detector. You can then save these to a .cal file using SaveCalFile.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diffraction"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetEi.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetEi.h index 63fa29df9084..99f6e44a2b25 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetEi.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetEi.h @@ -53,14 +53,16 @@ class DLLExport GetEi : public API::Algorithm /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "GetEi"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates the kinetic energy of neutrons leaving the source based on the time it takes for them to travel between two monitors.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const{return "Inelastic; CorrectionFunctions";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// name of the tempory workspace that we create and use API::MatrixWorkspace_sptr m_tempWS; /// An estimate of the percentage of the algorithm runtimes that has been completed diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetEi2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetEi2.h index e4fefc3f70e9..ab618339a935 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetEi2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetEi2.h @@ -59,14 +59,16 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "GetEi"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates the kinetic energy of neutrons leaving the source based on the time it takes for them to travel between two monitors.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 2; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const{return "Inelastic";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Calculate Ei from the initial guess given double calculateEi(const double initial_guess); /// Get the distance from the source of the detector at the workspace index given diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetTimeSeriesLogInformation.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetTimeSeriesLogInformation.h index a818dc18dc57..619091f62003 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetTimeSeriesLogInformation.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GetTimeSeriesLogInformation.h @@ -44,6 +44,9 @@ namespace Algorithms virtual ~GetTimeSeriesLogInformation(); virtual const std::string name() const {return "GetTimeSeriesLogInformation"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Get information from a TimeSeriesProperty log.";} + virtual int version() const {return 1; } virtual const std::string category() const {return "Diffraction;Events\\EventFiltering"; } @@ -66,7 +69,7 @@ namespace Algorithms bool m_ignoreNegativeTime; - virtual void initDocs(); + void init(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GroupWorkspaces.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GroupWorkspaces.h index 6b3869776a54..8cb9bc1c9f81 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GroupWorkspaces.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/GroupWorkspaces.h @@ -47,6 +47,9 @@ namespace Mantid GroupWorkspaces(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "GroupWorkspaces";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes workspaces as input and groups similar workspaces together.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/HRPDSlabCanAbsorption.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/HRPDSlabCanAbsorption.h index d5d34f799a6e..556ad72ee3f8 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/HRPDSlabCanAbsorption.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/HRPDSlabCanAbsorption.h @@ -65,14 +65,16 @@ class DLLExport HRPDSlabCanAbsorption : public API::Algorithm virtual ~HRPDSlabCanAbsorption() {} /// Algorithm's name virtual const std::string name() const { return "HRPDSlabCanAbsorption"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates attenuation due to absorption and scattering in an HRPD 'slab' can.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Diffraction"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/He3TubeEfficiency.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/He3TubeEfficiency.h index d1af66759f19..16f855d7e0e2 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/He3TubeEfficiency.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/He3TubeEfficiency.h @@ -59,14 +59,16 @@ class DLLExport He3TubeEfficiency: public API::Algorithm virtual ~He3TubeEfficiency(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "He3TubeEfficiency"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "He3 tube efficiency correction.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const{ return "CorrectionFunctions\\EfficiencyCorrections"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IQTransform.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IQTransform.h index 588296937413..3414c34718cf 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IQTransform.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IQTransform.h @@ -56,12 +56,14 @@ class DLLExport IQTransform : public API::Algorithm IQTransform(); virtual ~IQTransform(); virtual const std::string name() const { return "IQTransform"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm provides various functions that are sometimes used to linearise the output of a 'SANS' data reduction prior to fitting it.";} + virtual int version() const { return (1); } virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IdentifyNoisyDetectors.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IdentifyNoisyDetectors.h index df9b3ec5daf5..d102c06639e0 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IdentifyNoisyDetectors.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IdentifyNoisyDetectors.h @@ -41,12 +41,14 @@ class DLLExport IdentifyNoisyDetectors : public API::Algorithm virtual ~IdentifyNoisyDetectors() {} ///< Empty destructor virtual const std::string name() const { return "IdentifyNoisyDetectors"; } ///< @return the algorithms name + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm creates a single-column workspace where the Y values are populated withs 1s and 0s, 0 signifying that the detector is to be considered 'bad' based on the method described below.";} + virtual const std::string category() const { return "Diagnostics"; } ///< @return the algorithms category virtual int version() const { return (1); } ///< @return version number of algorithm private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void init(); ///< Initialise the algorithm. Declare properties, etc. void exec(); ///< Executes the algorithm. diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IntegrateByComponent.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IntegrateByComponent.h index b513444135bb..0d99aa5fbf80 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IntegrateByComponent.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/IntegrateByComponent.h @@ -38,11 +38,14 @@ namespace Algorithms virtual ~IntegrateByComponent(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Averages up the instrument hierarchy.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Integration.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Integration.h index 04372628da12..2aff08bc9747 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Integration.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Integration.h @@ -59,14 +59,16 @@ class DLLExport Integration : public API::Algorithm virtual ~Integration() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Integration";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Integration takes a 2D workspace or an EventWorkspace as input and sums the data values. Optionally, the range summed can be restricted in either dimension.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic;Transforms\\Rebin";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/InterpolatingRebin.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/InterpolatingRebin.h index ede09939ca15..48ea50a599b6 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/InterpolatingRebin.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/InterpolatingRebin.h @@ -68,6 +68,9 @@ class DLLExport InterpolatingRebin : public Algorithms::Rebin virtual ~InterpolatingRebin() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "InterpolatingRebin";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates a workspace with different x-value bin boundaries where the new y-values are estimated using cubic splines.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method @@ -76,10 +79,7 @@ class DLLExport InterpolatingRebin : public Algorithms::Rebin virtual const std::string alias() const { return ""; } protected: - const std::string workspaceMethodName() const { return ""; } // Override the one from Rebin to ignore us - - /// Sets documentation strings for this algorithm - virtual void initDocs(); + const std::string workspaceMethodName() const { return ""; } // Overridden Algorithm methods void init(); virtual void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/InvertMask.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/InvertMask.h index 51be6006e5b4..f75536d805ef 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/InvertMask.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/InvertMask.h @@ -41,14 +41,16 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "InvertMask";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm inverts every mask bit in a MaskWorkspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Masking";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); // Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Logarithm.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Logarithm.h index 23b81e44045d..1811b057e834 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Logarithm.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Logarithm.h @@ -49,13 +49,15 @@ class DLLExport Logarithm : public UnaryOperation virtual ~Logarithm(void){}; /// Algorithm's name for identification virtual const std::string name() const { return "Logarithm";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Logarithm function calculates the logarithm of the data, held in a workspace. A user can choose between natural (default) or base 10 logarithm";} + /// Algorithm's version for identification virtual int version() const { return (1);} /// Algorithm's category for identification virtual const std::string category() const { return "Arithmetic";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// The value to replace ln(0) double log_Min; /// If the logarithm natural or 10-based diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskBins.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskBins.h index 753c2f3661a4..9d140bde3ca7 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskBins.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskBins.h @@ -57,14 +57,16 @@ class DLLExport MaskBins : public API::Algorithm virtual ~MaskBins() {} /// Algorithm's name virtual const std::string name() const { return "MaskBins"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Marks bins in a workspace as being masked.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Masking"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskBinsFromTable.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskBinsFromTable.h index 08135b984211..1380e21997a1 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskBinsFromTable.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskBinsFromTable.h @@ -42,14 +42,16 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "MaskBinsFromTable";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Mask bins from a table workspace. ";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Masking";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); // Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskDetectorsIf.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskDetectorsIf.h index 9bd2f9178ad8..8b11d899f262 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskDetectorsIf.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaskDetectorsIf.h @@ -56,14 +56,16 @@ class DLLExport MaskDetectorsIf: public API::Algorithm virtual ~MaskDetectorsIf(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "MaskDetectorsIf"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Adjusts the selected field for a CalFile depending on the values in the input workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diffraction;Transforms\\Masking"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Returns an allowed values statement to insert into decumentation std::string allowedValuesStatement( std::vector vals); #ifndef HAS_UNORDERED_MAP_H diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Max.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Max.h index 8729a807bcb8..d78d4064fb0d 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Max.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Max.h @@ -59,6 +59,9 @@ class DLLExport Max : public API::Algorithm virtual ~Max() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Max";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes a 2D workspace as input and find the maximum in each 1D spectrum. The algorithm creates a new 1D workspace containing all maxima as well as their X boundaries and error. This is used in particular for single crystal as a quick way to find strong peaks.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaxMin.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaxMin.h index d0e32499cb3c..3ca95ab307b9 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaxMin.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaxMin.h @@ -59,6 +59,9 @@ class DLLExport MaxMin : public API::Algorithm virtual ~MaxMin() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "MaxMin";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes a 2D workspace as input and find the maximum (minimum) in each 1D spectrum.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MergeRuns.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MergeRuns.h index 97a833e5fd90..a8a9e4b99c4e 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MergeRuns.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MergeRuns.h @@ -64,6 +64,9 @@ class DLLExport MergeRuns : public API::MultiPeriodGroupAlgorithm virtual ~MergeRuns(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "MergeRuns"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Combines the data contained in an arbitrary number of input workspaces.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -71,8 +74,7 @@ class DLLExport MergeRuns : public API::MultiPeriodGroupAlgorithm // Overriden MultiPeriodGroupAlgorithm method. bool useCustomInputPropertyName() const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Min.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Min.h index c0a8c3c7857a..bc24e25a9532 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Min.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Min.h @@ -59,6 +59,9 @@ class DLLExport Min : public API::Algorithm virtual ~Min() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Min";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes a 2D workspace as input and find the minimum in each 1D spectrum. The algorithm creates a new 1D workspace containing all minima as well as their X boundaries and error. This is used in particular for single crystal as a quick way to find strong peaks.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Minus.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Minus.h index b93eb1dd00c8..3f4010e77bc2 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Minus.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Minus.h @@ -53,14 +53,16 @@ namespace Mantid virtual ~Minus() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Minus";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The Minus algorithm will subtract the data values and calculate the corresponding error values for two compatible workspaces.";} + /// Algorithm's alias for identification overriding a virtual method virtual const std::string alias() const; /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden BinaryOperation methods void performBinaryOperation(const MantidVec& lhsX, const MantidVec& lhsY, const MantidVec& lhsE, const MantidVec& rhsY, const MantidVec& rhsE, MantidVec& YOut, MantidVec& EOut); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ModeratorTzero.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ModeratorTzero.h index 0c260a1f23d9..be5322c8d256 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ModeratorTzero.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ModeratorTzero.h @@ -68,6 +68,9 @@ class DLLExport ModeratorTzero: public Mantid::API::Algorithm virtual ~ModeratorTzero() {} /// Algorithm's name virtual const std::string name() const { return "ModeratorTzero"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Corrects the time of flight of an indirect geometry instrument by a time offset that is dependent on the energy of the neutron after passing through the moderator.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -79,8 +82,7 @@ class DLLExport ModeratorTzero: public Mantid::API::Algorithm private: Mantid::Geometry::Instrument_const_sptr m_instrument; - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Initialisation code void init(); /// Execution code for histogram workspace diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ModeratorTzeroLinear.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ModeratorTzeroLinear.h index 7a871770cbb0..8107dd2a26eb 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ModeratorTzeroLinear.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ModeratorTzeroLinear.h @@ -72,6 +72,9 @@ class DLLExport ModeratorTzeroLinear : public API::Algorithm virtual ~ModeratorTzeroLinear() {} /// Algorithm's name virtual const std::string name() const { return "ModeratorTzeroLinear"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return " Corrects the time of flight of an indirect geometry instrument by a time offset that is linearly dependent on the wavelength of the neutron after passing through the moderator.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -82,8 +85,7 @@ class DLLExport ModeratorTzeroLinear : public API::Algorithm double m_gradient; double m_intercept; Geometry::Instrument_const_sptr m_instrument; - // Sets documentation strings for this algorithm - virtual void initDocs(); + // Initialisation code void init(); // Execution code for histogram workspace diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MonteCarloAbsorption.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MonteCarloAbsorption.h index b30672253da0..59c2fa12f310 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MonteCarloAbsorption.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MonteCarloAbsorption.h @@ -60,6 +60,9 @@ namespace Mantid virtual int version() const { return 1; } /// Algorithm's category for identification virtual const std::string category() const { return "CorrectionFunctions\\AbsorptionCorrections"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates attenuation due to absorption and scattering in a sample & its environment using a weighted Monte Carlo.";} + private: /// Initialize the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MultipleScatteringCylinderAbsorption.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MultipleScatteringCylinderAbsorption.h index cf67562e7c71..f67491b790b8 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MultipleScatteringCylinderAbsorption.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MultipleScatteringCylinderAbsorption.h @@ -59,6 +59,9 @@ class DLLExport MultipleScatteringCylinderAbsorption : public API::Algorithm /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const; + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Multiple scattering absorption correction, originally used to correct vanadium spectrum at IPNS.";} private: diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Multiply.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Multiply.h index 2cdc12b9004e..b03240445dc6 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Multiply.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Multiply.h @@ -53,12 +53,14 @@ namespace Mantid virtual ~Multiply() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Multiply";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The Multiply algorithm will multiply the data values and calculate the corresponding error values of two compatible workspaces. ";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden BinaryOperation methods void performBinaryOperation(const MantidVec& lhsX, const MantidVec& lhsY, const MantidVec& lhsE, const MantidVec& rhsY, const MantidVec& rhsE, MantidVec& YOut, MantidVec& EOut); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MultiplyRange.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MultiplyRange.h index 8202ee23418a..4fe9e118b859 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MultiplyRange.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MultiplyRange.h @@ -53,12 +53,14 @@ class DLLExport MultiplyRange : public API::Algorithm virtual ~MultiplyRange() {} virtual const std::string name() const { return "MultiplyRange";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "An algorithm to multiply a range of bins in a workspace by the factor given.";} + virtual int version() const { return (1);} virtual const std::string category() const { return "CorrectionFunctions";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + ///Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MuonGroupDetectors.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MuonGroupDetectors.h index 6fa3570e3e8e..ccb2e6968216 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MuonGroupDetectors.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MuonGroupDetectors.h @@ -38,11 +38,14 @@ namespace Algorithms virtual ~MuonGroupDetectors(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Applies detector grouping to a workspace. (Muon version).";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseByCurrent.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseByCurrent.h index fe5560277633..8f218b96b8a1 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseByCurrent.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseByCurrent.h @@ -56,14 +56,16 @@ class DLLExport NormaliseByCurrent : public API::Algorithm virtual ~NormaliseByCurrent(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "NormaliseByCurrent"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Normalises a workspace by the proton charge.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "CorrectionFunctions\\NormalisationCorrections";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseByDetector.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseByDetector.h index 540113f3a0a2..d4ba4692d0b1 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseByDetector.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseByDetector.h @@ -50,6 +50,9 @@ namespace Algorithms virtual ~NormaliseByDetector(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Normalise the input workspace by the detector efficiency.";} + virtual int version() const; virtual const std::string category() const; @@ -62,7 +65,7 @@ namespace Algorithms boost::shared_ptr processHistograms(boost::shared_ptr inWS); /// Process indivdual histogram. void processHistogram(size_t wsIndex, boost::shared_ptr denominatorWS, boost::shared_ptr inWS, Mantid::API::Progress& prog); - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseToMonitor.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseToMonitor.h index 787b6bf07d1e..43bc9dd14f68 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseToMonitor.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseToMonitor.h @@ -69,13 +69,15 @@ class DLLExport NormaliseToMonitor : public API::Algorithm virtual ~NormaliseToMonitor(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "NormaliseToMonitor"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Normalises a 2D workspace by a specified spectrum, spectrum, described by a monitor ID or spectrun provided in a separate worskspace. ";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "CorrectionFunctions\\NormalisationCorrections";} private: - virtual void initDocs(); // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseToUnity.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseToUnity.h index ee377d38e14f..6af16613f38f 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseToUnity.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/NormaliseToUnity.h @@ -57,14 +57,16 @@ class DLLExport NormaliseToUnity : public API::Algorithm virtual ~NormaliseToUnity() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "NormaliseToUnity";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "NormaliseToUnity takes a 2D workspace or an EventWorkspace as input and normalises it to 1. Optionally, the range summed can be restricted in either dimension.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "CorrectionFunctions\\NormalisationCorrections";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/OneMinusExponentialCor.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/OneMinusExponentialCor.h index e8123b5e5a9c..0292677223c9 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/OneMinusExponentialCor.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/OneMinusExponentialCor.h @@ -55,14 +55,16 @@ namespace Mantid virtual ~OneMinusExponentialCor() {}; /// Algorithm's name for identification virtual const std::string name() const { return "OneMinusExponentialCor";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Corrects the data in a workspace by one minus the value of an exponential function.";} + /// Algorithm's version for identification virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const{ return "CorrectionFunctions"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden UnaryOperation methods void defineProperties(); void retrieveProperties(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PDFFourierTransform.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PDFFourierTransform.h index b11f1e9a67e2..3df7301cc7e3 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PDFFourierTransform.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PDFFourierTransform.h @@ -19,6 +19,9 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fourier transform from S(Q) to G(r), which is paired distribution function (PDF). G(r) will be stored in another named workspace.";} + /// Algorithm's version for identification virtual int version() const; /// Algorithm's category for identification @@ -27,8 +30,7 @@ namespace Algorithms virtual std::map validateInputs(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Pause.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Pause.h index a68376247f39..6c305f92357f 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Pause.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Pause.h @@ -40,11 +40,14 @@ namespace Algorithms virtual ~Pause(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Pause a script for a given duration.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PerformIndexOperations.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PerformIndexOperations.h index 2e028005f5dd..483b9c5ced0b 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PerformIndexOperations.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PerformIndexOperations.h @@ -38,11 +38,14 @@ namespace Algorithms virtual ~PerformIndexOperations(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Process the workspace according to the Index operations provided.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PlotAsymmetryByLogValue.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PlotAsymmetryByLogValue.h index 3763de040859..269c3eb621b7 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PlotAsymmetryByLogValue.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PlotAsymmetryByLogValue.h @@ -65,14 +65,16 @@ namespace Mantid virtual ~PlotAsymmetryByLogValue() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PlotAsymmetryByLogValue";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates asymmetry for a series of log values";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Muon";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Plus.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Plus.h index 25379a7d56f2..0bb3e2648856 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Plus.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Plus.h @@ -55,12 +55,14 @@ namespace Mantid virtual ~Plus() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Plus";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The Plus algorithm will add the data values and calculate the corresponding error values in two compatible workspaces. ";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden BinaryOperation methods void performBinaryOperation(const MantidVec& lhsX, const MantidVec& lhsY, const MantidVec& lhsE, const MantidVec& rhsY, const MantidVec& rhsE, MantidVec& YOut, MantidVec& EOut); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PointByPointVCorrection.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PointByPointVCorrection.h index 66eecf5543f6..151209e17852 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PointByPointVCorrection.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PointByPointVCorrection.h @@ -42,14 +42,16 @@ class DLLExport PointByPointVCorrection : public API::Algorithm virtual ~PointByPointVCorrection(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PointByPointVCorrection"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Spectrum by spectrum division for vanadium normalisation correction.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diffraction;CorrectionFunctions\\SpecialCorrections";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PoissonErrors.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PoissonErrors.h index 27cb8a667fc5..0471a8b393fc 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PoissonErrors.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PoissonErrors.h @@ -53,14 +53,16 @@ class DLLExport PoissonErrors : public BinaryOperation virtual ~PoissonErrors() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PoissonErrors";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates the gaussian approxiamtion of Poisson error based on a matching workspace containing the original counts.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "SANS;Arithmetic\\Errors";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden BinaryOperation methods void performBinaryOperation(const MantidVec& lhsX, const MantidVec& lhsY, const MantidVec& lhsE, const MantidVec& rhsY, const MantidVec& rhsE, MantidVec& YOut, MantidVec& EOut); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PolynomialCorrection.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PolynomialCorrection.h index b5481cc2ab29..d01b9c52ba38 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PolynomialCorrection.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PolynomialCorrection.h @@ -54,14 +54,16 @@ namespace Mantid virtual ~PolynomialCorrection() {}; /// Algorithm's name for identification virtual const std::string name() const { return "PolynomialCorrection";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Corrects the data in a workspace by the value of a polynomial function which is evaluated at the X value of each data point.";} + /// Algorithm's version for identification virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const{ return "CorrectionFunctions"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden UnaryOperation methods void defineProperties(); void retrieveProperties(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Power.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Power.h index a3d83b6e05a0..2cb73ecb3188 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Power.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Power.h @@ -54,14 +54,16 @@ class DLLExport Power: public UnaryOperation virtual ~Power() {}; /// Algorithm's name for identification virtual const std::string name() const { return "Power"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The Power algorithm will raise the base workspace to a particular power. Corresponding error values will be created.";} + /// Algorithm's version for identification virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden UnaryOperation methods void defineProperties(); void retrieveProperties(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PowerLawCorrection.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PowerLawCorrection.h index 3dedad95e154..617b5f332a6b 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PowerLawCorrection.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/PowerLawCorrection.h @@ -54,14 +54,16 @@ namespace Mantid virtual ~PowerLawCorrection() {}; /// Algorithm's name for identification virtual const std::string name() const { return "PowerLawCorrection";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Corrects the data and error values on a workspace by the value of an exponential function which is evaluated at the X value of each data point: c0*x^C1. The data and error values are multiplied by the value of this function.";} + /// Algorithm's version for identification virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const{ return "CorrectionFunctions"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden UnaryOperation methods void defineProperties(); void retrieveProperties(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1D2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1D2.h index 898d231bfb14..12b09bb9d87c 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1D2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1D2.h @@ -46,6 +46,9 @@ class DLLExport Q1D2 : public API::Algorithm virtual ~Q1D2() {} /// Algorithm's name virtual const std::string name() const { return "Q1D"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts a workspace of counts in wavelength bins into a workspace of counts verses momentum transfer, Q, assuming completely elastic scattering";} + /// Algorithm's version virtual int version() const { return (2); } /// Algorithm's category for identification @@ -56,8 +59,7 @@ class DLLExport Q1D2 : public API::Algorithm API::MatrixWorkspace_const_sptr m_dataWS; bool m_doSolidAngle; - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1DTOF.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1DTOF.h index 831f2b83d0e0..ea17fc2fcdf5 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1DTOF.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1DTOF.h @@ -23,14 +23,16 @@ class DLLExport Q1DTOF : public API::Algorithm virtual ~Q1DTOF() {} /// Algorithm's name virtual const std::string name() const { return "Q1DTOF"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs azimuthal averaging on a 2D SANS data to produce I(Q).";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1DWeighted.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1DWeighted.h index 13b762e8213c..8972e2284020 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1DWeighted.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Q1DWeighted.h @@ -46,14 +46,16 @@ class DLLExport Q1DWeighted : public API::Algorithm virtual ~Q1DWeighted() {} /// Algorithm's name virtual const std::string name() const { return "Q1DWeighted"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs azimuthal averaging on a 2D SANS data to produce I(Q).";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Qxy.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Qxy.h index 8a98e073785e..c02c47e73fdf 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Qxy.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Qxy.h @@ -57,14 +57,16 @@ class DLLExport Qxy : public API::Algorithm virtual ~Qxy() {} /// Algorithm's name virtual const std::string name() const { return "Qxy"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs the final part of a SANS (LOQ/SANS2D) two dimensional (in Q) data reduction.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RadiusSum.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RadiusSum.h index ebd76d59df22..3a4c02086d5d 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RadiusSum.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RadiusSum.h @@ -44,6 +44,9 @@ namespace Algorithms virtual ~RadiusSum(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Sum of all the counts inside a ring against the scattering angle for each Radius.";} + virtual int version() const; virtual const std::string category() const; @@ -59,7 +62,7 @@ namespace Algorithms private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RayTracerTester.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RayTracerTester.h index 55ff34b406b2..857de99403ed 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RayTracerTester.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RayTracerTester.h @@ -42,6 +42,9 @@ namespace Algorithms /// Algorithm's name for identification virtual const std::string name() const { return "RayTracerTester";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Algorithm to test ray tracer by spraying evenly spaced rays around.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification @@ -51,8 +54,7 @@ namespace Algorithms void exec(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReadGroupsFromFile.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReadGroupsFromFile.h index 5ba897c87ecc..b9928d369868 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReadGroupsFromFile.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReadGroupsFromFile.h @@ -77,14 +77,16 @@ class DLLExport ReadGroupsFromFile : public API::Algorithm virtual ~ReadGroupsFromFile() {} /// Algorithm's name virtual const std::string name() const { return "ReadGroupsFromFile"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Read a diffraction calibration file (*.cal) or an XML grouping file (*.xml) and an instrument name, and output a 2D workspace containing on the Y-axis the values of the Group each detector belongs to. This is used to visualise the grouping scheme for powder diffractometers, where a large number of detectors are grouped together. The output 2D workspace can be visualize using the show instrument method.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Diffraction"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Map containing the detector entries found in the *.cal file. The key is the udet number, the value of is a pair of . #ifndef HAS_UNORDERED_MAP_H typedef std::map > calmap; diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RealFFT.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RealFFT.h index 643a6efa1fa1..a3e7f2ece42f 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RealFFT.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RealFFT.h @@ -46,14 +46,16 @@ class DLLExport RealFFT : public API::Algorithm virtual ~RealFFT() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "RealFFT";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs real Fast Fourier Transform";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic\\FFT";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebin.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebin.h index eda0db24a526..0cc2cfc4a8b6 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebin.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebin.h @@ -56,6 +56,9 @@ class DLLExport Rebin : public API::Algorithm virtual ~Rebin() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Rebin";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Rebins data with new X bin boundaries. For EventWorkspaces, you can very quickly rebin in-place by keeping the same output name and PreserveEvents=true.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method @@ -69,8 +72,7 @@ class DLLExport Rebin : public API::Algorithm const std::string workspaceMethodOnTypes() const { return "MatrixWorkspace"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); virtual void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebin2D.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebin2D.h index 6a38f1e9aac1..1c16356c2c03 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebin2D.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebin2D.h @@ -52,6 +52,9 @@ namespace Mantid public: /// Algorithm's name for identification virtual const std::string name() const { return "Rebin2D";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Rebins both axes of a 2D workspace using the given parameters";} + /// Algorithm's version for identification virtual int version() const { return 1;} /// Algorithm's category for identification @@ -80,8 +83,7 @@ namespace Mantid private: /// Flag for using a RebinnedOutput workspace bool useFractionalArea; - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RebinByPulseTimes.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RebinByPulseTimes.h index 5471ce24df52..4c927b099afd 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RebinByPulseTimes.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RebinByPulseTimes.h @@ -38,11 +38,14 @@ namespace Algorithms virtual ~RebinByPulseTimes(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Bins events according to pulse time. Binning parameters are specified relative to the start of the run.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); }; diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RebinToWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RebinToWorkspace.h index d5e081e75806..30c5bef37399 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RebinToWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RebinToWorkspace.h @@ -53,14 +53,16 @@ class DLLExport RebinToWorkspace : public Mantid::API::Algorithm virtual ~RebinToWorkspace() {} /// Algorithm's name virtual const std::string name() const { return "RebinToWorkspace"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Rebin a selected workspace to the same binning as a different workspace";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Rebin"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebunch.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebunch.h index 15f79564a3a0..18deec5f2213 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebunch.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Rebunch.h @@ -56,14 +56,16 @@ namespace Mantid virtual ~Rebunch() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Rebunch";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Rebins data by adding together 'n_bunch' successive bins.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Rebin";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RecordPythonScript.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RecordPythonScript.h index c0e9682e2947..1cdad6227f69 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RecordPythonScript.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RecordPythonScript.h @@ -48,14 +48,16 @@ class DLLExport RecordPythonScript : public Algorithms::GeneratePythonScript, pu /// Algorithm's name for identification virtual const std::string name() const { return "RecordPythonScript";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "An Algorithm to generate a Python script file to reproduce the history of a workspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Utility;PythonAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOne.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOne.h index 9463ba9c9d9b..3e94ce1ece09 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOne.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReflectometryReductionOne.h @@ -45,6 +45,9 @@ namespace Mantid virtual ~ReflectometryReductionOne(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Reduces a single TOF reflectometry run into a mod Q vs I/I0 workspace. Performs transmission corrections.";} + virtual int version() const; virtual const std::string category() const; @@ -55,7 +58,7 @@ namespace Mantid private: /** Overridden Algorithm methods **/ - virtual void initDocs(); + void init(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Regroup.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Regroup.h index f553984ea0aa..59a623bbe9cd 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Regroup.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Regroup.h @@ -52,6 +52,9 @@ class DLLExport Regroup : public API::Algorithm virtual ~Regroup() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Regroup";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Regroups data with new bin boundaries.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method @@ -62,8 +65,7 @@ class DLLExport Regroup : public API::Algorithm std::vector& xnew, std::vector &xoldIndex); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveBins.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveBins.h index c13715a02ee8..42ef1acb28c9 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveBins.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveBins.h @@ -59,14 +59,16 @@ class DLLExport RemoveBins : public API::Algorithm virtual ~RemoveBins() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "RemoveBins";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Used to remove data from a range of bins in a workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Splitting";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveExpDecay.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveExpDecay.h index 9b16e25a0ab4..7cfdcfaf8387 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveExpDecay.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveExpDecay.h @@ -54,14 +54,16 @@ namespace Mantid virtual ~MuonRemoveExpDecay() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "RemoveExpDecay";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm removes the exponential decay from a muon workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Muon";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveLowResTOF.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveLowResTOF.h index 01570316e1fc..3028c1cbc114 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveLowResTOF.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemoveLowResTOF.h @@ -17,6 +17,8 @@ class DLLExport RemoveLowResTOF : public API::Algorithm virtual const std::string name() const; virtual int version() const; virtual const std::string category() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Removes low resolution Time of Flight data.";} private: void init(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemovePromptPulse.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemovePromptPulse.h index 697dc6395636..b8e79c5a6207 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemovePromptPulse.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RemovePromptPulse.h @@ -50,9 +50,13 @@ namespace Algorithms /// Algorithm's category for identification virtual const std::string category() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Remove the prompt pulse for a time of flight measurement.";} + + private: /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RenameWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RenameWorkspace.h index c72144c3a4e6..4769f5efbf79 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RenameWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RenameWorkspace.h @@ -49,6 +49,9 @@ class DLLExport RenameWorkspace : public API::Algorithm virtual ~RenameWorkspace() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "RenameWorkspace";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Rename the Workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method @@ -58,8 +61,7 @@ class DLLExport RenameWorkspace : public API::Algorithm const std::string workspaceMethodName() const { return "rename"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RenameWorkspaces.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RenameWorkspaces.h index 4952b18c0ca2..dc65d4fd2939 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RenameWorkspaces.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RenameWorkspaces.h @@ -50,14 +50,16 @@ class DLLExport RenameWorkspaces : public API::Algorithm virtual ~RenameWorkspaces() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "RenameWorkspaces";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Rename the Workspace. Please provide either a comma-separated list of new workspace names in WorkspaceNames or Prefix and/or Suffix to add to existing names";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Utility\\Workspaces";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReplaceSpecialValues.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReplaceSpecialValues.h index f7d1b9e6db10..a13b9e6682e2 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReplaceSpecialValues.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ReplaceSpecialValues.h @@ -55,14 +55,16 @@ class DLLExport ReplaceSpecialValues : public UnaryOperation virtual ~ReplaceSpecialValues() {} /// Algorithm's name for identification virtual const std::string name() const { return "ReplaceSpecialValues"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Replaces instances of NaN and infinity in the workspace with user defined numbers. If a replacement value is not provided the check will not occur. This algorithm can also be used to replace numbers whose absolute value is larger than a user-defined threshold.";} + /// Algorithm's version for identification virtual int version() const { return 1; } /// Algorithm's category for identification virtual const std::string category() const { return "Utility;CorrectionFunctions\\SpecialCorrections"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden UnaryOperation methods void defineProperties(); void retrieveProperties(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResampleX.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResampleX.h index 5870ab7f6ca9..58395027ec07 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResampleX.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResampleX.h @@ -43,6 +43,10 @@ namespace Algorithms virtual int version() const; virtual const std::string category() const; virtual const std::string alias() const; + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Resample the x-axis of the data with the requested number of points.";} + /// MADE PUBLIC FOR TESTING ONLY - DO NOT USE double determineBinning(MantidVec& xValues, const double xmin, const double xmax); /// MADE PUBLIC FOR TESTING ONLY - DO NOT USE @@ -51,7 +55,7 @@ namespace Algorithms private: const std::string workspaceMethodName() const { return ""; } // Override the one from Rebin to ignore us - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResetNegatives.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResetNegatives.h index 464bdae81d06..87c35bc2b56b 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResetNegatives.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResetNegatives.h @@ -40,11 +40,14 @@ namespace Algorithms virtual ~ResetNegatives(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Reset negative values to something else.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); void pushMinimum(API::MatrixWorkspace_const_sptr minWS, API::MatrixWorkspace_sptr wksp, API::Progress &prog); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResizeRectangularDetector.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResizeRectangularDetector.h index acb60b372d94..b71099e1235c 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResizeRectangularDetector.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ResizeRectangularDetector.h @@ -40,11 +40,14 @@ namespace Algorithms virtual ~ResizeRectangularDetector(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Resize a RectangularDetector in X and/or Y.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RingProfile.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RingProfile.h index 3866b9af4766..b8c1ebc0f210 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RingProfile.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/RingProfile.h @@ -44,6 +44,9 @@ namespace Algorithms virtual ~RingProfile(); virtual const std::string name() const { return "RingProfile";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates the sum of the counts against a circular ring.";} + virtual int version() const { return 1; }; virtual const std::string category() const {return "Transforms";}; @@ -51,7 +54,7 @@ namespace Algorithms boost::shared_ptr m_progress; private: - virtual void initDocs(); + void init(); void exec(); /// get the bin position for the given angle diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SANSDirectBeamScaling.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SANSDirectBeamScaling.h index e436af0ef543..f235b1caf3cb 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SANSDirectBeamScaling.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SANSDirectBeamScaling.h @@ -41,14 +41,16 @@ class DLLExport SANSDirectBeamScaling : public API::Algorithm virtual ~SANSDirectBeamScaling() {} /// Algorithm's name virtual const std::string name() const { return "SANSDirectBeamScaling"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Computes the scaling factor to get reduced SANS data on an absolute scale.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SassenaFFT.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SassenaFFT.h index 40a29ecf30f4..1cfd086a2ef4 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SassenaFFT.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SassenaFFT.h @@ -45,6 +45,9 @@ class DLLExport SassenaFFT : public API::Algorithm virtual ~SassenaFFT() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "SassenaFFT"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs complex Fast Fourier Transform of intermediate scattering function";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -53,8 +56,7 @@ class DLLExport SassenaFFT : public API::Algorithm // Overridden Algorithm methods bool processGroups(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SaveGSASInstrumentFile.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SaveGSASInstrumentFile.h index e3acf30664b0..9c571ae52258 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SaveGSASInstrumentFile.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SaveGSASInstrumentFile.h @@ -43,14 +43,16 @@ class DLLExport SaveGSASInstrumentFile : public API::Algorithm virtual ~SaveGSASInstrumentFile(); /// Algorithm's name virtual const std::string name() const { return "SaveGSASInstrumentFile"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Generate a GSAS instrument file from either a table workspace containing profile parameters or a Fullprof's instrument resolution file (.irf file). ";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Diffraction"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Scale.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Scale.h index 792e23ed0304..dafae7553a00 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Scale.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Scale.h @@ -52,14 +52,16 @@ class DLLExport Scale : public API::Algorithm virtual ~Scale() {} /// Algorithm's name virtual const std::string name() const { return "Scale"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Scales an input workspace by the given factor, which can be either multiplicative or additive.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Arithmetic;CorrectionFunctions"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ScaleX.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ScaleX.h index db88230a3d78..39ff6e03f0a5 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ScaleX.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ScaleX.h @@ -54,14 +54,16 @@ namespace Mantid virtual ~ScaleX(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "ScaleX";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Scales an input workspace by the given factor, which can be either multiplicative or additive.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic;CorrectionFunctions";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SetInstrumentParameter.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SetInstrumentParameter.h index 54297437ebd3..55ef1a2e28ef 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SetInstrumentParameter.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SetInstrumentParameter.h @@ -45,11 +45,14 @@ namespace Algorithms virtual ~SetInstrumentParameter(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Add or replace an parameter attached to an instrument component.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SetUncertainties.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SetUncertainties.h index e1ede7a21de8..6922957e0696 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SetUncertainties.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SetUncertainties.h @@ -51,6 +51,9 @@ class DLLExport SetUncertainties : public API::Algorithm /// Algorithm's name virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm creates a workspace which is the duplicate of the input, but where the error value for every bin has been set to zero.";} + /// Algorithm's version virtual int version() const; @@ -59,8 +62,7 @@ class DLLExport SetUncertainties : public API::Algorithm virtual const std::string category() const { return "Arithmetic\\Errors";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ShiftLogTime.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ShiftLogTime.h index 9e0e47ef5fb8..1e12a3501120 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ShiftLogTime.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/ShiftLogTime.h @@ -43,9 +43,12 @@ namespace Algorithms virtual int version() const; virtual const std::string category() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Shifts the indexes of the specified log. This will make the log shorter by the specified shift.";} + private: /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SignalOverError.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SignalOverError.h index de6c035bba73..da87ebda7563 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SignalOverError.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SignalOverError.h @@ -41,11 +41,14 @@ namespace Algorithms virtual ~SignalOverError(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Replace Y by Y/E for a MatrixWorkspace";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + // Overridden UnaryOperation methods void performUnaryOperation(const double XIn, const double YIn, const double EIn, double& YOut, double& EOut); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SmoothData.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SmoothData.h index f5a76849876e..4d8aa8a61f38 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SmoothData.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SmoothData.h @@ -57,14 +57,16 @@ class DLLExport SmoothData : public API::Algorithm virtual ~SmoothData() {} /// Algorithm's name virtual const std::string name() const { return "SmoothData"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Smooths out statistical fluctuations in a workspace's data.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Smoothing"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SmoothNeighbours.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SmoothNeighbours.h index 574f04854f13..8f83f4aabb0e 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SmoothNeighbours.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SmoothNeighbours.h @@ -92,13 +92,15 @@ class DLLExport SmoothNeighbours : public API::Algorithm virtual ~SmoothNeighbours() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "SmoothNeighbours";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Perform a moving-average smoothing by summing spectra of nearest neighbours over the face of detectors.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Smoothing";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW.h index 30508a35255f..0f38f3fa6242 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW.h @@ -54,6 +54,9 @@ class DLLExport SofQW : public API::Algorithm virtual ~SofQW() {} /// Algorithm's name virtual const std::string name() const { return "SofQW"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts a 2D workspace that has axes of \\Delta E against spectrum number to one that gives intensity as a function of momentum transfer against energy: \\rm{S}\\left( q, \\omega \\right).";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -69,8 +72,7 @@ class DLLExport SofQW : public API::Algorithm static double energyToK(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW2.h index ae173b9221f5..f077d855aef4 100755 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW2.h @@ -59,6 +59,9 @@ namespace Mantid SofQW2(); /// Algorithm's name for identification virtual const std::string name() const { return "SofQW2"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the intensity as a function of momentum transfer and energy.";} + /// Algorithm's version for identification virtual int version() const { return 1; }; /// Algorithm's category for identification @@ -66,8 +69,7 @@ namespace Mantid private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialize the algorithm void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW3.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW3.h index ac54661bdf26..ca541de3f983 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW3.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SofQW3.h @@ -60,14 +60,16 @@ namespace Mantid SofQW3(); /// Algorithm's name for identification virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the intensity as a function of momentum transfer and energy.";} + /// Algorithm's version for identification virtual int version() const; /// Algorithm's category for identification virtual const std::string category() const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialize the algorithm void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SolidAngle.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SolidAngle.h index bd34007881d6..6edf1e7c5449 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SolidAngle.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SolidAngle.h @@ -51,14 +51,16 @@ class DLLExport SolidAngle : public API::Algorithm virtual ~SolidAngle(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "SolidAngle"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The SolidAngle algorithm calculates the solid angle in steradians for each of the detectors in an instrument and outputs the data in a workspace. This can then be used to normalize a data workspace using the divide algorithm should you wish.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "CorrectionFunctions\\InstrumentCorrections";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SortEvents.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SortEvents.h index 1c1ae0b79dd0..63621c00059f 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SortEvents.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SortEvents.h @@ -50,14 +50,16 @@ class DLLExport SortEvents : public API::Algorithm virtual ~SortEvents() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "SortEvents";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Sort the events in an EventWorkspace, for faster rebinning.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Events";} protected: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); virtual void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpatialGrouping.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpatialGrouping.h index 08316f132ad8..6d1fad3f5fd2 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpatialGrouping.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpatialGrouping.h @@ -58,14 +58,16 @@ class DLLExport SpatialGrouping : public API::Algorithm virtual ~SpatialGrouping() {} /// Algorithm's name virtual const std::string name() const { return "SpatialGrouping"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm creates an XML grouping file, which can be used in GroupDetectors or ReadGroupsFromFile, which groups the detectors of an instrument based on the distance between the detectors. It does this by querying the getNeighbours method on the Detector object.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Grouping"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpecularReflectionCalculateTheta.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpecularReflectionCalculateTheta.h index 4caaf2962565..d7d9caa5a44e 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpecularReflectionCalculateTheta.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpecularReflectionCalculateTheta.h @@ -39,11 +39,14 @@ namespace Algorithms virtual ~SpecularReflectionCalculateTheta(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the specular reflection two theta scattering angle (degrees) from the detector and sample locations .";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpecularReflectionPositionCorrect.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpecularReflectionPositionCorrect.h index 81170d82e16d..41e3f8c1f797 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpecularReflectionPositionCorrect.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SpecularReflectionPositionCorrect.h @@ -39,11 +39,14 @@ namespace Mantid virtual ~SpecularReflectionPositionCorrect(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Correct detector positions vertically based on the specular reflection condition.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SphericalAbsorption.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SphericalAbsorption.h index 80452e28feba..54dbce1c9c95 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SphericalAbsorption.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SphericalAbsorption.h @@ -65,6 +65,9 @@ class DLLExport SphericalAbsorption : public API::Algorithm virtual const std::string category() const { return "CorrectionFunctions\\AbsorptionCorrections"; } /// Algorithm's name virtual const std::string name() const { return "SphericalAbsorption"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates bin-by-bin correction factors for attenuation due to absorption and scattering in a 'spherical' sample.";} + /// Algorithm's version virtual int version() const { return (1); } @@ -81,8 +84,7 @@ class DLLExport SphericalAbsorption : public API::Algorithm double m_sampleVolume; ///< The total volume of the sample private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripPeaks.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripPeaks.h index ffde5eca4716..5190673327ad 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripPeaks.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripPeaks.h @@ -61,14 +61,16 @@ class DLLExport StripPeaks : public API::Algorithm virtual ~StripPeaks() {} /// Algorithm's name virtual const std::string name() const { return "StripPeaks"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm attempts to find all the peaks in all spectra of a workspace and subtract them from the data, leaving just the 'background'.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "CorrectionFunctions;Optimization\\PeakFinding"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks.h index 187e4fe084ed..66c0c2723387 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks.h @@ -61,14 +61,16 @@ class DLLExport StripVanadiumPeaks : public API::Algorithm virtual ~StripVanadiumPeaks() {} /// Algorithm's name virtual const std::string name() const { return "StripVanadiumPeaks"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm removes peaks (at vanadium d-spacing positions by default) out of a background by linearly interpolating over the expected peak positions.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "CorrectionFunctions;Optimization\\PeakFinding;Diffraction"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks2.h index 7a345fa55dc4..bfa08637d094 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks2.h @@ -46,6 +46,11 @@ namespace Algorithms { return "StripVanadiumPeaks"; } + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm removes peaks (at vanadium d-spacing positions by default) out of a background by linearly/quadratically interpolating over the expected peak positions. ";} + + /// Algorithm's version for identification overriding a virtual method virtual int version() const { diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumEventsByLogValue.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumEventsByLogValue.h index a31805936657..00656e92d039 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumEventsByLogValue.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumEventsByLogValue.h @@ -45,6 +45,9 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "SumEventsByLogValue";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Produces a single spectrum workspace containing the total summed events in the workspace as a function of a specified log.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumNeighbours.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumNeighbours.h index 7ad3f64b434c..cae1c8631b54 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumNeighbours.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumNeighbours.h @@ -49,14 +49,16 @@ class DLLExport SumNeighbours : public API::Algorithm virtual ~SumNeighbours() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "SumNeighbours";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Sum event lists from neighboring pixels in rectangular area detectors - e.g. to reduce the signal-to-noise of individual spectra. Each spectrum in the output workspace is a sum of a block of SumX*SumY pixels. Only works on EventWorkspaces and for instruments with RectangularDetector's.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Grouping";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumRowColumn.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumRowColumn.h index 281c648e95a1..842c7709a629 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumRowColumn.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumRowColumn.h @@ -64,14 +64,16 @@ class DLLExport SumRowColumn : public API::Algorithm virtual ~SumRowColumn() {} /// Algorithm's name virtual const std::string name() const { return "SumRowColumn"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "SANS-specific algorithm which gives a single spectrum containing the total counts in either each row or each column of pixels in a square LOQ or SANS2D detector bank.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS;Transforms\\Grouping"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumSpectra.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumSpectra.h index a0064014face..c513db624d7f 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumSpectra.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumSpectra.h @@ -61,6 +61,9 @@ class DLLExport SumSpectra : public API::Algorithm virtual ~SumSpectra() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "SumSpectra";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The SumSpectra algorithm adds the data values in each time bin across a range of spectra; the output workspace has a single spectrum. If the input is an EventWorkspace, the output is also an EventWorkspace; otherwise it will be a Workspace2D.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method @@ -75,8 +78,7 @@ class DLLExport SumSpectra : public API::Algorithm void doWorkspace2D(API::MatrixWorkspace_const_sptr localworkspace, API::ISpectrum *outSpec, API::Progress &progress, size_t &numSpectra,size_t &numMasked,size_t &numZeros); - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/TOFSANSResolution.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/TOFSANSResolution.h index 74606a79cde7..14c23d675ff2 100755 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/TOFSANSResolution.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/TOFSANSResolution.h @@ -43,14 +43,16 @@ class DLLExport TOFSANSResolution : public API::Algorithm virtual ~TOFSANSResolution() {} /// Algorithm's name virtual const std::string name() const { return "TOFSANSResolution"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the Q resolution for TOF SANS data.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Transpose.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Transpose.h index 2e5a88bb599f..617805ee4c77 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Transpose.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Transpose.h @@ -47,14 +47,16 @@ namespace Mantid virtual ~Transpose() {} /// Algorithm's name virtual const std::string name() const { return "Transpose"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Transposes a workspace, so that an N1 x N2 workspace becomes N2 x N1.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Transforms\\Axes"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnGroupWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnGroupWorkspace.h index 8867da501868..64691748f369 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnGroupWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnGroupWorkspace.h @@ -49,14 +49,16 @@ class DLLExport UnGroupWorkspace : public API::Algorithm virtual ~UnGroupWorkspace() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "UnGroupWorkspace";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes a group workspace as input and ungroups the workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Transforms\\Grouping;Utility\\Workspaces";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overridden Init method void init(); /// overridden execute method diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnwrapMonitor.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnwrapMonitor.h index 8ab7293de7e1..28e29ea28f34 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnwrapMonitor.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnwrapMonitor.h @@ -51,14 +51,16 @@ class DLLExport UnwrapMonitor : public API::Algorithm virtual ~UnwrapMonitor(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "UnwrapMonitor"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes an input workspace that contains 'raw' data, unwraps the data according to the reference flightpath provided and converts the units to wavelength. The output workspace will have common bins in the maximum theoretical wavelength range.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "CorrectionFunctions\\InstrumentCorrections";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnwrapSNS.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnwrapSNS.h index 37c167b1f06f..565f4d366dde 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnwrapSNS.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnwrapSNS.h @@ -51,12 +51,14 @@ class DLLExport UnwrapSNS : public API::Algorithm UnwrapSNS(); virtual ~UnwrapSNS(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes an input workspace that contains 'raw' data, unwraps the data according to the reference flightpath provided and converts the units to wavelength. The output workspace will have common bins in the maximum theoretical wavelength range.";} + virtual int version() const; virtual const std::string category() const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void init(); void exec(); void execEvent(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UpdateScriptRepository.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UpdateScriptRepository.h index 0bed498b6a6f..5c88e2e2edf4 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UpdateScriptRepository.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UpdateScriptRepository.h @@ -42,11 +42,14 @@ namespace Algorithms virtual ~UpdateScriptRepository(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Update the local instance of ScriptRepository.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WeightedMean.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WeightedMean.h index 4936d30f1132..a4bfd65ac163 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WeightedMean.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WeightedMean.h @@ -51,13 +51,15 @@ namespace Mantid virtual ~WeightedMean() {} virtual const std::string name() const { return "WeightedMean"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "An algorithm to calculate the weighted mean of two workspaces.";} + virtual int version() const { return (1); } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden BinaryOperation methods void performBinaryOperation(const MantidVec& lhsX, const MantidVec& lhsY, const MantidVec& lhsE, const MantidVec& rhsY, const MantidVec& rhsE, MantidVec& YOut, MantidVec& EOut); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WeightedMeanOfWorkspace.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WeightedMeanOfWorkspace.h index 341b03a324f9..9e6ddea6e0a8 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WeightedMeanOfWorkspace.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WeightedMeanOfWorkspace.h @@ -40,11 +40,14 @@ namespace Mantid virtual ~WeightedMeanOfWorkspace(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm calculates the weighted mean for an entire workspace.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); + void init(); void exec(); }; diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WorkspaceJoiners.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WorkspaceJoiners.h index 65543b84eb10..c7d6e0995473 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WorkspaceJoiners.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WorkspaceJoiners.h @@ -44,6 +44,10 @@ namespace Algorithms virtual ~WorkspaceJoiners(); virtual const std::string category() const; + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Join two workspaces together by appending their spectra.";} + protected: API::MatrixWorkspace_sptr execWS2D(API::MatrixWorkspace_const_sptr ws1, API::MatrixWorkspace_const_sptr ws2); diff --git a/Code/Mantid/Framework/Algorithms/src/AbsorptionCorrection.cpp b/Code/Mantid/Framework/Algorithms/src/AbsorptionCorrection.cpp index f79b6f54f7b1..98bfbecea76f 100644 --- a/Code/Mantid/Framework/Algorithms/src/AbsorptionCorrection.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AbsorptionCorrection.cpp @@ -50,7 +50,6 @@ AbsorptionCorrection::AbsorptionCorrection() : API::Algorithm(), m_inputWS(), void AbsorptionCorrection::init() { - this->setWikiSummary("Calculates an approximation of the attenuation due to absorption and single scattering in a generic sample shape. The sample shape can be defined by, e.g., the [[CreateSampleShape]] algorithm. /n/n'''Note that if your sample is of cuboid or cylinder geometry, you will get a more accurate result from the [[FlatPlateAbsorption]] or [[CylinderAbsorption]] algorithms respectively.'''"); // The input workspace must have an instrument and units of wavelength auto wsValidator = boost::make_shared(); diff --git a/Code/Mantid/Framework/Algorithms/src/AddLogDerivative.cpp b/Code/Mantid/Framework/Algorithms/src/AddLogDerivative.cpp index 77b59f41e77b..f92f89231d4c 100644 --- a/Code/Mantid/Framework/Algorithms/src/AddLogDerivative.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AddLogDerivative.cpp @@ -49,12 +49,6 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void AddLogDerivative::initDocs() - { - this->setWikiSummary("Add a sample log that is the first or second derivative of an existing sample log."); - this->setOptionalMessage("Add a sample log that is the first or second derivative of an existing sample log."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/AddPeak.cpp b/Code/Mantid/Framework/Algorithms/src/AddPeak.cpp index aadfc02c9e12..dc9d797c4901 100644 --- a/Code/Mantid/Framework/Algorithms/src/AddPeak.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AddPeak.cpp @@ -40,12 +40,6 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void AddPeak::initDocs() - { - this->setWikiSummary("Adds a peak to a PeaksWorkspace."); - this->setOptionalMessage("Adds a peak to a PeaksWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/AddSampleLog.cpp b/Code/Mantid/Framework/Algorithms/src/AddSampleLog.cpp index 4eba3d381c74..3848301de11d 100644 --- a/Code/Mantid/Framework/Algorithms/src/AddSampleLog.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AddSampleLog.cpp @@ -25,13 +25,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(AddSampleLog) -/// Sets documentation strings for this algorithm -void AddSampleLog::initDocs() -{ - this->setWikiSummary("Used to insert a value into the sample logs in a workspace."); - this->setOptionalMessage("Used to insert a value into the sample logs in a workspace."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/AddTimeSeriesLog.cpp b/Code/Mantid/Framework/Algorithms/src/AddTimeSeriesLog.cpp index fb7973771ce8..47dc3d09fdde 100644 --- a/Code/Mantid/Framework/Algorithms/src/AddTimeSeriesLog.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AddTimeSeriesLog.cpp @@ -76,12 +76,6 @@ namespace Mantid const std::string AddTimeSeriesLog::category() const { return "DataHandling\\Logs"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void AddTimeSeriesLog::initDocs() - { - this->setWikiSummary("Creates/updates a time-series log"); - this->setOptionalMessage("Creates/updates a time-series log"); - } //---------------------------------------------------------------------------------------------- /** diff --git a/Code/Mantid/Framework/Algorithms/src/AlignDetectors.cpp b/Code/Mantid/Framework/Algorithms/src/AlignDetectors.cpp index 3f81082c975a..cccf45562de6 100644 --- a/Code/Mantid/Framework/Algorithms/src/AlignDetectors.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AlignDetectors.cpp @@ -41,13 +41,6 @@ namespace Algorithms // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(AlignDetectors) -/// Sets documentation strings for this algorithm -void AlignDetectors::initDocs() -{ - this->setWikiSummary("Performs a unit change from TOF to dSpacing, correcting the X values to account for small errors in the detector positions. "); - this->setOptionalMessage("Performs a unit change from TOF to dSpacing, correcting the X values to account for small errors in the detector positions."); -} - //----------------------------------------------------------------------- /** diff --git a/Code/Mantid/Framework/Algorithms/src/AlphaCalc.cpp b/Code/Mantid/Framework/Algorithms/src/AlphaCalc.cpp index fb4bdb9392c4..708c304f8ecf 100644 --- a/Code/Mantid/Framework/Algorithms/src/AlphaCalc.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AlphaCalc.cpp @@ -32,7 +32,7 @@ DECLARE_ALGORITHM( AlphaCalc) */ void AlphaCalc::init() { - this->setWikiSummary("Muon algorithm for calculating the detector efficiency between two groups of detectors."); + declareProperty(new API::WorkspaceProperty<>("InputWorkspace", "", Direction::Input), "Name of the input workspace"); diff --git a/Code/Mantid/Framework/Algorithms/src/AnyShapeAbsorption.cpp b/Code/Mantid/Framework/Algorithms/src/AnyShapeAbsorption.cpp index 3411d1cc3bc0..5d1e0054f398 100644 --- a/Code/Mantid/Framework/Algorithms/src/AnyShapeAbsorption.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AnyShapeAbsorption.cpp @@ -13,13 +13,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(AnyShapeAbsorption) -/// Sets documentation strings for this algorithm -void AnyShapeAbsorption::initDocs() -{ - this->setWikiSummary("Calculates an approximation of the attenuation due to absorption and single scattering in a generic sample shape. The sample shape can be defined by, e.g., the [[CreateSampleShape]] algorithm. '''Note that if your sample is of cuboid or cylinder geometry, you will get a more accurate result from the [[FlatPlateAbsorption]] or [[CylinderAbsorption]] algorithms respectively.''' "); - this->setOptionalMessage("Calculates an approximation of the attenuation due to absorption and single scattering in a generic sample shape. The sample shape can be defined by, e.g., the CreateSampleShape algorithm.\nNote that if your sample is of cuboid or cylinder geometry, you will get a more accurate result from the FlatPlateAbsorption or CylinderAbsorption algorithms respectively."); -} - using namespace Kernel; using namespace Geometry; diff --git a/Code/Mantid/Framework/Algorithms/src/ApplyCalibration.cpp b/Code/Mantid/Framework/Algorithms/src/ApplyCalibration.cpp index 799baef75a44..2aa9bd552b73 100644 --- a/Code/Mantid/Framework/Algorithms/src/ApplyCalibration.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ApplyCalibration.cpp @@ -21,13 +21,6 @@ namespace Mantid { DECLARE_ALGORITHM(ApplyCalibration) - - /// Sets documentation strings for this algorithm - void ApplyCalibration::initDocs() - { - this->setWikiSummary("Update detector positions from input table workspace."); - this->setOptionalMessage("Update detector positions from input table workspace."); - } using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ApplyDeadTimeCorr.cpp b/Code/Mantid/Framework/Algorithms/src/ApplyDeadTimeCorr.cpp index a50117199aa1..b194e159ce62 100644 --- a/Code/Mantid/Framework/Algorithms/src/ApplyDeadTimeCorr.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ApplyDeadTimeCorr.cpp @@ -46,7 +46,7 @@ DECLARE_ALGORITHM(ApplyDeadTimeCorr) */ void ApplyDeadTimeCorr::init() { - this->setWikiSummary("Apply deadtime correction to each spectra of a workspace."); + declareProperty(new API::WorkspaceProperty("InputWorkspace", "", Direction::Input), "The name of the input workspace containing measured counts"); diff --git a/Code/Mantid/Framework/Algorithms/src/ApplyDetailedBalance.cpp b/Code/Mantid/Framework/Algorithms/src/ApplyDetailedBalance.cpp index d8ed9143fc01..93dd39550350 100644 --- a/Code/Mantid/Framework/Algorithms/src/ApplyDetailedBalance.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ApplyDetailedBalance.cpp @@ -54,12 +54,6 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ApplyDetailedBalance::initDocs() - { - this->setWikiSummary("Transform scattering intensity to dynamic susceptibility."); - this->setOptionalMessage("Transform scattering intensity to dynamic susceptibility."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/ApplyTransmissionCorrection.cpp b/Code/Mantid/Framework/Algorithms/src/ApplyTransmissionCorrection.cpp index c03d349035c3..f4fb3ff6d574 100644 --- a/Code/Mantid/Framework/Algorithms/src/ApplyTransmissionCorrection.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ApplyTransmissionCorrection.cpp @@ -23,13 +23,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ApplyTransmissionCorrection) -/// Sets documentation strings for this algorithm -void ApplyTransmissionCorrection::initDocs() -{ - this->setWikiSummary("Apply a transmission correction to 2D SANS data. "); - this->setOptionalMessage("Apply a transmission correction to 2D SANS data."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/AsymmetryCalc.cpp b/Code/Mantid/Framework/Algorithms/src/AsymmetryCalc.cpp index 7f75b767c812..8963b6590660 100644 --- a/Code/Mantid/Framework/Algorithms/src/AsymmetryCalc.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AsymmetryCalc.cpp @@ -54,7 +54,7 @@ DECLARE_ALGORITHM( AsymmetryCalc) */ void AsymmetryCalc::init() { - this->setWikiSummary("Calculates the asymmetry between two groups of detectors for a muon workspace."); + declareProperty(new API::WorkspaceProperty<>("InputWorkspace", "", Direction::Input), "Name of the input workspace"); declareProperty(new API::WorkspaceProperty<>("OutputWorkspace", "", diff --git a/Code/Mantid/Framework/Algorithms/src/AverageLogData.cpp b/Code/Mantid/Framework/Algorithms/src/AverageLogData.cpp index ae969cd26ae1..4354c72ee79d 100644 --- a/Code/Mantid/Framework/Algorithms/src/AverageLogData.cpp +++ b/Code/Mantid/Framework/Algorithms/src/AverageLogData.cpp @@ -45,15 +45,6 @@ namespace Algorithms /// Algorithm's category for identification. @see Algorithm::category const std::string AverageLogData::category() const { return "DataHandling\\Logs";} - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void AverageLogData::initDocs() - { - std::string summary = "Computes the proton charge averaged value of a given log."; - this->setWikiSummary(summary); - this->setOptionalMessage(summary); - } - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/Algorithms/src/BinaryOperateMasks.cpp b/Code/Mantid/Framework/Algorithms/src/BinaryOperateMasks.cpp index 007614c047a3..652892c55b21 100644 --- a/Code/Mantid/Framework/Algorithms/src/BinaryOperateMasks.cpp +++ b/Code/Mantid/Framework/Algorithms/src/BinaryOperateMasks.cpp @@ -42,15 +42,10 @@ namespace Algorithms { // TODO Auto-generated destructor stub } - - void BinaryOperateMasks::initDocs(){ - - return; - } void BinaryOperateMasks::init() { - this->setWikiSummary("Performs binary operation, including and, or and xor, on two mask Workspaces, i.e., [[SpecialWorkspace2D]]."); + std::vector operators; operators.push_back("AND"); operators.push_back("OR"); diff --git a/Code/Mantid/Framework/Algorithms/src/CalMuonDeadTime.cpp b/Code/Mantid/Framework/Algorithms/src/CalMuonDeadTime.cpp index d46ab96e4249..7b61c947dce8 100644 --- a/Code/Mantid/Framework/Algorithms/src/CalMuonDeadTime.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CalMuonDeadTime.cpp @@ -46,7 +46,7 @@ DECLARE_ALGORITHM( CalMuonDeadTime) */ void CalMuonDeadTime::init() { - this->setWikiSummary("Calculate Muon deadtime for each spectra in a workspace."); + declareProperty(new API::WorkspaceProperty<>("InputWorkspace", "", Direction::Input), "Name of the input workspace"); diff --git a/Code/Mantid/Framework/Algorithms/src/CalculateEfficiency.cpp b/Code/Mantid/Framework/Algorithms/src/CalculateEfficiency.cpp index 0a2e945a6666..f4e245a947cc 100644 --- a/Code/Mantid/Framework/Algorithms/src/CalculateEfficiency.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CalculateEfficiency.cpp @@ -22,13 +22,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(CalculateEfficiency) -/// Sets documentation strings for this algorithm -void CalculateEfficiency::initDocs() -{ - this->setWikiSummary("Calculates the detector efficiency for a SANS instrument. "); - this->setOptionalMessage("Calculates the detector efficiency for a SANS instrument."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/CalculateFlatBackground.cpp b/Code/Mantid/Framework/Algorithms/src/CalculateFlatBackground.cpp index dfee602c798f..404c74ff4968 100644 --- a/Code/Mantid/Framework/Algorithms/src/CalculateFlatBackground.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CalculateFlatBackground.cpp @@ -36,13 +36,6 @@ namespace Mantid // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CalculateFlatBackground) - /// Sets documentation strings for this algorithm - void CalculateFlatBackground::initDocs() - { - this->setWikiSummary("Finds a constant value fit to an appropriate range of each desired spectrum and subtracts that value from the entire spectrum. "); - this->setOptionalMessage("Finds a constant value fit to an appropriate range of each desired spectrum and subtracts that value from the entire spectrum."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/CalculateTransmission.cpp b/Code/Mantid/Framework/Algorithms/src/CalculateTransmission.cpp index 83fa17aa2da6..94607af21ef5 100644 --- a/Code/Mantid/Framework/Algorithms/src/CalculateTransmission.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CalculateTransmission.cpp @@ -41,13 +41,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CalculateTransmission) -/// Sets documentation strings for this algorithm -void CalculateTransmission::initDocs() -{ - this->setWikiSummary("Calculates the transmission correction, as a function of wavelength, for a SANS instrument. "); - this->setOptionalMessage("Calculates the transmission correction, as a function of wavelength, for a SANS instrument."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/CalculateTransmissionBeamSpreader.cpp b/Code/Mantid/Framework/Algorithms/src/CalculateTransmissionBeamSpreader.cpp index 49dfb10e2c6f..f07da6116cac 100644 --- a/Code/Mantid/Framework/Algorithms/src/CalculateTransmissionBeamSpreader.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CalculateTransmissionBeamSpreader.cpp @@ -22,13 +22,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CalculateTransmissionBeamSpreader) -/// Sets documentation strings for this algorithm -void CalculateTransmissionBeamSpreader::initDocs() -{ - this->setWikiSummary("Calculates the sample transmission using the beam spreader (aka glass carbon) method. "); - this->setOptionalMessage("Calculates the sample transmission using the beam spreader (aka glass carbon) method."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/CalculateZscore.cpp b/Code/Mantid/Framework/Algorithms/src/CalculateZscore.cpp index cd10646fccef..4f744827c1d4 100644 --- a/Code/Mantid/Framework/Algorithms/src/CalculateZscore.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CalculateZscore.cpp @@ -44,12 +44,7 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- /** WIKI: - */ - void CalculateZscore::initDocs() - { - setWikiSummary("Calculate Z-score for Y and E of MatrixWorkspace."); - setOptionalMessage("Calculate Z-score for Y and E of MatrixWorkspace."); - } + * //---------------------------------------------------------------------------------------------- /** Define properties diff --git a/Code/Mantid/Framework/Algorithms/src/ChangeBinOffset.cpp b/Code/Mantid/Framework/Algorithms/src/ChangeBinOffset.cpp index d64d700a3c86..b1fc03f51237 100644 --- a/Code/Mantid/Framework/Algorithms/src/ChangeBinOffset.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ChangeBinOffset.cpp @@ -28,13 +28,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(ChangeBinOffset) - - /// Sets documentation strings for this algorithm - void ChangeBinOffset::initDocs() - { - this->setWikiSummary("Adjusts all the time bin values in a workspace by a specified amount. "); - this->setOptionalMessage("Adjusts all the time bin values in a workspace by a specified amount."); - } /** diff --git a/Code/Mantid/Framework/Algorithms/src/ChangeLogTime.cpp b/Code/Mantid/Framework/Algorithms/src/ChangeLogTime.cpp index 61a3ebf92285..ca1dae338d5e 100644 --- a/Code/Mantid/Framework/Algorithms/src/ChangeLogTime.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ChangeLogTime.cpp @@ -50,13 +50,6 @@ const std::string ChangeLogTime::category() const return "DataHandling\\Logs"; } -void ChangeLogTime::initDocs() -{ - string summary = "Adds a constant to the times for the requested log."; - this->setWikiSummary(summary); - this->setOptionalMessage(summary); -} - /// Declares the parameters for running the algorithm. void ChangeLogTime::init() { diff --git a/Code/Mantid/Framework/Algorithms/src/ChangePulsetime.cpp b/Code/Mantid/Framework/Algorithms/src/ChangePulsetime.cpp index fcfdbe80dd23..938b3dfde664 100644 --- a/Code/Mantid/Framework/Algorithms/src/ChangePulsetime.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ChangePulsetime.cpp @@ -39,12 +39,6 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ChangePulsetime::initDocs() - { - this->setWikiSummary("Adds a constant time value, in seconds, to the pulse time of events in an [[EventWorkspace]]. "); - this->setOptionalMessage("Adds a constant time value, in seconds, to the pulse time of events in an EventWorkspace. "); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/CheckWorkspacesMatch.cpp b/Code/Mantid/Framework/Algorithms/src/CheckWorkspacesMatch.cpp index da22f7adaa05..c2662303a8b8 100644 --- a/Code/Mantid/Framework/Algorithms/src/CheckWorkspacesMatch.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CheckWorkspacesMatch.cpp @@ -59,13 +59,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CheckWorkspacesMatch) -/// Sets documentation strings for this algorithm -void CheckWorkspacesMatch::initDocs() -{ - this->setWikiSummary("Compares two workspaces for equality. This algorithm is mainly intended for use by the Mantid development team as part of the testing process. "); - this->setOptionalMessage("Compares two workspaces for equality. This algorithm is mainly intended for use by the Mantid development team as part of the testing process."); -} - /// Constructor CheckWorkspacesMatch::CheckWorkspacesMatch() : API::Algorithm(), result(), prog(NULL),m_ParallelComparison(true) {} diff --git a/Code/Mantid/Framework/Algorithms/src/ChopData.cpp b/Code/Mantid/Framework/Algorithms/src/ChopData.cpp index 252d3ac74779..7b06e87da219 100644 --- a/Code/Mantid/Framework/Algorithms/src/ChopData.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ChopData.cpp @@ -31,9 +31,6 @@ DECLARE_ALGORITHM(ChopData) void ChopData::init() { - this->setWikiSummary("Splits an input workspace into a grouped workspace, where each spectra " - "if 'chopped' at a certain point (given in 'Step' input value) " - "and the X values adjusted to give all the workspace in the group the same binning."); auto wsVal = boost::make_shared(); wsVal->add("TOF"); wsVal->add(); diff --git a/Code/Mantid/Framework/Algorithms/src/ClearMaskFlag.cpp b/Code/Mantid/Framework/Algorithms/src/ClearMaskFlag.cpp index 8a638f237be1..fd50b04502be 100644 --- a/Code/Mantid/Framework/Algorithms/src/ClearMaskFlag.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ClearMaskFlag.cpp @@ -37,14 +37,6 @@ namespace Algorithms /// Algorithm's category for identification. @see Algorithm::category const std::string ClearMaskFlag::category() const { return "Utility";} - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ClearMaskFlag::initDocs() - { - std::string summary("Delete the mask flag/bit on all spectra in a workspace."); - this->setWikiSummary(summary); - this->setOptionalMessage(summary); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/CloneWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CloneWorkspace.cpp index 1f07afb7ad80..83e4fb57eba5 100644 --- a/Code/Mantid/Framework/Algorithms/src/CloneWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CloneWorkspace.cpp @@ -21,13 +21,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CloneWorkspace) -/// Sets documentation strings for this algorithm -void CloneWorkspace::initDocs() -{ - this->setWikiSummary("Copies an existing workspace into a new one. "); - this->setOptionalMessage("Copies an existing workspace into a new one."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertAxisByFormula.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertAxisByFormula.cpp index c53d7bbb3bf2..f16d9ed45646 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertAxisByFormula.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertAxisByFormula.cpp @@ -78,13 +78,6 @@ namespace Mantid return "Transforms\\Axes"; } - /// Sets documentation strings for this algorithm - void ConvertAxisByFormula::initDocs() - { - this->setWikiSummary("Converts the X or Y axis of a [[MatrixWorkspace]] via a user defined math formula."); - this->setOptionalMessage("Converts the X or Y axis of a MatrixWorkspace via a user defined math formula."); - } - /** Initialisation method. Declares properties to be used in algorithm. * */ diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertFromDistribution.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertFromDistribution.cpp index f5de242ebbb0..bcaa0993fb6a 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertFromDistribution.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertFromDistribution.cpp @@ -22,13 +22,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ConvertFromDistribution) -/// Sets documentation strings for this algorithm -void ConvertFromDistribution::initDocs() -{ - this->setWikiSummary("Converts a histogram workspace from a distribution i.e. multiplies by the bin width. "); - this->setOptionalMessage("Converts a histogram workspace from a distribution i.e. multiplies by the bin width."); -} - using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertMDHistoToMatrixWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertMDHistoToMatrixWorkspace.cpp index 3831eb0cb390..466bca427d6e 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertMDHistoToMatrixWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertMDHistoToMatrixWorkspace.cpp @@ -36,13 +36,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ConvertMDHistoToMatrixWorkspace) -/// Sets documentation strings for this algorithm -void ConvertMDHistoToMatrixWorkspace::initDocs() -{ - this->setWikiSummary("Creates a single spectrum Workspace2D with X,Y, and E copied from an first non-integrated dimension of a IMDHistoWorkspace."); - this->setOptionalMessage("Creates a single spectrum Workspace2D with X,Y, and E copied from an first non-integrated dimension of a IMDHistoWorkspace."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertSpectrumAxis.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertSpectrumAxis.cpp index e820e02a7798..8dcc64f8e7b6 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertSpectrumAxis.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertSpectrumAxis.cpp @@ -32,13 +32,6 @@ namespace Algorithms using namespace Kernel; using namespace API; using namespace Geometry; - - /// Sets documentation strings for this algorithm - void ConvertSpectrumAxis::initDocs() - { - this->setWikiSummary("Converts the axis of a [[Workspace2D]] which normally holds spectrum numbers to some other unit, which will normally be some physical value about the instrument such as Q, Q^2 or theta.

'''Note''': After running this algorithm, some features will be unavailable on the workspace as it will have lost all connection to the instrument. This includes things like the 3D Instrument Display. "); - this->setOptionalMessage("Converts the axis of a Workspace2D which normally holds spectrum numbers to some other unit, which will normally be some physical value about the instrument such as Q, Q^2 or theta. 'Note': After running this algorithm, some features will be unavailable on the workspace as it will have lost all connection to the instrument. This includes things like the 3D Instrument Display."); - } void ConvertSpectrumAxis::init() diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertSpectrumAxis2.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertSpectrumAxis2.cpp index 69cda48dda8b..6f0ad8c57ff8 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertSpectrumAxis2.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertSpectrumAxis2.cpp @@ -29,14 +29,7 @@ namespace Algorithms DECLARE_ALGORITHM(ConvertSpectrumAxis2) using namespace Kernel; using namespace API; - using namespace Geometry; - - /// Sets documentation strings for this algorithm - void ConvertSpectrumAxis2::initDocs() - { - this->setWikiSummary("Converts the axis of a [[Workspace2D]] which normally holds spectrum numbers to one of Q, Q^2 or theta.

'''Note''': After running this algorithm, some features will be unavailable on the workspace as it will have lost all connection to the instrument. This includes things like the 3D Instrument Display. "); - this->setOptionalMessage("Converts the axis of a Workspace2D which normally holds spectrum numbers to one of Q, Q^2 or theta. 'Note': After running this algorithm, some features will be unavailable on the workspace as it will have lost all connection to the instrument. This includes things like the 3D Instrument Display."); - } + using namespace Geometry; void ConvertSpectrumAxis2::init() { diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertTableToMatrixWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertTableToMatrixWorkspace.cpp index bea278524288..4062bcb119ae 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertTableToMatrixWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertTableToMatrixWorkspace.cpp @@ -26,13 +26,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ConvertTableToMatrixWorkspace) -/// Sets documentation strings for this algorithm -void ConvertTableToMatrixWorkspace::initDocs() -{ - this->setWikiSummary("Creates a single spectrum matrix workspace from some columns of a table workspace."); - this->setOptionalMessage("Creates a single spectrum matrix workspace from some columns of a table workspace."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertToDistribution.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertToDistribution.cpp index 171f073d4b5b..358d46aa56d0 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertToDistribution.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertToDistribution.cpp @@ -21,13 +21,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ConvertToDistribution) -/// Sets documentation strings for this algorithm -void ConvertToDistribution::initDocs() -{ - this->setWikiSummary("Makes a histogram workspace a distribution i.e. divides by the bin width. "); - this->setOptionalMessage("Makes a histogram workspace a distribution i.e. divides by the bin width."); -} - using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertToEventWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertToEventWorkspace.cpp index 1ef234a6d3bf..5b6bd176d6a8 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertToEventWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertToEventWorkspace.cpp @@ -52,12 +52,6 @@ namespace Algorithms //------------------------------------------MaxEventsPerBin---------------------------------------------------- - /// Sets documentation strings for this algorithm - void ConvertToEventWorkspace::initDocs() - { - this->setWikiSummary("Converts a Workspace2D from histograms to events in an EventWorkspace by converting each bin to an equivalent weighted event."); - this->setOptionalMessage("Converts a Workspace2D from histograms to events in an EventWorkspace by converting each bin to an equivalent weighted event."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertToHistogram.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertToHistogram.cpp index 080e3e975520..f41cb3afff89 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertToHistogram.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertToHistogram.cpp @@ -19,13 +19,6 @@ namespace Mantid DECLARE_ALGORITHM(ConvertToHistogram); - /// Sets documentation strings for this algorithm - void ConvertToHistogram::initDocs() - { - this->setWikiSummary("Converts a workspace containing point data into one containing histograms. "); - this->setOptionalMessage("Converts a workspace containing point data into one containing histograms."); - } - using API::MatrixWorkspace_sptr; using Mantid::MantidVec; diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertToMatrixWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertToMatrixWorkspace.cpp index 7521e61ef3aa..23763f470871 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertToMatrixWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertToMatrixWorkspace.cpp @@ -19,13 +19,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ConvertToMatrixWorkspace) -/// Sets documentation strings for this algorithm -void ConvertToMatrixWorkspace::initDocs() -{ - this->setWikiSummary("Converts an EventWorkspace into a Workspace2D, using the input workspace's current X bin values. "); - this->setOptionalMessage("Converts an EventWorkspace into a Workspace2D, using the input workspace's current X bin values."); -} - using namespace Kernel; using namespace API; using namespace DataObjects; diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertToPointData.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertToPointData.cpp index 25dc8193673c..484cef7f69a6 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertToPointData.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertToPointData.cpp @@ -16,13 +16,6 @@ namespace Mantid { DECLARE_ALGORITHM(ConvertToPointData); - - /// Sets documentation strings for this algorithm - void ConvertToPointData::initDocs() - { - this->setWikiSummary("Converts a workspace containing histogram data into one containing point data. "); - this->setOptionalMessage("Converts a workspace containing histogram data into one containing point data."); - } using API::MatrixWorkspace_sptr; using Mantid::MantidVec; diff --git a/Code/Mantid/Framework/Algorithms/src/ConvertUnits.cpp b/Code/Mantid/Framework/Algorithms/src/ConvertUnits.cpp index c391547b186a..861913b7004c 100644 --- a/Code/Mantid/Framework/Algorithms/src/ConvertUnits.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ConvertUnits.cpp @@ -46,13 +46,6 @@ namespace Algorithms // Register with the algorithm factory DECLARE_ALGORITHM(ConvertUnits) -/// Sets documentation strings for this algorithm -void ConvertUnits::initDocs() -{ - this->setWikiSummary("Performs a unit change on the X values of a [[workspace]] "); - this->setOptionalMessage("Performs a unit change on the X values of a workspace"); -} - using namespace Kernel; using namespace API; using namespace DataObjects; diff --git a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp index ff4be2b61c60..56ab23814fe6 100644 --- a/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CopyInstrumentParameters.cpp @@ -27,13 +27,6 @@ using std::size_t; // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CopyInstrumentParameters) -/// Sets documentation strings for this algorithm -void CopyInstrumentParameters::initDocs() -{ - this->setWikiSummary("Transfers an instrument from on workspace to another workspace with same base instrument."); - this->setOptionalMessage("Transfers an instrument from on workspace to another workspace with same base instrument."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/Algorithms/src/CopyLogs.cpp b/Code/Mantid/Framework/Algorithms/src/CopyLogs.cpp index d42a02b68a3b..8d853f391596 100644 --- a/Code/Mantid/Framework/Algorithms/src/CopyLogs.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CopyLogs.cpp @@ -49,12 +49,6 @@ namespace Algorithms const std::string CopyLogs::category() const { return "Utility\\Workspaces";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CopyLogs::initDocs() - { - this->setWikiSummary("Copies the sample logs from one workspace to another."); - this->setOptionalMessage("Copies the sample logs from one workspace to another."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/CopySample.cpp b/Code/Mantid/Framework/Algorithms/src/CopySample.cpp index 922fe6df593d..e139a31422d2 100644 --- a/Code/Mantid/Framework/Algorithms/src/CopySample.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CopySample.cpp @@ -46,12 +46,6 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CopySample::initDocs() - { - this->setWikiSummary("Copy some/all the sample information from one workspace to another."); - this->setOptionalMessage("Copy some/all the sample information from one workspace to another."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/CorrectFlightPaths.cpp b/Code/Mantid/Framework/Algorithms/src/CorrectFlightPaths.cpp index 2a5a95738738..59d72ea68b3d 100644 --- a/Code/Mantid/Framework/Algorithms/src/CorrectFlightPaths.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CorrectFlightPaths.cpp @@ -32,14 +32,6 @@ using namespace Geometry; // Register the class into the algorithm factory DECLARE_ALGORITHM(CorrectFlightPaths) -/// Sets documentation strings for this algorithm -void CorrectFlightPaths::initDocs() { - this->setWikiSummary( - "Used to correct flight paths in 2D shaped detectors."); - this->setOptionalMessage( - "Used to correct flight paths in 2D shaped detectors."); -} - // Constructor CorrectFlightPaths::CorrectFlightPaths() : API::Algorithm() { diff --git a/Code/Mantid/Framework/Algorithms/src/CorrectKiKf.cpp b/Code/Mantid/Framework/Algorithms/src/CorrectKiKf.cpp index a258cf9284fb..81d06d2db6a9 100644 --- a/Code/Mantid/Framework/Algorithms/src/CorrectKiKf.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CorrectKiKf.cpp @@ -26,13 +26,6 @@ namespace Algorithms // Register with the algorithm factory DECLARE_ALGORITHM(CorrectKiKf) -/// Sets documentation strings for this algorithm -void CorrectKiKf::initDocs() -{ - this->setWikiSummary("Performs k_i/k_f multiplication, in order to transform differential scattering cross section into dynamic structure factor."); - this->setOptionalMessage("Performs k_i/k_f multiplication, in order to transform differential scattering cross section into dynamic structure factor."); -} - using namespace Kernel; using namespace API; using namespace DataObjects; @@ -52,7 +45,6 @@ CorrectKiKf::~CorrectKiKf() /// Initialisation method void CorrectKiKf::init() { - this->initDocs(); auto wsValidator = boost::make_shared(); wsValidator->add("DeltaE"); diff --git a/Code/Mantid/Framework/Algorithms/src/CorrectToFile.cpp b/Code/Mantid/Framework/Algorithms/src/CorrectToFile.cpp index 410ca89edcdf..ee68937dbaf0 100644 --- a/Code/Mantid/Framework/Algorithms/src/CorrectToFile.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CorrectToFile.cpp @@ -25,13 +25,6 @@ DECLARE_ALGORITHM(CorrectToFile) // estimate that this algorithm will spend half it's time loading the file const double CorrectToFile::LOAD_TIME = 0.5; -/// Sets documentation strings for this algorithm -void CorrectToFile::initDocs() -{ - this->setWikiSummary("Correct data using a file in the LOQ RKH format "); - this->setOptionalMessage("Correct data using a file in the LOQ RKH format"); -} - void CorrectToFile::init() { diff --git a/Code/Mantid/Framework/Algorithms/src/CreateCalFileByNames.cpp b/Code/Mantid/Framework/Algorithms/src/CreateCalFileByNames.cpp index cb6b41b1cdfb..fe6920030761 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateCalFileByNames.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateCalFileByNames.cpp @@ -59,13 +59,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(CreateCalFileByNames) - /// Sets documentation strings for this algorithm - void CreateCalFileByNames::initDocs() - { - this->setWikiSummary("Create a [[CalFile|calibration file]] (extension *.cal) for diffraction focusing based on the names of the components in the instrument tree."); - this->setOptionalMessage("Create a calibration file (extension *.cal) for diffraction focusing based on the names of the components in the instrument tree."); - } - using namespace Kernel; using API::Progress; diff --git a/Code/Mantid/Framework/Algorithms/src/CreateDummyCalFile.cpp b/Code/Mantid/Framework/Algorithms/src/CreateDummyCalFile.cpp index 00b2054c62d6..7b36f2042182 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateDummyCalFile.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateDummyCalFile.cpp @@ -61,13 +61,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(CreateDummyCalFile) - /// Sets documentation strings for this algorithm - void CreateDummyCalFile::initDocs() - { - this->setWikiSummary("Create a [[CalFile|calibration file]] (extension *.cal) from a workspace by harvesting the detector ids from the instrument. All of the offsets will be zero, and the pixels will be all grouped into group one and the final column should be one. This will allow generating powder patterns from instruments that have not done a proper calibration."); - this->setOptionalMessage("Create a calibration file (extension *.cal) from a workspace by harvesting the detector ids from the instrument. All of the offsets will be zero, and the pixels will be all grouped into group one and the final column should be one. This will allow generating powder patterns from instruments that have not done a proper calibration."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/CreateFlatEventWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CreateFlatEventWorkspace.cpp index 2e9100feb98c..fe85dbd163d9 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateFlatEventWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateFlatEventWorkspace.cpp @@ -46,12 +46,6 @@ namespace Algorithms const std::string CreateFlatEventWorkspace::category() const { return "CorrectionFunctions\\BackgroundCorrections";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CreateFlatEventWorkspace::initDocs() - { - this->setWikiSummary("Creates a flat event workspace that can be used for background removal."); - this->setOptionalMessage("Creates a flat event workspace that can be used for background removal."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/CreateGroupingWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CreateGroupingWorkspace.cpp index 3455e9094c3e..18a2c0a05210 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateGroupingWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateGroupingWorkspace.cpp @@ -70,12 +70,6 @@ namespace Algorithms } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CreateGroupingWorkspace::initDocs() - { - this->setWikiSummary("Creates a new GroupingWorkspace using an instrument from one of: an input workspace, an instrument name, or an instrument IDF file.\nOptionally uses bank names to create the groups."); - this->setOptionalMessage("Creates a new GroupingWorkspace using an instrument from one of: an input workspace, an instrument name, or an instrument IDF file.\nOptionally uses bank names to create the groups."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/CreateLogPropertyTable.cpp b/Code/Mantid/Framework/Algorithms/src/CreateLogPropertyTable.cpp index 9b8172395212..5cfc42ac819b 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateLogPropertyTable.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateLogPropertyTable.cpp @@ -146,15 +146,6 @@ namespace Algorithms this->setProperty("OutputWorkspace", outputTable); } - /** - * Sets documentation strings for this algorithm. - */ - void CreateLogPropertyTable::initDocs() - { - this->setWikiSummary("Takes a list of workspaces and a list of log property names. For each workspace, the Run info is inspected and " - "all log property values are used to populate a resulting output TableWorkspace."); - } - namespace { /** diff --git a/Code/Mantid/Framework/Algorithms/src/CreateLogTimeCorrection.cpp b/Code/Mantid/Framework/Algorithms/src/CreateLogTimeCorrection.cpp index 8fa2379ee1c0..adb75ca99768 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateLogTimeCorrection.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateLogTimeCorrection.cpp @@ -44,16 +44,7 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- /** Init documentation - */ - void CreateLogTimeCorrection::initDocs() - { - setWikiSummary("Create log time correction table for event filtering by log value" - ", if frequency of log is high."); - - setOptionalMessage("Create log time correction table. Correction for each pixel is based on L1 and L2."); - - return; - } + * //---------------------------------------------------------------------------------------------- /** Declare properties diff --git a/Code/Mantid/Framework/Algorithms/src/CreatePSDBleedMask.cpp b/Code/Mantid/Framework/Algorithms/src/CreatePSDBleedMask.cpp index 3a10ee2bc323..82fac8cdfa75 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreatePSDBleedMask.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreatePSDBleedMask.cpp @@ -32,13 +32,6 @@ namespace Mantid // Register the class DECLARE_ALGORITHM(CreatePSDBleedMask) - /// Sets documentation strings for this algorithm - void CreatePSDBleedMask::initDocs() - { - this->setWikiSummary("Runs a diagnostic test for saturation of PSD tubes and creates a MaskWorkspace marking the failed tube spectra. "); - this->setOptionalMessage("Runs a diagnostic test for saturation of PSD tubes and creates a MaskWorkspace marking the failed tube spectra."); - } - const std::string CreatePSDBleedMask::category() const { return "Diagnostics"; diff --git a/Code/Mantid/Framework/Algorithms/src/CreatePeaksWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CreatePeaksWorkspace.cpp index dbbbe3434f4b..ca43358881cb 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreatePeaksWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreatePeaksWorkspace.cpp @@ -41,12 +41,6 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CreatePeaksWorkspace::initDocs() - { - this->setWikiSummary("Create an empty PeaksWorkspace."); - this->setOptionalMessage("Create an empty PeaksWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp index b481522d4d1e..730a1395c05d 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateSampleWorkspace.cpp @@ -14,7 +14,6 @@ If Random is selected the results will differ between runs of the algorithm and If comparing the output is important set Random to false or uncheck the box. *WIKI*/ -#include "MantidAlgorithms/CreateSampleWorkspace.h" #include "MantidAlgorithms/CreateSampleWorkspace.h" #include "MantidDataObjects/Workspace2D.h" #include "MantidDataObjects/EventWorkspace.h" @@ -79,15 +78,6 @@ namespace Algorithms /// Algorithm's category for identification. @see Algorithm::category const std::string CreateSampleWorkspace::category() const { return "Utility\\Workspaces";} - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CreateSampleWorkspace::initDocs() - { - std::string message = "Creates sample workspaces for usage examples and other situations."; - this->setWikiSummary(message); - this->setOptionalMessage(message); - } - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/Algorithms/src/CreateSingleValuedWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CreateSingleValuedWorkspace.cpp index 098864497adf..b8e14859f666 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateSingleValuedWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateSingleValuedWorkspace.cpp @@ -22,13 +22,6 @@ using namespace Mantid::Algorithms; // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CreateSingleValuedWorkspace) -/// Sets documentation strings for this algorithm -void CreateSingleValuedWorkspace::initDocs() -{ - this->setWikiSummary("Creates a 2D workspace with a single value contained in it. "); - this->setOptionalMessage("Creates a 2D workspace with a single value contained in it."); -} - void CreateSingleValuedWorkspace::init() { diff --git a/Code/Mantid/Framework/Algorithms/src/CreateTransmissionWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CreateTransmissionWorkspace.cpp index 3d672d8c72b0..334a1fade493 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateTransmissionWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateTransmissionWorkspace.cpp @@ -61,13 +61,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CreateTransmissionWorkspace::initDocs() - { - this->setOptionalMessage("Creates a transmission run workspace in Wavelength from input TOF workspaces."); - this->setWikiSummary( - "Creates a transmission run workspace in Wavelength from input TOF workspaces. See [[Reflectometry_Guide]]"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/CreateWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CreateWorkspace.cpp index d92c39617dcb..5cc14a5508ad 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateWorkspace.cpp @@ -37,13 +37,6 @@ using namespace API; DECLARE_ALGORITHM(CreateWorkspace) -/// Sets documentation strings for this algorithm -void CreateWorkspace::initDocs() -{ - this->setWikiSummary("This algorithm constructs a [[MatrixWorkspace]] when passed a vector for each of the X, Y, and E data values. The unit for the X Axis can optionally be specified as any of the units in the Kernel's UnitFactory. Multiple spectra may be created by supplying the NSpec Property (integer, default 1). When this is provided the vectors are split into equal-sized spectra (all X, Y, E values must still be in a single vector for input). "); - this->setOptionalMessage("This algorithm constructs a MatrixWorkspace when passed a vector for each of the X, Y, and E data values. The unit for the X Axis can optionally be specified as any of the units in the Kernel's UnitFactory. Multiple spectra may be created by supplying the NSpec Property (integer, default 1). When this is provided the vectors are split into equal-sized spectra (all X, Y, E values must still be in a single vector for input)."); -} - /// Default (empty) constructor CreateWorkspace::CreateWorkspace() : Algorithm() diff --git a/Code/Mantid/Framework/Algorithms/src/CropWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/CropWorkspace.cpp index fefe16cebd9e..1c1d1adea870 100644 --- a/Code/Mantid/Framework/Algorithms/src/CropWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CropWorkspace.cpp @@ -39,13 +39,6 @@ using std::size_t; // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CropWorkspace) -/// Sets documentation strings for this algorithm -void CropWorkspace::initDocs() -{ - this->setWikiSummary("Extracts a 'block' from a workspace and places it in a new workspace. Works for matrix and event workspaces."); - this->setOptionalMessage("Extracts a 'block' from a workspace and places it in a new workspace."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/CrossCorrelate.cpp b/Code/Mantid/Framework/Algorithms/src/CrossCorrelate.cpp index 87812741cd89..cedcec2b360d 100644 --- a/Code/Mantid/Framework/Algorithms/src/CrossCorrelate.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CrossCorrelate.cpp @@ -32,13 +32,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(CrossCorrelate) - /// Sets documentation strings for this algorithm - void CrossCorrelate::initDocs() - { - this->setWikiSummary("Cross-correlates a range of spectra against one reference spectra in the same workspace. "); - this->setOptionalMessage("Cross-correlates a range of spectra against one reference spectra in the same workspace."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/CuboidGaugeVolumeAbsorption.cpp b/Code/Mantid/Framework/Algorithms/src/CuboidGaugeVolumeAbsorption.cpp index fdfd4a13cec5..5c4ead7dcdfb 100644 --- a/Code/Mantid/Framework/Algorithms/src/CuboidGaugeVolumeAbsorption.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CuboidGaugeVolumeAbsorption.cpp @@ -25,13 +25,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CuboidGaugeVolumeAbsorption) -/// Sets documentation strings for this algorithm -void CuboidGaugeVolumeAbsorption::initDocs() -{ - this->setWikiSummary("Calculates bin-by-bin correction factors for attenuation due to absorption and (single) scattering within a cuboid shaped 'gauge volume' of a generic sample. The sample shape can be defined by, e.g., the [[CreateSampleShape]] algorithm. "); - this->setOptionalMessage("Calculates bin-by-bin correction factors for attenuation due to absorption and (single) scattering within a cuboid shaped 'gauge volume' of a generic sample. The sample shape can be defined by, e.g., the CreateSampleShape algorithm."); -} - using namespace Kernel; using namespace Geometry; diff --git a/Code/Mantid/Framework/Algorithms/src/CylinderAbsorption.cpp b/Code/Mantid/Framework/Algorithms/src/CylinderAbsorption.cpp index 98ae6635ecbb..d67883d151b0 100644 --- a/Code/Mantid/Framework/Algorithms/src/CylinderAbsorption.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CylinderAbsorption.cpp @@ -32,13 +32,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CylinderAbsorption) -/// Sets documentation strings for this algorithm -void CylinderAbsorption::initDocs() -{ - this->setWikiSummary("Calculates bin-by-bin correction factors for attenuation due to absorption and single scattering in a '''cylindrical''' sample. "); - this->setOptionalMessage("Calculates bin-by-bin correction factors for attenuation due to absorption and single scattering in a 'cylindrical' sample."); -} - using namespace Kernel; using namespace Geometry; diff --git a/Code/Mantid/Framework/Algorithms/src/DeleteLog.cpp b/Code/Mantid/Framework/Algorithms/src/DeleteLog.cpp index ab0e20f627b6..a9e7f5a22001 100644 --- a/Code/Mantid/Framework/Algorithms/src/DeleteLog.cpp +++ b/Code/Mantid/Framework/Algorithms/src/DeleteLog.cpp @@ -26,12 +26,6 @@ namespace Algorithms const std::string DeleteLog::category() const { return "DataHandling\\Logs";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void DeleteLog::initDocs() - { - this->setWikiSummary("Removes a named log from a run"); - this->setOptionalMessage("Removes a named log from a run"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/DeleteWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/DeleteWorkspace.cpp index 21d867aa13e4..4de2b0349cd5 100644 --- a/Code/Mantid/Framework/Algorithms/src/DeleteWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/DeleteWorkspace.cpp @@ -18,13 +18,6 @@ namespace Mantid // Register the algorithm DECLARE_ALGORITHM(DeleteWorkspace); - /// Sets documentation strings for this algorithm - void DeleteWorkspace::initDocs() - { - this->setWikiSummary("Removes a workspace from memory. "); - this->setOptionalMessage("Removes a workspace from memory."); - } - //-------------------------------------------------------------------------- // Private member functions diff --git a/Code/Mantid/Framework/Algorithms/src/DetectorDiagnostic.cpp b/Code/Mantid/Framework/Algorithms/src/DetectorDiagnostic.cpp index 720a06b3712a..a46420349cf9 100644 --- a/Code/Mantid/Framework/Algorithms/src/DetectorDiagnostic.cpp +++ b/Code/Mantid/Framework/Algorithms/src/DetectorDiagnostic.cpp @@ -62,12 +62,6 @@ namespace Mantid return 1; } - void DetectorDiagnostic::initDocs() - { - this->setWikiSummary("Identifies histograms and their detectors that have total numbers of counts over a user defined maximum or less than the user define minimum. "); - this->setOptionalMessage("Identifies histograms and their detectors that have total numbers of counts over a user defined maximum or less than the user define minimum."); - } - void DetectorDiagnostic::init() { this->declareProperty(new WorkspaceProperty<>("InputWorkspace", "", diff --git a/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyCor.cpp b/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyCor.cpp index c4f1ba6f4cde..458f6b804dc8 100644 --- a/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyCor.cpp +++ b/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyCor.cpp @@ -32,13 +32,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(DetectorEfficiencyCor) -/// Sets documentation strings for this algorithm -void DetectorEfficiencyCor::initDocs() -{ - this->setWikiSummary("This algorithm adjusts the binned data in a workspace for detector efficiency, calculated from the neutrons' kinetic energy, the gas filled detector's geometry and gas pressure. The data are then multiplied by k_i/k_f. "); - this->setOptionalMessage("This algorithm adjusts the binned data in a workspace for detector efficiency, calculated from the neutrons' kinetic energy, the gas filled detector's geometry and gas pressure. The data are then multiplied by k_i/k_f."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyCorUser.cpp b/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyCorUser.cpp index 7ed79f37a810..d63c4e66def0 100644 --- a/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyCorUser.cpp +++ b/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyCorUser.cpp @@ -61,13 +61,6 @@ const std::string DetectorEfficiencyCorUser::category() const { } //---------------------------------------------------------------------------------------------- -/// Sets documentation strings for this algorithm -void DetectorEfficiencyCorUser::initDocs() { - this->setWikiSummary( - "This algorithm calculates the detector efficiency according the formula set in the instrument definition file/parameters."); - this->setOptionalMessage( - "This algorithm calculates the detector efficiency according the formula set in the instrument definition file/parameters."); -} //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyVariation.cpp b/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyVariation.cpp index aafd9536c8f6..cb7be2e4e3e1 100644 --- a/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyVariation.cpp +++ b/Code/Mantid/Framework/Algorithms/src/DetectorEfficiencyVariation.cpp @@ -32,13 +32,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(DetectorEfficiencyVariation) - - /// Sets documentation strings for this algorithm - void DetectorEfficiencyVariation::initDocs() - { - this->setWikiSummary("Compares two white beam vanadium workspaces from the same instrument to find detectors whose efficiencies have changed beyond a threshold. "); - this->setOptionalMessage("Compares two white beam vanadium workspaces from the same instrument to find detectors whose efficiencies have changed beyond a threshold."); - } const std::string DetectorEfficiencyVariation::category() const { diff --git a/Code/Mantid/Framework/Algorithms/src/DiffractionEventCalibrateDetectors.cpp b/Code/Mantid/Framework/Algorithms/src/DiffractionEventCalibrateDetectors.cpp index b1bc5076ace8..54f9f94c3de9 100644 --- a/Code/Mantid/Framework/Algorithms/src/DiffractionEventCalibrateDetectors.cpp +++ b/Code/Mantid/Framework/Algorithms/src/DiffractionEventCalibrateDetectors.cpp @@ -53,13 +53,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(DiffractionEventCalibrateDetectors) - /// Sets documentation strings for this algorithm - void DiffractionEventCalibrateDetectors::initDocs() - { - this->setWikiSummary("This algorithm optimizes the position and angles of all of the detector panels. The target instruments for this feature are SNAP and TOPAZ. "); - this->setOptionalMessage("This algorithm optimizes the position and angles of all of the detector panels. The target instruments for this feature are SNAP and TOPAZ."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/DiffractionFocussing.cpp b/Code/Mantid/Framework/Algorithms/src/DiffractionFocussing.cpp index 813c9f5f437f..75279cbc7f22 100644 --- a/Code/Mantid/Framework/Algorithms/src/DiffractionFocussing.cpp +++ b/Code/Mantid/Framework/Algorithms/src/DiffractionFocussing.cpp @@ -57,13 +57,6 @@ DiffractionFocussing::DiffractionFocussing() : API::Algorithm(), API::Deprecated this->useAlgorithm("DiffractionFocussing version 2"); } -/// Sets documentation strings for this algorithm -void DiffractionFocussing::initDocs() -{ - this->setWikiSummary("Algorithm to focus powder diffraction data into a number of histograms according to a grouping scheme defined in a [[CalFile]]. "); - this->setOptionalMessage("Algorithm to focus powder diffraction data into a number of histograms according to a grouping scheme defined in a CalFile."); -} - using namespace Kernel; using API::WorkspaceProperty; diff --git a/Code/Mantid/Framework/Algorithms/src/DiffractionFocussing2.cpp b/Code/Mantid/Framework/Algorithms/src/DiffractionFocussing2.cpp index c52bf271207b..26c22d389a7b 100644 --- a/Code/Mantid/Framework/Algorithms/src/DiffractionFocussing2.cpp +++ b/Code/Mantid/Framework/Algorithms/src/DiffractionFocussing2.cpp @@ -60,13 +60,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(DiffractionFocussing2) -/// Sets documentation strings for this algorithm -void DiffractionFocussing2::initDocs() -{ - this->setWikiSummary("Algorithm to focus powder diffraction data into a number of histograms according to a grouping scheme defined in a [[CalFile]]. "); - this->setOptionalMessage("Algorithm to focus powder diffraction data into a number of histograms according to a grouping scheme defined in a CalFile."); -} - /// Constructor diff --git a/Code/Mantid/Framework/Algorithms/src/Divide.cpp b/Code/Mantid/Framework/Algorithms/src/Divide.cpp index 207b20c63f02..857ee184aaeb 100644 --- a/Code/Mantid/Framework/Algorithms/src/Divide.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Divide.cpp @@ -37,16 +37,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(Divide) - /// Sets documentation strings for this algorithm - void Divide::initDocs() - { - this->setWikiSummary("The Divide algorithm will divide the data values and calculate the corresponding [[Error Values|error values]] of two compatible workspaces. "); - this->setOptionalMessage("The Divide algorithm will divide the data values and calculate the corresponding error values of two compatible workspaces."); - this->getPointerToProperty("LHSWorkspace")->setDocumentation("The workspace to be divided by, this can be considered to be the workspace on the left hand side of the division symbol."); - this->getPointerToProperty("RHSWorkspace")->setDocumentation("The workspace to be divided, this can be considered to be the workspace on the right hand side of the division symbol."); - this->getPointerToProperty("OutputWorkspace")->setDocumentation("The name of the workspace to be created as the output of the algorithm. A workspace of this name will be created and stored in the Analysis Data Service."); - } - void Divide::init() { BinaryOperation::init(); diff --git a/Code/Mantid/Framework/Algorithms/src/EQSANSResolution.cpp b/Code/Mantid/Framework/Algorithms/src/EQSANSResolution.cpp index 2821f3e4de42..20ee0f4fba96 100644 --- a/Code/Mantid/Framework/Algorithms/src/EQSANSResolution.cpp +++ b/Code/Mantid/Framework/Algorithms/src/EQSANSResolution.cpp @@ -21,13 +21,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(EQSANSResolution) -/// Sets documentation strings for this algorithm -void EQSANSResolution::initDocs() -{ - this->setWikiSummary("Calculate the Q resolution for EQSANS data."); - this->setOptionalMessage("Calculate the Q resolution for EQSANS data."); -} - /* * Double Boltzmann fit to the TOF resolution as a function of wavelength */ diff --git a/Code/Mantid/Framework/Algorithms/src/EQSANSTofStructure.cpp b/Code/Mantid/Framework/Algorithms/src/EQSANSTofStructure.cpp index ceb646123eb2..0f3c71e88882 100644 --- a/Code/Mantid/Framework/Algorithms/src/EQSANSTofStructure.cpp +++ b/Code/Mantid/Framework/Algorithms/src/EQSANSTofStructure.cpp @@ -29,13 +29,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(EQSANSTofStructure) -/// Sets documentation strings for this algorithm -void EQSANSTofStructure::initDocs() -{ - this->setWikiSummary("Corrects the Time of Flight binning of raw EQSANS data. This algorithm needs to be run once on every data set. "); - this->setOptionalMessage("Corrects the Time of Flight binning of raw EQSANS data. This algorithm needs to be run once on every data set."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/EditInstrumentGeometry.cpp b/Code/Mantid/Framework/Algorithms/src/EditInstrumentGeometry.cpp index ce069fb394f1..78eb8a112217 100644 --- a/Code/Mantid/Framework/Algorithms/src/EditInstrumentGeometry.cpp +++ b/Code/Mantid/Framework/Algorithms/src/EditInstrumentGeometry.cpp @@ -77,12 +77,6 @@ namespace Algorithms } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void EditInstrumentGeometry::initDocs() - { - this->setWikiSummary("Add, substitute and edit an Instrument associated with a Workspace"); - this->setOptionalMessage("The edit or added information will be attached to a Workspace. Currently it is in an overwrite mode only."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/ElasticWindow.cpp b/Code/Mantid/Framework/Algorithms/src/ElasticWindow.cpp index 5bc59db6ef16..8af6a0ffe252 100644 --- a/Code/Mantid/Framework/Algorithms/src/ElasticWindow.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ElasticWindow.cpp @@ -23,13 +23,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ElasticWindow) -/// Sets documentation strings for this algorithm -void ElasticWindow::initDocs() -{ - this->setWikiSummary("This algorithm performs an integration over an energy range, with the option to subtract a background over a second range, then transposes the result into a single-spectrum workspace with units in Q and Q^2. "); - this->setOptionalMessage("This algorithm performs an integration over an energy range, with the option to subtract a background over a second range, then transposes the result into a single-spectrum workspace with units in Q and Q^2."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/EstimatePDDetectorResolution.cpp b/Code/Mantid/Framework/Algorithms/src/EstimatePDDetectorResolution.cpp index b5616ab0512e..fdea0216ccb9 100644 --- a/Code/Mantid/Framework/Algorithms/src/EstimatePDDetectorResolution.cpp +++ b/Code/Mantid/Framework/Algorithms/src/EstimatePDDetectorResolution.cpp @@ -73,14 +73,6 @@ namespace Algorithms { } - //---------------------------------------------------------------------------------------------- - /** - */ - void EstimatePDDetectorResolution::initDocs() - { - setWikiSummary("Estimate the resolution of each detector for a powder diffractometer. "); - setOptionalMessage("Estimate the resolution of each detector for a powder diffractometer. "); - } //---------------------------------------------------------------------------------------------- void EstimatePDDetectorResolution::init() diff --git a/Code/Mantid/Framework/Algorithms/src/Exponential.cpp b/Code/Mantid/Framework/Algorithms/src/Exponential.cpp index 29955c048c08..aa5c9d841e50 100644 --- a/Code/Mantid/Framework/Algorithms/src/Exponential.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Exponential.cpp @@ -28,12 +28,6 @@ namespace Mantid { this->useHistogram=true; } - /// Sets documentation strings for this algorithm - void Exponential::initDocs() - { - this->setWikiSummary("The Exponential algorithm will transform the signal values ''y'' into e^y. The corresponding error values will be updated using E_{new}=E_{old}.e^y, assuming errors are Gaussian and small compared to the signal. "); - this->setOptionalMessage("The Exponential algorithm will transform the signal values 'y' into e^y. The corresponding error values will be updated using E_{new}=E_{old}.e^y, assuming errors are Gaussian and small compared to the signal."); - } void Exponential::performUnaryOperation(const double XIn, const double YIn, const double EIn, double& YOut, double& EOut) diff --git a/Code/Mantid/Framework/Algorithms/src/ExponentialCorrection.cpp b/Code/Mantid/Framework/Algorithms/src/ExponentialCorrection.cpp index d3e3901aadfb..0015d8befc39 100644 --- a/Code/Mantid/Framework/Algorithms/src/ExponentialCorrection.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ExponentialCorrection.cpp @@ -26,13 +26,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(ExponentialCorrection) - /// Sets documentation strings for this algorithm - void ExponentialCorrection::initDocs() - { - this->setWikiSummary("Corrects the data in a workspace by the value of an exponential function which is evaluated at the X value of each data point. "); - this->setOptionalMessage("Corrects the data in a workspace by the value of an exponential function which is evaluated at the X value of each data point."); - } - void ExponentialCorrection::defineProperties() { diff --git a/Code/Mantid/Framework/Algorithms/src/ExportTimeSeriesLog.cpp b/Code/Mantid/Framework/Algorithms/src/ExportTimeSeriesLog.cpp index 8c232ce54531..7940a815c6ef 100644 --- a/Code/Mantid/Framework/Algorithms/src/ExportTimeSeriesLog.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ExportTimeSeriesLog.cpp @@ -53,10 +53,6 @@ namespace Algorithms ExportTimeSeriesLog::~ExportTimeSeriesLog() { } - - void ExportTimeSeriesLog::initDocs(){ - - } //---------------------------------------------------------------------------------------------- /** Definition of all input arguments diff --git a/Code/Mantid/Framework/Algorithms/src/ExtractFFTSpectrum.cpp b/Code/Mantid/Framework/Algorithms/src/ExtractFFTSpectrum.cpp index 14a39d3fac3e..4885db48a818 100644 --- a/Code/Mantid/Framework/Algorithms/src/ExtractFFTSpectrum.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ExtractFFTSpectrum.cpp @@ -60,13 +60,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ExtractFFTSpectrum) -/// Sets documentation strings for this algorithm -void ExtractFFTSpectrum::initDocs() -{ - this->setWikiSummary("This algorithm performs a [[FFT|Fast Fourier Transform]] on each spectrum in a workspace, and from the result takes the indicated spectrum and places it into the OutputWorkspace, so that you end up with one result spectrum for each input spectrum in the same workspace. "); - this->setOptionalMessage("This algorithm performs a Fast Fourier Transform on each spectrum in a workspace, and from the result takes the indicated spectrum and places it into the OutputWorkspace, so that you end up with one result spectrum for each input spectrum in the same workspace."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ExtractMask.cpp b/Code/Mantid/Framework/Algorithms/src/ExtractMask.cpp index 604d04bedcda..ebb280a5c7e2 100644 --- a/Code/Mantid/Framework/Algorithms/src/ExtractMask.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ExtractMask.cpp @@ -25,13 +25,6 @@ namespace Mantid // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ExtractMask) - /// Sets documentation strings for this algorithm - void ExtractMask::initDocs() - { - this->setWikiSummary("Extracts the masking from a given workspace and places it in a new workspace. "); - this->setOptionalMessage("Extracts the masking from a given workspace and places it in a new workspace."); - } - using Kernel::Direction; using Geometry::IDetector_const_sptr; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ExtractMaskToTable.cpp b/Code/Mantid/Framework/Algorithms/src/ExtractMaskToTable.cpp index 205f8b62922d..6587dfa01913 100644 --- a/Code/Mantid/Framework/Algorithms/src/ExtractMaskToTable.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ExtractMaskToTable.cpp @@ -55,12 +55,7 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- /** Documentation - */ - void ExtractMaskToTable::initDocs() - { - setWikiSummary("Extracts the masking from a given workspace and places it in a new table workspace compatible to MaskBinsFromTable."); - setOptionalMessage("The output TableWorkspace should be compatible to MaskBinsFromTable."); - } + * //---------------------------------------------------------------------------------------------- /** Declare properties diff --git a/Code/Mantid/Framework/Algorithms/src/ExtractSingleSpectrum.cpp b/Code/Mantid/Framework/Algorithms/src/ExtractSingleSpectrum.cpp index aaa367f98c88..88ba5f682a4b 100644 --- a/Code/Mantid/Framework/Algorithms/src/ExtractSingleSpectrum.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ExtractSingleSpectrum.cpp @@ -20,13 +20,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ExtractSingleSpectrum) -/// Sets documentation strings for this algorithm -void ExtractSingleSpectrum::initDocs() -{ - this->setWikiSummary("Extracts the specified spectrum from a workspace and places it in a new single-spectrum workspace. "); - this->setOptionalMessage("Extracts the specified spectrum from a workspace and places it in a new single-spectrum workspace."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/FFT.cpp b/Code/Mantid/Framework/Algorithms/src/FFT.cpp index a36d7d474e9f..1df430e7449f 100644 --- a/Code/Mantid/Framework/Algorithms/src/FFT.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FFT.cpp @@ -150,13 +150,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(FFT) -/// Sets documentation strings for this algorithm -void FFT::initDocs() -{ - this->setWikiSummary("Performs complex Fast Fourier Transform "); - this->setOptionalMessage("Performs complex Fast Fourier Transform"); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/FFTDerivative.cpp b/Code/Mantid/Framework/Algorithms/src/FFTDerivative.cpp index b92774406a74..e9d69c141d9a 100644 --- a/Code/Mantid/Framework/Algorithms/src/FFTDerivative.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FFTDerivative.cpp @@ -20,13 +20,6 @@ DECLARE_ALGORITHM(FFTDerivative) using namespace Mantid::Kernel; using namespace Mantid::API; -/// Sets documentation strings for this algorithm -void FFTDerivative::initDocs() -{ - this->setWikiSummary("Calculated derivatives of a spectra in the MatrixWorkspace using Fast Fourier Transform (FFT)."); - this->setOptionalMessage("Calculated derivatives of a spectra in the MatrixWorkspace using Fast Fourier Transform (FFT)."); -} - void FFTDerivative::init() { declareProperty(new WorkspaceProperty<>("InputWorkspace","",Direction::Input),"Input workspace for differentiation"); diff --git a/Code/Mantid/Framework/Algorithms/src/FFTSmooth.cpp b/Code/Mantid/Framework/Algorithms/src/FFTSmooth.cpp index eb8d9044eb6e..d1a33cd198f0 100644 --- a/Code/Mantid/Framework/Algorithms/src/FFTSmooth.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FFTSmooth.cpp @@ -38,13 +38,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(FFTSmooth) -/// Sets documentation strings for this algorithm -void FFTSmooth::initDocs() -{ - this->setWikiSummary("Performs smoothing of a spectrum using various filters. "); - this->setOptionalMessage("Performs smoothing of a spectrum using various filters."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/FFTSmooth2.cpp b/Code/Mantid/Framework/Algorithms/src/FFTSmooth2.cpp index cbd9298b6a12..1b4b07a8028c 100644 --- a/Code/Mantid/Framework/Algorithms/src/FFTSmooth2.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FFTSmooth2.cpp @@ -43,13 +43,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(FFTSmooth2) -/// Sets documentation strings for this algorithm -void FFTSmooth2::initDocs() -{ - this->setWikiSummary("Performs smoothing of a spectrum using various filters. "); - this->setOptionalMessage("Performs smoothing of a spectrum using various filters."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/FilterBadPulses.cpp b/Code/Mantid/Framework/Algorithms/src/FilterBadPulses.cpp index b60c6f5351da..c18e15cb72b2 100644 --- a/Code/Mantid/Framework/Algorithms/src/FilterBadPulses.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FilterBadPulses.cpp @@ -25,13 +25,6 @@ namespace Algorithms // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(FilterBadPulses) -/// Sets documentation strings for this algorithm -void FilterBadPulses::initDocs() -{ - this->setWikiSummary("Filters out events associated with pulses that happen when proton charge is lower than a given percentage of the average. "); - this->setOptionalMessage("Filters out events associated with pulses that happen when proton charge is lower than a given percentage of the average."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/FilterByLogValue.cpp b/Code/Mantid/Framework/Algorithms/src/FilterByLogValue.cpp index 0964aa1f4105..30805893c3b3 100644 --- a/Code/Mantid/Framework/Algorithms/src/FilterByLogValue.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FilterByLogValue.cpp @@ -54,13 +54,6 @@ namespace Algorithms // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(FilterByLogValue) -/// Sets documentation strings for this algorithm -void FilterByLogValue::initDocs() -{ - this->setWikiSummary("Filter out events from an [[EventWorkspace]] based on a sample log value satisfying filter criteria. "); - this->setOptionalMessage("Filter out events from an EventWorkspace based on a sample log value satisfying filter criteria."); -} - using namespace Kernel; using namespace DataObjects; diff --git a/Code/Mantid/Framework/Algorithms/src/FilterByTime.cpp b/Code/Mantid/Framework/Algorithms/src/FilterByTime.cpp index f305ad9fd963..87885e08d68e 100644 --- a/Code/Mantid/Framework/Algorithms/src/FilterByTime.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FilterByTime.cpp @@ -34,13 +34,6 @@ namespace Algorithms // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(FilterByTime) -/// Sets documentation strings for this algorithm -void FilterByTime::initDocs() -{ - this->setWikiSummary("This algorithm filters out events from an EventWorkspace that are not between given start and stop times."); - this->setOptionalMessage("This algorithm filters out events from an EventWorkspace that are not between given start and stop times."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/FilterByTime2.cpp b/Code/Mantid/Framework/Algorithms/src/FilterByTime2.cpp index 6b668a82c444..b55d28e61273 100644 --- a/Code/Mantid/Framework/Algorithms/src/FilterByTime2.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FilterByTime2.cpp @@ -27,11 +27,6 @@ namespace Algorithms FilterByTime2::~FilterByTime2() { } - - void FilterByTime2::initDocs() - { - - } //----------------------------------------------------------------------- void FilterByTime2::init() diff --git a/Code/Mantid/Framework/Algorithms/src/FilterByXValue.cpp b/Code/Mantid/Framework/Algorithms/src/FilterByXValue.cpp index 73696eb2da34..03d2da2ef4e5 100644 --- a/Code/Mantid/Framework/Algorithms/src/FilterByXValue.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FilterByXValue.cpp @@ -33,13 +33,6 @@ namespace Algorithms /// Algorithm's category for identification. @see Algorithm::category const std::string FilterByXValue::category() const { return "Events\\EventFiltering";} - /// Sets documentation strings for this algorithm - void FilterByXValue::initDocs() - { - this->setWikiSummary("Filters the events in an event workspace according to a minimum and/or maximum value of X."); - this->setOptionalMessage("Filters events according to a min and/or max value of X."); - } - void FilterByXValue::init() { declareProperty(new WorkspaceProperty("InputWorkspace","",Direction::Input), "The input workspace."); diff --git a/Code/Mantid/Framework/Algorithms/src/FilterEvents.cpp b/Code/Mantid/Framework/Algorithms/src/FilterEvents.cpp index 6399720a88e6..aa44fc688b0e 100644 --- a/Code/Mantid/Framework/Algorithms/src/FilterEvents.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FilterEvents.cpp @@ -75,11 +75,6 @@ namespace Algorithms FilterEvents::~FilterEvents() { } - - void FilterEvents::initDocs() - { - setWikiSummary("Filter events from an [[EventWorkspace]] to one or multiple [[EventWorkspace]]s according to a series of splitters."); - } //---------------------------------------------------------------------------------------------- /** Declare Inputs diff --git a/Code/Mantid/Framework/Algorithms/src/FindCenterOfMassPosition.cpp b/Code/Mantid/Framework/Algorithms/src/FindCenterOfMassPosition.cpp index 0f09c6f6225c..8bb2b9574983 100644 --- a/Code/Mantid/Framework/Algorithms/src/FindCenterOfMassPosition.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FindCenterOfMassPosition.cpp @@ -32,13 +32,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(FindCenterOfMassPosition) -/// Sets documentation strings for this algorithm -void FindCenterOfMassPosition::initDocs() -{ - this->setWikiSummary("Finds the beam center in a 2D SANS data set. "); - this->setOptionalMessage("Finds the beam center in a 2D SANS data set."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/FindCenterOfMassPosition2.cpp b/Code/Mantid/Framework/Algorithms/src/FindCenterOfMassPosition2.cpp index ffb4ffae1c24..fd8333fa8beb 100644 --- a/Code/Mantid/Framework/Algorithms/src/FindCenterOfMassPosition2.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FindCenterOfMassPosition2.cpp @@ -33,13 +33,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(FindCenterOfMassPosition2) -/// Sets documentation strings for this algorithm -void FindCenterOfMassPosition2::initDocs() -{ - this->setWikiSummary("Finds the beam center in a 2D SANS data set. "); - this->setOptionalMessage("Finds the beam center in a 2D SANS data set."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/FindDeadDetectors.cpp b/Code/Mantid/Framework/Algorithms/src/FindDeadDetectors.cpp index 10f378f05c69..e4d9c37ddb0d 100644 --- a/Code/Mantid/Framework/Algorithms/src/FindDeadDetectors.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FindDeadDetectors.cpp @@ -25,13 +25,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(FindDeadDetectors) - /// Sets documentation strings for this algorithm - void FindDeadDetectors::initDocs() - { - this->setWikiSummary("Identifies and flags empty spectra caused by 'dead' detectors. "); - this->setOptionalMessage("Identifies and flags empty spectra caused by 'dead' detectors."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/FindDetectorsOutsideLimits.cpp b/Code/Mantid/Framework/Algorithms/src/FindDetectorsOutsideLimits.cpp index 142ae85f7a09..28886200b856 100644 --- a/Code/Mantid/Framework/Algorithms/src/FindDetectorsOutsideLimits.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FindDetectorsOutsideLimits.cpp @@ -28,13 +28,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(FindDetectorsOutsideLimits) - /// Sets documentation strings for this algorithm - void FindDetectorsOutsideLimits::initDocs() - { - this->setWikiSummary("Identifies histograms and their detectors that have total numbers of counts over a user defined maximum or less than the user define minimum. "); - this->setOptionalMessage("Identifies histograms and their detectors that have total numbers of counts over a user defined maximum or less than the user define minimum."); - } - const std::string FindDetectorsOutsideLimits::category() const { return "Diagnostics"; diff --git a/Code/Mantid/Framework/Algorithms/src/FindPeakBackground.cpp b/Code/Mantid/Framework/Algorithms/src/FindPeakBackground.cpp index 99edc4f21783..b5795550488f 100644 --- a/Code/Mantid/Framework/Algorithms/src/FindPeakBackground.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FindPeakBackground.cpp @@ -61,12 +61,7 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- /** WIKI: - */ - void FindPeakBackground::initDocs() - { - setWikiSummary("Separates background from signal for spectra of a workspace."); - setOptionalMessage("Separates background from signal for spectra of a workspace."); - } + * //---------------------------------------------------------------------------------------------- /** Define properties diff --git a/Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp b/Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp index bcb0dd4f8274..bf0075855ca8 100644 --- a/Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp @@ -88,12 +88,7 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- /** Sets documentation strings for this algorithm - */ - void FindPeaks::initDocs() - { - this->setWikiSummary("Searches for peaks in a dataset."); - this->setOptionalMessage("Searches for peaks in a dataset."); - } + * //---------------------------------------------------------------------------------------------- /** Initialize and declare properties. diff --git a/Code/Mantid/Framework/Algorithms/src/FitPeak.cpp b/Code/Mantid/Framework/Algorithms/src/FitPeak.cpp index 00576f909466..ca9dfb408032 100644 --- a/Code/Mantid/Framework/Algorithms/src/FitPeak.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FitPeak.cpp @@ -1130,14 +1130,7 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- /** Document - */ - void FitPeak::initDocs() - { - setWikiSummary("Fit a single peak with checking mechanism. "); - setOptionalMessage("Fit a single peak with checking mechanism. "); - - return; - } + * //---------------------------------------------------------------------------------------------- /** Declare properties diff --git a/Code/Mantid/Framework/Algorithms/src/FixGSASInstrumentFile.cpp b/Code/Mantid/Framework/Algorithms/src/FixGSASInstrumentFile.cpp index 87cffc72488a..b263ca097b4e 100644 --- a/Code/Mantid/Framework/Algorithms/src/FixGSASInstrumentFile.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FixGSASInstrumentFile.cpp @@ -53,14 +53,7 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- /** Sets documentation strings for this algorithm - */ - void FixGSASInstrumentFile::initDocs() - { - setWikiSummary("Fix format error in an GSAS instrument file."); - setOptionalMessage("Fix format error in an GSAS instrument file."); - - return; - } + * //---------------------------------------------------------------------------------------------- /** Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/src/FlatPlateAbsorption.cpp b/Code/Mantid/Framework/Algorithms/src/FlatPlateAbsorption.cpp index 87bc22f36c0a..9886e8d5af2e 100644 --- a/Code/Mantid/Framework/Algorithms/src/FlatPlateAbsorption.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FlatPlateAbsorption.cpp @@ -24,13 +24,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(FlatPlateAbsorption) -/// Sets documentation strings for this algorithm -void FlatPlateAbsorption::initDocs() -{ - this->setWikiSummary("Calculates bin-by-bin correction factors for attenuation due to absorption and scattering in a sample of 'flat plate' geometry. "); - this->setOptionalMessage("Calculates bin-by-bin correction factors for attenuation due to absorption and scattering in a sample of 'flat plate' geometry."); -} - using namespace Kernel; using namespace Geometry; diff --git a/Code/Mantid/Framework/Algorithms/src/GeneralisedSecondDifference.cpp b/Code/Mantid/Framework/Algorithms/src/GeneralisedSecondDifference.cpp index fd695e3c6988..7fabe9e3eddb 100644 --- a/Code/Mantid/Framework/Algorithms/src/GeneralisedSecondDifference.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GeneralisedSecondDifference.cpp @@ -24,15 +24,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(GeneralisedSecondDifference) - /// Sets documentation strings for this algorithm - void GeneralisedSecondDifference::initDocs() - { - this->setWikiSummary( - "Computes the generalised second difference of a spectrum or several spectra. "); - this->setOptionalMessage( - "Computes the generalised second difference of a spectrum or several spectra."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp b/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp index 8da0697a4830..8c749c849b28 100644 --- a/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GenerateEventsFilter.cpp @@ -93,11 +93,6 @@ namespace Algorithms GenerateEventsFilter::~GenerateEventsFilter() { } - - void GenerateEventsFilter::initDocs() - { - this->setWikiSummary("Generate one or a set of event filters according to time or specified log's value."); - } //---------------------------------------------------------------------------------------------- /** Declare input diff --git a/Code/Mantid/Framework/Algorithms/src/GeneratePeaks.cpp b/Code/Mantid/Framework/Algorithms/src/GeneratePeaks.cpp index d9f4b566b35b..4dbc895be27e 100644 --- a/Code/Mantid/Framework/Algorithms/src/GeneratePeaks.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GeneratePeaks.cpp @@ -72,11 +72,7 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- /** Wiki documentation - */ - void GeneratePeaks::initDocs() - { - this->setWikiSummary("Generate peaks in an output workspace according to a [[TableWorkspace]] containing a list of peak's parameters."); - } + * //---------------------------------------------------------------------------------------------- /** Define algorithm's properties diff --git a/Code/Mantid/Framework/Algorithms/src/GeneratePythonScript.cpp b/Code/Mantid/Framework/Algorithms/src/GeneratePythonScript.cpp index 63ec763287d3..ce8fc50d55c6 100644 --- a/Code/Mantid/Framework/Algorithms/src/GeneratePythonScript.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GeneratePythonScript.cpp @@ -45,12 +45,6 @@ namespace Algorithms DECLARE_ALGORITHM(GeneratePythonScript) //---------------------------------------------------------------------------------------------- -/// Sets documentation strings for this algorithm -void GeneratePythonScript::initDocs() -{ - this->setWikiSummary("Reproduce the history of a workspace and save it to a Python script file or Python variable."); - this->setOptionalMessage("An Algorithm to generate a Python script file to reproduce the history of a workspace."); -} //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/GetDetOffsetsMultiPeaks.cpp b/Code/Mantid/Framework/Algorithms/src/GetDetOffsetsMultiPeaks.cpp index bc72f6e56809..1c1ce7a8727a 100644 --- a/Code/Mantid/Framework/Algorithms/src/GetDetOffsetsMultiPeaks.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GetDetOffsetsMultiPeaks.cpp @@ -236,17 +236,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(GetDetOffsetsMultiPeaks) - //---------------------------------------------------------------------------------------------- - /** Sets documentation strings for this algorithm - */ - void GetDetOffsetsMultiPeaks::initDocs() - { - this->setWikiSummary("Creates an [[OffsetsWorkspace]] containing offsets for each detector. " - "You can then save these to a .cal file using SaveCalFile."); - this->setOptionalMessage("Creates an OffsetsWorkspace containing offsets for each detector. " - "You can then save these to a .cal file using SaveCalFile."); - } - //---------------------------------------------------------------------------------------------- /** Constructor */ diff --git a/Code/Mantid/Framework/Algorithms/src/GetDetectorOffsets.cpp b/Code/Mantid/Framework/Algorithms/src/GetDetectorOffsets.cpp index d28e6bf67d35..c979a7d1f046 100644 --- a/Code/Mantid/Framework/Algorithms/src/GetDetectorOffsets.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GetDetectorOffsets.cpp @@ -39,13 +39,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(GetDetectorOffsets) - /// Sets documentation strings for this algorithm - void GetDetectorOffsets::initDocs() - { - this->setWikiSummary("Creates an [[OffsetsWorkspace]] containing offsets for each detector. You can then save these to a .cal file using SaveCalFile."); - this->setOptionalMessage("Creates an OffsetsWorkspace containing offsets for each detector. You can then save these to a .cal file using SaveCalFile."); - } - using namespace Kernel; using namespace API; using std::size_t; diff --git a/Code/Mantid/Framework/Algorithms/src/GetEi.cpp b/Code/Mantid/Framework/Algorithms/src/GetEi.cpp index 1705b4de99a4..23a3bb2644da 100644 --- a/Code/Mantid/Framework/Algorithms/src/GetEi.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GetEi.cpp @@ -37,13 +37,6 @@ namespace Algorithms // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(GetEi) -/// Sets documentation strings for this algorithm -void GetEi::initDocs() -{ - this->setWikiSummary("Calculates the kinetic energy of neutrons leaving the source based on the time it takes for them to travel between two monitors."); - this->setOptionalMessage("Calculates the kinetic energy of neutrons leaving the source based on the time it takes for them to travel between two monitors."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/GetEi2.cpp b/Code/Mantid/Framework/Algorithms/src/GetEi2.cpp index 29d1f0f7e1f6..02c190a0bd5a 100644 --- a/Code/Mantid/Framework/Algorithms/src/GetEi2.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GetEi2.cpp @@ -47,13 +47,6 @@ namespace Algorithms // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(GetEi2) - /// Sets documentation strings for this algorithm - void GetEi2::initDocs() - { - this->setWikiSummary("Calculates the kinetic energy of neutrons leaving the source based on the time it takes for them to travel between two monitors. "); - this->setOptionalMessage("Calculates the kinetic energy of neutrons leaving the source based on the time it takes for them to travel between two monitors."); - } - /** * Default contructor diff --git a/Code/Mantid/Framework/Algorithms/src/GetTimeSeriesLogInformation.cpp b/Code/Mantid/Framework/Algorithms/src/GetTimeSeriesLogInformation.cpp index 9ba2a4293f8b..7b5a797d2da4 100644 --- a/Code/Mantid/Framework/Algorithms/src/GetTimeSeriesLogInformation.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GetTimeSeriesLogInformation.cpp @@ -45,12 +45,6 @@ namespace Algorithms GetTimeSeriesLogInformation::~GetTimeSeriesLogInformation() { } - - void GetTimeSeriesLogInformation::initDocs() - { - this->setWikiSummary("Get information from a TimeSeriesProperty log."); - this->setOptionalMessage("Get information from a TimeSeriesProperty log."); - } /** Definition of all input arguments */ diff --git a/Code/Mantid/Framework/Algorithms/src/GroupWorkspaces.cpp b/Code/Mantid/Framework/Algorithms/src/GroupWorkspaces.cpp index 7d99fb87becd..163c8d6e5b75 100644 --- a/Code/Mantid/Framework/Algorithms/src/GroupWorkspaces.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GroupWorkspaces.cpp @@ -25,7 +25,7 @@ namespace Mantid ///Initialisation method void GroupWorkspaces::init() { - this->setWikiSummary("Takes workspaces as input and groups similar workspaces together."); + declareProperty(new ArrayProperty ("InputWorkspaces", boost::make_shared>>()), "Name of the Input Workspaces to Group"); declareProperty(new WorkspaceProperty ("OutputWorkspace", "", Direction::Output), diff --git a/Code/Mantid/Framework/Algorithms/src/HRPDSlabCanAbsorption.cpp b/Code/Mantid/Framework/Algorithms/src/HRPDSlabCanAbsorption.cpp index 9134c6f92e05..721751c6baf5 100644 --- a/Code/Mantid/Framework/Algorithms/src/HRPDSlabCanAbsorption.cpp +++ b/Code/Mantid/Framework/Algorithms/src/HRPDSlabCanAbsorption.cpp @@ -30,13 +30,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(HRPDSlabCanAbsorption) -/// Sets documentation strings for this algorithm -void HRPDSlabCanAbsorption::initDocs() -{ - this->setWikiSummary("Calculates attenuation due to absorption and scattering in an HRPD 'slab' can. "); - this->setOptionalMessage("Calculates attenuation due to absorption and scattering in an HRPD 'slab' can."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/He3TubeEfficiency.cpp b/Code/Mantid/Framework/Algorithms/src/He3TubeEfficiency.cpp index b7f7f027591a..9beae1985a0e 100644 --- a/Code/Mantid/Framework/Algorithms/src/He3TubeEfficiency.cpp +++ b/Code/Mantid/Framework/Algorithms/src/He3TubeEfficiency.cpp @@ -44,13 +44,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(He3TubeEfficiency) -/// Sets documentation strings for this algorithm -void He3TubeEfficiency::initDocs() -{ - this->setWikiSummary(" He3 tube efficiency correction. "); - this->setOptionalMessage("He3 tube efficiency correction."); -} - /// Default constructor He3TubeEfficiency::He3TubeEfficiency() : Algorithm(), inputWS(), outputWS(), paraMap(NULL), shapeCache(), samplePos(), spectraSkipped(), diff --git a/Code/Mantid/Framework/Algorithms/src/IQTransform.cpp b/Code/Mantid/Framework/Algorithms/src/IQTransform.cpp index 52fc0f3a93cc..79cfb86f5d56 100644 --- a/Code/Mantid/Framework/Algorithms/src/IQTransform.cpp +++ b/Code/Mantid/Framework/Algorithms/src/IQTransform.cpp @@ -56,13 +56,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(IQTransform) -/// Sets documentation strings for this algorithm -void IQTransform::initDocs() -{ - this->setWikiSummary("This algorithm provides various functions that are sometimes used to linearise the output of a '''SANS''' data reduction prior to fitting it. "); - this->setOptionalMessage("This algorithm provides various functions that are sometimes used to linearise the output of a 'SANS' data reduction prior to fitting it."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/IdentifyNoisyDetectors.cpp b/Code/Mantid/Framework/Algorithms/src/IdentifyNoisyDetectors.cpp index 7436dd931b0e..67b0bb5c11f2 100644 --- a/Code/Mantid/Framework/Algorithms/src/IdentifyNoisyDetectors.cpp +++ b/Code/Mantid/Framework/Algorithms/src/IdentifyNoisyDetectors.cpp @@ -31,13 +31,6 @@ using namespace API; DECLARE_ALGORITHM(IdentifyNoisyDetectors) -/// Sets documentation strings for this algorithm -void IdentifyNoisyDetectors::initDocs() -{ - this->setWikiSummary("This algorithm creates a single-column workspace where the Y values are populated withs 1s and 0s, 0 signifying that the detector is to be considered \"bad\" based on the method described below. "); - this->setOptionalMessage("This algorithm creates a single-column workspace where the Y values are populated withs 1s and 0s, 0 signifying that the detector is to be considered 'bad' based on the method described below."); -} - void IdentifyNoisyDetectors::init() { diff --git a/Code/Mantid/Framework/Algorithms/src/IntegrateByComponent.cpp b/Code/Mantid/Framework/Algorithms/src/IntegrateByComponent.cpp index 08411e42ecea..be7c3c00e229 100644 --- a/Code/Mantid/Framework/Algorithms/src/IntegrateByComponent.cpp +++ b/Code/Mantid/Framework/Algorithms/src/IntegrateByComponent.cpp @@ -47,12 +47,6 @@ namespace Algorithms const std::string IntegrateByComponent::category() const { return "Utility\\Workspaces";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void IntegrateByComponent::initDocs() - { - this->setWikiSummary("Averages up the instrument hierarchy."); - this->setOptionalMessage("Averages up the instrument hierarchy."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/Integration.cpp b/Code/Mantid/Framework/Algorithms/src/Integration.cpp index 8afa99d38323..657b288e966b 100644 --- a/Code/Mantid/Framework/Algorithms/src/Integration.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Integration.cpp @@ -35,13 +35,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(Integration) -/// Sets documentation strings for this algorithm -void Integration::initDocs() -{ - this->setWikiSummary("Integration takes a 2D [[workspace]] or an [[EventWorkspace]] as input and sums the data values. Optionally, the range summed can be restricted in either dimension. The output will always be a [[MatrixWorkspace]] even when inputting an EventWorkspace, if you wish to keep this as the output then you should use [[Rebin]]."); - this->setOptionalMessage("Integration takes a 2D workspace or an EventWorkspace as input and sums the data values. Optionally, the range summed can be restricted in either dimension."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/InterpolatingRebin.cpp b/Code/Mantid/Framework/Algorithms/src/InterpolatingRebin.cpp index 5c7945a16937..22b44ca33660 100644 --- a/Code/Mantid/Framework/Algorithms/src/InterpolatingRebin.cpp +++ b/Code/Mantid/Framework/Algorithms/src/InterpolatingRebin.cpp @@ -40,13 +40,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(InterpolatingRebin) - /// Sets documentation strings for this algorithm - void InterpolatingRebin::initDocs() - { - this->setWikiSummary("Creates a workspace with different x-value bin boundaries where the new y-values are estimated using cubic splines. "); - this->setOptionalMessage("Creates a workspace with different x-value bin boundaries where the new y-values are estimated using cubic splines."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/InvertMask.cpp b/Code/Mantid/Framework/Algorithms/src/InvertMask.cpp index 06dae2897120..1596616cb38c 100644 --- a/Code/Mantid/Framework/Algorithms/src/InvertMask.cpp +++ b/Code/Mantid/Framework/Algorithms/src/InvertMask.cpp @@ -37,14 +37,6 @@ namespace Algorithms InvertMask::~InvertMask() { } - - void InvertMask::initDocs() - { - this->setWikiSummary("This algorithm inverts every mask bit in a MaskWorkspace. "); - this->setOptionalMessage("This algorithm inverts every mask bit in a MaskWorkspace."); - - return; - } void InvertMask::init() { diff --git a/Code/Mantid/Framework/Algorithms/src/Logarithm.cpp b/Code/Mantid/Framework/Algorithms/src/Logarithm.cpp index 33fff1d44916..dbeca463675f 100644 --- a/Code/Mantid/Framework/Algorithms/src/Logarithm.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Logarithm.cpp @@ -21,11 +21,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(Logarithm) -void Logarithm::initDocs(){ - this->setWikiSummary("''Logarithm'' function calculates the logarithm of the data, held in a workspace. A user can choose between natural (default) or base 10 logarithm"); - this->setOptionalMessage("Logarithm function calculates the logarithm of the data, held in a workspace. A user can choose between natural (default) or base 10 logarithm"); -} - Logarithm::Logarithm():UnaryOperation(),log_Min(0),is_natural(true) { this->useHistogram=true; diff --git a/Code/Mantid/Framework/Algorithms/src/MaskBins.cpp b/Code/Mantid/Framework/Algorithms/src/MaskBins.cpp index 25b152b6c8a6..9c14f51f1b4e 100644 --- a/Code/Mantid/Framework/Algorithms/src/MaskBins.cpp +++ b/Code/Mantid/Framework/Algorithms/src/MaskBins.cpp @@ -38,13 +38,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(MaskBins) -/// Sets documentation strings for this algorithm -void MaskBins::initDocs() -{ - this->setWikiSummary("Marks bins in a workspace as being masked. "); - this->setOptionalMessage("Marks bins in a workspace as being masked."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/MaskBinsFromTable.cpp b/Code/Mantid/Framework/Algorithms/src/MaskBinsFromTable.cpp index 136383d332aa..aa02975aa17d 100644 --- a/Code/Mantid/Framework/Algorithms/src/MaskBinsFromTable.cpp +++ b/Code/Mantid/Framework/Algorithms/src/MaskBinsFromTable.cpp @@ -53,11 +53,6 @@ namespace Algorithms } //---------------------------------------------------------------------------------------------- - void MaskBinsFromTable::initDocs() - { - this->setWikiSummary("Mask bins from a table workspace. "); - this->setOptionalMessage("Mask bins from a table workspace. "); - } //---------------------------------------------------------------------------------------------- void MaskBinsFromTable::init() diff --git a/Code/Mantid/Framework/Algorithms/src/MaskDetectorsIf.cpp b/Code/Mantid/Framework/Algorithms/src/MaskDetectorsIf.cpp index a7fcf1b17084..02c86a6bd0ee 100644 --- a/Code/Mantid/Framework/Algorithms/src/MaskDetectorsIf.cpp +++ b/Code/Mantid/Framework/Algorithms/src/MaskDetectorsIf.cpp @@ -24,13 +24,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(MaskDetectorsIf) -/// Sets documentation strings for this algorithm -void MaskDetectorsIf::initDocs() -{ - this->setWikiSummary("Adjusts the selected field for a [[CalFile]] depending on the values in the input workspace. "); - this->setOptionalMessage("Adjusts the selected field for a CalFile depending on the values in the input workspace."); -} - using namespace Kernel; diff --git a/Code/Mantid/Framework/Algorithms/src/Max.cpp b/Code/Mantid/Framework/Algorithms/src/Max.cpp index f88938e8dd30..35f3af46cae5 100644 --- a/Code/Mantid/Framework/Algorithms/src/Max.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Max.cpp @@ -24,13 +24,6 @@ DECLARE_ALGORITHM(Max) using namespace Kernel; using namespace API; -/// Set the documentation strings -void Max::initDocs() -{ - this->setWikiSummary("Takes a 2D workspace as input and find the maximum in each 1D spectrum. The algorithm creates a new 1D workspace containing all maxima as well as their X boundaries and error. This is used in particular for single crystal as a quick way to find strong peaks."); - this->setOptionalMessage("Takes a 2D workspace as input and find the maximum in each 1D spectrum. The algorithm creates a new 1D workspace containing all maxima as well as their X boundaries and error. This is used in particular for single crystal as a quick way to find strong peaks."); -} - /** Initialisation method. * */ diff --git a/Code/Mantid/Framework/Algorithms/src/MaxMin.cpp b/Code/Mantid/Framework/Algorithms/src/MaxMin.cpp index 5e25b84d81af..fb15de75c44c 100644 --- a/Code/Mantid/Framework/Algorithms/src/MaxMin.cpp +++ b/Code/Mantid/Framework/Algorithms/src/MaxMin.cpp @@ -26,13 +26,6 @@ DECLARE_ALGORITHM(MaxMin) using namespace Kernel; using namespace API; -/// Set the documentation strings -void MaxMin::initDocs() -{ - this->setWikiSummary("Takes a 2D workspace as input and find the maximum (minimum) in each 1D spectrum. The algorithm creates a new 1D workspace containing all maxima (minima) as well as their X boundaries and error. This is used in particular for single crystal as a quick way to find strong peaks."); - this->setOptionalMessage("Takes a 2D workspace as input and find the maximum (minimum) in each 1D spectrum."); -} - /** Initialisation method. * */ diff --git a/Code/Mantid/Framework/Algorithms/src/MergeRuns.cpp b/Code/Mantid/Framework/Algorithms/src/MergeRuns.cpp index 898d02aaaac0..08d422a9da0c 100644 --- a/Code/Mantid/Framework/Algorithms/src/MergeRuns.cpp +++ b/Code/Mantid/Framework/Algorithms/src/MergeRuns.cpp @@ -48,13 +48,6 @@ namespace Algorithms // Register with the algorithm factory DECLARE_ALGORITHM(MergeRuns) -/// Sets documentation strings for this algorithm -void MergeRuns::initDocs() -{ - this->setWikiSummary("Combines the data contained in an arbitrary number of input workspaces."); - this->setOptionalMessage("Combines the data contained in an arbitrary number of input workspaces."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/Min.cpp b/Code/Mantid/Framework/Algorithms/src/Min.cpp index a75b4af329d1..221e656977dc 100644 --- a/Code/Mantid/Framework/Algorithms/src/Min.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Min.cpp @@ -24,13 +24,6 @@ DECLARE_ALGORITHM(Min) using namespace Kernel; using namespace API; -/// Set the documentation strings -void Min::initDocs() -{ - this->setWikiSummary("Takes a 2D workspace as input and find the minimum in each 1D spectrum. The algorithm creates a new 1D workspace containing all minima as well as their X boundaries and error. This is used in particular for single crystal as a quick way to find strong peaks."); - this->setOptionalMessage("Takes a 2D workspace as input and find the minimum in each 1D spectrum. The algorithm creates a new 1D workspace containing all minima as well as their X boundaries and error. This is used in particular for single crystal as a quick way to find strong peaks."); -} - /** Initialisation method. * */ diff --git a/Code/Mantid/Framework/Algorithms/src/Minus.cpp b/Code/Mantid/Framework/Algorithms/src/Minus.cpp index ff9e836f0eef..bd10c65f9d5e 100644 --- a/Code/Mantid/Framework/Algorithms/src/Minus.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Minus.cpp @@ -32,13 +32,6 @@ namespace Mantid { // Register the class into the algorithm factory DECLARE_ALGORITHM(Minus) - - /// Sets documentation strings for this algorithm - void Minus::initDocs() - { - this->setWikiSummary("The Minus algorithm will subtract the data values and calculate the corresponding [[Error Values|error values]] for two compatible workspaces."); - this->setOptionalMessage("The Minus algorithm will subtract the data values and calculate the corresponding error values for two compatible workspaces."); - } const std::string Minus::alias() const { diff --git a/Code/Mantid/Framework/Algorithms/src/ModeratorTzero.cpp b/Code/Mantid/Framework/Algorithms/src/ModeratorTzero.cpp index 7acb8319d310..a9b7e404ab36 100644 --- a/Code/Mantid/Framework/Algorithms/src/ModeratorTzero.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ModeratorTzero.cpp @@ -63,13 +63,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ModeratorTzero); -/// Sets documentation strings for this algorithm -void ModeratorTzero::initDocs() -{ - setWikiSummary("Corrects the time of flight of an indirect geometry instrument by a time offset that is dependent on the energy of the neutron after passing through the moderator."); - setOptionalMessage("Corrects the time of flight of an indirect geometry instrument by a time offset that is dependent on the energy of the neutron after passing through the moderator."); -} - using namespace Mantid::Kernel; using namespace Mantid::API; using namespace Mantid::Geometry; diff --git a/Code/Mantid/Framework/Algorithms/src/ModeratorTzeroLinear.cpp b/Code/Mantid/Framework/Algorithms/src/ModeratorTzeroLinear.cpp index c1aab587dc01..ff6de9ccf5a3 100644 --- a/Code/Mantid/Framework/Algorithms/src/ModeratorTzeroLinear.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ModeratorTzeroLinear.cpp @@ -58,13 +58,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ModeratorTzeroLinear) -/// Sets documentation strings for this algorithm -void ModeratorTzeroLinear::initDocs() -{ - setWikiSummary("Corrects the time of flight of an indirect geometry instrument by a time offset that is linearly dependent on the wavelength of the neutron after passing through the moderator."); - setOptionalMessage(" Corrects the time of flight of an indirect geometry instrument by a time offset that is linearly dependent on the wavelength of the neutron after passing through the moderator."); -} - using namespace Mantid::Kernel; using namespace Mantid::API; using namespace Mantid::Geometry; diff --git a/Code/Mantid/Framework/Algorithms/src/Multiply.cpp b/Code/Mantid/Framework/Algorithms/src/Multiply.cpp index b4c730b687b5..a0cbe875dc94 100644 --- a/Code/Mantid/Framework/Algorithms/src/Multiply.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Multiply.cpp @@ -35,13 +35,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(Multiply) - /// Sets documentation strings for this algorithm - void Multiply::initDocs() - { - this->setWikiSummary("The Multiply algorithm will multiply the data values and calculate the corresponding [[Error Values|error values]] of two compatible workspaces."); - this->setOptionalMessage("The Multiply algorithm will multiply the data values and calculate the corresponding error values of two compatible workspaces. "); - } - void Multiply::performBinaryOperation(const MantidVec& lhsX, const MantidVec& lhsY, const MantidVec& lhsE, const MantidVec& rhsY, const MantidVec& rhsE, MantidVec& YOut, MantidVec& EOut) diff --git a/Code/Mantid/Framework/Algorithms/src/MultiplyRange.cpp b/Code/Mantid/Framework/Algorithms/src/MultiplyRange.cpp index 1ffe8a7353de..5f4d6adc931d 100644 --- a/Code/Mantid/Framework/Algorithms/src/MultiplyRange.cpp +++ b/Code/Mantid/Framework/Algorithms/src/MultiplyRange.cpp @@ -18,13 +18,6 @@ namespace Algorithms // Algorithm must be declared DECLARE_ALGORITHM(MultiplyRange) -/// Sets documentation strings for this algorithm -void MultiplyRange::initDocs() -{ - this->setWikiSummary("An algorithm to multiply a range of bins in a workspace by the factor given."); - this->setOptionalMessage("An algorithm to multiply a range of bins in a workspace by the factor given."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/MuonGroupDetectors.cpp b/Code/Mantid/Framework/Algorithms/src/MuonGroupDetectors.cpp index f860e6e63fb5..d10bea6a7b79 100644 --- a/Code/Mantid/Framework/Algorithms/src/MuonGroupDetectors.cpp +++ b/Code/Mantid/Framework/Algorithms/src/MuonGroupDetectors.cpp @@ -49,12 +49,6 @@ namespace Algorithms const std::string MuonGroupDetectors::category() const { return "Muon"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void MuonGroupDetectors::initDocs() - { - this->setWikiSummary("Applies detector grouping to a workspace. (Muon version)."); - this->setOptionalMessage("Applies detector grouping to a workspace. (Muon version)."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/NormaliseByCurrent.cpp b/Code/Mantid/Framework/Algorithms/src/NormaliseByCurrent.cpp index 1eafc3f30c3c..27b6b469e550 100644 --- a/Code/Mantid/Framework/Algorithms/src/NormaliseByCurrent.cpp +++ b/Code/Mantid/Framework/Algorithms/src/NormaliseByCurrent.cpp @@ -25,13 +25,6 @@ namespace Algorithms // Register with the algorithm factory DECLARE_ALGORITHM(NormaliseByCurrent) -/// Sets documentation strings for this algorithm -void NormaliseByCurrent::initDocs() -{ - this->setWikiSummary("Normalises a workspace by the proton charge."); - this->setOptionalMessage("Normalises a workspace by the proton charge."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/NormaliseByDetector.cpp b/Code/Mantid/Framework/Algorithms/src/NormaliseByDetector.cpp index 4134c7adeea3..925a33f2321b 100644 --- a/Code/Mantid/Framework/Algorithms/src/NormaliseByDetector.cpp +++ b/Code/Mantid/Framework/Algorithms/src/NormaliseByDetector.cpp @@ -154,12 +154,6 @@ namespace Mantid const std::string NormaliseByDetector::category() const { return "CorrectionFunctions\\NormalisationCorrections";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void NormaliseByDetector::initDocs() - { - this->setWikiSummary("Normalise the input workspace by the detector efficiency."); - this->setOptionalMessage("Normalise the input workspace by the detector efficiency."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/NormaliseToMonitor.cpp b/Code/Mantid/Framework/Algorithms/src/NormaliseToMonitor.cpp index f32391aa7c7f..25a53909cd7f 100644 --- a/Code/Mantid/Framework/Algorithms/src/NormaliseToMonitor.cpp +++ b/Code/Mantid/Framework/Algorithms/src/NormaliseToMonitor.cpp @@ -190,14 +190,6 @@ NormaliseToMonitor::NormaliseToMonitor() : /// Destructor NormaliseToMonitor::~NormaliseToMonitor() {} -/// Sets documentation strings for this algorithm -void NormaliseToMonitor::initDocs() -{ - this->setWikiSummary("Normalises a 2D workspace by a specified spectrum, spectrum, described by a monitor ID or spectrun provided in a separate worskspace. "); - this->setOptionalMessage("Normalises a 2D workspace by a specified spectrum or spectrum, described by monitor ID." - "If monitor spectrum specified, it is used as input property"); -} - void NormaliseToMonitor::init() { auto val = boost::make_shared(); diff --git a/Code/Mantid/Framework/Algorithms/src/NormaliseToUnity.cpp b/Code/Mantid/Framework/Algorithms/src/NormaliseToUnity.cpp index 4e347c375857..c54803b1a248 100644 --- a/Code/Mantid/Framework/Algorithms/src/NormaliseToUnity.cpp +++ b/Code/Mantid/Framework/Algorithms/src/NormaliseToUnity.cpp @@ -21,13 +21,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(NormaliseToUnity) -/// Sets documentation strings for this algorithm -void NormaliseToUnity::initDocs() -{ - this->setWikiSummary("NormaliseToUnity takes a 2D [[workspace]] or an [[EventWorkspace]] as input and normalises it to 1. Optionally, the range summed can be restricted in either dimension. "); - this->setOptionalMessage("NormaliseToUnity takes a 2D workspace or an EventWorkspace as input and normalises it to 1. Optionally, the range summed can be restricted in either dimension."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/OneMinusExponentialCor.cpp b/Code/Mantid/Framework/Algorithms/src/OneMinusExponentialCor.cpp index 67c190bc653d..8ab0b589b578 100644 --- a/Code/Mantid/Framework/Algorithms/src/OneMinusExponentialCor.cpp +++ b/Code/Mantid/Framework/Algorithms/src/OneMinusExponentialCor.cpp @@ -31,13 +31,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(OneMinusExponentialCor) - /// Sets documentation strings for this algorithm - void OneMinusExponentialCor::initDocs() - { - this->setWikiSummary("Corrects the data in a workspace by one minus the value of an exponential function. "); - this->setOptionalMessage("Corrects the data in a workspace by one minus the value of an exponential function."); - } - void OneMinusExponentialCor::defineProperties() { diff --git a/Code/Mantid/Framework/Algorithms/src/PDFFourierTransform.cpp b/Code/Mantid/Framework/Algorithms/src/PDFFourierTransform.cpp index d3f066b84cb0..06e34e10dddf 100644 --- a/Code/Mantid/Framework/Algorithms/src/PDFFourierTransform.cpp +++ b/Code/Mantid/Framework/Algorithms/src/PDFFourierTransform.cpp @@ -113,12 +113,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void PDFFourierTransform::initDocs() - { - this->setWikiSummary("PDFFourierTransform() does Fourier transform from S(Q) to G(r), which is paired distribution function (PDF). G(r) will be stored in another named workspace."); - this->setOptionalMessage("Fourier transform from S(Q) to G(r), which is paired distribution function (PDF). G(r) will be stored in another named workspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/Pause.cpp b/Code/Mantid/Framework/Algorithms/src/Pause.cpp index b6eb1fb51504..a18cf4b220b2 100644 --- a/Code/Mantid/Framework/Algorithms/src/Pause.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Pause.cpp @@ -52,12 +52,6 @@ namespace Algorithms const std::string Pause::category() const { return "Utility\\Development";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void Pause::initDocs() - { - this->setWikiSummary("Pause a script for a given duration."); - this->setOptionalMessage("Pause a script for a given duration."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/PerformIndexOperations.cpp b/Code/Mantid/Framework/Algorithms/src/PerformIndexOperations.cpp index 0fe5a1dc9c0b..cbc4b000133d 100644 --- a/Code/Mantid/Framework/Algorithms/src/PerformIndexOperations.cpp +++ b/Code/Mantid/Framework/Algorithms/src/PerformIndexOperations.cpp @@ -423,12 +423,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void PerformIndexOperations::initDocs() - { - this->setWikiSummary("Process the workspace according to the Index operations provided."); - this->setOptionalMessage(this->getWikiSummary()); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/PlotAsymmetryByLogValue.cpp b/Code/Mantid/Framework/Algorithms/src/PlotAsymmetryByLogValue.cpp index ca3ba511a1d6..014bf153744f 100644 --- a/Code/Mantid/Framework/Algorithms/src/PlotAsymmetryByLogValue.cpp +++ b/Code/Mantid/Framework/Algorithms/src/PlotAsymmetryByLogValue.cpp @@ -99,13 +99,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(PlotAsymmetryByLogValue) - /// Sets documentation strings for this algorithm - void PlotAsymmetryByLogValue::initDocs() - { - this->setWikiSummary("Calculates asymmetry for a series of log values "); - this->setOptionalMessage("Calculates asymmetry for a series of log values"); - } - /** Initialisation method. Declares properties to be used in algorithm. * diff --git a/Code/Mantid/Framework/Algorithms/src/Plus.cpp b/Code/Mantid/Framework/Algorithms/src/Plus.cpp index 1abac4d3d228..ab624c938d31 100644 --- a/Code/Mantid/Framework/Algorithms/src/Plus.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Plus.cpp @@ -35,13 +35,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(Plus) - /// Sets documentation strings for this algorithm - void Plus::initDocs() - { - this->setWikiSummary("The Plus algorithm will add the data values and calculate the corresponding [[Error Values|error values]] in two compatible workspaces. "); - this->setOptionalMessage("The Plus algorithm will add the data values and calculate the corresponding error values in two compatible workspaces. "); - } - // ===================================== HISTOGRAM BINARY OPERATIONS ========================================== //--------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/Algorithms/src/PointByPointVCorrection.cpp b/Code/Mantid/Framework/Algorithms/src/PointByPointVCorrection.cpp index 511c0f8b3b97..1b4c42893cdc 100644 --- a/Code/Mantid/Framework/Algorithms/src/PointByPointVCorrection.cpp +++ b/Code/Mantid/Framework/Algorithms/src/PointByPointVCorrection.cpp @@ -35,13 +35,6 @@ namespace Algorithms // Register with the algorithm factory DECLARE_ALGORITHM(PointByPointVCorrection) -/// Sets documentation strings for this algorithm -void PointByPointVCorrection::initDocs() -{ - this->setWikiSummary("Spectrum by spectrum division for vanadium normalisation correction. "); - this->setOptionalMessage("Spectrum by spectrum division for vanadium normalisation correction."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/PoissonErrors.cpp b/Code/Mantid/Framework/Algorithms/src/PoissonErrors.cpp index 870bf4da6277..5be821f3b932 100644 --- a/Code/Mantid/Framework/Algorithms/src/PoissonErrors.cpp +++ b/Code/Mantid/Framework/Algorithms/src/PoissonErrors.cpp @@ -21,13 +21,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(PoissonErrors) - /// Sets documentation strings for this algorithm - void PoissonErrors::initDocs() - { - this->setWikiSummary("Calculates the gaussian approximation of Poisson error based on a matching workspace containing the original counts. "); - this->setOptionalMessage("Calculates the gaussian approxiamtion of Poisson error based on a matching workspace containing the original counts."); - } - /** Performs a simple check to see if the sizes of two workspaces are identically sized * @param lhs :: the first workspace to compare diff --git a/Code/Mantid/Framework/Algorithms/src/PolynomialCorrection.cpp b/Code/Mantid/Framework/Algorithms/src/PolynomialCorrection.cpp index e5f598f0f30e..ef0b02624af6 100644 --- a/Code/Mantid/Framework/Algorithms/src/PolynomialCorrection.cpp +++ b/Code/Mantid/Framework/Algorithms/src/PolynomialCorrection.cpp @@ -28,13 +28,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(PolynomialCorrection) - /// Sets documentation strings for this algorithm - void PolynomialCorrection::initDocs() - { - this->setWikiSummary("Corrects the data in a workspace by the value of a polynomial function which is evaluated at the X value of each data point. "); - this->setOptionalMessage("Corrects the data in a workspace by the value of a polynomial function which is evaluated at the X value of each data point."); - } - void PolynomialCorrection::defineProperties() { diff --git a/Code/Mantid/Framework/Algorithms/src/Power.cpp b/Code/Mantid/Framework/Algorithms/src/Power.cpp index 2d0f55874143..8916fbcd59e1 100644 --- a/Code/Mantid/Framework/Algorithms/src/Power.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Power.cpp @@ -36,12 +36,6 @@ Power::Power():UnaryOperation() { this->useHistogram=true; } -/// Sets documentation strings for this algorithm -void Power::initDocs() -{ - this->setWikiSummary("The Power algorithm will raise the base workspace to a particular power. Corresponding [[Error Values|error values]] will be created. "); - this->setOptionalMessage("The Power algorithm will raise the base workspace to a particular power. Corresponding error values will be created."); -} /////////////////////////////////// diff --git a/Code/Mantid/Framework/Algorithms/src/PowerLawCorrection.cpp b/Code/Mantid/Framework/Algorithms/src/PowerLawCorrection.cpp index af4c92eddcb9..f23a0e3d6460 100644 --- a/Code/Mantid/Framework/Algorithms/src/PowerLawCorrection.cpp +++ b/Code/Mantid/Framework/Algorithms/src/PowerLawCorrection.cpp @@ -25,13 +25,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(PowerLawCorrection) - /// Sets documentation strings for this algorithm - void PowerLawCorrection::initDocs() - { - this->setWikiSummary("Corrects the data and error values on a workspace by the value of an exponential function which is evaluated at the X value of each data point: c0*x^C1. The data and error values are multiplied by the value of this function. "); - this->setOptionalMessage("Corrects the data and error values on a workspace by the value of an exponential function which is evaluated at the X value of each data point: c0*x^C1. The data and error values are multiplied by the value of this function."); - } - void PowerLawCorrection::defineProperties() { diff --git a/Code/Mantid/Framework/Algorithms/src/Q1D2.cpp b/Code/Mantid/Framework/Algorithms/src/Q1D2.cpp index 16355163212c..f2c1b899dfe9 100644 --- a/Code/Mantid/Framework/Algorithms/src/Q1D2.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Q1D2.cpp @@ -145,13 +145,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(Q1D2) -/// Sets documentation strings for this algorithm -void Q1D2::initDocs() -{ - this->setWikiSummary("Converts a workspace of counts in wavelength bins into a workspace of counts verses momentum transfer, Q, assuming completely elastic scattering"); - this->setOptionalMessage("Converts a workspace of counts in wavelength bins into a workspace of counts verses momentum transfer, Q, assuming completely elastic scattering"); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/Q1DTOF.cpp b/Code/Mantid/Framework/Algorithms/src/Q1DTOF.cpp index 684f87083071..e8fd8bbedaca 100644 --- a/Code/Mantid/Framework/Algorithms/src/Q1DTOF.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Q1DTOF.cpp @@ -20,13 +20,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(Q1DTOF) -/// Sets documentation strings for this algorithm -void Q1DTOF::initDocs() -{ - this->setWikiSummary("Performs azimuthal averaging on a 2D SANS data to produce I(Q). "); - this->setOptionalMessage("Performs azimuthal averaging on a 2D SANS data to produce I(Q)."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/Q1DWeighted.cpp b/Code/Mantid/Framework/Algorithms/src/Q1DWeighted.cpp index 5c3923bb59e4..17da18887c34 100644 --- a/Code/Mantid/Framework/Algorithms/src/Q1DWeighted.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Q1DWeighted.cpp @@ -31,13 +31,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(Q1DWeighted) -/// Sets documentation strings for this algorithm -void Q1DWeighted::initDocs() -{ - this->setWikiSummary("Performs azimuthal averaging on a 2D SANS data to produce I(Q). "); - this->setOptionalMessage("Performs azimuthal averaging on a 2D SANS data to produce I(Q)."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/Qxy.cpp b/Code/Mantid/Framework/Algorithms/src/Qxy.cpp index 9546a2c96506..a9aeb597aaf8 100644 --- a/Code/Mantid/Framework/Algorithms/src/Qxy.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Qxy.cpp @@ -25,13 +25,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(Qxy) -/// Sets documentation strings for this algorithm -void Qxy::initDocs() -{ - this->setWikiSummary("Performs the final part of a SANS (LOQ/SANS2D) two dimensional (in Q) data reduction. "); - this->setOptionalMessage("Performs the final part of a SANS (LOQ/SANS2D) two dimensional (in Q) data reduction."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/RadiusSum.cpp b/Code/Mantid/Framework/Algorithms/src/RadiusSum.cpp index b7957e4cc7be..7bcdda25573a 100644 --- a/Code/Mantid/Framework/Algorithms/src/RadiusSum.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RadiusSum.cpp @@ -74,12 +74,6 @@ namespace Algorithms const std::string RadiusSum::category() const { return "Transforms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void RadiusSum::initDocs() - { - this->setWikiSummary("Sum of all the counts inside a ring against the scattering angle for each Radius."); - this->setOptionalMessage("Sum of all the counts inside a ring against the scattering angle for each Radius."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/RayTracerTester.cpp b/Code/Mantid/Framework/Algorithms/src/RayTracerTester.cpp index 1c5a3aae3f2f..bfb704a2c619 100644 --- a/Code/Mantid/Framework/Algorithms/src/RayTracerTester.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RayTracerTester.cpp @@ -46,12 +46,6 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void RayTracerTester::initDocs() - { - this->setWikiSummary("Algorithm to test ray tracer by spraying evenly spaced rays around."); - this->setOptionalMessage("Algorithm to test ray tracer by spraying evenly spaced rays around."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/ReadGroupsFromFile.cpp b/Code/Mantid/Framework/Algorithms/src/ReadGroupsFromFile.cpp index ccd95360f66b..2efe210955aa 100644 --- a/Code/Mantid/Framework/Algorithms/src/ReadGroupsFromFile.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ReadGroupsFromFile.cpp @@ -47,14 +47,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(ReadGroupsFromFile) - /// Sets documentation strings for this algorithm - void ReadGroupsFromFile::initDocs() - { - this->setWikiSummary("Read a diffraction [[CalFile|calibration file]] (*.cal) or an [[GroupDetectors|XML grouping file]] (*.xml) and an instrument name, and output a 2D workspace containing on the Y-axis the values of the Group each detector belongs to.

This is used to visualise the grouping scheme for powder diffractometers, where a large number of detectors are grouped together. The output 2D workspace can be visualize using the show instrument method."); - - this->setOptionalMessage("Read a diffraction calibration file (*.cal) or an XML grouping file (*.xml) and an instrument name, and output a 2D workspace containing on the Y-axis the values of the Group each detector belongs to. This is used to visualise the grouping scheme for powder diffractometers, where a large number of detectors are grouped together. The output 2D workspace can be visualize using the show instrument method."); - } - using namespace Kernel; using API::WorkspaceProperty; diff --git a/Code/Mantid/Framework/Algorithms/src/RealFFT.cpp b/Code/Mantid/Framework/Algorithms/src/RealFFT.cpp index e319d0bbff52..0ae432ca5e5f 100644 --- a/Code/Mantid/Framework/Algorithms/src/RealFFT.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RealFFT.cpp @@ -41,13 +41,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(RealFFT) -/// Sets documentation strings for this algorithm -void RealFFT::initDocs() -{ - this->setWikiSummary("Performs real Fast Fourier Transform "); - this->setOptionalMessage("Performs real Fast Fourier Transform"); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/Rebin.cpp b/Code/Mantid/Framework/Algorithms/src/Rebin.cpp index 490e8e42ec55..4ce9ac175fa2 100644 --- a/Code/Mantid/Framework/Algorithms/src/Rebin.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Rebin.cpp @@ -61,13 +61,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(Rebin) - /// Sets documentation strings for this algorithm - void Rebin::initDocs() - { - this->setWikiSummary("Rebins data with new X bin boundaries. For EventWorkspaces, you can very quickly rebin in-place by keeping the same output name and PreserveEvents=true."); - this->setOptionalMessage("Rebins data with new X bin boundaries. For EventWorkspaces, you can very quickly rebin in-place by keeping the same output name and PreserveEvents=true."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/Rebin2D.cpp b/Code/Mantid/Framework/Algorithms/src/Rebin2D.cpp index b606ccbe6848..774e5df5bd6c 100644 --- a/Code/Mantid/Framework/Algorithms/src/Rebin2D.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Rebin2D.cpp @@ -43,12 +43,7 @@ namespace Mantid //-------------------------------------------------------------------------- /** * Sets documentation strings for this algorithm - */ - void Rebin2D::initDocs() - { - this->setWikiSummary("Rebins both axes of a 2D workspace."); - this->setOptionalMessage("Rebins both axes of a 2D workspace using the given parameters"); - } + * //-------------------------------------------------------------------------- // Private methods diff --git a/Code/Mantid/Framework/Algorithms/src/RebinByPulseTimes.cpp b/Code/Mantid/Framework/Algorithms/src/RebinByPulseTimes.cpp index d7704f790db1..a97b941e1d70 100644 --- a/Code/Mantid/Framework/Algorithms/src/RebinByPulseTimes.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RebinByPulseTimes.cpp @@ -79,12 +79,6 @@ namespace Algorithms const std::string RebinByPulseTimes::category() const { return "Transforms\\Rebin";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void RebinByPulseTimes::initDocs() - { - this->setWikiSummary("Bins events according to pulse time. Binning parameters are specified relative to the start of the run."); - this->setOptionalMessage("Bins events according to pulse time. Binning parameters are specified relative to the start of the run."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/RebinToWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/RebinToWorkspace.cpp index 6423f056b011..c0d575d491d8 100644 --- a/Code/Mantid/Framework/Algorithms/src/RebinToWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RebinToWorkspace.cpp @@ -16,13 +16,6 @@ using namespace Mantid::Algorithms; // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(RebinToWorkspace) -/// Sets documentation strings for this algorithm -void RebinToWorkspace::initDocs() -{ - this->setWikiSummary("Rebin a selected workspace to the same binning as a different workspace"); - this->setOptionalMessage("Rebin a selected workspace to the same binning as a different workspace"); -} - //--------------------------- // Private Methods diff --git a/Code/Mantid/Framework/Algorithms/src/Rebunch.cpp b/Code/Mantid/Framework/Algorithms/src/Rebunch.cpp index c9373d355529..731e1244d389 100644 --- a/Code/Mantid/Framework/Algorithms/src/Rebunch.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Rebunch.cpp @@ -26,13 +26,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(Rebunch) - /// Sets documentation strings for this algorithm - void Rebunch::initDocs() - { - this->setWikiSummary("Rebins data by adding together ''n_bunch'' successive bins."); - this->setOptionalMessage("Rebins data by adding together 'n_bunch' successive bins."); - } - using namespace Kernel; using API::WorkspaceProperty; using API::MatrixWorkspace_const_sptr; diff --git a/Code/Mantid/Framework/Algorithms/src/RecordPythonScript.cpp b/Code/Mantid/Framework/Algorithms/src/RecordPythonScript.cpp index 37b7a3824b7b..522dc9b27ff6 100644 --- a/Code/Mantid/Framework/Algorithms/src/RecordPythonScript.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RecordPythonScript.cpp @@ -28,12 +28,6 @@ RecordPythonScript::RecordPythonScript() : Algorithms::GeneratePythonScript(), A } //---------------------------------------------------------------------------------------------- -/// Sets documentation strings for this algorithm -void RecordPythonScript::initDocs() -{ - this->setWikiSummary("An Algorithm to generate a Python script file to reproduce the history of a workspace."); - this->setOptionalMessage("An Algorithm to generate a Python script file to reproduce the history of a workspace."); -} //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/ReflectometryReductionOne.cpp b/Code/Mantid/Framework/Algorithms/src/ReflectometryReductionOne.cpp index 22d483ad6bfc..869fb37b30be 100644 --- a/Code/Mantid/Framework/Algorithms/src/ReflectometryReductionOne.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ReflectometryReductionOne.cpp @@ -121,12 +121,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ReflectometryReductionOne::initDocs() - { - this->setOptionalMessage("Reduces a single TOF reflectometry run into a mod Q vs I/I0 workspace. Performs transmission corrections."); - this->setWikiSummary("Reduces a single TOF reflectometry run into a mod Q vs I/I0 workspace. Performs transmission corrections. See [[Reflectometry_Guide]]"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/Regroup.cpp b/Code/Mantid/Framework/Algorithms/src/Regroup.cpp index 90d4cd61fe83..8aa56fcccdd8 100644 --- a/Code/Mantid/Framework/Algorithms/src/Regroup.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Regroup.cpp @@ -34,13 +34,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(Regroup) -/// Sets documentation strings for this algorithm -void Regroup::initDocs() -{ - this->setWikiSummary("Regroups data with new bin boundaries. "); - this->setOptionalMessage("Regroups data with new bin boundaries."); -} - using namespace Kernel; using API::WorkspaceProperty; diff --git a/Code/Mantid/Framework/Algorithms/src/RemoveBins.cpp b/Code/Mantid/Framework/Algorithms/src/RemoveBins.cpp index c4f3fca7a670..3bd03e34c0e9 100644 --- a/Code/Mantid/Framework/Algorithms/src/RemoveBins.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RemoveBins.cpp @@ -53,13 +53,6 @@ using namespace API; // Register the class into the algorithm factory DECLARE_ALGORITHM(RemoveBins) -/// Sets documentation strings for this algorithm -void RemoveBins::initDocs() -{ - this->setWikiSummary("Used to remove data from a range of bins in a workspace. "); - this->setOptionalMessage("Used to remove data from a range of bins in a workspace."); -} - RemoveBins::RemoveBins() : API::Algorithm(), m_rangeUnit() {} diff --git a/Code/Mantid/Framework/Algorithms/src/RemoveExpDecay.cpp b/Code/Mantid/Framework/Algorithms/src/RemoveExpDecay.cpp index 14a379fdaf21..17538acd69e5 100644 --- a/Code/Mantid/Framework/Algorithms/src/RemoveExpDecay.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RemoveExpDecay.cpp @@ -39,13 +39,6 @@ using std::size_t; // Register the class into the algorithm factory DECLARE_ALGORITHM(MuonRemoveExpDecay) -/// Sets documentation strings for this algorithm -void MuonRemoveExpDecay::initDocs() -{ - this->setWikiSummary("This algorithm removes the exponential decay from a muon workspace. "); - this->setOptionalMessage("This algorithm removes the exponential decay from a muon workspace."); -} - /** Initialisation method. Declares properties to be used in algorithm. * diff --git a/Code/Mantid/Framework/Algorithms/src/RemovePromptPulse.cpp b/Code/Mantid/Framework/Algorithms/src/RemovePromptPulse.cpp index bef4ed75e808..db43a3689ed8 100644 --- a/Code/Mantid/Framework/Algorithms/src/RemovePromptPulse.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RemovePromptPulse.cpp @@ -50,14 +50,6 @@ namespace Algorithms return "CorrectionFunctions\\BackgroundCorrections"; } - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void RemovePromptPulse::initDocs() - { - string msg("Remove the prompt pulse for a time of flight measurement."); - this->setWikiSummary(msg); - this->setOptionalMessage(msg); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/RenameWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/RenameWorkspace.cpp index 81591258e3e6..f2ec76ea0d86 100644 --- a/Code/Mantid/Framework/Algorithms/src/RenameWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RenameWorkspace.cpp @@ -21,12 +21,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM( RenameWorkspace) -void RenameWorkspace::initDocs() -{ - this->setWikiSummary("Used to Rename a workspace in the [[Analysis Data Service]]. This is the algorithm that is run if 'Rename' is chosen from the context menu of a workspace."); - this->setOptionalMessage("Rename the Workspace."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/RenameWorkspaces.cpp b/Code/Mantid/Framework/Algorithms/src/RenameWorkspaces.cpp index 3353faad48cc..6651306ca58e 100644 --- a/Code/Mantid/Framework/Algorithms/src/RenameWorkspaces.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RenameWorkspaces.cpp @@ -28,12 +28,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM( RenameWorkspaces) -void RenameWorkspaces::initDocs() -{ - this->setWikiSummary("Used to Rename a list workspaces in the [[Analysis Data Service]]. This is the algorithm that is run if 'Rename' is chosen from the context menu of a workspace and several workspaces have been selected."); - this->setOptionalMessage("Rename the Workspace. Please provide either a comma-separated list of new workspace names in WorkspaceNames or Prefix and/or Suffix to add to existing names"); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ReplaceSpecialValues.cpp b/Code/Mantid/Framework/Algorithms/src/ReplaceSpecialValues.cpp index a3d08f973bef..fb36e09113ad 100644 --- a/Code/Mantid/Framework/Algorithms/src/ReplaceSpecialValues.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ReplaceSpecialValues.cpp @@ -27,13 +27,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(ReplaceSpecialValues) -/// Sets documentation strings for this algorithm -void ReplaceSpecialValues::initDocs() -{ - this->setWikiSummary("Replaces instances of NaN and infinity in the workspace with user defined numbers.

If a replacement value is not provided the check will not occur. This algorithm can also be used to replace numbers whose absolute value is larger than a user-defined threshold. "); - this->setOptionalMessage("Replaces instances of NaN and infinity in the workspace with user defined numbers. If a replacement value is not provided the check will not occur. This algorithm can also be used to replace numbers whose absolute value is larger than a user-defined threshold."); -} - void ReplaceSpecialValues::defineProperties() { diff --git a/Code/Mantid/Framework/Algorithms/src/ResampleX.cpp b/Code/Mantid/Framework/Algorithms/src/ResampleX.cpp index f26fc53b377a..b91bc1f1c273 100644 --- a/Code/Mantid/Framework/Algorithms/src/ResampleX.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ResampleX.cpp @@ -70,14 +70,6 @@ namespace Algorithms return ""; } - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ResampleX::initDocs() - { - string msg("Resample the x-axis of the data with the requested number of points."); - this->setWikiSummary(msg); - this->setOptionalMessage(msg); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/ResetNegatives.cpp b/Code/Mantid/Framework/Algorithms/src/ResetNegatives.cpp index 7145e4572385..b8aea8bd5acb 100644 --- a/Code/Mantid/Framework/Algorithms/src/ResetNegatives.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ResetNegatives.cpp @@ -56,12 +56,7 @@ namespace Algorithms } //---------------------------------------------------------------------------------------------- - /// @copydoc Mantid::API::Algorithm::initDocs() - void ResetNegatives::initDocs() - { - this->setWikiSummary("Reset negative values to something else."); - this->setOptionalMessage("Reset negative values to something else."); - } + /// @copydoc Mantid::API:: //---------------------------------------------------------------------------------------------- /// @copydoc Mantid::API::Algorithm::init() diff --git a/Code/Mantid/Framework/Algorithms/src/ResizeRectangularDetector.cpp b/Code/Mantid/Framework/Algorithms/src/ResizeRectangularDetector.cpp index 21b4a2440c3e..64f97387f56c 100644 --- a/Code/Mantid/Framework/Algorithms/src/ResizeRectangularDetector.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ResizeRectangularDetector.cpp @@ -66,12 +66,6 @@ namespace Algorithms const std::string ResizeRectangularDetector::category() const { return "DataHandling\\Instrument";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ResizeRectangularDetector::initDocs() - { - this->setWikiSummary("Resize a RectangularDetector in X and/or Y."); - this->setOptionalMessage("Resize a RectangularDetector in X and/or Y."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/RingProfile.cpp b/Code/Mantid/Framework/Algorithms/src/RingProfile.cpp index c13491f9b80e..bbd294833512 100644 --- a/Code/Mantid/Framework/Algorithms/src/RingProfile.cpp +++ b/Code/Mantid/Framework/Algorithms/src/RingProfile.cpp @@ -75,12 +75,6 @@ namespace Algorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void RingProfile::initDocs() - { - this->setWikiSummary("Calculates the sum of the counts against a circular ring."); - this->setOptionalMessage("Calculates the sum of the counts against a circular ring."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/SANSDirectBeamScaling.cpp b/Code/Mantid/Framework/Algorithms/src/SANSDirectBeamScaling.cpp index 7da9c4167145..9c102419118d 100644 --- a/Code/Mantid/Framework/Algorithms/src/SANSDirectBeamScaling.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SANSDirectBeamScaling.cpp @@ -25,13 +25,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SANSDirectBeamScaling) -/// Sets documentation strings for this algorithm -void SANSDirectBeamScaling::initDocs() -{ - this->setWikiSummary("Computes the scaling factor to get reduced SANS data on an absolute scale."); - this->setOptionalMessage("Computes the scaling factor to get reduced SANS data on an absolute scale."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/SassenaFFT.cpp b/Code/Mantid/Framework/Algorithms/src/SassenaFFT.cpp index 624c54134597..f97087a3b189 100644 --- a/Code/Mantid/Framework/Algorithms/src/SassenaFFT.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SassenaFFT.cpp @@ -41,13 +41,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(SassenaFFT); -/// Sets Documentation strings for this algorithm -void SassenaFFT::initDocs() -{ - this->setWikiSummary("Performs complex Fast Fourier Transform of intermediate scattering function"); - this->setOptionalMessage("Performs complex Fast Fourier Transform of intermediate scattering function"); -} - /// Override Algorithm::checkGroups bool SassenaFFT::checkGroups() { return false; } diff --git a/Code/Mantid/Framework/Algorithms/src/SaveGSASInstrumentFile.cpp b/Code/Mantid/Framework/Algorithms/src/SaveGSASInstrumentFile.cpp index 5198a762f89a..bea91a599f81 100644 --- a/Code/Mantid/Framework/Algorithms/src/SaveGSASInstrumentFile.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SaveGSASInstrumentFile.cpp @@ -341,11 +341,6 @@ ChopperConfiguration::ChopperConfiguration(const int freq, const std::string& ba } //---------------------------------------------------------------------------------------------- - void SaveGSASInstrumentFile::initDocs() - { - setWikiSummary("Generate a GSAS instrument file from either a table workspace containing profile parameters or a Fullprof's instrument resolution file (.irf file). "); - setOptionalMessage(""); - } //---------------------------------------------------------------------------------------------- /** Declare properties diff --git a/Code/Mantid/Framework/Algorithms/src/Scale.cpp b/Code/Mantid/Framework/Algorithms/src/Scale.cpp index c84c89a7fbd4..94a4509f5ce6 100644 --- a/Code/Mantid/Framework/Algorithms/src/Scale.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Scale.cpp @@ -18,13 +18,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(Scale) -/// Sets documentation strings for this algorithm -void Scale::initDocs() -{ - this->setWikiSummary("Scales an input workspace by the given factor, which can be either multiplicative or additive. "); - this->setOptionalMessage("Scales an input workspace by the given factor, which can be either multiplicative or additive."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ScaleX.cpp b/Code/Mantid/Framework/Algorithms/src/ScaleX.cpp index e4439b2ff2a8..d53241803580 100644 --- a/Code/Mantid/Framework/Algorithms/src/ScaleX.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ScaleX.cpp @@ -26,13 +26,6 @@ using namespace DataObjects; // Register the class into the algorithm factory DECLARE_ALGORITHM(ScaleX) -/// Sets documentation strings for this algorithm -void ScaleX::initDocs() -{ - this->setWikiSummary("Scales an input workspace by the given factor, which can be either multiplicative or additive."); - this->setOptionalMessage("Scales an input workspace by the given factor, which can be either multiplicative or additive."); -} - /** * Default constructor */ diff --git a/Code/Mantid/Framework/Algorithms/src/SetInstrumentParameter.cpp b/Code/Mantid/Framework/Algorithms/src/SetInstrumentParameter.cpp index 21de1daa31fa..67a7641407be 100644 --- a/Code/Mantid/Framework/Algorithms/src/SetInstrumentParameter.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SetInstrumentParameter.cpp @@ -56,12 +56,6 @@ namespace Algorithms const std::string SetInstrumentParameter::category() const { return "DataHandling\\Instrument";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SetInstrumentParameter::initDocs() - { - this->setWikiSummary("Add or replace an parameter attached to an instrument component."); - this->setOptionalMessage("Add or replace an parameter attached to an instrument component."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/SetUncertainties.cpp b/Code/Mantid/Framework/Algorithms/src/SetUncertainties.cpp index 346026f9616d..be70e2a4be3e 100644 --- a/Code/Mantid/Framework/Algorithms/src/SetUncertainties.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SetUncertainties.cpp @@ -17,13 +17,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SetUncertainties) -/// Sets documentation strings for this algorithm -void SetUncertainties::initDocs() -{ - this->setWikiSummary("This algorithm creates a workspace which is the duplicate of the input, but where the error value for every bin has been set to zero. "); - this->setOptionalMessage("This algorithm creates a workspace which is the duplicate of the input, but where the error value for every bin has been set to zero."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/ShiftLogTime.cpp b/Code/Mantid/Framework/Algorithms/src/ShiftLogTime.cpp index 7c6e590ea1df..017fcfe9ade2 100644 --- a/Code/Mantid/Framework/Algorithms/src/ShiftLogTime.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ShiftLogTime.cpp @@ -55,15 +55,6 @@ namespace Algorithms return "DataHandling\\Logs"; } - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ShiftLogTime::initDocs() - { - string descr("Shifts the indexes of the specified log. This will make the log shorter by the specified shift."); - this->setWikiSummary(descr); - this->setOptionalMessage(descr); - } - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/Algorithms/src/SignalOverError.cpp b/Code/Mantid/Framework/Algorithms/src/SignalOverError.cpp index 9040d7524d9c..79624c4bb03c 100644 --- a/Code/Mantid/Framework/Algorithms/src/SignalOverError.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SignalOverError.cpp @@ -48,12 +48,6 @@ namespace Algorithms const std::string SignalOverError::category() const { return "Arithmetic";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SignalOverError::initDocs() - { - this->setWikiSummary("Replace Y by Y/E for a MatrixWorkspace"); - this->setOptionalMessage("Replace Y by Y/E for a MatrixWorkspace"); - } //---------------------------------------------------------------------------------------------- /** Perform the Y/E */ diff --git a/Code/Mantid/Framework/Algorithms/src/SmoothData.cpp b/Code/Mantid/Framework/Algorithms/src/SmoothData.cpp index effa079beb62..b8175dc94d35 100644 --- a/Code/Mantid/Framework/Algorithms/src/SmoothData.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SmoothData.cpp @@ -22,13 +22,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SmoothData) -/// Sets documentation strings for this algorithm -void SmoothData::initDocs() -{ - this->setWikiSummary("Smooths out statistical fluctuations in a workspace's data. "); - this->setOptionalMessage("Smooths out statistical fluctuations in a workspace's data."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/SmoothNeighbours.cpp b/Code/Mantid/Framework/Algorithms/src/SmoothNeighbours.cpp index e4e85f22a9b6..d9f1c1ff24ea 100644 --- a/Code/Mantid/Framework/Algorithms/src/SmoothNeighbours.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SmoothNeighbours.cpp @@ -136,13 +136,6 @@ SmoothNeighbours::SmoothNeighbours() : { } -/// Sets documentation strings for this algorithm -void SmoothNeighbours::initDocs() -{ - this->setWikiSummary("Perform a moving-average smoothing by summing spectra of nearest neighbours over the face of detectors."); - this->setOptionalMessage("Perform a moving-average smoothing by summing spectra of nearest neighbours over the face of detectors."); -} - /** Initialisation method. * */ diff --git a/Code/Mantid/Framework/Algorithms/src/SofQW.cpp b/Code/Mantid/Framework/Algorithms/src/SofQW.cpp index 7b15563832ad..b7d213b5339d 100644 --- a/Code/Mantid/Framework/Algorithms/src/SofQW.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SofQW.cpp @@ -41,13 +41,6 @@ double SofQW::energyToK() return energyToK; } -/// Sets documentation strings for this algorithm -void SofQW::initDocs() -{ - this->setWikiSummary("Converts a 2D workspace that has axes of \\Delta E against spectrum number to one that gives intensity as a function of momentum transfer against energy: \\rm{S}\\left( q, \\omega \\right). "); - this->setOptionalMessage("Converts a 2D workspace that has axes of \\Delta E against spectrum number to one that gives intensity as a function of momentum transfer against energy: \\rm{S}\\left( q, \\omega \\right)."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/SofQW2.cpp b/Code/Mantid/Framework/Algorithms/src/SofQW2.cpp index 2c9e1a96a824..7bdf91e8aa34 100755 --- a/Code/Mantid/Framework/Algorithms/src/SofQW2.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SofQW2.cpp @@ -38,12 +38,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SofQW2::initDocs() - { - this->setWikiSummary("Calculate the intensity as a function of momentum transfer and energy."); - this->setOptionalMessage("Calculate the intensity as a function of momentum transfer and energy."); - } /** * Initialize the algorithm diff --git a/Code/Mantid/Framework/Algorithms/src/SofQW3.cpp b/Code/Mantid/Framework/Algorithms/src/SofQW3.cpp index 7c102e1ba18b..fa6342042ea8 100644 --- a/Code/Mantid/Framework/Algorithms/src/SofQW3.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SofQW3.cpp @@ -59,12 +59,6 @@ namespace Algorithms } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SofQW3::initDocs() - { - this->setWikiSummary("Calculate the intensity as a function of momentum transfer and energy"); - this->setOptionalMessage("Calculate the intensity as a function of momentum transfer and energy."); - } /** * @return the name of the Algorithm diff --git a/Code/Mantid/Framework/Algorithms/src/SolidAngle.cpp b/Code/Mantid/Framework/Algorithms/src/SolidAngle.cpp index 264b2a6caab7..38a628f235dd 100644 --- a/Code/Mantid/Framework/Algorithms/src/SolidAngle.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SolidAngle.cpp @@ -30,13 +30,6 @@ namespace Mantid // Register with the algorithm factory DECLARE_ALGORITHM(SolidAngle) - /// Sets documentation strings for this algorithm - void SolidAngle::initDocs() - { - this->setWikiSummary("The SolidAngle algorithm calculates the solid angle in steradians for each of the detectors in an instrument and outputs the data in a workspace. This can then be used to normalize a data workspace using the divide algorithm should you wish. "); - this->setOptionalMessage("The SolidAngle algorithm calculates the solid angle in steradians for each of the detectors in an instrument and outputs the data in a workspace. This can then be used to normalize a data workspace using the divide algorithm should you wish."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/SortEvents.cpp b/Code/Mantid/Framework/Algorithms/src/SortEvents.cpp index d762ff10b88f..6ffba16bc675 100644 --- a/Code/Mantid/Framework/Algorithms/src/SortEvents.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SortEvents.cpp @@ -27,13 +27,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(SortEvents) - /// Sets documentation strings for this algorithm - void SortEvents::initDocs() - { - this->setWikiSummary("Sort the events in an [[EventWorkspace]], for faster rebinning. "); - this->setOptionalMessage("Sort the events in an EventWorkspace, for faster rebinning."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/SpatialGrouping.cpp b/Code/Mantid/Framework/Algorithms/src/SpatialGrouping.cpp index 590453dd3b27..7461e26141e2 100644 --- a/Code/Mantid/Framework/Algorithms/src/SpatialGrouping.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SpatialGrouping.cpp @@ -62,13 +62,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SpatialGrouping) -/// Sets documentation strings for this algorithm -void SpatialGrouping::initDocs() -{ - this->setWikiSummary("This algorithm creates an XML grouping file, which can be used in [[GroupDetectors]] or [[ReadGroupsFromFile]], which groups the detectors of an instrument based on the distance between the detectors. It does this by querying the [http://doxygen.mantidproject.org/classMantid_1_1Geometry_1_1Detector.html#a3abb2dd5dca89d759b848489360ff9df getNeighbours] method on the Detector object. "); - this->setOptionalMessage("This algorithm creates an XML grouping file, which can be used in GroupDetectors or ReadGroupsFromFile, which groups the detectors of an instrument based on the distance between the detectors. It does this by querying the getNeighbours method on the Detector object."); -} - /** * init() method implemented from Algorithm base class diff --git a/Code/Mantid/Framework/Algorithms/src/SpecularReflectionCalculateTheta.cpp b/Code/Mantid/Framework/Algorithms/src/SpecularReflectionCalculateTheta.cpp index 08ed7d3fa6da..009708a3e3d3 100644 --- a/Code/Mantid/Framework/Algorithms/src/SpecularReflectionCalculateTheta.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SpecularReflectionCalculateTheta.cpp @@ -74,13 +74,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SpecularReflectionCalculateTheta::initDocs() - { - this->setWikiSummary( - "Calculate the specular reflection two theta scattering angle (degrees) from the detector and sample locations ."); - this->setOptionalMessage(this->getWikiSummary()); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/SpecularReflectionPositionCorrect.cpp b/Code/Mantid/Framework/Algorithms/src/SpecularReflectionPositionCorrect.cpp index f2a8f77f967f..d7d273d4caf1 100644 --- a/Code/Mantid/Framework/Algorithms/src/SpecularReflectionPositionCorrect.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SpecularReflectionPositionCorrect.cpp @@ -117,13 +117,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SpecularReflectionPositionCorrect::initDocs() - { - this->setWikiSummary( - "Correct detector positions vertically based on the specular reflection condition."); - this->setOptionalMessage(this->getWikiSummary()); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/SphericalAbsorption.cpp b/Code/Mantid/Framework/Algorithms/src/SphericalAbsorption.cpp index 8d957b623d6d..29b6593a9ee6 100644 --- a/Code/Mantid/Framework/Algorithms/src/SphericalAbsorption.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SphericalAbsorption.cpp @@ -27,13 +27,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SphericalAbsorption) -/// Sets documentation strings for this algorithm -void SphericalAbsorption::initDocs() -{ - this->setWikiSummary("Calculates bin-by-bin correction factors for attenuation due to absorption and scattering in a '''spherical''' sample. "); - this->setOptionalMessage("Calculates bin-by-bin correction factors for attenuation due to absorption and scattering in a 'spherical' sample."); -} - using namespace Kernel; using namespace Geometry; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/StripPeaks.cpp b/Code/Mantid/Framework/Algorithms/src/StripPeaks.cpp index 46d58c431044..c42e3bb94f79 100644 --- a/Code/Mantid/Framework/Algorithms/src/StripPeaks.cpp +++ b/Code/Mantid/Framework/Algorithms/src/StripPeaks.cpp @@ -23,13 +23,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(StripPeaks) -/// Sets documentation strings for this algorithm -void StripPeaks::initDocs() -{ - this->setWikiSummary("This algorithm attempts to find all the peaks in all spectra of a workspace and subtract them from the data, leaving just the 'background'. "); - this->setOptionalMessage("This algorithm attempts to find all the peaks in all spectra of a workspace and subtract them from the data, leaving just the 'background'."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/StripVanadiumPeaks.cpp b/Code/Mantid/Framework/Algorithms/src/StripVanadiumPeaks.cpp index ab3fd3163bc8..8765d406c01f 100644 --- a/Code/Mantid/Framework/Algorithms/src/StripVanadiumPeaks.cpp +++ b/Code/Mantid/Framework/Algorithms/src/StripVanadiumPeaks.cpp @@ -26,13 +26,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(StripVanadiumPeaks) -/// Sets documentation strings for this algorithm -void StripVanadiumPeaks::initDocs() -{ - this->setWikiSummary("This algorithm removes peaks (at vanadium d-spacing positions by default) out of a background by linearly interpolating over the expected peak positions. "); - this->setOptionalMessage("This algorithm removes peaks (at vanadium d-spacing positions by default) out of a background by linearly interpolating over the expected peak positions."); -} - using namespace Kernel; using namespace DataObjects; diff --git a/Code/Mantid/Framework/Algorithms/src/StripVanadiumPeaks2.cpp b/Code/Mantid/Framework/Algorithms/src/StripVanadiumPeaks2.cpp index 318aea26a459..88321b6fda4d 100644 --- a/Code/Mantid/Framework/Algorithms/src/StripVanadiumPeaks2.cpp +++ b/Code/Mantid/Framework/Algorithms/src/StripVanadiumPeaks2.cpp @@ -36,11 +36,6 @@ DECLARE_ALGORITHM(StripVanadiumPeaks2) StripVanadiumPeaks2::~StripVanadiumPeaks2() { } - - void StripVanadiumPeaks2::initDocs() - { - this->setWikiSummary("This algorithm removes peaks (at vanadium d-spacing positions by default) out of a background by linearly/quadratically interpolating over the expected peak positions. "); - } void StripVanadiumPeaks2::init() { diff --git a/Code/Mantid/Framework/Algorithms/src/SumEventsByLogValue.cpp b/Code/Mantid/Framework/Algorithms/src/SumEventsByLogValue.cpp index 63994ed78d6e..678da2e38a94 100644 --- a/Code/Mantid/Framework/Algorithms/src/SumEventsByLogValue.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SumEventsByLogValue.cpp @@ -51,13 +51,6 @@ namespace Algorithms SumEventsByLogValue::~SumEventsByLogValue() { } - - /// Sets documentation strings for this algorithm - void SumEventsByLogValue::initDocs() - { - this->setWikiSummary("Produces a single spectrum workspace containing the total summed events in the workspace as a function of a specified log."); - this->setOptionalMessage("Produces a single spectrum workspace containing the total summed events in the workspace as a function of a specified log."); - } void SumEventsByLogValue::init() { diff --git a/Code/Mantid/Framework/Algorithms/src/SumNeighbours.cpp b/Code/Mantid/Framework/Algorithms/src/SumNeighbours.cpp index 1a197c74faeb..a388385b4a0d 100644 --- a/Code/Mantid/Framework/Algorithms/src/SumNeighbours.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SumNeighbours.cpp @@ -28,13 +28,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(SumNeighbours) -/// Sets documentation strings for this algorithm -void SumNeighbours::initDocs() -{ - this->setWikiSummary("Sum event lists from neighboring pixels in rectangular area detectors - e.g. to reduce the signal-to-noise of individual spectra. Each spectrum in the output workspace is a sum of a block of SumX*SumY pixels. Only works on EventWorkspaces and for instruments with RectangularDetector's. "); - this->setOptionalMessage("Sum event lists from neighboring pixels in rectangular area detectors - e.g. to reduce the signal-to-noise of individual spectra. Each spectrum in the output workspace is a sum of a block of SumX*SumY pixels. Only works on EventWorkspaces and for instruments with RectangularDetector's."); -} - using namespace Kernel; using namespace Geometry; diff --git a/Code/Mantid/Framework/Algorithms/src/SumRowColumn.cpp b/Code/Mantid/Framework/Algorithms/src/SumRowColumn.cpp index e02a2191465e..a008d3f777a3 100644 --- a/Code/Mantid/Framework/Algorithms/src/SumRowColumn.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SumRowColumn.cpp @@ -29,13 +29,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SumRowColumn) -/// Sets documentation strings for this algorithm -void SumRowColumn::initDocs() -{ - this->setWikiSummary("SANS-specific algorithm which gives a single spectrum containing the total counts in either each row or each column of pixels in a square LOQ or SANS2D detector bank. "); - this->setOptionalMessage("SANS-specific algorithm which gives a single spectrum containing the total counts in either each row or each column of pixels in a square LOQ or SANS2D detector bank."); -} - using namespace Mantid::Kernel; using namespace Mantid::API; diff --git a/Code/Mantid/Framework/Algorithms/src/SumSpectra.cpp b/Code/Mantid/Framework/Algorithms/src/SumSpectra.cpp index 90e7485a92e5..174855a851bd 100644 --- a/Code/Mantid/Framework/Algorithms/src/SumSpectra.cpp +++ b/Code/Mantid/Framework/Algorithms/src/SumSpectra.cpp @@ -50,13 +50,6 @@ namespace Algorithms // Register the class into the algorithm factory DECLARE_ALGORITHM(SumSpectra) -/// Sets documentation strings for this algorithm -void SumSpectra::initDocs() -{ - this->setWikiSummary("The SumSpectra algorithm adds the data values in each time bin across a range of spectra; the output workspace has a single spectrum. If the input is an [[EventWorkspace]], the output is also an [[EventWorkspace]]; otherwise it will be a [[Workspace2D]]. "); - this->setOptionalMessage("The SumSpectra algorithm adds the data values in each time bin across a range of spectra; the output workspace has a single spectrum. If the input is an EventWorkspace, the output is also an EventWorkspace; otherwise it will be a Workspace2D."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/TOFSANSResolution.cpp b/Code/Mantid/Framework/Algorithms/src/TOFSANSResolution.cpp index 96ae5f34f069..fd84c2ec02be 100755 --- a/Code/Mantid/Framework/Algorithms/src/TOFSANSResolution.cpp +++ b/Code/Mantid/Framework/Algorithms/src/TOFSANSResolution.cpp @@ -24,13 +24,6 @@ namespace Algorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(TOFSANSResolution) -/// Sets documentation strings for this algorithm -void TOFSANSResolution::initDocs() -{ - this->setWikiSummary("Calculate the Q resolution for TOF SANS data."); - this->setOptionalMessage("Calculate the Q resolution for TOF SANS data."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/Transpose.cpp b/Code/Mantid/Framework/Algorithms/src/Transpose.cpp index d6026dce09e0..c57444335fde 100644 --- a/Code/Mantid/Framework/Algorithms/src/Transpose.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Transpose.cpp @@ -24,13 +24,6 @@ namespace Mantid // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(Transpose) - /// Sets documentation strings for this algorithm - void Transpose::initDocs() - { - this->setWikiSummary("Transposes a workspace, so that an N1 x N2 workspace becomes N2 x N1."); - this->setOptionalMessage("Transposes a workspace, so that an N1 x N2 workspace becomes N2 x N1."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/UnGroupWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/UnGroupWorkspace.cpp index c9d1deb3feef..b7455665de16 100644 --- a/Code/Mantid/Framework/Algorithms/src/UnGroupWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/UnGroupWorkspace.cpp @@ -14,13 +14,6 @@ namespace Mantid DECLARE_ALGORITHM(UnGroupWorkspace) - /// Sets documentation strings for this algorithm - void UnGroupWorkspace::initDocs() - { - this->setWikiSummary("Takes a group workspace as input and ungroups the workspace. "); - this->setOptionalMessage("Takes a group workspace as input and ungroups the workspace."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/UnwrapMonitor.cpp b/Code/Mantid/Framework/Algorithms/src/UnwrapMonitor.cpp index 7ddca58762fe..ed253f39f1e5 100644 --- a/Code/Mantid/Framework/Algorithms/src/UnwrapMonitor.cpp +++ b/Code/Mantid/Framework/Algorithms/src/UnwrapMonitor.cpp @@ -57,13 +57,6 @@ namespace Algorithms DECLARE_ALGORITHM(UnwrapMonitor) -/// Sets documentation strings for this algorithm -void UnwrapMonitor::initDocs() -{ - this->setWikiSummary("Takes an input [[workspace]] that contains 'raw' data, unwraps the data according to the reference flightpath provided and converts the units to wavelength. The output workspace will have common bins in the maximum theoretical wavelength range. "); - this->setOptionalMessage("Takes an input workspace that contains 'raw' data, unwraps the data according to the reference flightpath provided and converts the units to wavelength. The output workspace will have common bins in the maximum theoretical wavelength range."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/UnwrapSNS.cpp b/Code/Mantid/Framework/Algorithms/src/UnwrapSNS.cpp index aee9d23a9b2a..191440785235 100644 --- a/Code/Mantid/Framework/Algorithms/src/UnwrapSNS.cpp +++ b/Code/Mantid/Framework/Algorithms/src/UnwrapSNS.cpp @@ -33,13 +33,6 @@ namespace Algorithms DECLARE_ALGORITHM(UnwrapSNS) -/// Sets documentation strings for this algorithm -void UnwrapSNS::initDocs() -{ - this->setWikiSummary("Takes an input [[workspace]] that contains 'raw' data, unwraps the data according to the reference flightpath provided and converts the units to wavelength. The output workspace will have common bins in the maximum theoretical wavelength range. "); - this->setOptionalMessage("Takes an input workspace that contains 'raw' data, unwraps the data according to the reference flightpath provided and converts the units to wavelength. The output workspace will have common bins in the maximum theoretical wavelength range."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/Algorithms/src/UpdateScriptRepository.cpp b/Code/Mantid/Framework/Algorithms/src/UpdateScriptRepository.cpp index 9a9d6d94b905..638a869844e0 100644 --- a/Code/Mantid/Framework/Algorithms/src/UpdateScriptRepository.cpp +++ b/Code/Mantid/Framework/Algorithms/src/UpdateScriptRepository.cpp @@ -43,12 +43,6 @@ namespace Algorithms const std::string UpdateScriptRepository::category() const { return "Utility";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void UpdateScriptRepository::initDocs() - { - this->setWikiSummary("Update the local instance of [[ScriptRepository]]."); - this->setOptionalMessage("Update the local instance of ScriptRepository."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/WeightedMean.cpp b/Code/Mantid/Framework/Algorithms/src/WeightedMean.cpp index e80ab7032ae6..287035f01ab7 100644 --- a/Code/Mantid/Framework/Algorithms/src/WeightedMean.cpp +++ b/Code/Mantid/Framework/Algorithms/src/WeightedMean.cpp @@ -17,13 +17,6 @@ namespace Mantid // Algorithm must be declared DECLARE_ALGORITHM(WeightedMean) - /// Sets documentation strings for this algorithm - void WeightedMean::initDocs() - { - this->setWikiSummary("An algorithm to calculate the weighted mean of two workspaces. "); - this->setOptionalMessage("An algorithm to calculate the weighted mean of two workspaces."); - } - bool WeightedMean::checkCompatibility(const API::MatrixWorkspace_const_sptr lhs,const API::MatrixWorkspace_const_sptr rhs) const { diff --git a/Code/Mantid/Framework/Algorithms/src/WeightedMeanOfWorkspace.cpp b/Code/Mantid/Framework/Algorithms/src/WeightedMeanOfWorkspace.cpp index 5822e2e13358..969dd747097e 100644 --- a/Code/Mantid/Framework/Algorithms/src/WeightedMeanOfWorkspace.cpp +++ b/Code/Mantid/Framework/Algorithms/src/WeightedMeanOfWorkspace.cpp @@ -56,12 +56,6 @@ namespace Mantid const std::string WeightedMeanOfWorkspace::category() const { return "Arithmetic"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void WeightedMeanOfWorkspace::initDocs() - { - this->setWikiSummary("This algorithm calculates the weighted mean for an entire workspace."); - this->setOptionalMessage("This algorithm calculates the weighted mean for an entire workspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Algorithms/src/WorkspaceJoiners.cpp b/Code/Mantid/Framework/Algorithms/src/WorkspaceJoiners.cpp index 1c3f48eaa909..6407d7addab4 100644 --- a/Code/Mantid/Framework/Algorithms/src/WorkspaceJoiners.cpp +++ b/Code/Mantid/Framework/Algorithms/src/WorkspaceJoiners.cpp @@ -28,13 +28,6 @@ namespace Algorithms /// Algorithm's category for identification. @see Algorithm::category const std::string WorkspaceJoiners::category() const { return "Transforms\\Merging";} - /// Sets documentation strings for this algorithm - void WorkspaceJoiners::initDocs() - { - this->setWikiSummary("Join two workspaces together by appending their spectra."); - this->setOptionalMessage("Join two workspaces together by appending their spectra."); - } - /** Executes the algorithm for histogram workspace inputs * @returns The result workspace */ diff --git a/Code/Tools/DocMigration/MigrateOptMessage.py b/Code/Tools/DocMigration/MigrateOptMessage.py new file mode 100644 index 000000000000..8d7ed3a719ba --- /dev/null +++ b/Code/Tools/DocMigration/MigrateOptMessage.py @@ -0,0 +1,118 @@ +import argparse +import fnmatch +import os +import re + + +def main(): + parser = argparse.ArgumentParser() + parser.add_argument("-d","--dry", help="dry run, does not change files",action="store_true") + parser.add_argument("codedir", help="The directory to start searching for algorithms", type=str) + args = parser.parse_args() + + + cppFiles = [] + for root, dirnames, filenames in os.walk(args.codedir): + for filename in fnmatch.filter(filenames, '*.cpp'): + cppFiles.append(os.path.join(root, filename)) + + for cppFile in cppFiles: + cppdir = os.path.dirname(cppFile) + (cppname,cppext) = os.path.splitext(os.path.basename(cppFile)) + print cppname,"\t", + + #get .h file + moduledir = os.path.dirname(cppdir) + incdir = os.path.join(moduledir,"inc") + #this should contain only one directory + hdir = "" + for x in os.listdir(incdir): + if os.path.isfile(x): + pass + else: + hdir = os.path.join(incdir,x) + hFile = os.path.join(hdir,cppname+".h") + if not os.path.isfile(hFile): + print "HEADER NOT FOUND" + #next file + break + + #read cppFile + cppText= "" + with open (cppFile, "r") as cppfileHandle: + cppText=cppfileHandle.read() + + #read hFile + hText= "" + with open (hFile, "r") as hfileHandle: + hText=hfileHandle.read() + + summary = readOptionalMessage(cppText) + summary = striplinks(summary) + + if summary != "": + hText=insertSummaryCommand(hText,summary) + hText=removeHeaderInitDocs(hText) + if hText != "": + cppText=removeOptionalMessage(cppText) + if not args.dry: + with open(hFile, "w") as outHFile: + outHFile.write(hText) + with open(cppFile, "w") as outCppFile: + outCppFile.write(cppText) + + print + else: + print "Could not find h instertion position" + else: + print "Could not find summary" + +def striplinks(text): + retVal = text.replace("[[","") + retVal = retVal.replace("]]","") + return retVal + +def readOptionalMessage(cppText): + retVal = "" + match = re.search(r'^.*setOptionalMessage\s*\(\s*"(.+)"\s*\)\s*;\.*$',cppText,re.MULTILINE) + if match: + retVal = match.group(1) + else: + wikiMatch = re.search(r'^.*setWikiSummary\s*\(\s*"(.+)"\s*\)\s*;\.*$',cppText,re.MULTILINE) + if wikiMatch: + retVal = wikiMatch.group(1) + return retVal + +def removeOptionalMessage(cppText): + retVal = regexReplace(r'^.*setOptionalMessage\s*\(\s*"(.+)"\s*\)\s*;\.*$','',cppText,re.MULTILINE) + retVal = regexReplace(r'^.*setWikiSummary\s*\(\s*"(.+)"\s*\)\s*;\.*$','',retVal,re.MULTILINE) + retVal = regexReplace(r'[\w\s/]*::initDocs.*?\}','',retVal,re.DOTALL) + return retVal + +def removeHeaderInitDocs(hText): + retVal = regexReplace(r'//[\w\s/]*initDocs.*?$','',hText,re.MULTILINE+re.DOTALL) + return retVal + +def insertSummaryCommand(hText,summary): + retVal = "" + newLine = '\n ///Summary of algorithms purpose\n virtual const std::string summary() const {return "' + summary + '";}\n' + match = re.search(r'^.*const.*string\s+name\(\)\s+const.*$',hText,re.MULTILINE) + if match: + endpos = match.end(0) + #insert new line + retVal = hText[:endpos] + newLine + hText[endpos:] + else: + print "DID NOT MATCH!!!" + return retVal + +def regexReplace(regex,replaceString,inputString,regexOpts): + retVal = inputString + match = re.search(regex,inputString,regexOpts) + if match: + retVal = inputString[:match.start(0)] + replaceString + inputString[match.end(0):] + return retVal + + + + +main() \ No newline at end of file From edcf7fd044367b356bc82300e93f67fc90bb05b6 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 16:06:51 +0100 Subject: [PATCH 079/126] Delete all screenshot images that were generated in the source dir Sphinx requires them in the source tree to build properly but we don't want them around all of the time. Refs #9521 --- .../mantiddoc/directives/algorithm.py | 54 ++++++++++++++++--- 1 file changed, 48 insertions(+), 6 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index ebe179bb3142..bb20442d8382 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -100,7 +100,7 @@ def _create_screenshot(self): from mantiddoc.tools.screenshot import algorithm_screenshot env = self.state.document.settings.env - screenshots_dir = self._screenshot_directory(env) + screenshots_dir = self._screenshot_directory() if not os.path.exists(screenshots_dir): os.makedirs(screenshots_dir) @@ -132,7 +132,7 @@ def _insert_screenshot_link(self, img_path): self.add_rst(format_str % (path, caption)) - def _screenshot_directory(self, env): + def _screenshot_directory(self): """ Returns a full path where the screenshots should be generated. They are put in a screenshots subdirectory of the main images directory in the source @@ -145,8 +145,7 @@ def _screenshot_directory(self, env): str: A string containing a path to where the screenshots should be created. This will be a filesystem path """ - cfg_dir = env.app.srcdir - return os.path.join(cfg_dir, "images", "screenshots") + return screenshot_directory(self.state.document.settings.env.app) def _insert_deprecation_warning(self): """ @@ -167,7 +166,26 @@ def _insert_deprecation_warning(self): self.add_rst(".. warning:: %s" % msg) -############################################################################################################ + +#------------------------------------------------------------------------------------------------------------ + +def screenshot_directory(app): + """ + Returns a full path where the screenshots should be generated. They are + put in a screenshots subdirectory of the main images directory in the source + tree. Sphinx then handles copying them to the final location + + Arguments: + app (Sphinx.Application): A reference to the application object + + Returns: + str: A string containing a path to where the screenshots should be created. This will + be a filesystem path + """ + cfg_dir = app.srcdir + return os.path.join(cfg_dir, "images", "screenshots") + +#------------------------------------------------------------------------------------------------------------ def html_collect_pages(app): """ @@ -186,7 +204,28 @@ def html_collect_pages(app): context = {"name" : name, "target" : target} yield (redirect_pagename, context, template) -############################################################################################################ +#------------------------------------------------------------------------------------------------------------ + +def purge_screenshots(app, exception): + """ + Remove all screenshots images that were generated in the source directory during the build + + Arguments: + app (Sphinx.Application): A reference to the application object + exception (Exception): If an exception was raised this is a reference to the exception object, else None + """ + import os + + screenshot_dir = screenshot_directory(app) + for filename in os.listdir(screenshot_dir): + filepath = os.path.join(screenshot_dir, filename) + try: + if os.path.isfile(filepath): + os.remove(filepath) + except Exception, e: + app.warn(str(e)) + +#------------------------------------------------------------------------------------------------------------ def setup(app): """ @@ -200,3 +239,6 @@ def setup(app): # connect event html collection to handler app.connect("html-collect-pages", html_collect_pages) + # Remove all generated screenshots from the source directory when finished + # so that they don't become stale + app.connect("build-finished", purge_screenshots) \ No newline at end of file From ce0d5734c322493776ad838adf65a8e8b054bf80 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 16:55:11 +0100 Subject: [PATCH 080/126] Fix property descriptions that span multiple lines Simply replaces the new line with a space and lets the output formatter take care of displaying it. Refs #9521 --- Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py index 3eb955bffc7b..0f6177b0ed26 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/properties.py @@ -40,7 +40,7 @@ def _populate_properties_table(self): str(direction_string[prop.direction]), str(prop.type), str(self._get_default_prop(prop)), - str(prop.documentation) + str(prop.documentation.replace("\n", " ")) )) # Build and add the properties to the ReST table. From d48a5a621ce3817fdb9e8370efc26c5695dea13f Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 16:55:48 +0100 Subject: [PATCH 081/126] Re-enable content for mobile devices It may not look the best at the moment but it's better than not being able to see it at all. Refs #9521 --- Code/Mantid/docs/source/_static/custom.css | 9 --------- 1 file changed, 9 deletions(-) diff --git a/Code/Mantid/docs/source/_static/custom.css b/Code/Mantid/docs/source/_static/custom.css index b21258686d13..e7fe0571614f 100644 --- a/Code/Mantid/docs/source/_static/custom.css +++ b/Code/Mantid/docs/source/_static/custom.css @@ -74,12 +74,3 @@ td, th { max-width: 40%; } } - -/* - Hide the screenshot image as it does not have a relevant header. TOC should be first. - * - Hide the properties table as it's contents are too large for mobile display. - * - Hide properties title since the table is also hidden. */ -@media (max-width: 767px) { - .figure, .table, #properties { - display: none; - } -} From 028174e8bfe5f80300cf4c2d9d05d3b1a6b18139 Mon Sep 17 00:00:00 2001 From: Nick Draper Date: Wed, 28 May 2014 17:38:03 +0100 Subject: [PATCH 082/126] re #9523 Crystal, CurveFitting, DataHandling, ICat and ISISLiveData --- Code/Mantid/Build/class_maker.py | 14 +- .../inc/MantidCrystal/AnvredCorrection.h | 3 + .../inc/MantidCrystal/CalculatePeaksHKL.h | 4 +- .../inc/MantidCrystal/CalculateUMatrix.h | 6 +- .../Crystal/inc/MantidCrystal/CentroidPeaks.h | 6 +- .../Crystal/inc/MantidCrystal/ClearUB.h | 4 +- .../MantidCrystal/CombinePeaksWorkspaces.h | 4 +- .../inc/MantidCrystal/DiffPeaksWorkspaces.h | 4 +- .../Crystal/inc/MantidCrystal/FilterPeaks.h | 4 +- .../inc/MantidCrystal/FindClusterFaces.h | 4 +- .../Crystal/inc/MantidCrystal/FindSXPeaks.h | 4 +- .../inc/MantidCrystal/FindUBUsingFFT.h | 6 +- .../MantidCrystal/FindUBUsingIndexedPeaks.h | 6 +- .../FindUBUsingLatticeParameters.h | 8 +- .../inc/MantidCrystal/FindUBUsingMinMaxD.h | 6 +- .../GoniometerAnglesFromPhiRotation.h | 14 +- .../Crystal/inc/MantidCrystal/HasUB.h | 4 +- .../Crystal/inc/MantidCrystal/IndexPeaks.h | 10 +- .../Crystal/inc/MantidCrystal/IndexSXPeaks.h | 4 +- .../MantidCrystal/IntegratePeakTimeSlices.h | 5 +- .../IntegratePeaksUsingClusters.h | 4 +- .../Crystal/inc/MantidCrystal/LoadHKL.h | 6 +- .../Crystal/inc/MantidCrystal/LoadIsawPeaks.h | 6 +- .../inc/MantidCrystal/LoadIsawSpectrum.h | 6 +- .../Crystal/inc/MantidCrystal/LoadIsawUB.h | 6 +- .../inc/MantidCrystal/MaskPeaksWorkspace.h | 3 + .../inc/MantidCrystal/NormaliseVanadium.h | 6 +- .../MantidCrystal/OptimizeCrystalPlacement.h | 74 +++--- .../OptimizeExtinctionParameters.h | 6 +- .../OptimizeLatticeForCellType.h | 6 +- .../inc/MantidCrystal/PeakIntegration.h | 5 +- .../inc/MantidCrystal/PeakIntensityVsRadius.h | 4 +- .../Crystal/inc/MantidCrystal/PeaksInRegion.h | 4 +- .../inc/MantidCrystal/PeaksOnSurface.h | 4 +- .../MantidCrystal/PredictFractionalPeaks.h | 8 +- .../Crystal/inc/MantidCrystal/PredictPeaks.h | 6 +- .../inc/MantidCrystal/SCDCalibratePanels.h | 4 +- .../Crystal/inc/MantidCrystal/SaveHKL.h | 6 +- .../Crystal/inc/MantidCrystal/SaveIsawPeaks.h | 6 +- .../Crystal/inc/MantidCrystal/SaveIsawUB.h | 6 +- .../Crystal/inc/MantidCrystal/SavePeaksFile.h | 6 +- .../inc/MantidCrystal/SelectCellOfType.h | 7 +- .../inc/MantidCrystal/SelectCellWithForm.h | 7 +- .../Crystal/inc/MantidCrystal/SetGoniometer.h | 6 +- .../inc/MantidCrystal/SetSpecialCoordinates.h | 4 +- .../Crystal/inc/MantidCrystal/SetUB.h | 4 +- .../inc/MantidCrystal/ShowPeakHKLOffsets.h | 94 ++++---- .../inc/MantidCrystal/ShowPossibleCells.h | 6 +- .../Crystal/inc/MantidCrystal/SortHKL.h | 6 +- .../inc/MantidCrystal/SortPeaksWorkspace.h | 4 +- .../Crystal/inc/MantidCrystal/TOFExtinction.h | 5 +- .../Crystal/inc/MantidCrystal/TransformHKL.h | 7 +- .../Crystal/src/AnvredCorrection.cpp | 2 +- .../Crystal/src/CalculatePeaksHKL.cpp | 7 - .../Crystal/src/CalculateUMatrix.cpp | 6 - .../Framework/Crystal/src/CentroidPeaks.cpp | 6 - Code/Mantid/Framework/Crystal/src/ClearUB.cpp | 6 - .../Crystal/src/CombinePeaksWorkspaces.cpp | 7 - .../Crystal/src/DiffPeaksWorkspaces.cpp | 7 - .../Framework/Crystal/src/FilterPeaks.cpp | 7 - .../Crystal/src/FindClusterFaces.cpp | 6 - .../Framework/Crystal/src/FindSXPeaks.cpp | 7 - .../Framework/Crystal/src/FindUBUsingFFT.cpp | 13 -- .../Crystal/src/FindUBUsingIndexedPeaks.cpp | 14 -- .../src/FindUBUsingLatticeParameters.cpp | 12 - .../Crystal/src/FindUBUsingMinMaxD.cpp | 14 -- .../src/GoniometerAnglesFromPhiRotation.cpp | 5 - Code/Mantid/Framework/Crystal/src/HasUB.cpp | 6 - .../Framework/Crystal/src/IndexPeaks.cpp | 9 - .../Framework/Crystal/src/IndexSXPeaks.cpp | 7 - .../Crystal/src/IntegratePeakTimeSlices.cpp | 6 - .../src/IntegratePeaksUsingClusters.cpp | 6 - Code/Mantid/Framework/Crystal/src/LoadHKL.cpp | 6 - .../Framework/Crystal/src/LoadIsawPeaks.cpp | 6 - .../Crystal/src/LoadIsawSpectrum.cpp | 6 - .../Framework/Crystal/src/LoadIsawUB.cpp | 6 - .../Crystal/src/NormaliseVanadium.cpp | 7 - .../Crystal/src/OptimizeCrystalPlacement.cpp | 8 - .../src/OptimizeExtinctionParameters.cpp | 7 - .../src/OptimizeLatticeForCellType.cpp | 7 - .../Crystal/src/PeakIntensityVsRadius.cpp | 6 - .../Framework/Crystal/src/PeaksInRegion.cpp | 6 - .../Framework/Crystal/src/PeaksOnSurface.cpp | 6 - .../Crystal/src/PredictFractionalPeaks.cpp | 6 - .../Framework/Crystal/src/PredictPeaks.cpp | 6 - .../Crystal/src/SCDCalibratePanels.cpp | 8 - Code/Mantid/Framework/Crystal/src/SaveHKL.cpp | 6 - .../Framework/Crystal/src/SaveIsawPeaks.cpp | 6 - .../Framework/Crystal/src/SaveIsawUB.cpp | 6 - .../Framework/Crystal/src/SavePeaksFile.cpp | 6 - .../Crystal/src/SelectCellOfType.cpp | 14 -- .../Crystal/src/SelectCellWithForm.cpp | 14 -- .../Framework/Crystal/src/SetGoniometer.cpp | 6 - .../Crystal/src/SetSpecialCoordinates.cpp | 6 - Code/Mantid/Framework/Crystal/src/SetUB.cpp | 6 - .../Crystal/src/ShowPeakHKLOffsets.cpp | 6 - .../Crystal/src/ShowPossibleCells.cpp | 13 -- Code/Mantid/Framework/Crystal/src/SortHKL.cpp | 6 - .../Crystal/src/SortPeaksWorkspace.cpp | 6 - .../Framework/Crystal/src/TOFExtinction.cpp | 6 - .../Framework/Crystal/src/TransformHKL.cpp | 14 -- .../CalculateGammaBackground.h | 4 +- .../inc/MantidCurveFitting/ConvertToYSpace.h | 4 +- .../MantidCurveFitting/ConvolveWorkspaces.h | 4 +- .../CurveFitting/inc/MantidCurveFitting/Fit.h | 6 +- .../MantidCurveFitting/FitPowderDiffPeaks.h | 6 +- .../inc/MantidCurveFitting/LeBailFit.h | 6 +- .../inc/MantidCurveFitting/Lorentzian1D.h | 6 +- .../MantidCurveFitting/NormaliseByPeakArea.h | 4 +- .../MantidCurveFitting/PlotPeakByLogValue.h | 6 +- .../MantidCurveFitting/ProcessBackground.h | 9 +- .../RefinePowderInstrumentParameters.h | 6 +- .../RefinePowderInstrumentParameters3.h | 6 +- .../inc/MantidCurveFitting/SplineBackground.h | 6 +- .../MantidCurveFitting/SplineInterpolation.h | 3 +- .../inc/MantidCurveFitting/SplineSmoothing.h | 3 +- .../inc/MantidCurveFitting/UserFunction1D.h | 6 +- .../src/CalculateGammaBackground.cpp | 6 - .../CurveFitting/src/ConvertToYSpace.cpp | 6 - .../CurveFitting/src/ConvolveWorkspaces.cpp | 7 - .../Mantid/Framework/CurveFitting/src/Fit.cpp | 7 - .../CurveFitting/src/FitPowderDiffPeaks.cpp | 7 +- .../Framework/CurveFitting/src/LeBailFit.cpp | 7 +- .../CurveFitting/src/Lorentzian1D.cpp | 7 - .../CurveFitting/src/NormaliseByPeakArea.cpp | 6 - .../CurveFitting/src/PlotPeakByLogValue.cpp | 7 - .../CurveFitting/src/ProcessBackground.cpp | 8 - .../src/RefinePowderInstrumentParameters.cpp | 7 +- .../src/RefinePowderInstrumentParameters3.cpp | 7 +- .../CurveFitting/src/SplineBackground.cpp | 6 - .../CurveFitting/src/SplineInterpolation.cpp | 8 - .../CurveFitting/src/SplineSmoothing.cpp | 8 - .../CurveFitting/src/UserFunction1D.cpp | 8 - .../AppendGeometryToSNSNexus.h | 4 +- .../inc/MantidDataHandling/AsciiPointBase.h | 2 - .../inc/MantidDataHandling/CompressEvents.h | 6 +- .../MantidDataHandling/CreateChopperModel.h | 4 +- .../MantidDataHandling/CreateModeratorModel.h | 4 +- .../MantidDataHandling/CreateSampleShape.h | 6 +- .../CreateSimulationWorkspace.h | 4 +- .../MantidDataHandling/DefineGaugeVolume.h | 6 +- .../inc/MantidDataHandling/DeleteTableRows.h | 6 +- .../MantidDataHandling/DetermineChunking.h | 4 +- .../FilterEventsByLogValuePreNexus.h | 6 +- .../MantidDataHandling/FindDetectorsInShape.h | 6 +- .../inc/MantidDataHandling/FindDetectorsPar.h | 6 +- .../GenerateGroupingPowder.h | 4 +- .../inc/MantidDataHandling/GroupDetectors.h | 6 +- .../inc/MantidDataHandling/GroupDetectors2.h | 6 +- .../inc/MantidDataHandling/Load.h | 6 +- .../inc/MantidDataHandling/LoadAscii.h | 6 +- .../inc/MantidDataHandling/LoadAscii2.h | 6 +- .../inc/MantidDataHandling/LoadCalFile.h | 6 +- .../inc/MantidDataHandling/LoadCanSAS1D.h | 6 +- .../inc/MantidDataHandling/LoadDaveGrp.h | 6 +- .../inc/MantidDataHandling/LoadDetectorInfo.h | 4 +- .../LoadDetectorsGroupingFile.h | 6 +- .../inc/MantidDataHandling/LoadDspacemap.h | 6 +- .../MantidDataHandling/LoadEmptyInstrument.h | 6 +- .../inc/MantidDataHandling/LoadEventNexus.h | 6 +- .../MantidDataHandling/LoadEventPreNexus.h | 6 +- .../MantidDataHandling/LoadEventPreNexus2.h | 5 +- .../LoadFullprofResolution.h | 145 ++++++------ .../LoadGSASInstrumentFile.h | 6 +- .../inc/MantidDataHandling/LoadGSS.h | 6 +- .../inc/MantidDataHandling/LoadIDFFromNexus.h | 6 +- .../inc/MantidDataHandling/LoadILL.h | 217 +++++++++--------- .../inc/MantidDataHandling/LoadILLIndirect.h | 4 +- .../inc/MantidDataHandling/LoadILLSANS.h | 4 +- .../inc/MantidDataHandling/LoadISISNexus.h | 4 +- .../inc/MantidDataHandling/LoadISISNexus2.h | 2 + .../inc/MantidDataHandling/LoadInstrument.h | 4 +- .../LoadInstrumentFromNexus.h | 6 +- .../LoadInstrumentFromRaw.h | 6 +- .../inc/MantidDataHandling/LoadIsawDetCal.h | 6 +- .../inc/MantidDataHandling/LoadLLB.h | 4 +- .../LoadLOQDistancesFromRaw.h | 6 +- .../inc/MantidDataHandling/LoadLog.h | 6 +- .../LoadLogsForSNSPulsedMagnet.h | 6 +- .../inc/MantidDataHandling/LoadMappingTable.h | 6 +- .../inc/MantidDataHandling/LoadMask.h | 6 +- .../inc/MantidDataHandling/LoadMcStas.h | 4 +- .../inc/MantidDataHandling/LoadMcStasNexus.h | 4 +- .../inc/MantidDataHandling/LoadMuonLog.h | 6 +- .../inc/MantidDataHandling/LoadMuonNexus.h | 6 +- .../inc/MantidDataHandling/LoadMuonNexus1.h | 6 +- .../inc/MantidDataHandling/LoadMuonNexus2.h | 6 +- .../inc/MantidDataHandling/LoadNXSPE.h | 6 +- .../inc/MantidDataHandling/LoadNexus.h | 6 +- .../inc/MantidDataHandling/LoadNexusLogs.h | 5 +- .../MantidDataHandling/LoadNexusMonitors.h | 6 +- .../MantidDataHandling/LoadNexusProcessed.h | 6 +- .../inc/MantidDataHandling/LoadPDFgetNFile.h | 6 +- .../MantidDataHandling/LoadParameterFile.h | 6 +- .../inc/MantidDataHandling/LoadPreNexus.h | 4 +- .../MantidDataHandling/LoadPreNexusMonitors.h | 6 +- .../inc/MantidDataHandling/LoadQKK.h | 6 +- .../inc/MantidDataHandling/LoadRKH.h | 6 +- .../inc/MantidDataHandling/LoadRaw.h | 4 +- .../inc/MantidDataHandling/LoadRaw2.h | 4 +- .../inc/MantidDataHandling/LoadRaw3.h | 6 +- .../inc/MantidDataHandling/LoadRawBin0.h | 6 +- .../inc/MantidDataHandling/LoadRawHelper.h | 2 + .../inc/MantidDataHandling/LoadRawSpectrum0.h | 6 +- .../inc/MantidDataHandling/LoadReflTBL.h | 6 +- .../inc/MantidDataHandling/LoadSINQFocus.h | 4 +- .../inc/MantidDataHandling/LoadSNSspec.h | 6 +- .../inc/MantidDataHandling/LoadSPE.h | 6 +- .../LoadSampleDetailsFromRaw.h | 6 +- .../inc/MantidDataHandling/LoadSassena.h | 6 +- .../inc/MantidDataHandling/LoadSpec.h | 6 +- .../inc/MantidDataHandling/LoadSpice2D.h | 6 +- .../inc/MantidDataHandling/LoadTOFRawNexus.h | 7 +- .../inc/MantidDataHandling/MaskDetectors.h | 6 +- .../MantidDataHandling/MaskDetectorsInShape.h | 3 +- .../inc/MantidDataHandling/MergeLogs.h | 4 +- .../ModifyDetectorDotDatFile.h | 6 +- .../MoveInstrumentComponent.h | 6 +- .../inc/MantidDataHandling/NexusTester.h | 4 +- .../PDLoadCharacterizations.h | 5 +- .../MantidDataHandling/ProcessDasNexusLog.h | 4 +- .../inc/MantidDataHandling/RawFileInfo.h | 6 +- .../inc/MantidDataHandling/RemoveLogs.h | 6 +- .../inc/MantidDataHandling/RenameLog.h | 4 +- .../RotateInstrumentComponent.h | 6 +- .../inc/MantidDataHandling/SaveANSTOAscii.h | 6 +- .../inc/MantidDataHandling/SaveAscii.h | 6 +- .../inc/MantidDataHandling/SaveAscii2.h | 6 +- .../inc/MantidDataHandling/SaveCSV.h | 6 +- .../inc/MantidDataHandling/SaveCalFile.h | 6 +- .../inc/MantidDataHandling/SaveCanSAS1D.h | 6 +- .../inc/MantidDataHandling/SaveDaveGrp.h | 6 +- .../SaveDetectorsGrouping.h | 5 +- .../inc/MantidDataHandling/SaveDspacemap.h | 6 +- .../inc/MantidDataHandling/SaveFocusedXYE.h | 6 +- .../SaveFullprofResolution.h | 6 +- .../inc/MantidDataHandling/SaveGSS.h | 6 +- .../MantidDataHandling/SaveILLCosmosAscii.h | 6 +- .../inc/MantidDataHandling/SaveISISNexus.h | 6 +- .../inc/MantidDataHandling/SaveIsawDetCal.h | 6 +- .../inc/MantidDataHandling/SaveMask.h | 5 +- .../inc/MantidDataHandling/SaveNISTDAT.h | 6 +- .../inc/MantidDataHandling/SaveNXSPE.h | 6 +- .../inc/MantidDataHandling/SaveNexus.h | 6 +- .../MantidDataHandling/SaveNexusProcessed.h | 6 +- .../inc/MantidDataHandling/SavePAR.h | 6 +- .../inc/MantidDataHandling/SavePHX.h | 6 +- .../inc/MantidDataHandling/SaveRKH.h | 6 +- .../inc/MantidDataHandling/SaveReflTBL.h | 6 +- .../inc/MantidDataHandling/SaveSPE.h | 6 +- .../SaveToSNSHistogramNexus.h | 6 +- .../inc/MantidDataHandling/SaveVTK.h | 6 +- .../MantidDataHandling/SetSampleMaterial.h | 6 +- .../inc/MantidDataHandling/SetScalingPSD.h | 6 +- .../UpdateInstrumentFromFile.h | 6 +- .../src/AppendGeometryToSNSNexus.cpp | 6 - .../DataHandling/src/CompressEvents.cpp | 7 - .../DataHandling/src/CreateChopperModel.cpp | 6 - .../DataHandling/src/CreateModeratorModel.cpp | 6 - .../DataHandling/src/CreateSampleShape.cpp | 7 - .../src/CreateSimulationWorkspace.cpp | 6 - .../DataHandling/src/DefineGaugeVolume.cpp | 7 - .../DataHandling/src/DeleteTableRows.cpp | 7 - .../DataHandling/src/DetermineChunking.cpp | 8 - .../src/FilterEventsByLogValuePreNexus.cpp | 10 - .../DataHandling/src/FindDetectorsInShape.cpp | 7 - .../DataHandling/src/FindDetectorsPar.cpp | 8 - .../src/GenerateGroupingPowder.cpp | 6 - .../DataHandling/src/GroupDetectors.cpp | 7 - .../DataHandling/src/GroupDetectors2.cpp | 7 - .../Framework/DataHandling/src/Load.cpp | 7 - .../Framework/DataHandling/src/LoadAscii.cpp | 7 - .../Framework/DataHandling/src/LoadAscii2.cpp | 7 - .../DataHandling/src/LoadCalFile.cpp | 6 - .../DataHandling/src/LoadCanSAS1D.cpp | 7 - .../DataHandling/src/LoadDaveGrp.cpp | 7 - .../DataHandling/src/LoadDetectorInfo.cpp | 7 - .../src/LoadDetectorsGroupingFile.cpp | 6 - .../DataHandling/src/LoadDspacemap.cpp | 6 - .../DataHandling/src/LoadEmptyInstrument.cpp | 7 - .../DataHandling/src/LoadEventNexus.cpp | 7 - .../DataHandling/src/LoadEventPreNexus.cpp | 7 - .../DataHandling/src/LoadEventPreNexus2.cpp | 12 - .../src/LoadFullprofResolution.cpp | 13 -- .../src/LoadGSASInstrumentFile.cpp | 9 +- .../Framework/DataHandling/src/LoadGSS.cpp | 9 - .../DataHandling/src/LoadIDFFromNexus.cpp | 7 - .../Framework/DataHandling/src/LoadILL.cpp | 7 - .../DataHandling/src/LoadILLIndirect.cpp | 5 - .../DataHandling/src/LoadILLSANS.cpp | 5 - .../DataHandling/src/LoadISISNexus.cpp | 5 - .../DataHandling/src/LoadInstrument.cpp | 7 - .../src/LoadInstrumentFromNexus.cpp | 7 - .../src/LoadInstrumentFromRaw.cpp | 7 - .../DataHandling/src/LoadIsawDetCal.cpp | 7 - .../Framework/DataHandling/src/LoadLLB.cpp | 5 - .../src/LoadLOQDistancesFromRaw.cpp | 7 - .../Framework/DataHandling/src/LoadLog.cpp | 7 - .../src/LoadLogsForSNSPulsedMagnet.cpp | 6 - .../DataHandling/src/LoadMappingTable.cpp | 7 - .../Framework/DataHandling/src/LoadMask.cpp | 6 - .../Framework/DataHandling/src/LoadMcStas.cpp | 6 - .../DataHandling/src/LoadMcStasNexus.cpp | 6 - .../DataHandling/src/LoadMuonLog.cpp | 7 - .../DataHandling/src/LoadMuonNexus.cpp | 7 - .../DataHandling/src/LoadMuonNexus1.cpp | 7 - .../DataHandling/src/LoadMuonNexus2.cpp | 7 - .../Framework/DataHandling/src/LoadNXSPE.cpp | 7 - .../Framework/DataHandling/src/LoadNexus.cpp | 7 - .../DataHandling/src/LoadNexusLogs.cpp | 7 - .../DataHandling/src/LoadNexusMonitors.cpp | 7 - .../DataHandling/src/LoadNexusProcessed.cpp | 7 - .../DataHandling/src/LoadPDFgetNFile.cpp | 7 +- .../DataHandling/src/LoadParameterFile.cpp | 7 - .../DataHandling/src/LoadPreNexus.cpp | 7 +- .../DataHandling/src/LoadPreNexusMonitors.cpp | 9 - .../Framework/DataHandling/src/LoadQKK.cpp | 9 - .../Framework/DataHandling/src/LoadRKH.cpp | 8 - .../Framework/DataHandling/src/LoadRaw.cpp | 6 - .../Framework/DataHandling/src/LoadRaw2.cpp | 6 - .../Framework/DataHandling/src/LoadRaw3.cpp | 7 - .../DataHandling/src/LoadRawBin0.cpp | 7 - .../DataHandling/src/LoadRawSpectrum0.cpp | 7 - .../DataHandling/src/LoadReflTBL.cpp | 7 - .../DataHandling/src/LoadSINQFocus.cpp | 5 - .../DataHandling/src/LoadSNSspec.cpp | 8 - .../Framework/DataHandling/src/LoadSPE.cpp | 8 - .../src/LoadSampleDetailsFromRaw.cpp | 7 - .../DataHandling/src/LoadSassena.cpp | 7 - .../Framework/DataHandling/src/LoadSpec.cpp | 7 - .../DataHandling/src/LoadSpice2D.cpp | 7 - .../DataHandling/src/LoadTOFRawNexus.cpp | 8 - .../DataHandling/src/MaskDetectors.cpp | 7 - .../Framework/DataHandling/src/MergeLogs.cpp | 8 - .../src/ModifyDetectorDotDatFile.cpp | 6 - .../src/MoveInstrumentComponent.cpp | 7 - .../DataHandling/src/NexusTester.cpp | 6 - .../src/PDLoadCharacterizations.cpp | 9 - .../DataHandling/src/ProcessDasNexusLog.cpp | 7 - .../DataHandling/src/RawFileInfo.cpp | 7 - .../Framework/DataHandling/src/RemoveLogs.cpp | 7 - .../Framework/DataHandling/src/RenameLog.cpp | 8 - .../src/RotateInstrumentComponent.cpp | 7 - .../DataHandling/src/SaveANSTOAscii.cpp | 7 - .../Framework/DataHandling/src/SaveAscii.cpp | 7 - .../Framework/DataHandling/src/SaveAscii2.cpp | 7 - .../Framework/DataHandling/src/SaveCSV.cpp | 7 - .../DataHandling/src/SaveCalFile.cpp | 6 - .../DataHandling/src/SaveCanSAS1D.cpp | 7 - .../DataHandling/src/SaveDaveGrp.cpp | 6 - .../src/SaveDetectorsGrouping.cpp | 5 - .../DataHandling/src/SaveDspacemap.cpp | 6 - .../DataHandling/src/SaveFocusedXYE.cpp | 9 - .../src/SaveFullprofResolution.cpp | 7 +- .../Framework/DataHandling/src/SaveGSS.cpp | 7 - .../DataHandling/src/SaveILLCosmosAscii.cpp | 7 - .../DataHandling/src/SaveISISNexus.cpp | 7 - .../DataHandling/src/SaveIsawDetCal.cpp | 6 - .../Framework/DataHandling/src/SaveMask.cpp | 7 - .../DataHandling/src/SaveNISTDAT.cpp | 7 - .../Framework/DataHandling/src/SaveNXSPE.cpp | 7 - .../Framework/DataHandling/src/SaveNexus.cpp | 7 - .../DataHandling/src/SaveNexusProcessed.cpp | 7 - .../Framework/DataHandling/src/SavePAR.cpp | 9 +- .../Framework/DataHandling/src/SavePHX.cpp | 9 +- .../Framework/DataHandling/src/SaveRKH.cpp | 7 - .../DataHandling/src/SaveReflTBL.cpp | 7 - .../Framework/DataHandling/src/SaveSPE.cpp | 7 - .../src/SaveToSNSHistogramNexus.cpp | 7 - .../Framework/DataHandling/src/SaveVTK.cpp | 7 - .../DataHandling/src/SetSampleMaterial.cpp | 7 - .../DataHandling/src/SetScalingPSD.cpp | 7 - .../src/UpdateInstrumentFromFile.cpp | 7 - .../inc/MantidICat/CatalogDownloadDataFiles.h | 6 +- .../ICat/inc/MantidICat/CatalogGetDataFiles.h | 6 +- .../ICat/inc/MantidICat/CatalogGetDataSets.h | 6 +- .../ICat/inc/MantidICat/CatalogKeepAlive.h | 6 +- .../inc/MantidICat/CatalogListInstruments.h | 6 +- .../CatalogListInvestigationTypes.h | 6 +- .../ICat/inc/MantidICat/CatalogLogin.h | 6 +- .../ICat/inc/MantidICat/CatalogLogout.h | 4 +- .../ICat/inc/MantidICat/CatalogMyDataSearch.h | 6 +- .../ICat/inc/MantidICat/CatalogPublish.h | 6 +- .../ICat/inc/MantidICat/CatalogSearch.h | 6 +- .../ICat/src/CatalogDownloadDataFiles.cpp | 7 - .../ICat/src/CatalogGetDataFiles.cpp | 7 - .../Framework/ICat/src/CatalogGetDataSets.cpp | 7 - .../Framework/ICat/src/CatalogKeepAlive.cpp | 6 - .../ICat/src/CatalogListInstruments.cpp | 7 - .../src/CatalogListInvestigationTypes.cpp | 7 - .../Framework/ICat/src/CatalogLogin.cpp | 7 - .../Framework/ICat/src/CatalogLogout.cpp | 7 - .../ICat/src/CatalogMyDataSearch.cpp | 7 - .../Framework/ICat/src/CatalogPublish.cpp | 8 - .../Framework/ICat/src/CatalogSearch.cpp | 7 - .../inc/MantidISISLiveData/FakeISISEventDAE.h | 5 +- .../ISISLiveData/src/FakeISISEventDAE.cpp | 7 - 397 files changed, 999 insertions(+), 2019 deletions(-) diff --git a/Code/Mantid/Build/class_maker.py b/Code/Mantid/Build/class_maker.py index 5cda5a7f1d72..9fdb3ab9cba5 100755 --- a/Code/Mantid/Build/class_maker.py +++ b/Code/Mantid/Build/class_maker.py @@ -30,9 +30,9 @@ def write_header(subproject, classname, filename, args): virtual const std::string name() const; virtual int version() const; virtual const std::string category() const; + virtual const std::string summary() const; private: - virtual void initDocs(); void init(); void exec(); @@ -125,8 +125,7 @@ def write_source(subproject, classname, filename, args): algorithm_source = """ //---------------------------------------------------------------------------------------------- - /// Algorithm's name for identification. @see Algorithm::name - const std::string %s::name() const { return "%s";}; + /// Algorithm's version for identification. @see Algorithm::version int %s::version() const { return 1;}; @@ -134,13 +133,8 @@ def write_source(subproject, classname, filename, args): /// Algorithm's category for identification. @see Algorithm::category const std::string %s::category() const { return TODO: FILL IN A CATEGORY;} - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void %s::initDocs() - { - this->setWikiSummary("TODO: Enter a quick description of your algorithm."); - this->setOptionalMessage("TODO: Enter a quick description of your algorithm."); - } + /// Algorithm's summary for use in the GUI and help. @see Algorithm::summary + const std::string %s::summary() const { return TODO: FILL IN A SUMMARY;}; //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/AnvredCorrection.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/AnvredCorrection.h index 4bd3b007a64f..d0272a3299ac 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/AnvredCorrection.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/AnvredCorrection.h @@ -73,6 +73,9 @@ class DLLExport AnvredCorrection : public API::Algorithm virtual ~AnvredCorrection() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "AnvredCorrection"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates anvred correction factors for attenuation due to absorption and scattering in a spherical sample";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CalculatePeaksHKL.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CalculatePeaksHKL.h index 1d19dd84a5d1..0d24200fed36 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CalculatePeaksHKL.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CalculatePeaksHKL.h @@ -40,11 +40,13 @@ namespace Crystal virtual ~CalculatePeaksHKL(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates Miller indices for each peak. No rounding or UB optimization.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CalculateUMatrix.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CalculateUMatrix.h index 00a52364b922..0a1a03e45228 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CalculateUMatrix.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CalculateUMatrix.h @@ -42,14 +42,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "CalculateUMatrix";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the U matrix from a peaks workspace, given lattice parameters.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CentroidPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CentroidPeaks.h index 4147ba381774..ac7e85f7d25d 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CentroidPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CentroidPeaks.h @@ -30,14 +30,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "CentroidPeaks";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Find the centroid of single-crystal peaks in a 2D Workspace, in order to refine their positions.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ClearUB.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ClearUB.h index 852f191f05d0..7753c37ff195 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ClearUB.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ClearUB.h @@ -38,6 +38,9 @@ namespace Crystal virtual ~ClearUB(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Clears the UB by removing the oriented lattice from the sample.";} + virtual int version() const; virtual const std::string category() const; @@ -47,7 +50,6 @@ namespace Crystal private: bool clearSingleExperimentInfo(Mantid::API::ExperimentInfo * const experimentInfo, const bool dryRun) const; - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CombinePeaksWorkspaces.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CombinePeaksWorkspaces.h index ed09076e7f4c..8f56cdf0807a 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CombinePeaksWorkspaces.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/CombinePeaksWorkspaces.h @@ -38,11 +38,13 @@ namespace Crystal virtual ~CombinePeaksWorkspaces(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Combines the sets of peaks in two peaks workspaces, optionally omitting duplicates.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/DiffPeaksWorkspaces.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/DiffPeaksWorkspaces.h index a6cb8ee8a913..f95c30bf5802 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/DiffPeaksWorkspaces.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/DiffPeaksWorkspaces.h @@ -36,11 +36,13 @@ namespace Crystal virtual ~DiffPeaksWorkspaces(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Removes from a workspace any peaks that match a peak in a second workspace.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FilterPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FilterPeaks.h index 51979844b485..b02a71568d8b 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FilterPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FilterPeaks.h @@ -38,11 +38,13 @@ namespace Crystal virtual ~FilterPeaks(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Filters the peaks in a peaks workspace based upon the valur of a chosen variable.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindClusterFaces.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindClusterFaces.h index ba9c01176646..3778895978d3 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindClusterFaces.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindClusterFaces.h @@ -40,11 +40,13 @@ namespace Crystal virtual ~FindClusterFaces(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Find faces for clusters in a cluster image.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindSXPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindSXPeaks.h index abb4ce14be06..d13177917212 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindSXPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindSXPeaks.h @@ -203,13 +203,15 @@ class DLLExport FindSXPeaks : public API::Algorithm virtual ~FindSXPeaks() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FindSXPeaks";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes a 2D workspace as input and find the FindSXPeaksimum in each 1D spectrum. This is used in particular for single crystal as a quick way to find strong peaks.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Crystal;Optimization\\PeakFinding";} private: - void initDocs(); // Overridden Algorithm methods void init(); // diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingFFT.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingFFT.h index e17d404a9319..d4c4e0f8bddb 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingFFT.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingFFT.h @@ -50,10 +50,10 @@ namespace Crystal /// Algorithm's category for identification virtual const std::string category() const; - private: + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the UB matrix from a peaks workspace, given min(a,b,c) and max(a,b,c).";} - /// Sets documentation strings for this algorithm - virtual void initDocs(); + private: /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingIndexedPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingIndexedPeaks.h index 619ab1664fee..0716d152dfbd 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingIndexedPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingIndexedPeaks.h @@ -54,10 +54,12 @@ namespace Crystal virtual const std::string category() const { return "Crystal";} + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the UB matrix from a peaks workspace, containing indexed peaks.";} + private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingLatticeParameters.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingLatticeParameters.h index 3719c9c6fa80..119e6a61b699 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingLatticeParameters.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingLatticeParameters.h @@ -54,11 +54,11 @@ namespace Crystal virtual const std::string category() const { return "Crystal";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the UB matrix from a peaks workspace, given lattice parameters.";} + + private: - - /// Sets documentation strings for this algorithm - virtual void initDocs(); - /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingMinMaxD.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingMinMaxD.h index 1ff3be756533..8d55c1c47c05 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingMinMaxD.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/FindUBUsingMinMaxD.h @@ -51,11 +51,13 @@ namespace Crystal /// Algorithm's category for identification virtual const std::string category() const; + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the UB matrix from a peaks workspace, given min(a,b,c) and max(a,b,c).";} + private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/GoniometerAnglesFromPhiRotation.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/GoniometerAnglesFromPhiRotation.h index ef0ab1b2d6be..90ac03ac449f 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/GoniometerAnglesFromPhiRotation.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/GoniometerAnglesFromPhiRotation.h @@ -50,18 +50,16 @@ namespace Mantid ~GoniometerAnglesFromPhiRotation(); /// Algorithm's name for identification - const std::string name() const - { - return "GoniometerAnglesFromPhiRotation"; - } - ; + const std::string name() const { return "GoniometerAnglesFromPhiRotation"; } + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The 2nd PeaksWorkspace is set up with the correct sample orientations and UB matrices";} /// Algorithm's version for identification int version() const { return 1; } - ; /// Algorithm's category for identification const std::string category() const @@ -70,10 +68,6 @@ namespace Mantid } private: - - /// Sets documentation strings for this algorithm - void initDocs(); - /// Initialise the properties void init(); Kernel::Matrix getUBRaw(const Kernel::Matrix &UB, diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/HasUB.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/HasUB.h index b627b29e1c3a..cfe3bc669b25 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/HasUB.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/HasUB.h @@ -40,11 +40,13 @@ namespace Crystal virtual ~HasUB(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Determines whether the workspace has one or more UB Matrix";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IndexPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IndexPeaks.h index 1109e96887c9..80ed82e666ef 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IndexPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IndexPeaks.h @@ -43,12 +43,13 @@ namespace Crystal ~IndexPeaks(); /// Algorithm's name for identification - virtual const std::string name() const - { return "IndexPeaks";}; + virtual const std::string name() const { return "IndexPeaks";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Index the peaks using the UB from the sample.";} /// Algorithm's version for identification virtual int version() const - { return 1;}; + { return 1;} /// Algorithm's category for identification virtual const std::string category() const @@ -56,8 +57,7 @@ namespace Crystal private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IndexSXPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IndexSXPeaks.h index cd00dc3470b3..7ca313f7f16b 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IndexSXPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IndexSXPeaks.h @@ -178,6 +178,9 @@ class DLLExport IndexSXPeaks : public API::Algorithm virtual ~IndexSXPeaks() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "IndexSXPeaks";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes a PeaksWorkspace and a B-Matrix and determines the HKL values corresponding to each Single Crystal peak. Sets indexes on the input/output workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method @@ -189,7 +192,6 @@ class DLLExport IndexSXPeaks : public API::Algorithm void cullHKLs(std::vector& peaksCandidates, Mantid::Geometry::UnitCell& unitcell); //Helper method used to check that not all peaks are colinear. void validateNotColinear(std::vector& peakCandidates) const; - void initDocs(); // Overridden Algorithm methods void init(); // diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IntegratePeakTimeSlices.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IntegratePeakTimeSlices.h index 8be89c03ae61..2f6edf75670b 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IntegratePeakTimeSlices.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IntegratePeakTimeSlices.h @@ -286,6 +286,10 @@ class DLLExport IntegratePeakTimeSlices: public Mantid::API::Algorithm return "IntegratePeakTimeSlices"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The algorithm uses CurveFitting::BivariateNormal for fitting a time slice";} + + /// Algorithm's version for identification overriding a virtual method virtual int version() const { @@ -304,7 +308,6 @@ class DLLExport IntegratePeakTimeSlices: public Mantid::API::Algorithm void init(); void exec(); - virtual void initDocs(); Mantid::API::MatrixWorkspace_sptr inputW; ///< A pointer to the input workspace, the data set Mantid::DataObjects::TableWorkspace_sptr outputW; ///< A pointer to the output workspace diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IntegratePeaksUsingClusters.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IntegratePeaksUsingClusters.h index 139fd5637ace..659ee12e89af 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IntegratePeaksUsingClusters.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/IntegratePeaksUsingClusters.h @@ -39,12 +39,14 @@ namespace Crystal virtual ~IntegratePeaksUsingClusters(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Integrate single crystal peaks using connected component analysis";} + virtual int version() const; virtual const std::string category() const; private: Mantid::API::MDNormalization getNormalization(); - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadHKL.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadHKL.h index f15cc56e15fc..c41e4c1baa13 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadHKL.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadHKL.h @@ -27,14 +27,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "LoadHKL";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads an ASCII .hkl file to a PeaksWorkspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal;DataHandling\\Text";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawPeaks.h index 79a4db870cf5..1d54399ecc91 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawPeaks.h @@ -24,6 +24,9 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "LoadIsawPeaks";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load an ISAW-style .peaks file into a PeaksWorkspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification @@ -34,8 +37,7 @@ namespace Crystal int findPixelID(Geometry::Instrument_const_sptr inst, std::string bankName, int col, int row); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawSpectrum.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawSpectrum.h index 555aff8978d0..437920624407 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawSpectrum.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawSpectrum.h @@ -42,14 +42,16 @@ Load incident spectrum and detector efficiency correction file. /// Algorithm's name for identification virtual const std::string name() const { return "LoadIsawSpectrum";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load incident spectrum and detector efficiency correction file.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal;DataHandling\\Text";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawUB.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawUB.h index cdf2b7c2e4e5..8fd76c1037b4 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawUB.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/LoadIsawUB.h @@ -24,14 +24,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "LoadIsawUB";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load an ISAW-style ASCII UB matrix and lattice parameters file, and place its information into a workspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal;DataHandling\\Isaw";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/MaskPeaksWorkspace.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/MaskPeaksWorkspace.h index eac040265fc6..68508d6d64c7 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/MaskPeaksWorkspace.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/MaskPeaksWorkspace.h @@ -51,6 +51,9 @@ class DLLExport MaskPeaksWorkspace: public API::Algorithm virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Crystal"; } + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Masks a peaks workspace.";} private: API::MatrixWorkspace_sptr inputW; ///< A pointer to the input workspace diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/NormaliseVanadium.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/NormaliseVanadium.h index af5e17b3bc72..5692f380d708 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/NormaliseVanadium.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/NormaliseVanadium.h @@ -53,6 +53,9 @@ class DLLExport NormaliseVanadium : public API::Algorithm virtual ~NormaliseVanadium() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "NormaliseVanadium"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Normalises all spectra to a specified wavelength.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -66,8 +69,7 @@ class DLLExport NormaliseVanadium : public API::Algorithm API::MatrixWorkspace_sptr m_inputWS; ///< A pointer to the input workspace protected: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeCrystalPlacement.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeCrystalPlacement.h index 92588a593853..ccb82699b705 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeCrystalPlacement.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeCrystalPlacement.h @@ -1,9 +1,9 @@ /* - * OptimizeCrystalPlacement.h - * - * Created on: Jan 26, 2013 - * Author: ruth - */ +* OptimizeCrystalPlacement.h +* +* Created on: Jan 26, 2013 +* Author: ruth +*/ #ifndef OPTIMIZECRYSTALPLACEMENT_H_ #define OPTIMIZECRYSTALPLACEMENT_H_ @@ -13,17 +13,17 @@ namespace Mantid { -namespace Crystal -{ + namespace Crystal + { - /** OptimizeCrystalPlacement + /** OptimizeCrystalPlacement Description: - This algorithm basically indexes peaks with the crystal orientation matrix stored in the peaks workspace. - The optimization is on the goniometer settings for the runs in the peaks workspace and also the sample - orientation . - @author Ruth Mikkelson, SNS,ORNL - @date 01/26/2013 + This algorithm basically indexes peaks with the crystal orientation matrix stored in the peaks workspace. + The optimization is on the goniometer settings for the runs in the peaks workspace and also the sample + orientation . + @author Ruth Mikkelson, SNS,ORNL + @date 01/26/2013 Copyright © 2012 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory @@ -44,36 +44,38 @@ namespace Crystal File change history is stored at: Code Documentation is available at: - */ - class DLLExport OptimizeCrystalPlacement : public API::Algorithm - { - public: - OptimizeCrystalPlacement(); - virtual ~OptimizeCrystalPlacement(); - - virtual const std::string name() const - { + */ + class DLLExport OptimizeCrystalPlacement : public API::Algorithm + { + public: + OptimizeCrystalPlacement(); + virtual ~OptimizeCrystalPlacement(); + + virtual const std::string name() const + { return "OptimizeCrystalPlacement"; - }; + }; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm optimizes goniometer settings and sample orientation to better index the peaks.";} - virtual int version() const - { - return 1; - }; - const std::string category() const - { return "Crystal"; - }; + virtual int version() const + { + return 1; + }; - private: + const std::string category() const + { return "Crystal"; + }; - void initDocs(); + private: - void init(); - void exec(); - }; -} + void init(); + + void exec(); + }; + } } #endif /* OPTIMIZECRYSTALPLACEMENT_H_ */ diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeExtinctionParameters.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeExtinctionParameters.h index 66e1578270fa..38abc6e5c8b0 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeExtinctionParameters.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeExtinctionParameters.h @@ -49,6 +49,9 @@ class DLLExport OptimizeExtinctionParameters: public API::Algorithm virtual ~OptimizeExtinctionParameters(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "OptimizeExtinctionParameters"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Finds optimal mosaic and r_crystallite parameters for extinction correction.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -60,8 +63,7 @@ class DLLExport OptimizeExtinctionParameters: public API::Algorithm /// Point Groups possible std::vector m_pointGroups; - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeLatticeForCellType.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeLatticeForCellType.h index a8c9e25b3aef..271b0c4564ab 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeLatticeForCellType.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/OptimizeLatticeForCellType.h @@ -49,6 +49,9 @@ class DLLExport OptimizeLatticeForCellType: public API::Algorithm virtual ~OptimizeLatticeForCellType(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "OptimizeLatticeForCellType"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Optimize lattice parameters for cell type.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -58,8 +61,7 @@ class DLLExport OptimizeLatticeForCellType: public API::Algorithm void optLattice(std::string inname, std::vector & params, double *out); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakIntegration.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakIntegration.h index 11f8f1f31ed3..c518e40f7f0a 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakIntegration.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakIntegration.h @@ -50,8 +50,9 @@ class DLLExport PeakIntegration: public API::Algorithm /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method - virtual const std::string category() const { return "Crystal"; } - + virtual const std::string category() const { return "Crystal";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Integrate single crystal peaks using IkedaCarpenter fit TOF";} private: API::MatrixWorkspace_sptr inputW; ///< A pointer to the input workspace API::MatrixWorkspace_sptr outputW; ///< A pointer to the output workspace diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakIntensityVsRadius.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakIntensityVsRadius.h index 234a4d73ad41..204d4732e6f5 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakIntensityVsRadius.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeakIntensityVsRadius.h @@ -40,11 +40,13 @@ namespace Crystal virtual ~PeakIntensityVsRadius(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate the integrated intensity of peaks vs integration radius.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); std::map validateInputs(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeaksInRegion.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeaksInRegion.h index c3badb3e4e38..d1a88c00aefc 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeaksInRegion.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeaksInRegion.h @@ -38,12 +38,14 @@ namespace Crystal virtual ~PeaksInRegion(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Find peaks intersecting a box region.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeaksOnSurface.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeaksOnSurface.h index c325657ebd3f..1bc6563b2bb7 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeaksOnSurface.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PeaksOnSurface.h @@ -37,11 +37,13 @@ namespace Crystal virtual ~PeaksOnSurface(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Find peaks intersecting a single surface region.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PredictFractionalPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PredictFractionalPeaks.h index 69c5ab9d25aa..b3713ebec288 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PredictFractionalPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PredictFractionalPeaks.h @@ -43,8 +43,9 @@ namespace Crystal virtual ~PredictFractionalPeaks(); /// Algorithm's name for identification - virtual const std::string name() const - { return "PredictFractionalPeaks";}; + virtual const std::string name() const { return "PredictFractionalPeaks";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The offsets can be from hkl values in a range of hkl values or from peaks in the input PeaksWorkspace";} /// Algorithm's version for identification virtual int version() const @@ -56,8 +57,7 @@ namespace Crystal private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PredictPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PredictPeaks.h index 710798922656..a34c1d15468f 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PredictPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/PredictPeaks.h @@ -28,14 +28,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "PredictPeaks";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Using a known crystal lattice and UB matrix, predict where single crystal peaks should be found in detector/TOF space. Creates a PeaksWorkspace containing the peaks at the expected positions.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SCDCalibratePanels.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SCDCalibratePanels.h index 6e31948d9640..c535b25f62ee 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SCDCalibratePanels.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SCDCalibratePanels.h @@ -53,6 +53,9 @@ namespace Crystal virtual ~SCDCalibratePanels(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Panel parameters, sample position,L0 and T0 are optimized to minimize errors between theoretical and actual q values for the peaks";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const; @@ -221,7 +224,6 @@ namespace Crystal void init (); - void initDocs (); /** * Creates a new instrument when a calibration file( .xml or .detcal) diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveHKL.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveHKL.h index 2f86d35ccb02..be34c51750be 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveHKL.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveHKL.h @@ -24,14 +24,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "SaveHKL";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Save a PeaksWorkspace to a ASCII .hkl file.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal;DataHandling\\Text";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveIsawPeaks.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveIsawPeaks.h index a591ab07cba2..4bd9ea685496 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveIsawPeaks.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveIsawPeaks.h @@ -22,14 +22,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "SaveIsawPeaks";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Save a PeaksWorkspace to a ISAW-style ASCII .peaks file.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal;DataHandling\\Isaw";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveIsawUB.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveIsawUB.h index 0beedf1cc143..166ccf09a994 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveIsawUB.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SaveIsawUB.h @@ -46,14 +46,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "SaveIsawUB";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Save a UB matrix and lattice parameters from a workspace to an ISAW-style ASCII file.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal;DataHandling\\Isaw";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SavePeaksFile.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SavePeaksFile.h index 9ee1eaeb55f8..b90b6e594b53 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SavePeaksFile.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SavePeaksFile.h @@ -22,14 +22,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "SavePeaksFile";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Save a PeaksWorkspace to a .peaks text-format file.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SelectCellOfType.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SelectCellOfType.h index 306fa87a1b03..b5fb6c0b31b2 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SelectCellOfType.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SelectCellOfType.h @@ -56,11 +56,12 @@ namespace Crystal virtual const std::string category() const { return "Crystal";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Select a conventional cell with a specific lattice type and centering, corresponding to the UB stored with the sample for this peaks works space.";} + + private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); - /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SelectCellWithForm.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SelectCellWithForm.h index 38dff3fb4db3..38c34b95b603 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SelectCellWithForm.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SelectCellWithForm.h @@ -58,16 +58,15 @@ namespace Crystal virtual const std::string category() const { return "Crystal";} - + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Select a conventional cell with a specific form number, corresponding to the UB stored with the sample for this peaks works space.";} + static Kernel::Matrix DetermineErrors( std::vector &sigabc, const Kernel::Matrix &UB, const DataObjects::PeaksWorkspace_sptr &ws, double tolerance); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); - /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetGoniometer.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetGoniometer.h index 2975854af8e5..6ebd829bfc0d 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetGoniometer.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetGoniometer.h @@ -22,14 +22,16 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "SetGoniometer";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Define the goniometer motors used in an experiment by giving the axes and directions of rotations.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetSpecialCoordinates.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetSpecialCoordinates.h index 8cbd01ed62f1..5bb280fa9337 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetSpecialCoordinates.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetSpecialCoordinates.h @@ -44,11 +44,13 @@ namespace Crystal virtual ~SetSpecialCoordinates(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Set or overwrite any Q3D special coordinates.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); std::vector m_specialCoordinatesNames; diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetUB.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetUB.h index 458492df32f3..f0bca8ad00e6 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetUB.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SetUB.h @@ -43,11 +43,13 @@ namespace Crystal ~SetUB(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Set the UB matrix, given either lattice parametersand orientation vectors or the UB matrix elements";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ShowPeakHKLOffsets.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ShowPeakHKLOffsets.h index f9fbdce3721c..8bb7b971f826 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ShowPeakHKLOffsets.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ShowPeakHKLOffsets.h @@ -2,36 +2,36 @@ namespace Crystal * PeakHKLOffsets.h - * - * Created on: May 13, 2013 - * Author: ruth - */ +* +* Created on: May 13, 2013 +* Author: ruth +*/ /** - Shows integer offsets for each peak of their h,k and l values, along with max offset and run number and detector number +Shows integer offsets for each peak of their h,k and l values, along with max offset and run number and detector number - @author Ruth Mikkelson, SNS, ORNL - @date 05/13/2013 +@author Ruth Mikkelson, SNS, ORNL +@date 05/13/2013 - Copyright © 2009 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory +Copyright © 2009 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory - This file is part of Mantid. +This file is part of Mantid. - Mantid is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. +Mantid is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 3 of the License, or +(at your option) any later version. - Mantid is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. +Mantid is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. - You should have received a copy of the GNU General Public License - along with this program. If not, see . +You should have received a copy of the GNU General Public License +along with this program. If not, see . - File change history is stored at: - Code Documentation is available at: - */ +File change history is stored at: +Code Documentation is available at: +*/ #ifndef SHOWPEAKHKLOFFSETS_H_ #define SHOWPEAKHKLOFFSETS_H_ @@ -41,39 +41,41 @@ namespace Crystal * PeakHKLOffsets.h namespace Mantid { -namespace Crystal -{ - class DLLExport ShowPeakHKLOffsets : public API::Algorithm - { - public: - ShowPeakHKLOffsets(); - virtual ~ShowPeakHKLOffsets(); - - virtual const std::string name() const - { + namespace Crystal + { + class DLLExport ShowPeakHKLOffsets : public API::Algorithm + { + public: + ShowPeakHKLOffsets(); + virtual ~ShowPeakHKLOffsets(); + + virtual const std::string name() const + { return "ShowPeakHKLOffsets"; - }; + }; - virtual int version() const - { - return 1; - }; + ///Summary of algorithms purpose + virtual const std::string summary() const {return " Histograms, scatter plots, etc. of this data could be useful to detect calibration problems";} - const std::string category() const - { return "Crystal"; - }; + virtual int version() const + { + return 1; + }; - private: + const std::string category() const + { return "Crystal"; + }; - void initDocs(); + private: - void init(); - void exec(); - }; + void init(); + void exec(); + }; -} + + } } #endif /* ShowPeakHKLOffsets_H_ */ diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ShowPossibleCells.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ShowPossibleCells.h index 1ba245806967..770ae467d9b1 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ShowPossibleCells.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/ShowPossibleCells.h @@ -56,11 +56,11 @@ namespace Crystal virtual const std::string category() const { return "Crystal";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Show conventional cells corresponding to the UB stored with the sample for this peaks works space.";} + private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); - /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SortHKL.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SortHKL.h index 605cb9f639f7..264883c01953 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SortHKL.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SortHKL.h @@ -25,6 +25,9 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "SortHKL";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Sorts a PeaksWorkspace by HKL. Averages intensities using point group.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification @@ -33,8 +36,7 @@ namespace Crystal private: /// Point Groups possible std::vector m_pointGroups; - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SortPeaksWorkspace.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SortPeaksWorkspace.h index 38968c27dc70..3e3cc8cede79 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SortPeaksWorkspace.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/SortPeaksWorkspace.h @@ -39,11 +39,13 @@ namespace Crystal virtual ~SortPeaksWorkspace(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Sort a peaks workspace by a column of the workspace";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); Mantid::DataObjects::PeaksWorkspace_sptr tryFetchOutputWorkspace() const; diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/TOFExtinction.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/TOFExtinction.h index 9db917eecaf5..eccde4a68b8e 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/TOFExtinction.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/TOFExtinction.h @@ -41,14 +41,15 @@ namespace Crystal /// Algorithm's name for identification virtual const std::string name() const { return "TOFExtinction";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Extinction correction for single crystal peaks.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Crystal;DataHandling\\Text";} private: - /// Sets documentation strings for this algorithm; - virtual void initDocs(); /// Initialise the properties; void init(); /// Run the algorithm; diff --git a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/TransformHKL.h b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/TransformHKL.h index 8dedc8b47823..dbe3e2791b45 100644 --- a/Code/Mantid/Framework/Crystal/inc/MantidCrystal/TransformHKL.h +++ b/Code/Mantid/Framework/Crystal/inc/MantidCrystal/TransformHKL.h @@ -51,11 +51,10 @@ namespace Crystal /// Algorithm's category for identification virtual const std::string category() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Specify a 3x3 matrix to apply to (HKL) vectors as a list of 9 comma separated numbers. Both the UB and HKL values will be updated";} + private: - - /// Sets documentation strings for this algorithm - virtual void initDocs(); - /// Initialise the properties void init(); diff --git a/Code/Mantid/Framework/Crystal/src/AnvredCorrection.cpp b/Code/Mantid/Framework/Crystal/src/AnvredCorrection.cpp index f8b6b15cb9fc..003c9a72c436 100644 --- a/Code/Mantid/Framework/Crystal/src/AnvredCorrection.cpp +++ b/Code/Mantid/Framework/Crystal/src/AnvredCorrection.cpp @@ -126,7 +126,7 @@ AnvredCorrection::AnvredCorrection() : API::Algorithm() void AnvredCorrection::init() { - this->setWikiSummary("Calculates anvred correction factors for attenuation due to absorption and scattering in a spherical sample"); + // The input workspace must have an instrument and units of wavelength boost::shared_ptr wsValidator = boost::make_shared(); wsValidator->add(boost::make_shared()); diff --git a/Code/Mantid/Framework/Crystal/src/CalculatePeaksHKL.cpp b/Code/Mantid/Framework/Crystal/src/CalculatePeaksHKL.cpp index bb33022cb0e4..a5ce7fdd218f 100644 --- a/Code/Mantid/Framework/Crystal/src/CalculatePeaksHKL.cpp +++ b/Code/Mantid/Framework/Crystal/src/CalculatePeaksHKL.cpp @@ -63,13 +63,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CalculatePeaksHKL::initDocs() - { - this->setWikiSummary("Calculates Miller indices for each peak. No rounding or UB optimization."); - this->setOptionalMessage( - "Calculates Miller indices for each peak. No rounding or UB optimization."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/CalculateUMatrix.cpp b/Code/Mantid/Framework/Crystal/src/CalculateUMatrix.cpp index f301be459674..2a751c10c2c2 100644 --- a/Code/Mantid/Framework/Crystal/src/CalculateUMatrix.cpp +++ b/Code/Mantid/Framework/Crystal/src/CalculateUMatrix.cpp @@ -141,12 +141,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CalculateUMatrix::initDocs() - { - this->setWikiSummary("Calculate the U matrix from a [[PeaksWorkspace]], given lattice parameters."); - this->setOptionalMessage("Calculate the U matrix from a peaks workspace, given lattice parameters."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/CentroidPeaks.cpp b/Code/Mantid/Framework/Crystal/src/CentroidPeaks.cpp index 3ec035b8a7e9..0852c655b94d 100644 --- a/Code/Mantid/Framework/Crystal/src/CentroidPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/CentroidPeaks.cpp @@ -45,12 +45,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CentroidPeaks::initDocs() - { - this->setWikiSummary("Find the centroid of single-crystal peaks in a 2D Workspace, in order to refine their positions."); - this->setOptionalMessage("Find the centroid of single-crystal peaks in a 2D Workspace, in order to refine their positions."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/ClearUB.cpp b/Code/Mantid/Framework/Crystal/src/ClearUB.cpp index 67a89e499efc..6f500e43f7e5 100644 --- a/Code/Mantid/Framework/Crystal/src/ClearUB.cpp +++ b/Code/Mantid/Framework/Crystal/src/ClearUB.cpp @@ -54,12 +54,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ClearUB::initDocs() - { - this->setWikiSummary("Clears the UB by removing the oriented lattice from the sample."); - this->setOptionalMessage(this->getWikiSummary()); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/CombinePeaksWorkspaces.cpp b/Code/Mantid/Framework/Crystal/src/CombinePeaksWorkspaces.cpp index 75672e6f7499..0098e8867846 100644 --- a/Code/Mantid/Framework/Crystal/src/CombinePeaksWorkspaces.cpp +++ b/Code/Mantid/Framework/Crystal/src/CombinePeaksWorkspaces.cpp @@ -47,13 +47,6 @@ namespace Crystal /// Algorithm's category for identification. @see Algorithm::category const std::string CombinePeaksWorkspaces::category() const { return "Crystal";} - /// Sets documentation strings for this algorithm - void CombinePeaksWorkspaces::initDocs() - { - this->setWikiSummary("Combines the sets of peaks in two peaks workspaces, optionally omitting duplicates."); - this->setOptionalMessage("Combines the sets of peaks in two peaks workspaces, optionally omitting duplicates."); - } - /** Initialises the algorithm's properties. */ void CombinePeaksWorkspaces::init() diff --git a/Code/Mantid/Framework/Crystal/src/DiffPeaksWorkspaces.cpp b/Code/Mantid/Framework/Crystal/src/DiffPeaksWorkspaces.cpp index ae752d0bd2f1..859eb09d0219 100644 --- a/Code/Mantid/Framework/Crystal/src/DiffPeaksWorkspaces.cpp +++ b/Code/Mantid/Framework/Crystal/src/DiffPeaksWorkspaces.cpp @@ -39,13 +39,6 @@ namespace Crystal /// Algorithm's category for identification. @see Algorithm::category const std::string DiffPeaksWorkspaces::category() const { return "Crystal"; } - /// Sets documentation strings for this algorithm - void DiffPeaksWorkspaces::initDocs() - { - this->setWikiSummary("Removes from a workspace any peaks that match a peak in a second workspace."); - this->setOptionalMessage("Removes from a workspace any peaks that match a peak in a second workspace."); - } - /** Initialises the algorithm's properties. */ void DiffPeaksWorkspaces::init() diff --git a/Code/Mantid/Framework/Crystal/src/FilterPeaks.cpp b/Code/Mantid/Framework/Crystal/src/FilterPeaks.cpp index d9caf4cb3ae1..f5a0ae7f140a 100644 --- a/Code/Mantid/Framework/Crystal/src/FilterPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/FilterPeaks.cpp @@ -62,13 +62,6 @@ namespace Crystal /// Algorithm's category for identification. @see Algorithm::category const std::string FilterPeaks::category() const { return "Crystal";} - /// Sets documentation strings for this algorithm - void FilterPeaks::initDocs() - { - this->setWikiSummary("Filters the peaks in a peaks workspace based upon the value of a chosen variable."); - this->setOptionalMessage("Filters the peaks in a peaks workspace based upon the valur of a chosen variable."); - } - /** Initialize the algorithm's properties. */ void FilterPeaks::init() diff --git a/Code/Mantid/Framework/Crystal/src/FindClusterFaces.cpp b/Code/Mantid/Framework/Crystal/src/FindClusterFaces.cpp index a863bea9210a..25b79298abb9 100644 --- a/Code/Mantid/Framework/Crystal/src/FindClusterFaces.cpp +++ b/Code/Mantid/Framework/Crystal/src/FindClusterFaces.cpp @@ -328,12 +328,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void FindClusterFaces::initDocs() - { - this->setWikiSummary("Find faces for clusters in a cluster image."); - this->setOptionalMessage(this->getWikiSummary()); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/FindSXPeaks.cpp b/Code/Mantid/Framework/Crystal/src/FindSXPeaks.cpp index 4b8ac8c6ba97..27fd9e19dea2 100644 --- a/Code/Mantid/Framework/Crystal/src/FindSXPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/FindSXPeaks.cpp @@ -35,13 +35,6 @@ namespace Mantid using namespace Kernel; using namespace API; - /// Set the documentation strings - void FindSXPeaks::initDocs() - { - this->setWikiSummary("Takes a 2D workspace as input and find the FindSXPeaksimum in each 1D spectrum. This is used in particular for single crystal as a quick way to find strong peaks."); - this->setOptionalMessage("Takes a 2D workspace as input and find the FindSXPeaksimum in each 1D spectrum. This is used in particular for single crystal as a quick way to find strong peaks."); - } - /** Initialisation method. * */ diff --git a/Code/Mantid/Framework/Crystal/src/FindUBUsingFFT.cpp b/Code/Mantid/Framework/Crystal/src/FindUBUsingFFT.cpp index ef2b2dec9e69..13759c851e47 100644 --- a/Code/Mantid/Framework/Crystal/src/FindUBUsingFFT.cpp +++ b/Code/Mantid/Framework/Crystal/src/FindUBUsingFFT.cpp @@ -64,19 +64,6 @@ namespace Crystal return "Crystal"; } - //-------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void FindUBUsingFFT::initDocs() - { - std::string summary("Calculate the UB matrix from a peaks workspace, "); - summary += "given estimates of the min and max real space unit cell "; - summary += "edge lengths."; - this->setWikiSummary( summary ); - - std::string message("Calculate the UB matrix from a peaks workspace, "); - message += "given min(a,b,c) and max(a,b,c)."; - this->setOptionalMessage( message ); - } //-------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/FindUBUsingIndexedPeaks.cpp b/Code/Mantid/Framework/Crystal/src/FindUBUsingIndexedPeaks.cpp index 3a8355761ac2..ec2a5d8523e4 100644 --- a/Code/Mantid/Framework/Crystal/src/FindUBUsingIndexedPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/FindUBUsingIndexedPeaks.cpp @@ -42,20 +42,6 @@ namespace Crystal { } - - //-------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void FindUBUsingIndexedPeaks::initDocs() - { - std::string summary("Calculate the UB matrix from a peaks workspace in "); - summary += "which (h,k,l) indices have already been set on at least three "; summary += "linearly independent Q vectors."; - this->setWikiSummary( summary ); - - std::string message("Calculate the UB matrix from a peaks workspace, "); - message += "containing indexed peaks."; - this->setOptionalMessage( message ); - } - //-------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/Crystal/src/FindUBUsingLatticeParameters.cpp b/Code/Mantid/Framework/Crystal/src/FindUBUsingLatticeParameters.cpp index f58d256804cb..315e619a957c 100644 --- a/Code/Mantid/Framework/Crystal/src/FindUBUsingLatticeParameters.cpp +++ b/Code/Mantid/Framework/Crystal/src/FindUBUsingLatticeParameters.cpp @@ -59,18 +59,6 @@ namespace Crystal { } - //-------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void FindUBUsingLatticeParameters::initDocs() - { - std::string summary("Calculate the UB matrix from a peaks workspace, "); - summary += "given lattice parameters."; - this->setWikiSummary( summary ); - - std::string message("Calculate the UB matrix from a peaks workspace, "); - message += "given lattice parameters."; - this->setOptionalMessage( message ); - } //-------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/FindUBUsingMinMaxD.cpp b/Code/Mantid/Framework/Crystal/src/FindUBUsingMinMaxD.cpp index 6a7149bf1b40..9b556b3b1cc7 100644 --- a/Code/Mantid/Framework/Crystal/src/FindUBUsingMinMaxD.cpp +++ b/Code/Mantid/Framework/Crystal/src/FindUBUsingMinMaxD.cpp @@ -56,20 +56,6 @@ namespace Crystal return "Crystal"; } - //-------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void FindUBUsingMinMaxD::initDocs() - { - std::string summary("Calculate the UB matrix from a peaks workspace, "); - summary += "given estimates of the min and max real space unit cell "; - summary += "edge lengths."; - this->setWikiSummary( summary ); - - std::string message("Calculate the UB matrix from a peaks workspace, "); - message += "given min(a,b,c) and max(a,b,c)."; - this->setOptionalMessage( message ); - } - //-------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/Crystal/src/GoniometerAnglesFromPhiRotation.cpp b/Code/Mantid/Framework/Crystal/src/GoniometerAnglesFromPhiRotation.cpp index d5bd9a555995..70e4abadd18a 100644 --- a/Code/Mantid/Framework/Crystal/src/GoniometerAnglesFromPhiRotation.cpp +++ b/Code/Mantid/Framework/Crystal/src/GoniometerAnglesFromPhiRotation.cpp @@ -94,11 +94,6 @@ namespace Mantid Kernel::Direction::Output); } - void GoniometerAnglesFromPhiRotation::initDocs() - { - this->setWikiSummary("Finds chi and omega rotations for two runs whose sample positions differ by only their phi angles"); - this->setOptionalMessage("The 2nd PeaksWorkspace is set up with the correct sample orientations and UB matrices"); - } /** * Calculate indexing stats if the peaks had been indexed with given UBraw by NOT applying the goniometer settings,i.e. diff --git a/Code/Mantid/Framework/Crystal/src/HasUB.cpp b/Code/Mantid/Framework/Crystal/src/HasUB.cpp index 1a504a425442..3d9ec91267d8 100644 --- a/Code/Mantid/Framework/Crystal/src/HasUB.cpp +++ b/Code/Mantid/Framework/Crystal/src/HasUB.cpp @@ -44,12 +44,6 @@ namespace Crystal const std::string HasUB::category() const { return "Crystal";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void HasUB::initDocs() - { - this->setWikiSummary("Determines whether the workspace has one or more UB Matrix."); - this->setOptionalMessage("Determines whether the workspace has one or more UB Matrix"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/IndexPeaks.cpp b/Code/Mantid/Framework/Crystal/src/IndexPeaks.cpp index e2bcff5a53f6..b7fedb7627a3 100644 --- a/Code/Mantid/Framework/Crystal/src/IndexPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/IndexPeaks.cpp @@ -50,15 +50,6 @@ namespace Crystal } //-------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void IndexPeaks::initDocs() - { - std::string summary("Index the peaks in the PeaksWorkspace using the UB "); - summary += "stored with the sample."; - this->setWikiSummary( summary ); - - this->setOptionalMessage("Index the peaks using the UB from the sample."); - } //-------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/IndexSXPeaks.cpp b/Code/Mantid/Framework/Crystal/src/IndexSXPeaks.cpp index 0aa681a2c619..500ef98c47bc 100644 --- a/Code/Mantid/Framework/Crystal/src/IndexSXPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/IndexSXPeaks.cpp @@ -35,13 +35,6 @@ namespace Mantid using namespace Kernel; using namespace API; - /// Set the documentation strings - void IndexSXPeaks::initDocs() - { - this->setWikiSummary("Takes a PeaksWorkspace and a B-Matrix and determines the HKL values corresponding to each Single Crystal peak. Sets indexes on the input/output workspace."); - this->setOptionalMessage("Takes a PeaksWorkspace and a B-Matrix and determines the HKL values corresponding to each Single Crystal peak. Sets indexes on the input/output workspace."); - } - /** Initialisation method. * */ diff --git a/Code/Mantid/Framework/Crystal/src/IntegratePeakTimeSlices.cpp b/Code/Mantid/Framework/Crystal/src/IntegratePeakTimeSlices.cpp index 273211ee5a43..f24bc7fde36a 100644 --- a/Code/Mantid/Framework/Crystal/src/IntegratePeakTimeSlices.cpp +++ b/Code/Mantid/Framework/Crystal/src/IntegratePeakTimeSlices.cpp @@ -201,12 +201,6 @@ namespace Mantid delete [] NeighborIDs; } - void IntegratePeakTimeSlices::initDocs() - { - this->setWikiSummary("Integrates each time slice around a peak "); - this->setOptionalMessage("The algorithm uses CurveFitting::BivariateNormal for fitting a time slice"); - } - void IntegratePeakTimeSlices::init() { diff --git a/Code/Mantid/Framework/Crystal/src/IntegratePeaksUsingClusters.cpp b/Code/Mantid/Framework/Crystal/src/IntegratePeaksUsingClusters.cpp index fb48cfcf66a2..05d9a290efa6 100644 --- a/Code/Mantid/Framework/Crystal/src/IntegratePeaksUsingClusters.cpp +++ b/Code/Mantid/Framework/Crystal/src/IntegratePeaksUsingClusters.cpp @@ -145,12 +145,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void IntegratePeaksUsingClusters::initDocs() - { - this->setWikiSummary("Integrate single crystal peaks using connected component analysis"); - this->setOptionalMessage(this->getWikiSummary()); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/LoadHKL.cpp b/Code/Mantid/Framework/Crystal/src/LoadHKL.cpp index 09f838eeca0b..94daa9872d18 100644 --- a/Code/Mantid/Framework/Crystal/src/LoadHKL.cpp +++ b/Code/Mantid/Framework/Crystal/src/LoadHKL.cpp @@ -77,12 +77,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadHKL::initDocs() - { - this->setWikiSummary("Loads an ASCII .hkl file to a PeaksWorkspace."); - this->setOptionalMessage("Loads an ASCII .hkl file to a PeaksWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/LoadIsawPeaks.cpp b/Code/Mantid/Framework/Crystal/src/LoadIsawPeaks.cpp index 429a2d492c49..c1563b7e2990 100644 --- a/Code/Mantid/Framework/Crystal/src/LoadIsawPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/LoadIsawPeaks.cpp @@ -120,12 +120,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadIsawPeaks::initDocs() - { - this->setWikiSummary("Load an ISAW-style .peaks file into a [[PeaksWorkspace]]."); - this->setOptionalMessage("Load an ISAW-style .peaks file into a PeaksWorkspace."); - } //---------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/Crystal/src/LoadIsawSpectrum.cpp b/Code/Mantid/Framework/Crystal/src/LoadIsawSpectrum.cpp index 9a59cd37fb9f..f1b8b68626ad 100644 --- a/Code/Mantid/Framework/Crystal/src/LoadIsawSpectrum.cpp +++ b/Code/Mantid/Framework/Crystal/src/LoadIsawSpectrum.cpp @@ -49,12 +49,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadIsawSpectrum::initDocs() - { - this->setWikiSummary("Load incident spectrum and detector efficiency correction file."); - this->setOptionalMessage("Load incident spectrum and detector efficiency correction file."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/LoadIsawUB.cpp b/Code/Mantid/Framework/Crystal/src/LoadIsawUB.cpp index 314f7ef9d4bd..313c52a3fa4f 100644 --- a/Code/Mantid/Framework/Crystal/src/LoadIsawUB.cpp +++ b/Code/Mantid/Framework/Crystal/src/LoadIsawUB.cpp @@ -56,12 +56,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadIsawUB::initDocs() - { - this->setWikiSummary("Load an ISAW-style ASCII UB matrix and lattice parameters file, and place its information into a workspace."); - this->setOptionalMessage("Load an ISAW-style ASCII UB matrix and lattice parameters file, and place its information into a workspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/NormaliseVanadium.cpp b/Code/Mantid/Framework/Crystal/src/NormaliseVanadium.cpp index 009cf757da53..87b85e1d8926 100644 --- a/Code/Mantid/Framework/Crystal/src/NormaliseVanadium.cpp +++ b/Code/Mantid/Framework/Crystal/src/NormaliseVanadium.cpp @@ -35,13 +35,6 @@ using namespace DataObjects; NormaliseVanadium::NormaliseVanadium() : API::Algorithm() {} -/// Sets documentation strings for this algorithm -void NormaliseVanadium::initDocs() -{ - this->setWikiSummary("Normalises all spectra to a specified wavelength."); - this->setOptionalMessage("Normalises all spectra to a specified wavelength."); -} - void NormaliseVanadium::init() { // The input workspace must have an instrument and units of wavelength diff --git a/Code/Mantid/Framework/Crystal/src/OptimizeCrystalPlacement.cpp b/Code/Mantid/Framework/Crystal/src/OptimizeCrystalPlacement.cpp index 80c45424052a..f5a7a0dee61c 100644 --- a/Code/Mantid/Framework/Crystal/src/OptimizeCrystalPlacement.cpp +++ b/Code/Mantid/Framework/Crystal/src/OptimizeCrystalPlacement.cpp @@ -120,14 +120,6 @@ namespace Mantid } - void OptimizeCrystalPlacement::initDocs() - { - this->setWikiSummary( - "This algorithm optimizes goniometer settings and sample orientation to better index the peaks." ); - this->setOptionalMessage( - "This algorithm optimizes goniometer settings and sample orientation to better index the peaks." ); - } - void OptimizeCrystalPlacement::init() { declareProperty(new WorkspaceProperty ("PeaksWorkspace", "", Direction::Input), diff --git a/Code/Mantid/Framework/Crystal/src/OptimizeExtinctionParameters.cpp b/Code/Mantid/Framework/Crystal/src/OptimizeExtinctionParameters.cpp index c86382c6d862..28e7ac009c2f 100644 --- a/Code/Mantid/Framework/Crystal/src/OptimizeExtinctionParameters.cpp +++ b/Code/Mantid/Framework/Crystal/src/OptimizeExtinctionParameters.cpp @@ -31,13 +31,6 @@ namespace Mantid // Register the class into the algorithm factory //DECLARE_ALGORITHM(OptimizeExtinctionParameters) - /// Sets documentation strings for this algorithm - void OptimizeExtinctionParameters::initDocs() - { - this->setWikiSummary("Finds optimal mosaic and r_crystallite parameters for extinction correction."); - this->setOptionalMessage("Finds optimal mosaic and r_crystallite parameters for extinction correction."); - } - using namespace Kernel; using namespace API; using std::size_t; diff --git a/Code/Mantid/Framework/Crystal/src/OptimizeLatticeForCellType.cpp b/Code/Mantid/Framework/Crystal/src/OptimizeLatticeForCellType.cpp index 84a2f33eaa96..be243b08acc2 100644 --- a/Code/Mantid/Framework/Crystal/src/OptimizeLatticeForCellType.cpp +++ b/Code/Mantid/Framework/Crystal/src/OptimizeLatticeForCellType.cpp @@ -39,13 +39,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(OptimizeLatticeForCellType) - /// Sets documentation strings for this algorithm - void OptimizeLatticeForCellType::initDocs() - { - this->setWikiSummary("Optimize lattice parameters for cell type."); - this->setOptionalMessage("Optimize lattice parameters for cell type."); - } - using namespace Kernel; using namespace API; using std::size_t; diff --git a/Code/Mantid/Framework/Crystal/src/PeakIntensityVsRadius.cpp b/Code/Mantid/Framework/Crystal/src/PeakIntensityVsRadius.cpp index b0f596888e09..1c4ed093085a 100644 --- a/Code/Mantid/Framework/Crystal/src/PeakIntensityVsRadius.cpp +++ b/Code/Mantid/Framework/Crystal/src/PeakIntensityVsRadius.cpp @@ -96,12 +96,6 @@ namespace Crystal const std::string PeakIntensityVsRadius::category() const { return "Crystal";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void PeakIntensityVsRadius::initDocs() - { - this->setWikiSummary("Calculate the integrated intensity of peaks vs integration radius."); - this->setOptionalMessage("Calculate the integrated intensity of peaks vs integration radius."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/PeaksInRegion.cpp b/Code/Mantid/Framework/Crystal/src/PeaksInRegion.cpp index 23c98d2d775e..55d8f40bee32 100644 --- a/Code/Mantid/Framework/Crystal/src/PeaksInRegion.cpp +++ b/Code/Mantid/Framework/Crystal/src/PeaksInRegion.cpp @@ -47,12 +47,6 @@ namespace Crystal const std::string PeaksInRegion::category() const { return "Crystal";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void PeaksInRegion::initDocs() - { - this->setWikiSummary("Find peaks intersecting a box region."); - this->setOptionalMessage(this->getWikiSummary()); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/PeaksOnSurface.cpp b/Code/Mantid/Framework/Crystal/src/PeaksOnSurface.cpp index c1f03158017d..a991049136eb 100644 --- a/Code/Mantid/Framework/Crystal/src/PeaksOnSurface.cpp +++ b/Code/Mantid/Framework/Crystal/src/PeaksOnSurface.cpp @@ -46,12 +46,6 @@ namespace Crystal const std::string PeaksOnSurface::category() const { return "Crystal";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void PeaksOnSurface::initDocs() - { - this->setWikiSummary("Find peaks intersecting a single surface region."); - this->setOptionalMessage(this->getWikiSummary()); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/PredictFractionalPeaks.cpp b/Code/Mantid/Framework/Crystal/src/PredictFractionalPeaks.cpp index 1258d2ae8824..2a00b4238ce0 100644 --- a/Code/Mantid/Framework/Crystal/src/PredictFractionalPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/PredictFractionalPeaks.cpp @@ -62,12 +62,6 @@ namespace Mantid { - } - /// Sets documentation strings for this algorithm - void PredictFractionalPeaks::initDocs() - { - this->setWikiSummary("Creates a PeaksWorkspace with peaks occurring at specific fractional h,k,or l values"); - this->setOptionalMessage("The offsets can be from hkl values in a range of hkl values or from peaks in the input PeaksWorkspace"); } /// Initialise the properties diff --git a/Code/Mantid/Framework/Crystal/src/PredictPeaks.cpp b/Code/Mantid/Framework/Crystal/src/PredictPeaks.cpp index 0a03cfdb7a5b..76036ad8261b 100644 --- a/Code/Mantid/Framework/Crystal/src/PredictPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/PredictPeaks.cpp @@ -75,12 +75,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void PredictPeaks::initDocs() - { - this->setWikiSummary("Using a known crystal lattice and UB matrix, predict where single crystal peaks should be found in detector/TOF space. Creates a PeaksWorkspace containing the peaks at the expected positions."); - this->setOptionalMessage("Using a known crystal lattice and UB matrix, predict where single crystal peaks should be found in detector/TOF space. Creates a PeaksWorkspace containing the peaks at the expected positions."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/SCDCalibratePanels.cpp b/Code/Mantid/Framework/Crystal/src/SCDCalibratePanels.cpp index 0e7ff0b27a74..de3741beca44 100644 --- a/Code/Mantid/Framework/Crystal/src/SCDCalibratePanels.cpp +++ b/Code/Mantid/Framework/Crystal/src/SCDCalibratePanels.cpp @@ -1487,14 +1487,6 @@ namespace Mantid } - - void SCDCalibratePanels::initDocs () - { - this->setWikiSummary("Calibrates Panels for Rectangular Detectors only"); - this->setOptionalMessage("Panel parameters, sample position,L0 and T0 are optimized to minimize errors between theoretical and actual q values for the peaks"); - - } - /** * Creates The SCDPanelErrors function with the optimum parameters to get the resultant out,xvals to report results. * @param ws The workspace sent to SCDPanelErrors diff --git a/Code/Mantid/Framework/Crystal/src/SaveHKL.cpp b/Code/Mantid/Framework/Crystal/src/SaveHKL.cpp index 9547fe3be5f4..b11cc8805646 100644 --- a/Code/Mantid/Framework/Crystal/src/SaveHKL.cpp +++ b/Code/Mantid/Framework/Crystal/src/SaveHKL.cpp @@ -97,12 +97,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveHKL::initDocs() - { - this->setWikiSummary("Save a PeaksWorkspace to a ASCII .hkl file."); - this->setOptionalMessage("Save a PeaksWorkspace to a ASCII .hkl file."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/SaveIsawPeaks.cpp b/Code/Mantid/Framework/Crystal/src/SaveIsawPeaks.cpp index 3ac03bcb3cae..197fac0b50f4 100644 --- a/Code/Mantid/Framework/Crystal/src/SaveIsawPeaks.cpp +++ b/Code/Mantid/Framework/Crystal/src/SaveIsawPeaks.cpp @@ -51,12 +51,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveIsawPeaks::initDocs() - { - this->setWikiSummary("Save a PeaksWorkspace to a ISAW-style ASCII .peaks file."); - this->setOptionalMessage("Save a PeaksWorkspace to a ISAW-style ASCII .peaks file."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/SaveIsawUB.cpp b/Code/Mantid/Framework/Crystal/src/SaveIsawUB.cpp index b494729c5285..54e8e3aea902 100644 --- a/Code/Mantid/Framework/Crystal/src/SaveIsawUB.cpp +++ b/Code/Mantid/Framework/Crystal/src/SaveIsawUB.cpp @@ -57,12 +57,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveIsawUB::initDocs() - { - this->setWikiSummary("Save a UB matrix and lattice parameters from a workspace to an ISAW-style ASCII file."); - this->setOptionalMessage("Save a UB matrix and lattice parameters from a workspace to an ISAW-style ASCII file."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/SavePeaksFile.cpp b/Code/Mantid/Framework/Crystal/src/SavePeaksFile.cpp index 9752065fcbea..9f21c42c714e 100644 --- a/Code/Mantid/Framework/Crystal/src/SavePeaksFile.cpp +++ b/Code/Mantid/Framework/Crystal/src/SavePeaksFile.cpp @@ -32,12 +32,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SavePeaksFile::initDocs() - { - this->setWikiSummary("Save a PeaksWorkspace to a .peaks text-format file."); - this->setOptionalMessage("Save a PeaksWorkspace to a .peaks text-format file."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/SelectCellOfType.cpp b/Code/Mantid/Framework/Crystal/src/SelectCellOfType.cpp index 3d734c0ea0fe..6d353e48262a 100644 --- a/Code/Mantid/Framework/Crystal/src/SelectCellOfType.cpp +++ b/Code/Mantid/Framework/Crystal/src/SelectCellOfType.cpp @@ -60,20 +60,6 @@ namespace Crystal { } - //-------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SelectCellOfType::initDocs() - { - std::string summary("Select a conventional cell with a specific "); - summary += "lattice type and centering, corresponding to the UB "; - summary += "stored with the sample for this peaks works space."; - this->setWikiSummary( summary ); - - std::string message("NOTE: The current UB must correspond to a "); - message += "Niggli reduced cell."; - this->setOptionalMessage(message); - } - //-------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/Crystal/src/SelectCellWithForm.cpp b/Code/Mantid/Framework/Crystal/src/SelectCellWithForm.cpp index 8cbfaf38c1eb..2f107819dc1b 100644 --- a/Code/Mantid/Framework/Crystal/src/SelectCellWithForm.cpp +++ b/Code/Mantid/Framework/Crystal/src/SelectCellWithForm.cpp @@ -59,20 +59,6 @@ namespace Crystal { } - //-------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SelectCellWithForm::initDocs() - { - std::string summary("Select a conventional cell with a specific "); - summary += "form number, corresponding to the UB "; - summary += "stored with the sample for this peaks works space."; - this->setWikiSummary( summary ); - - std::string message("NOTE: The current UB must correspond to a "); - message += "Niggli reduced cell."; - this->setOptionalMessage(message); - } - //-------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/SetGoniometer.cpp b/Code/Mantid/Framework/Crystal/src/SetGoniometer.cpp index 9de88fcce855..ca2ce08e888d 100644 --- a/Code/Mantid/Framework/Crystal/src/SetGoniometer.cpp +++ b/Code/Mantid/Framework/Crystal/src/SetGoniometer.cpp @@ -59,12 +59,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SetGoniometer::initDocs() - { - this->setWikiSummary("Define the goniometer motors used in an experiment by giving the axes and directions of rotations."); - this->setOptionalMessage("Define the goniometer motors used in an experiment by giving the axes and directions of rotations."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/SetSpecialCoordinates.cpp b/Code/Mantid/Framework/Crystal/src/SetSpecialCoordinates.cpp index ab3159ae08f7..642a1d660415 100644 --- a/Code/Mantid/Framework/Crystal/src/SetSpecialCoordinates.cpp +++ b/Code/Mantid/Framework/Crystal/src/SetSpecialCoordinates.cpp @@ -77,12 +77,6 @@ namespace Crystal const std::string SetSpecialCoordinates::category() const { return "Crystal";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SetSpecialCoordinates::initDocs() - { - this->setWikiSummary("Set or overwrite any Q3D special coordinates."); - this->setOptionalMessage("Set or overwrite any Q3D special coordinates."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/SetUB.cpp b/Code/Mantid/Framework/Crystal/src/SetUB.cpp index 4ca5ac6bb149..e0f24543014b 100644 --- a/Code/Mantid/Framework/Crystal/src/SetUB.cpp +++ b/Code/Mantid/Framework/Crystal/src/SetUB.cpp @@ -62,12 +62,6 @@ namespace Crystal } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SetUB::initDocs() - { - this->setWikiSummary("Set the UB matrix, given either lattice parametersand orientation vectors or the UB matrix elements"); - this->setOptionalMessage("Set the UB matrix, given either lattice parametersand orientation vectors or the UB matrix elements"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/ShowPeakHKLOffsets.cpp b/Code/Mantid/Framework/Crystal/src/ShowPeakHKLOffsets.cpp index 146afed5768c..6e2cb82b4d0c 100644 --- a/Code/Mantid/Framework/Crystal/src/ShowPeakHKLOffsets.cpp +++ b/Code/Mantid/Framework/Crystal/src/ShowPeakHKLOffsets.cpp @@ -53,12 +53,6 @@ namespace Mantid } - void ShowPeakHKLOffsets::initDocs() - { - this->setWikiSummary("Displays offsets of h,k,and l from an integer along with bank and run number"); - this->setOptionalMessage(" Histograms, scatter plots, etc. of this data could be useful to detect calibration problems"); - } - void ShowPeakHKLOffsets::init() { declareProperty(new WorkspaceProperty("PeaksWorkspace", "", Direction::Input), diff --git a/Code/Mantid/Framework/Crystal/src/ShowPossibleCells.cpp b/Code/Mantid/Framework/Crystal/src/ShowPossibleCells.cpp index 1910f2b4bd74..7ccb80358119 100644 --- a/Code/Mantid/Framework/Crystal/src/ShowPossibleCells.cpp +++ b/Code/Mantid/Framework/Crystal/src/ShowPossibleCells.cpp @@ -53,19 +53,6 @@ namespace Crystal { } - //-------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ShowPossibleCells::initDocs() - { - std::string summary("Show conventional cells corresponding to the UB "); - summary += "stored with the sample for this peaks works space."; - this->setWikiSummary( summary ); - - std::string message("NOTE: The current UB must correspond to a "); - message += "Niggli reduced cell."; - this->setOptionalMessage(message); - } - //-------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/Crystal/src/SortHKL.cpp b/Code/Mantid/Framework/Crystal/src/SortHKL.cpp index db1048475b99..7a8071990565 100644 --- a/Code/Mantid/Framework/Crystal/src/SortHKL.cpp +++ b/Code/Mantid/Framework/Crystal/src/SortHKL.cpp @@ -49,12 +49,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SortHKL::initDocs() - { - this->setWikiSummary("Sorts a PeaksWorkspace by HKL. Averages intensities using point group."); - this->setOptionalMessage("Sorts a PeaksWorkspace by HKL. Averages intensities using point group."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/SortPeaksWorkspace.cpp b/Code/Mantid/Framework/Crystal/src/SortPeaksWorkspace.cpp index 3f05e8e842c5..5adddec7d1b8 100644 --- a/Code/Mantid/Framework/Crystal/src/SortPeaksWorkspace.cpp +++ b/Code/Mantid/Framework/Crystal/src/SortPeaksWorkspace.cpp @@ -67,12 +67,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SortPeaksWorkspace::initDocs() - { - this->setWikiSummary("Sort a peaks workspace by a column name of that workspace"); - this->setOptionalMessage("Sort a peaks workspace by a column of the workspace"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/TOFExtinction.cpp b/Code/Mantid/Framework/Crystal/src/TOFExtinction.cpp index 944ec6d24158..e955f20a76c8 100644 --- a/Code/Mantid/Framework/Crystal/src/TOFExtinction.cpp +++ b/Code/Mantid/Framework/Crystal/src/TOFExtinction.cpp @@ -68,12 +68,6 @@ namespace Crystal //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void TOFExtinction::initDocs() - { - this->setWikiSummary("Extinction correction for single crystal peaks."); - this->setOptionalMessage("Extinction correction for single crystal peaks."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/Crystal/src/TransformHKL.cpp b/Code/Mantid/Framework/Crystal/src/TransformHKL.cpp index 84009befc393..05cba9379cf0 100644 --- a/Code/Mantid/Framework/Crystal/src/TransformHKL.cpp +++ b/Code/Mantid/Framework/Crystal/src/TransformHKL.cpp @@ -59,20 +59,6 @@ namespace Crystal return "Crystal"; } - //-------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void TransformHKL::initDocs() - { - std::string summary("Adjust the UB stored with the sample to map the peak's "); - summary += "(HKL) vectors to M*(HKL)"; - this->setWikiSummary( summary ); - - std::string message("Specify a 3x3 matrix to apply to (HKL) vectors."); - message += " as a list of 9 comma separated numbers."; - message += " Both the UB and HKL values will be updated"; - this->setOptionalMessage( message ); - } - //-------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/CalculateGammaBackground.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/CalculateGammaBackground.h index ec594164fd25..fc935af9d970 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/CalculateGammaBackground.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/CalculateGammaBackground.h @@ -44,11 +44,13 @@ namespace Mantid ~CalculateGammaBackground(); const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculates the background due to gamma rays produced when neutrons are absorbed by shielding.";} + int version() const; const std::string category() const; private: - void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ConvertToYSpace.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ConvertToYSpace.h index 2086143a1e3e..3bbbfeaa2292 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ConvertToYSpace.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ConvertToYSpace.h @@ -50,6 +50,9 @@ namespace CurveFitting ConvertToYSpace(); const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts workspace in units of TOF to Y-space as defined in Compton scattering field";} + int version() const; const std::string category() const; @@ -66,7 +69,6 @@ namespace CurveFitting const DetectorParams & detpar); private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ConvolveWorkspaces.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ConvolveWorkspaces.h index 21085d1ac69f..f0f5995159f9 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ConvolveWorkspaces.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ConvolveWorkspaces.h @@ -47,13 +47,15 @@ class DLLExport ConvolveWorkspaces : public API::Algorithm virtual ~ConvolveWorkspaces(); /// Algorithm's name virtual const std::string name() const { return "ConvolveWorkspaces"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Convolution of two workspaces.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Utility\\Workspaces"; } private: - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/Fit.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/Fit.h index 8f2c223c54f8..6d293a8f4bb5 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/Fit.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/Fit.h @@ -90,14 +90,16 @@ namespace Mantid Fit() : API::Algorithm(),m_domainType(API::IDomainCreator::Simple) {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Fit";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fits a function to data in a Workspace";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Optimization";} protected: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/FitPowderDiffPeaks.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/FitPowderDiffPeaks.h index 3cebaca7bdfa..751c3e3dde56 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/FitPowderDiffPeaks.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/FitPowderDiffPeaks.h @@ -61,6 +61,9 @@ namespace CurveFitting /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "FitPowderDiffPeaks";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fit peaks in powder diffraction pattern. ";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} @@ -69,8 +72,7 @@ namespace CurveFitting virtual const std::string category() const { return "Diffraction";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); /// Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/LeBailFit.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/LeBailFit.h index 64b8dce9f936..8746c7adfefa 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/LeBailFit.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/LeBailFit.h @@ -87,6 +87,9 @@ namespace CurveFitting /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LeBailFit";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Do LeBail Fit to a spectrum of powder diffraction data. ";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} @@ -95,8 +98,7 @@ namespace CurveFitting virtual const std::string category() const { return "Diffraction";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); // Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/Lorentzian1D.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/Lorentzian1D.h index 1b5190819d34..003c3ed8af3f 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/Lorentzian1D.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/Lorentzian1D.h @@ -59,14 +59,16 @@ namespace Mantid virtual ~Lorentzian1D() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Lorentzian1D";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "== Deprecation notice == Instead of using this algorithm to fit a Lorentzian please use the Fit algorithm where the Function parameter of this algorithm is used to specified the fitting function, including selecting a Lorentzian.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Optimization\\FitFunctions";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Fit1D methods void declareParameters(); void function(const double* in, double* out, const double* xValues, const size_t nData); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/NormaliseByPeakArea.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/NormaliseByPeakArea.h index c65753fe5353..d2b0f963d486 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/NormaliseByPeakArea.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/NormaliseByPeakArea.h @@ -37,11 +37,13 @@ namespace Mantid NormaliseByPeakArea(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Normalises the input data by the area of of peak defined by the input mass value.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/PlotPeakByLogValue.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/PlotPeakByLogValue.h index 0c35604f807a..33aebd31dbc1 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/PlotPeakByLogValue.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/PlotPeakByLogValue.h @@ -96,14 +96,16 @@ namespace Mantid virtual ~PlotPeakByLogValue() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PlotPeakByLogValue";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fits a number of spectra with the same function.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Optimization";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ProcessBackground.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ProcessBackground.h index 765054cfe07b..e263d2c8b075 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ProcessBackground.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/ProcessBackground.h @@ -67,14 +67,17 @@ class DLLExport ProcessBackground : public API::Algorithm public: ProcessBackground(); virtual ~ProcessBackground(); - - virtual void initDocs(); - + virtual const std::string category() const {return "Diffraction\\Utility";} virtual const std::string name() const {return "ProcessBackground";} virtual int version() const {return 1;} + + ///Summary of algorithms purpose + virtual const std::string summary() const {return "ProcessBackground provides some tools to process powder diffraction pattern's " + "background in order to help Le Bail Fit.";} + private: /// Define properties diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/RefinePowderInstrumentParameters.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/RefinePowderInstrumentParameters.h index fdd8030a56b0..39064f47d73b 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/RefinePowderInstrumentParameters.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/RefinePowderInstrumentParameters.h @@ -58,6 +58,9 @@ namespace CurveFitting /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "RefinePowderInstrumentParameters";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Parameters include Dtt1, Dtt1t, Dtt2t, Zero, Zerot. ";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 2;} @@ -66,8 +69,7 @@ namespace CurveFitting virtual const std::string category() const { return "Diffraction";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); // Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/RefinePowderInstrumentParameters3.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/RefinePowderInstrumentParameters3.h index 6459decd911b..cac85bb232b2 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/RefinePowderInstrumentParameters3.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/RefinePowderInstrumentParameters3.h @@ -47,6 +47,9 @@ namespace CurveFitting /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "RefinePowderInstrumentParameters";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Parameters include Dtt1, Dtt1t, Dtt2t, Zero, Zerot. ";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 3;} @@ -55,8 +58,7 @@ namespace CurveFitting virtual const std::string category() const { return "Diffraction";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineBackground.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineBackground.h index c8d8deb6fce6..47dc79be3386 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineBackground.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineBackground.h @@ -50,10 +50,10 @@ class DLLExport SplineBackground : public API::Algorithm virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Optimization;CorrectionFunctions\\BackgroundCorrections";} - + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fit spectra background using b-splines.";} + private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineInterpolation.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineInterpolation.h index 9acb01b909b7..eee8220bdce0 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineInterpolation.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineInterpolation.h @@ -50,9 +50,10 @@ namespace CurveFitting virtual const std::string name() const; virtual int version() const; virtual const std::string category() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Interpolates a set of spectra onto a spline defined by a second input workspace. Optionally, this algorithm can also calculate derivatives up to order 2 as a side product";} private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineSmoothing.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineSmoothing.h index 23ed0797d685..e078b7ce9c4b 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineSmoothing.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/SplineSmoothing.h @@ -46,6 +46,8 @@ namespace CurveFitting virtual const std::string name() const; virtual int version() const; virtual const std::string category() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Smoothes a set of spectra using a cubic spline. Optionally, this algorithm can also calculate derivatives up to order 2 as a side product";} private: @@ -56,7 +58,6 @@ namespace CurveFitting boost::shared_ptr m_cspline; //Overriden methods - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/UserFunction1D.h b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/UserFunction1D.h index 166c9923531e..a2fbf12379ea 100644 --- a/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/UserFunction1D.h +++ b/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/UserFunction1D.h @@ -76,8 +76,8 @@ namespace Mantid virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Optimization\\FitFunctions";} - - + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fits a histogram from a workspace to a user defined function.";} protected: /// overwrite base class methods //double function(const double* in, const double& x); @@ -91,8 +91,6 @@ namespace Mantid static double* AddVariable(const char *varName, void *palg); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// muParser instance mu::Parser m_parser; /// Used as 'x' variable in m_parser. diff --git a/Code/Mantid/Framework/CurveFitting/src/CalculateGammaBackground.cpp b/Code/Mantid/Framework/CurveFitting/src/CalculateGammaBackground.cpp index 3cb3b512a74f..c1329b14d724 100644 --- a/Code/Mantid/Framework/CurveFitting/src/CalculateGammaBackground.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/CalculateGammaBackground.cpp @@ -89,12 +89,6 @@ namespace Mantid return "CorrectionFunctions"; } - void CalculateGammaBackground::initDocs() - { - this->setWikiSummary("Calculates the background due to gamma rays produced when neutrons are absorbed by shielding"); - this->setOptionalMessage("Calculates the background due to gamma rays produced when neutrons are absorbed by shielding."); - } - void CalculateGammaBackground::init() { diff --git a/Code/Mantid/Framework/CurveFitting/src/ConvertToYSpace.cpp b/Code/Mantid/Framework/CurveFitting/src/ConvertToYSpace.cpp index 28e7d5f5ba00..26583fcf430c 100644 --- a/Code/Mantid/Framework/CurveFitting/src/ConvertToYSpace.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/ConvertToYSpace.cpp @@ -54,12 +54,6 @@ namespace Mantid const std::string ConvertToYSpace::category() const { return "Transforms\\Units";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ConvertToYSpace::initDocs() - { - this->setWikiSummary("Converts workspace in units of TOF to Y-space as defined in Compton scattering field"); - this->setOptionalMessage("Converts workspace in units of TOF to Y-space as defined in Compton scattering field"); - } //---------------------------------------------------------------------------------------------- /** diff --git a/Code/Mantid/Framework/CurveFitting/src/ConvolveWorkspaces.cpp b/Code/Mantid/Framework/CurveFitting/src/ConvolveWorkspaces.cpp index 2ef076361a66..d30ae52af163 100644 --- a/Code/Mantid/Framework/CurveFitting/src/ConvolveWorkspaces.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/ConvolveWorkspaces.cpp @@ -23,13 +23,6 @@ namespace CurveFitting // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ConvolveWorkspaces) -/// Sets documentation strings for this algorithm -void ConvolveWorkspaces::initDocs() -{ - this->setWikiSummary("Convolution of two workspaces. "); - this->setOptionalMessage("Convolution of two workspaces."); -} - /// Constructor ConvolveWorkspaces::ConvolveWorkspaces() : API::Algorithm(), prog(NULL) {} diff --git a/Code/Mantid/Framework/CurveFitting/src/Fit.cpp b/Code/Mantid/Framework/CurveFitting/src/Fit.cpp index d3bc29a51895..635eb7a047a4 100644 --- a/Code/Mantid/Framework/CurveFitting/src/Fit.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/Fit.cpp @@ -275,13 +275,6 @@ namespace CurveFitting bool isStringEmpty(const std::string& str){return str.empty();} } - /// Sets documentation strings for this algorithm - void Fit::initDocs() - { - this->setWikiSummary("Fits a function to data in a Workspace "); - this->setOptionalMessage("Fits a function to data in a Workspace"); - } - /** * Examine "Function" and "InputWorkspace" properties to decide which domain creator to use. * @param propName :: A property name. diff --git a/Code/Mantid/Framework/CurveFitting/src/FitPowderDiffPeaks.cpp b/Code/Mantid/Framework/CurveFitting/src/FitPowderDiffPeaks.cpp index 803a60afd8a0..ac95b0aa477c 100644 --- a/Code/Mantid/Framework/CurveFitting/src/FitPowderDiffPeaks.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/FitPowderDiffPeaks.cpp @@ -143,12 +143,7 @@ namespace CurveFitting //---------------------------------------------------------------------------------------------- /** Set up documention - */ - void FitPowderDiffPeaks::initDocs() - { - setWikiSummary("Fit peaks in powder diffraction pattern. "); - setOptionalMessage("Fit peaks in powder diffraction pattern. "); - } + * //---------------------------------------------------------------------------------------------- /** Parameter declaration diff --git a/Code/Mantid/Framework/CurveFitting/src/LeBailFit.cpp b/Code/Mantid/Framework/CurveFitting/src/LeBailFit.cpp index b3c8b3e07d77..aadd8ccb53f7 100644 --- a/Code/Mantid/Framework/CurveFitting/src/LeBailFit.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/LeBailFit.cpp @@ -105,12 +105,7 @@ namespace CurveFitting //---------------------------------------------------------------------------------------------- /** Sets documentation strings for this algorithm - */ - void LeBailFit::initDocs() - { - setWikiSummary("Do LeBail Fit to a spectrum of powder diffraction data.. "); - setOptionalMessage("Do LeBail Fit to a spectrum of powder diffraction data. "); - } + * //---------------------------------------------------------------------------------------------- /** Declare the input properties for this algorithm diff --git a/Code/Mantid/Framework/CurveFitting/src/Lorentzian1D.cpp b/Code/Mantid/Framework/CurveFitting/src/Lorentzian1D.cpp index 7be22bec8e92..3bd716ee07ac 100644 --- a/Code/Mantid/Framework/CurveFitting/src/Lorentzian1D.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/Lorentzian1D.cpp @@ -38,13 +38,6 @@ using API::Jacobian; // Register the class into the algorithm factory DECLARE_ALGORITHM(Lorentzian1D) -/// Sets documentation strings for this algorithm -void Lorentzian1D::initDocs() -{ - this->setWikiSummary("== Deprecation notice == Instead of using this algorithm to fit a Lorentzian please use the [[Fit]] algorithm where the Function parameter of this algorithm is used to specified the fitting function, including selecting a [[Lorentzian]]."); - this->setOptionalMessage("== Deprecation notice == Instead of using this algorithm to fit a Lorentzian please use the Fit algorithm where the Function parameter of this algorithm is used to specified the fitting function, including selecting a Lorentzian."); -} - using namespace Kernel; diff --git a/Code/Mantid/Framework/CurveFitting/src/NormaliseByPeakArea.cpp b/Code/Mantid/Framework/CurveFitting/src/NormaliseByPeakArea.cpp index ba994cdcf009..5442ca6b65dc 100644 --- a/Code/Mantid/Framework/CurveFitting/src/NormaliseByPeakArea.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/NormaliseByPeakArea.cpp @@ -60,12 +60,6 @@ namespace Mantid const std::string NormaliseByPeakArea::category() const { return "Corrections"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void NormaliseByPeakArea::initDocs() - { - this->setWikiSummary("Normalises the input data by the area of of peak defined by the input mass value."); - this->setOptionalMessage("Normalises the input data by the area of of peak defined by the input mass value."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/CurveFitting/src/PlotPeakByLogValue.cpp b/Code/Mantid/Framework/CurveFitting/src/PlotPeakByLogValue.cpp index e8cde7b01513..28d460063336 100644 --- a/Code/Mantid/Framework/CurveFitting/src/PlotPeakByLogValue.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/PlotPeakByLogValue.cpp @@ -61,13 +61,6 @@ namespace Mantid // Register the class into the algorithm factory DECLARE_ALGORITHM(PlotPeakByLogValue) - /// Sets documentation strings for this algorithm - void PlotPeakByLogValue::initDocs() - { - this->setWikiSummary("Fits a number of spectra with the same function. "); - this->setOptionalMessage("Fits a number of spectra with the same function."); - } - /** Initialisation method. Declares properties to be used in algorithm. * diff --git a/Code/Mantid/Framework/CurveFitting/src/ProcessBackground.cpp b/Code/Mantid/Framework/CurveFitting/src/ProcessBackground.cpp index 41a152b2bb91..8341a2c1a687 100644 --- a/Code/Mantid/Framework/CurveFitting/src/ProcessBackground.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/ProcessBackground.cpp @@ -79,14 +79,6 @@ DECLARE_ALGORITHM(ProcessBackground) { } - void ProcessBackground::initDocs() - { - this->setWikiSummary("ProcessBackground provides some tools to process powder diffraction pattern's " - "background in order to help Le Bail Fit."); - this->setOptionalMessage("ProcessBackground provides some tools to process powder diffraction pattern's " - "background in order to help Le Bail Fit."); - } - //---------------------------------------------------------------------------------------------- /** Define parameters */ diff --git a/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters.cpp b/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters.cpp index e3e5e5f77d82..c83682905da8 100644 --- a/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters.cpp @@ -60,12 +60,7 @@ namespace CurveFitting //---------------------------------------------------------------------------------------------- /** Set up documention - */ - void RefinePowderInstrumentParameters::initDocs() - { - setWikiSummary("Refine the instrument geometry related parameters for powder diffractomer. "); - setOptionalMessage("Parameters include Dtt1, Dtt1t, Dtt2t, Zero, Zerot. "); - } + * //---------------------------------------------------------------------------------------------- /** Parameter declaration diff --git a/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters3.cpp b/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters3.cpp index 9ac9477dbcf9..b3dfdfb1abd4 100644 --- a/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters3.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters3.cpp @@ -71,12 +71,7 @@ namespace CurveFitting //---------------------------------------------------------------------------------------------- /** Set up documention - */ - void RefinePowderInstrumentParameters3::initDocs() - { - setWikiSummary("Refine the instrument geometry related parameters for powder diffractomer. "); - setOptionalMessage("Parameters include Dtt1, Dtt1t, Dtt2t, Zero, Zerot. "); - } + * //---------------------------------------------------------------------------------------------- /** Declare properties diff --git a/Code/Mantid/Framework/CurveFitting/src/SplineBackground.cpp b/Code/Mantid/Framework/CurveFitting/src/SplineBackground.cpp index 770eecab1750..125fa34f52e2 100644 --- a/Code/Mantid/Framework/CurveFitting/src/SplineBackground.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/SplineBackground.cpp @@ -21,12 +21,6 @@ namespace CurveFitting DECLARE_ALGORITHM(SplineBackground) -/// Sets documentation strings for this algorithm -void SplineBackground::initDocs() -{ - this->setWikiSummary("Fit spectra background using b-splines. "); - this->setOptionalMessage("Fit spectra background using b-splines."); -} using namespace Kernel; diff --git a/Code/Mantid/Framework/CurveFitting/src/SplineInterpolation.cpp b/Code/Mantid/Framework/CurveFitting/src/SplineInterpolation.cpp index 459d611eff38..b9f0c346e379 100644 --- a/Code/Mantid/Framework/CurveFitting/src/SplineInterpolation.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/SplineInterpolation.cpp @@ -56,14 +56,6 @@ namespace Mantid /// Algorithm's category for identification. @see Algorithm::category const std::string SplineInterpolation::category() const{ return "Optimization;CorrectionFunctions\\BackgroundCorrections"; } - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SplineInterpolation::initDocs() - { - this->setWikiSummary("Interpolates a set of spectra onto a spline defined by a second input workspace. Optionally, this algorithm can also calculate derivatives up to order 2 as a side product"); - this->setOptionalMessage("Interpolates a set of spectra onto a spline defined by a second input workspace. Optionally, this algorithm can also calculate derivatives up to order 2 as a side product"); - } - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/CurveFitting/src/SplineSmoothing.cpp b/Code/Mantid/Framework/CurveFitting/src/SplineSmoothing.cpp index 0f054bdeb3f6..148c35abdde0 100644 --- a/Code/Mantid/Framework/CurveFitting/src/SplineSmoothing.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/SplineSmoothing.cpp @@ -58,14 +58,6 @@ namespace CurveFitting /// Algorithm's category for identification. @see Algorithm::category const std::string SplineSmoothing::category() const { return "Optimization;CorrectionFunctions\\BackgroundCorrections";} - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SplineSmoothing::initDocs() - { - this->setWikiSummary("Smoothes a set of spectra using a cubic spline. Optionally, this algorithm can also calculate derivatives up to order 2 as a side product"); - this->setOptionalMessage("Smoothes a set of spectra using a cubic spline. Optionally, this algorithm can also calculate derivatives up to order 2 as a side product"); - } - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/CurveFitting/src/UserFunction1D.cpp b/Code/Mantid/Framework/CurveFitting/src/UserFunction1D.cpp index 406ab0189387..0462a0fa21ce 100644 --- a/Code/Mantid/Framework/CurveFitting/src/UserFunction1D.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/UserFunction1D.cpp @@ -85,14 +85,6 @@ namespace CurveFitting // Register the class into the algorithm factory DECLARE_ALGORITHM(UserFunction1D) -/// Sets documentation strings for this algorithm -void UserFunction1D::initDocs() -{ - this->setWikiSummary("Fits a histogram from a workspace to a user defined function. "); - this->setOptionalMessage("Fits a histogram from a workspace to a user defined function."); -} - - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/AppendGeometryToSNSNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/AppendGeometryToSNSNexus.h index a992b6cedbaa..1424959dee83 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/AppendGeometryToSNSNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/AppendGeometryToSNSNexus.h @@ -40,11 +40,13 @@ namespace DataHandling virtual ~AppendGeometryToSNSNexus(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Appends the resolved instrument geometry (detectors and monitors for now) to a SNS ADARA NeXus file.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/AsciiPointBase.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/AsciiPointBase.h index ccabca4db26c..6f938b48bf91 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/AsciiPointBase.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/AsciiPointBase.h @@ -52,8 +52,6 @@ namespace Mantid virtual const std::string category() const { return "DataHandling\\Text"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs() = 0; /// Return the file extension this algorthm should output. virtual std::string ext() = 0; /// return if the line should start with a separator diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CompressEvents.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CompressEvents.h index 7e87f50d6927..ffff72f56592 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CompressEvents.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CompressEvents.h @@ -49,14 +49,16 @@ class DLLExport CompressEvents : public API::Algorithm /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CompressEvents";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Reduce the number of events in an EventWorkspace by grouping together events with identical or similar X-values (time-of-flight).";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Events";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Implement abstract Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateChopperModel.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateChopperModel.h index 2ca130890acd..ff4c6440a5e8 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateChopperModel.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateChopperModel.h @@ -38,11 +38,13 @@ namespace Mantid public: virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates a chopper model for a given workspace";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateModeratorModel.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateModeratorModel.h index c1f487252bcc..75c3db185c09 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateModeratorModel.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateModeratorModel.h @@ -35,11 +35,13 @@ namespace Mantid public: virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates the given moderator model and attaches it to the input workspace.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateSampleShape.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateSampleShape.h index bb86dca5cbd0..f2d6a9d94d0d 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateSampleShape.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateSampleShape.h @@ -47,14 +47,16 @@ class DLLExport CreateSampleShape : public Mantid::API::Algorithm virtual ~CreateSampleShape() {} /// Algorithm's name virtual const std::string name() const { return "CreateSampleShape"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create a shape object to model the sample.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Sample;DataHandling"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateSimulationWorkspace.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateSimulationWorkspace.h index ca48e21d9d47..d8673a75e57a 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateSimulationWorkspace.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/CreateSimulationWorkspace.h @@ -36,11 +36,13 @@ namespace Mantid public: virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create a blank workspace for a given instrument.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DefineGaugeVolume.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DefineGaugeVolume.h index e8264f3507d0..3a504df5e9b7 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DefineGaugeVolume.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DefineGaugeVolume.h @@ -47,14 +47,16 @@ class DLLExport DefineGaugeVolume : public API::Algorithm virtual ~DefineGaugeVolume() {} /// Algorithm's name virtual const std::string name() const { return "DefineGaugeVolume"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Defines a geometrical shape object to be used as the gauge volume in the AbsorptionCorrection algorithm.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Sample"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DeleteTableRows.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DeleteTableRows.h index 6a9acaed346e..02c4ddaa3758 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DeleteTableRows.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DeleteTableRows.h @@ -44,14 +44,16 @@ namespace Mantid DeleteTableRows(){} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "DeleteTableRows"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Deletes rows from a TableWorkspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Category virtual const std::string category() const { return "Utility\\Workspaces"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialize the static base properties void init(); /// Execute diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DetermineChunking.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DetermineChunking.h index 4f2975258a19..4184db28122d 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DetermineChunking.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/DetermineChunking.h @@ -67,10 +67,12 @@ class DLLExport DetermineChunking : public API::Algorithm virtual ~DetermineChunking(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Workflow algorithm to determine chunking strategy for event nexus, runinfo.xml, raw, or histo nexus files.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); std::string setTopEntryName(std::string filename); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/FilterEventsByLogValuePreNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/FilterEventsByLogValuePreNexus.h index 5a7612018ed8..3f0a30de6be8 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/FilterEventsByLogValuePreNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/FilterEventsByLogValuePreNexus.h @@ -109,14 +109,14 @@ class DLLExport FilterEventsByLogValuePreNexus : public API::IFileLoader virtual ~LoadDaveGrp() {} /// Algorithm's name virtual const std::string name() const { return "LoadDaveGrp"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads data from a DAVE grouped ASCII file and stores it in a 2D workspace (Workspace2D class).";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -59,8 +62,7 @@ class DLLExport LoadDaveGrp : public API::IFileLoader virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialization code void init(); /// Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDetectorInfo.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDetectorInfo.h index e6f420f8e459..fb149c26d47e 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDetectorInfo.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDetectorInfo.h @@ -39,6 +39,9 @@ namespace Mantid /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadDetectorInfo"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads delay times, tube pressures and tube wall thicknesses from a given file.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -57,7 +60,6 @@ namespace Mantid std::vector pressures, thicknesses; }; - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDetectorsGroupingFile.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDetectorsGroupingFile.h index a8a5ba52c891..ff4bd7da3dd6 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDetectorsGroupingFile.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDetectorsGroupingFile.h @@ -54,14 +54,16 @@ namespace DataHandling /// virtual const std::string name() const { return "LoadDetectorsGroupingFile";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load an XML or Map file, which contains definition of detectors grouping, to a GroupingWorkspace).";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "DataHandling;Transforms\\Grouping";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDspacemap.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDspacemap.h index 79ae0c6c001f..02d887bb5381 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDspacemap.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadDspacemap.h @@ -25,14 +25,16 @@ namespace DataHandling /// Algorithm's name for identification virtual const std::string name() const { return "LoadDspacemap";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a Dspacemap file (POWGEN binary, VULCAN binary or ascii format) into an OffsetsWorkspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "DataHandling";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEmptyInstrument.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEmptyInstrument.h index 33af46b13d74..b2c616fb923b 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEmptyInstrument.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEmptyInstrument.h @@ -61,6 +61,9 @@ namespace Mantid LoadEmptyInstrument(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadEmptyInstrument"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads an Instrument Definition File (IDF) into a workspace rather than a data file.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -69,8 +72,7 @@ namespace Mantid virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEventNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEventNexus.h index c7e36dc77c09..5e150a105850 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEventNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEventNexus.h @@ -71,12 +71,14 @@ namespace Mantid class DLLExport LoadEventNexus : public API::IFileLoader { public: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + LoadEventNexus(); virtual ~LoadEventNexus(); virtual const std::string name() const { return "LoadEventNexus";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads Event NeXus files (produced by the SNS) and stores it in an EventWorkspace. Optionally, you can filter out events falling outside a range of times-of-flight and/or a time interval.";} + virtual int version() const { return 1;}; virtual const std::string category() const { return "DataHandling\\Nexus";} diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEventPreNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEventPreNexus.h index 432fee7eed39..5bbf26d371ba 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEventPreNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadEventPreNexus.h @@ -105,6 +105,9 @@ class DLLExport LoadEventPreNexus : public API::IFileLoader Code Documentation is available at: - */ - class DLLExport LoadFullprofResolution : public API::Algorithm - { - public: - LoadFullprofResolution(); - virtual ~LoadFullprofResolution(); + */ + class DLLExport LoadFullprofResolution : public API::Algorithm + { + public: + LoadFullprofResolution(); + virtual ~LoadFullprofResolution(); + + /// Algorithm's name for identification overriding a virtual method + virtual const std::string name() const { return "LoadFullprofResolution";} - /// Algorithm's name for identification overriding a virtual method - virtual const std::string name() const { return "LoadFullprofResolution";} + /// Algorithm's version for identification overriding a virtual method + virtual int version() const { return 1;} - /// Algorithm's version for identification overriding a virtual method - virtual int version() const { return 1;} + /// Algorithm's category for identification overriding a virtual method + virtual const std::string category() const { return "Diffraction";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load Fullprof's resolution (.irf) file to one or multiple TableWorkspace(s) and/or where this is supported." + " See description section, translate fullprof resolution fitting parameter into Mantid equivalent fitting parameters.";} - /// Algorithm's category for identification overriding a virtual method - virtual const std::string category() const { return "Diffraction";} + private: + /// Implement abstract Algorithm methods + void init(); + /// Implement abstract Algorithm methods + void exec(); - private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); - /// Implement abstract Algorithm methods - void init(); - /// Implement abstract Algorithm methods - void exec(); + /// Load file to a vector of strings + void loadFile(std::string filename, std::vector& lines); - /// Load file to a vector of strings - void loadFile(std::string filename, std::vector& lines); + /// Get the NPROF number + int getProfNumber( const std::vector& lines ); - /// Get the NPROF number - int getProfNumber( const std::vector& lines ); + /// Scan imported file for bank information + void scanBanks(const std::vector& lines, const bool useBankIDsInFile, std::vector& banks, + std::map &bankstartindexmap, std::map &bankendindexmap ); - /// Scan imported file for bank information - void scanBanks(const std::vector& lines, const bool useBankIDsInFile, std::vector& banks, - std::map &bankstartindexmap, std::map &bankendindexmap ); + /// Parse .irf file to a map + void parseResolutionStrings(std::map& parammap, const std::vector& lines, const bool useBankIDsInFile, int bankid, int startlineindex, int endlineindex, int nProf); - /// Parse .irf file to a map - void parseResolutionStrings(std::map& parammap, const std::vector& lines, const bool useBankIDsInFile, int bankid, int startlineindex, int endlineindex, int nProf); - - void parseBankLine(std::string line, double& cwl, int& bankid); + void parseBankLine(std::string line, double& cwl, int& bankid); - /// Search token for profile number - int searchProfile(); + /// Search token for profile number + int searchProfile(); - /// Parse 1 bank of lines of profile 9 - void parseProfile9(); + /// Parse 1 bank of lines of profile 9 + void parseProfile9(); - /// Parse 1 bank of lines of profile 10 - void parseProfile10(); + /// Parse 1 bank of lines of profile 10 + void parseProfile10(); - /// Generate output workspace - DataObjects::TableWorkspace_sptr genTableWorkspace(std::map > bankparammap); + /// Generate output workspace + DataObjects::TableWorkspace_sptr genTableWorkspace(std::map > bankparammap); - /// Generate bank information workspace - DataObjects::TableWorkspace_sptr genInfoTableWorkspace(std::vector banks); + /// Generate bank information workspace + DataObjects::TableWorkspace_sptr genInfoTableWorkspace(std::vector banks); - /// Create Bank to Workspace Correspondence - void createBankToWorkspaceMap ( const std::vector& banks, const std::vector& workspaces, std::map< int, size_t>& WorkpsaceOfBank ); + /// Create Bank to Workspace Correspondence + void createBankToWorkspaceMap ( const std::vector& banks, const std::vector& workspaces, std::map< int, size_t>& WorkpsaceOfBank ); - /// Put parameters into a matrix workspace - void putParametersIntoWorkspace( const API::Column_const_sptr, API::MatrixWorkspace_sptr ws, int profNumber); + /// Put parameters into a matrix workspace + void putParametersIntoWorkspace( const API::Column_const_sptr, API::MatrixWorkspace_sptr ws, int profNumber); - /// Add an Ikeda-Carpenter PV ALFBE parameter - void addALFBEParameter(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent, const std::string& paramName); + /// Add an Ikeda-Carpenter PV ALFBE parameter + void addALFBEParameter(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent, const std::string& paramName); - /// Add set of Ikeda-Carpenter PV Sigma parameters - void addSigmaParameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); + /// Add set of Ikeda-Carpenter PV Sigma parameters + void addSigmaParameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); - /// Add set of Ikeda-Carpenter PV Gamma parameters - void addGammaParameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); + /// Add set of Ikeda-Carpenter PV Gamma parameters + void addGammaParameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); - /// Add set of BackToBackExponential S parameters - void addBBX_S_Parameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); + /// Add set of BackToBackExponential S parameters + void addBBX_S_Parameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); - /// Add set of BackToBackExponential A parameters - void addBBX_A_Parameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); + /// Add set of BackToBackExponential A parameters + void addBBX_A_Parameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); - /// Add set of BackToBackExponential B parameters - void addBBX_B_Parameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); + /// Add set of BackToBackExponential B parameters + void addBBX_B_Parameters(const API::Column_const_sptr, Poco::XML::Document* mDoc, Poco::XML::Element* parent ); - /// Get value for XML eq attribute for parameter - std::string getXMLEqValue( const API::Column_const_sptr, const std::string& name ); + /// Get value for XML eq attribute for parameter + std::string getXMLEqValue( const API::Column_const_sptr, const std::string& name ); - /// Get value for XML eq attribute for squared parameter - std::string getXMLSquaredEqValue( const API::Column_const_sptr column, const std::string& name ); + /// Get value for XML eq attribute for squared parameter + std::string getXMLSquaredEqValue( const API::Column_const_sptr column, const std::string& name ); - // Translate a parameter name from as it appears in the table workspace to its name in the XML file - std::string getXMLParameterName( const std::string& name ); + // Translate a parameter name from as it appears in the table workspace to its name in the XML file + std::string getXMLParameterName( const std::string& name ); - /// Get row numbers of the parameters in the table workspace - void getTableRowNumbers(const API::ITableWorkspace_sptr & tablews, std::map& parammap); + /// Get row numbers of the parameters in the table workspace + void getTableRowNumbers(const API::ITableWorkspace_sptr & tablews, std::map& parammap); - /// Place to store the row numbers - std::map m_rowNumbers; + /// Place to store the row numbers + std::map m_rowNumbers; - }; + }; -} // namespace DataHandling + } // namespace DataHandling } // namespace Mantid #endif /* MANTID_DATAHANDLING_LOADFULLPROFRESOLUTION_H_ */ diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadGSASInstrumentFile.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadGSASInstrumentFile.h index a3cceae6d370..a4a6bdbf789a 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadGSASInstrumentFile.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadGSASInstrumentFile.h @@ -45,6 +45,9 @@ namespace DataHandling /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadGSASInstrumentFile";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load parameters from a GSAS Instrument file.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} @@ -53,8 +56,7 @@ namespace DataHandling virtual const std::string category() const { return "Diffraction";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); /// Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadGSS.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadGSS.h index 7e3ac71f6d7b..571b63ad4799 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadGSS.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadGSS.h @@ -45,6 +45,9 @@ class DLLExport LoadGSS : public API::IFileLoader virtual ~LoadGSS() {} /// Algorithm's name virtual const std::string name() const { return "LoadGSS"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a GSS file such as that saved by SaveGSS. This is not a lossless process, as SaveGSS truncates some data. There is no instrument assosciated with the resulting workspace. 'Please Note': Due to limitations of the GSS file format, the process of going from Mantid to a GSS file and back is not perfect.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -54,8 +57,7 @@ class DLLExport LoadGSS : public API::IFileLoader virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadIDFFromNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadIDFFromNexus.h index 3e7e8bfaac0b..046ff3d19dd0 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadIDFFromNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadIDFFromNexus.h @@ -58,6 +58,9 @@ namespace Mantid /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadIDFFromNexus";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load an IDF from a Nexus file, if found there. You may need to tell this algorithm where to find the Instrument folder in the Nexus file";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} @@ -66,8 +69,7 @@ namespace Mantid virtual const std::string category() const { return "DataHandling\\Instrument";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. Does nothing at present void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILL.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILL.h index 8bc13a44b1a7..958218639d5e 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILL.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILL.h @@ -9,114 +9,115 @@ #include "MantidDataHandling/LoadHelper.h" namespace Mantid { -namespace DataHandling { -/** - Loads an ILL nexus file into a Mantid workspace. - - Required properties: -

    -
  • Filename - The ILL nexus file to be read
  • -
  • Workspace - The name to give to the output workspace
  • -
- - Copyright © 2010 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory - - This file is part of Mantid. - - Mantid is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - Mantid is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - - File change history is stored at: - Code Documentation is available at: - */ - class DLLExport LoadILL: public API::IFileLoader - { - public: - /// Constructor - LoadILL(); /// Virtual destructor - virtual ~LoadILL() { - } - /// Algorithm's name - virtual const std::string name() const { - return "LoadILL"; - } - /// Algorithm's version - virtual int version() const { - return (1); - } - /// Algorithm's category for identification - virtual const std::string category() const { - return "DataHandling"; - } - - /// Returns a confidence value that this algorithm can load a file - int confidence(Kernel::NexusDescriptor & descriptor) const; - -private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); - // Initialisation code - void init(); - // Execution code - void exec(); - - int getEPPFromVanadium(const std::string &,Mantid::API::MatrixWorkspace_sptr); - void loadInstrumentDetails(NeXus::NXEntry&); - void initWorkSpace(NeXus::NXEntry& entry); - void initInstrumentSpecific(); - void loadRunDetails(NeXus::NXEntry & entry); - void loadExperimentDetails(NeXus::NXEntry & entry); - int getDetectorElasticPeakPosition(const NeXus::NXInt &data); - void loadTimeDetails(NeXus::NXEntry& entry); - NeXus::NXData loadNexusFileData(NeXus::NXEntry& entry); - void loadDataIntoTheWorkSpace(NeXus::NXEntry& entry, int vanaCalculatedDetectorElasticPeakPosition = -1); - - void runLoadInstrument(); - - /// Calculate error for y - static double calculateError(double in) { - return sqrt(in); - } - int validateVanadium(const std::string &); - - API::MatrixWorkspace_sptr m_localWorkspace; - -// NeXus::NXRoot m_dataRoot; -// NeXus::NXRoot m_vanaRoot; - - std::string m_instrumentName; ///< Name of the instrument - std::string m_instrumentPath; ///< Name of the instrument path - - // Variables describing the data in the detector - size_t m_numberOfTubes; // number of tubes - X - size_t m_numberOfPixelsPerTube; //number of pixels per tube - Y - size_t m_numberOfChannels; // time channels - Z - size_t m_numberOfHistograms; - - /* Values parsed from the nexus file */ - int m_monitorElasticPeakPosition; - double m_wavelength; - double m_channelWidth; - - double m_l1; //=2.0; - double m_l2; //=4.0; - - std::vector m_supportedInstruments; - LoadHelper m_loader; - -}; - -} // namespace DataHandling + namespace DataHandling { + /** + Loads an ILL nexus file into a Mantid workspace. + + Required properties: +
    +
  • Filename - The ILL nexus file to be read
  • +
  • Workspace - The name to give to the output workspace
  • +
+ + Copyright © 2010 ISIS Rutherford Appleton Laboratory & NScD Oak Ridge National Laboratory + + This file is part of Mantid. + + Mantid is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + Mantid is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + + File change history is stored at: + Code Documentation is available at: + */ + class DLLExport LoadILL: public API::IFileLoader + { + public: + /// Constructor + LoadILL(); /// Virtual destructor + virtual ~LoadILL() { + } + /// Algorithm's name + virtual const std::string name() const { + return "LoadILL"; + } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a ILL nexus file.";} + /// Algorithm's version + virtual int version() const { + return (1); + } + /// Algorithm's category for identification + virtual const std::string category() const { + return "DataHandling"; + } + + /// Returns a confidence value that this algorithm can load a file + int confidence(Kernel::NexusDescriptor & descriptor) const; + + private: + + // Initialisation code + void init(); + // Execution code + void exec(); + + int getEPPFromVanadium(const std::string &,Mantid::API::MatrixWorkspace_sptr); + void loadInstrumentDetails(NeXus::NXEntry&); + void initWorkSpace(NeXus::NXEntry& entry); + void initInstrumentSpecific(); + void loadRunDetails(NeXus::NXEntry & entry); + void loadExperimentDetails(NeXus::NXEntry & entry); + int getDetectorElasticPeakPosition(const NeXus::NXInt &data); + void loadTimeDetails(NeXus::NXEntry& entry); + NeXus::NXData loadNexusFileData(NeXus::NXEntry& entry); + void loadDataIntoTheWorkSpace(NeXus::NXEntry& entry, int vanaCalculatedDetectorElasticPeakPosition = -1); + + void runLoadInstrument(); + + /// Calculate error for y + static double calculateError(double in) { + return sqrt(in); + } + int validateVanadium(const std::string &); + + API::MatrixWorkspace_sptr m_localWorkspace; + + // NeXus::NXRoot m_dataRoot; + // NeXus::NXRoot m_vanaRoot; + + std::string m_instrumentName; ///< Name of the instrument + std::string m_instrumentPath; ///< Name of the instrument path + + // Variables describing the data in the detector + size_t m_numberOfTubes; // number of tubes - X + size_t m_numberOfPixelsPerTube; //number of pixels per tube - Y + size_t m_numberOfChannels; // time channels - Z + size_t m_numberOfHistograms; + + /* Values parsed from the nexus file */ + int m_monitorElasticPeakPosition; + double m_wavelength; + double m_channelWidth; + + double m_l1; //=2.0; + double m_l2; //=4.0; + + std::vector m_supportedInstruments; + LoadHelper m_loader; + + }; + + } // namespace DataHandling } // namespace Mantid #endif /*MANTID_DATAHANDLING_LoadILL_H_*/ diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILLIndirect.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILLIndirect.h index 509886c21be8..e6ad31a2d8d8 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILLIndirect.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILLIndirect.h @@ -42,11 +42,13 @@ namespace DataHandling int confidence(Kernel::NexusDescriptor & descriptor) const; virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a ILL/IN16B nexus file.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILLSANS.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILLSANS.h index 8db17d6c4dea..a67decc4782a 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILLSANS.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadILLSANS.h @@ -60,13 +60,15 @@ class DLLExport LoadILLSANS: public API::IFileLoader { virtual ~LoadILLSANS(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a ILL nexus files for SANS instruments.";} + virtual int version() const; virtual const std::string category() const; /// Returns a confidence value that this algorithm can load a file int confidence(Kernel::NexusDescriptor & descriptor) const; private: - virtual void initDocs(); void init(); void exec(); void setInstrumentName(const NeXus::NXEntry&, const std::string&); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadISISNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadISISNexus.h index 2e23699d8c04..a8c5ed36b791 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadISISNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadISISNexus.h @@ -42,13 +42,15 @@ namespace Mantid virtual ~LoadISISNexus() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadISISNexus"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "*** This version of LoadISISNexus has been removed from Mantid. You should use the current version of this algorithm or try an earlier release of Mantid. ***";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Nexus"; } private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadISISNexus2.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadISISNexus2.h index c50ed46fe8b7..60f9b5b87c14 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadISISNexus2.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadISISNexus2.h @@ -80,6 +80,8 @@ namespace Mantid virtual int version() const { return 2; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Nexus"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a file in ISIS NeXus format.";} /// Returns a confidence value that this algorithm can load a file virtual int confidence(Kernel::NexusDescriptor & descriptor) const; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrument.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrument.h index 3899c3b05e93..499babea9a34 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrument.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrument.h @@ -86,6 +86,9 @@ namespace Mantid virtual ~LoadInstrument() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadInstrument";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads an Instrument Definition File (IDF) into a workspace. After the IDF has been read this algorithm will attempt to run the Child Algorithm LoadParameterFile; where if IDF filename is of the form IDENTIFIER_Definition.xml then the instrument parameters in the file named IDENTIFIER_Parameters.xml would be loaded (in the directory specified by the parameterDefinition.directory Mantid property).";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method @@ -94,7 +97,6 @@ namespace Mantid void execManually(); private: - void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrumentFromNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrumentFromNexus.h index 542595326a1d..6ef00628b853 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrumentFromNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrumentFromNexus.h @@ -73,6 +73,9 @@ namespace Mantid /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadInstrumentFromNexus";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Attempts to load some information about the instrument from a Nexus file. In particular attempt to read L2 and 2-theta detector position values and add detectors which are positioned relative to the sample in spherical coordinates as (r,theta,phi)=(L2,2-theta,phi). Also adds dummy source and samplepos components to instrument. Later this will be extended to use any further available details about the instrument in the Nexus file. If the L1 source - sample distance is not available in the file then it may be read from the mantid properties file using the key instrument.L1, as a final fallback a default distance of 10m will be used.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; @@ -81,8 +84,7 @@ namespace Mantid virtual const std::string category() const { return "DataHandling\\Instrument";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. Does nothing at present void init(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrumentFromRaw.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrumentFromRaw.h index d4c52d0d88f1..5ac728b5e7a5 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrumentFromRaw.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadInstrumentFromRaw.h @@ -70,6 +70,9 @@ namespace Mantid /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadInstrumentFromRaw";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Attempts to load information about the instrument from a ISIS raw file. In particular attempt to read L2 and 2-theta detector position values and add detectors which are positioned relative to the sample in spherical coordinates as (r,theta,phi)=(L2,2-theta,0.0). Also adds dummy source and samplepos components to instrument. If the L1 source - sample distance is not available in the file then it may be read from the mantid properties file using the key instrument.L1, as a final fallback a default distance of 10m will be used.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; @@ -78,8 +81,7 @@ namespace Mantid virtual const std::string category() const { return "DataHandling\\Instrument;DataHandling\\Raw";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. Does nothing at present void init(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadIsawDetCal.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadIsawDetCal.h index db0021fd6d7d..a1d141b084bf 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadIsawDetCal.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadIsawDetCal.h @@ -49,6 +49,9 @@ class DLLExport LoadIsawDetCal: public API::Algorithm, public Kernel::Quat virtual ~LoadIsawDetCal(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadIsawDetCal"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Since ISAW already has the capability to calibrate the instrument using single crystal peaks, this algorithm leverages this in mantid. It loads in a detcal file from ISAW and moves all of the detector panels accordingly. The target instruments for this feature are SNAP and TOPAZ.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -56,8 +59,7 @@ class DLLExport LoadIsawDetCal: public API::Algorithm, public Kernel::Quat /// Function to optimize void center(double x, double y, double z, std::string detname, std::string inname); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLLB.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLLB.h index 19fba7fcc9a1..9cb306361981 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLLB.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLLB.h @@ -39,6 +39,9 @@ class DLLExport LoadLLB: public API::IFileLoader { virtual ~LoadLLB(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads LLB nexus file.";} + virtual int version() const; virtual const std::string category() const; @@ -46,7 +49,6 @@ class DLLExport LoadLLB: public API::IFileLoader { virtual int confidence(Kernel::NexusDescriptor & descriptor) const; private: - virtual void initDocs(); void init(); void exec(); void setInstrumentName(NeXus::NXEntry& entry); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLOQDistancesFromRaw.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLOQDistancesFromRaw.h index 524ae1fb01e5..1cf1a81c8150 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLOQDistancesFromRaw.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLOQDistancesFromRaw.h @@ -53,14 +53,16 @@ class DLLExport LoadLOQDistancesFromRaw : public Mantid::API::Algorithm virtual ~LoadLOQDistancesFromRaw() {} /// Algorithm's name virtual const std::string name() const { return "LoadLOQDistancesFromRaw"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads distance information that is specific to the ISIS TS1 LOQ instrument.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "SANS;DataHandling\\Raw"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLog.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLog.h index caf918e0578f..c14a81ba153f 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLog.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLog.h @@ -74,14 +74,16 @@ namespace Mantid ~LoadLog() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadLog";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load ISIS log file(s) into a workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Logs";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLogsForSNSPulsedMagnet.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLogsForSNSPulsedMagnet.h index 34b3663718ed..82d1ece800b1 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLogsForSNSPulsedMagnet.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadLogsForSNSPulsedMagnet.h @@ -26,14 +26,16 @@ namespace DataHandling /// Algorithm's name for identification virtual const std::string name() const { return "LoadLogsForSNSPulsedMagnet";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Both log files are in binary format";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "DataHandling\\Logs";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMappingTable.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMappingTable.h index 1b33eeb03245..51c22466a604 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMappingTable.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMappingTable.h @@ -60,13 +60,15 @@ namespace Mantid ~LoadMappingTable() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadMappingTable";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Builds up the mapping between spectrum number and the detector objects in the instrument Geometry.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Instrument;DataHandling\\Raw";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// The name and path of the input file std::string m_filename; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMask.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMask.h index b624af78f0d4..62735855f9cc 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMask.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMask.h @@ -49,14 +49,16 @@ namespace DataHandling /// Algorithm's name for identification virtual const std::string name() const { return "LoadMask";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load file containing masking information to a SpecialWorkspace2D (masking workspace). This algorithm is renamed from LoadMaskingFile.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "DataHandling;Transforms\\Masking";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMcStas.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMcStas.h index a51f52dcb11b..7278cdf8b8f5 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMcStas.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMcStas.h @@ -41,6 +41,9 @@ namespace DataHandling virtual ~LoadMcStas(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a McStas NeXus file into an workspace.";} + virtual int version() const; virtual const std::string category() const; @@ -48,7 +51,6 @@ namespace DataHandling virtual int confidence(Kernel::NexusDescriptor & descriptor) const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMcStasNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMcStasNexus.h index e70b03800714..543682508fdd 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMcStasNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMcStasNexus.h @@ -38,6 +38,9 @@ namespace DataHandling virtual ~LoadMcStasNexus(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads an McStas NeXus file into a group workspace.";} + virtual int version() const; virtual const std::string category() const; @@ -45,7 +48,6 @@ namespace DataHandling virtual int confidence(Kernel::NexusDescriptor & descriptor) const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonLog.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonLog.h index 5844f63ec22f..874464f28589 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonLog.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonLog.h @@ -64,14 +64,16 @@ namespace Mantid virtual ~LoadMuonLog() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadMuonLog";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load log data from within Muon Nexus files into a workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Logs;Muon";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus.h index 4d1b708b98ce..03942e5fd916 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus.h @@ -67,6 +67,9 @@ namespace Mantid virtual ~LoadMuonNexus() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadMuonNexus"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The LoadMuonNexus algorithm will read the given NeXus Muon data file Version 1 and use the results to populate the named workspace. LoadMuonNexus may be invoked by LoadNexus if it is given a NeXus file of this type.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -111,8 +114,7 @@ namespace Mantid std::vector m_groupings; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); }; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus1.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus1.h index d4902a33ad6e..37ab9e0a0876 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus1.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus1.h @@ -76,6 +76,9 @@ namespace Mantid virtual ~LoadMuonNexus1() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadMuonNexus"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The LoadMuonNexus algorithm will read the given NeXus Muon data file Version 1 and use the results to populate the named workspace. LoadMuonNexus may be invoked by LoadNexus if it is given a NeXus file of this type.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -91,8 +94,7 @@ namespace Mantid void runLoadInstrumentFromNexus(DataObjects::Workspace2D_sptr); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void loadData(const MantidVecPtr::ptr_type& tcbs,size_t hist, specid_t& i, MuonNexusReader& nxload, const int64_t lengthIn, DataObjects::Workspace2D_sptr localWorkspace); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus2.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus2.h index f14525aa91ce..341845f70d0f 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus2.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadMuonNexus2.h @@ -64,6 +64,9 @@ namespace Mantid ~LoadMuonNexus2() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadMuonNexus"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The LoadMuonNexus algorithm will read the given NeXus Muon data file Version 2 and use the results to populate the named workspace. LoadMuonNexus may be invoked by LoadNexus if it is given a NeXus file of this type.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 2; } /// Algorithm's category for identification overriding a virtual method @@ -73,8 +76,7 @@ namespace Mantid virtual int confidence(Kernel::NexusDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method void exec(); /// Execute this version of the algorithm diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNXSPE.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNXSPE.h index bfd7aaff4d63..73c12b72f787 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNXSPE.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNXSPE.h @@ -46,6 +46,9 @@ namespace DataHandling /// Algorithm's name for identification virtual const std::string name() const { return "LoadNXSPE";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return " Algorithm to load an NXSPE file into a workspace2D.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification @@ -55,8 +58,7 @@ namespace DataHandling virtual int confidence(Kernel::NexusDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexus.h index b1aa60612789..85a438eff5f1 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexus.h @@ -65,14 +65,16 @@ namespace Mantid ~LoadNexus() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadNexus";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The LoadNexus algorithm will try to identify the type of Nexus file given to it and invoke the appropriate algorithm to read the data and populate the named workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Nexus";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusLogs.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusLogs.h index 68a4c11d65ef..7cbaf5cf8915 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusLogs.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusLogs.h @@ -65,14 +65,15 @@ namespace Mantid virtual ~LoadNexusLogs() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadNexusLogs"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads run logs (temperature, pulse charges, etc.) from a NeXus file and adds it to the run information in a workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Logs;DataHandling\\Nexus"; } private: - /// Overwrites Algorithm method. - void initDocs(); /// Overwrites Algorithm method. void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusMonitors.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusMonitors.h index 71aa0be2b244..82a22219102f 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusMonitors.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusMonitors.h @@ -53,14 +53,16 @@ namespace Mantid virtual ~LoadNexusMonitors(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadNexusMonitors"; }; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load all monitors from a NeXus file into a workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; }; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Nexus"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Intialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusProcessed.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusProcessed.h index b5860a9cad90..bf994856b7ba 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusProcessed.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadNexusProcessed.h @@ -58,6 +58,9 @@ namespace Mantid ~LoadNexusProcessed(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadNexusProcessed";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "The LoadNexusProcessed algorithm will read the given Nexus Processed data file containing a Mantid Workspace. The data is placed in the named workspace. LoadNexusProcessed may be invoked by LoadNexus if it is given a Nexus file of this type.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method @@ -67,8 +70,7 @@ namespace Mantid virtual int confidence(Kernel::NexusDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPDFgetNFile.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPDFgetNFile.h index 8be6353bf07d..8e7de6b4f8ad 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPDFgetNFile.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPDFgetNFile.h @@ -40,6 +40,9 @@ namespace DataHandling /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadPDFgetNFile";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Types of PDFgetN data files include .sqa, .sq, .gr, and etc.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;} @@ -48,8 +51,7 @@ namespace DataHandling virtual const std::string category() const { return "Diffraction;DataHandling\\Text";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Implement abstract Algorithm methods void init(); /// Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadParameterFile.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadParameterFile.h index 1a0bad10c7f7..7e1d800517cd 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadParameterFile.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadParameterFile.h @@ -79,6 +79,9 @@ namespace Mantid ~LoadParameterFile() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadParameterFile";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads instrument parameters into a workspace. where these parameters are associated component names as defined in Instrument Definition File (IDF) or a string consisting of the contents of such.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method @@ -87,8 +90,7 @@ namespace Mantid static void execManually(bool useString, std::string filename, std::string parameterString, Mantid::API::ExperimentInfo_sptr localWorkspace); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void init(); void exec(); }; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPreNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPreNexus.h index ebe58d57e4f5..a772e384b021 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPreNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPreNexus.h @@ -43,13 +43,15 @@ namespace DataHandling virtual ~LoadPreNexus(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load a collection of PreNexus files.";} + virtual int version() const; virtual const std::string category() const; void parseRuninfo(const std::string &runinfo, std::string &dataDir, std::vector &eventFilenames); /// Returns a confidence value that this algorithm can load a file virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - virtual void initDocs(); void init(); void exec(); void runLoadNexusLogs(const std::string &runinfo, const std::string &dataDir, diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPreNexusMonitors.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPreNexusMonitors.h index 89705d0dc38f..8d1442473be8 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPreNexusMonitors.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadPreNexusMonitors.h @@ -51,6 +51,9 @@ class DLLExport LoadPreNexusMonitors: public Mantid::API::Algorithm { return "LoadPreNexusMonitors"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This is a routine to load in the beam monitors from SNS preNeXus files into a workspace.";} + /// Algorithm's version virtual int version() const { @@ -69,8 +72,7 @@ class DLLExport LoadPreNexusMonitors: public Mantid::API::Algorithm private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadQKK.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadQKK.h index 9a38c983e775..9d2ba619297a 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadQKK.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadQKK.h @@ -46,6 +46,9 @@ class DLLExport LoadQKK : public API::IFileLoader virtual ~LoadQKK() {} /// Algorithm's name virtual const std::string name() const { return "LoadQKK"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a ANSTO QKK file. ";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -55,8 +58,7 @@ class DLLExport LoadQKK : public API::IFileLoader virtual int confidence(Kernel::NexusDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRKH.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRKH.h index 9b2835e4a292..4299084d301f 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRKH.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRKH.h @@ -53,6 +53,9 @@ class DLLExport LoadRKH : public API::IFileLoader virtual ~LoadRKH() {} /// Algorithm's name virtual const std::string name() const { return "LoadRKH"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load a file written in the RKH format";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -62,8 +65,7 @@ class DLLExport LoadRKH : public API::IFileLoader virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Store the units known to the UnitFactory std::set m_unitKeys; /// Store the units added as options for this algorithm diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw.h index 5ef2ce5c5d6d..13934023e0af 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw.h @@ -44,13 +44,15 @@ namespace Mantid ~LoadRaw() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadRaw"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "*** This version of LoadRaw has been removed from Mantid. You should use the current version of this algorithm or try an earlier release of Mantid. ***";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Raw"; } private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw2.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw2.h index b4e56386a31e..01620a9d5347 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw2.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw2.h @@ -44,13 +44,15 @@ namespace Mantid ~LoadRaw2() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadRaw"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "*** This version of LoadRaw has been removed from Mantid. You should use the current version of this algorithm or try an earlier release of Mantid. ***";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 2; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Raw"; } private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h index 751925e3c822..7336f4bcfbfe 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRaw3.h @@ -54,14 +54,16 @@ namespace Mantid ~LoadRaw3(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadRaw"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a data file in ISIS RAW format and stores it in a 2D workspace (Workspace2D class).";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 3; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Raw"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawBin0.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawBin0.h index 8697c43b18ca..ee97585b3e13 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawBin0.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawBin0.h @@ -71,14 +71,16 @@ namespace Mantid ~LoadRawBin0(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadRawBin0"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads bin zero from ISIS raw file and stores it in a 2D workspace (Workspace2D class).";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diagnostics"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawHelper.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawHelper.h index 9b4dedbb90f8..70178fc433c2 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawHelper.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawHelper.h @@ -64,6 +64,8 @@ namespace Mantid virtual const std::string name() const { return "LoadRawHelper"; } /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Helper class for LoadRaw algorithms.";} ///Opens Raw File FILE* openRawFile(const std::string & fileName); /// Read in run parameters Public so that LoadRaw2 can use it diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawSpectrum0.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawSpectrum0.h index e6c870d80d71..bb054cd28592 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawSpectrum0.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadRawSpectrum0.h @@ -65,14 +65,16 @@ namespace Mantid ~LoadRawSpectrum0(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadRawSpectrum0"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads spectrum zero from ISIS raw file and stores it in a 2D workspace (Workspace2D class).";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Diagnostics"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadReflTBL.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadReflTBL.h index 6e9a164c3b5a..b795329b9290 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadReflTBL.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadReflTBL.h @@ -41,6 +41,9 @@ namespace Mantid LoadReflTBL(); /// The name of the algorithm virtual const std::string name() const { return "LoadReflTBL"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads data from a reflectometry table file and stores it in a table workspace (TableWorkspace class).";} + /// The version number virtual int version() const { return 1; } /// The category @@ -49,8 +52,7 @@ namespace Mantid virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Declare properties void init(); /// Execute the algorithm diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSINQFocus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSINQFocus.h index 7d313c9f5d9e..699bbea8d5ec 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSINQFocus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSINQFocus.h @@ -50,6 +50,9 @@ namespace DataHandling { virtual ~LoadSINQFocus(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a FOCUS nexus file from the PSI";} + virtual int version() const; virtual const std::string category() const; @@ -57,7 +60,6 @@ namespace DataHandling { virtual int confidence(Kernel::NexusDescriptor & descriptor) const; private: - virtual void initDocs(); void init(); void exec(); void setInstrumentName(NeXus::NXEntry& entry); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSNSspec.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSNSspec.h index b526678660b5..616fbb845e6d 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSNSspec.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSNSspec.h @@ -50,6 +50,9 @@ namespace Mantid LoadSNSspec(); ~LoadSNSspec() {} virtual const std::string name() const { return "LoadSNSspec"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads data from a text file and stores it in a 2D workspace (Workspace2D class).";} + virtual int version() const { return 1; } virtual const std::string category() const { return "DataHandling"; } @@ -57,8 +60,7 @@ namespace Mantid virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSPE.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSPE.h index 281dc2540ff3..e23a9734c0b0 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSPE.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSPE.h @@ -51,6 +51,9 @@ class DLLExport LoadSPE : public API::IFileLoader virtual ~LoadSPE() {} /// Algorithm's name virtual const std::string name() const { return "LoadSPE"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a file written in the spe format.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -59,8 +62,7 @@ class DLLExport LoadSPE : public API::IFileLoader virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + // Initialisation code void init(); // Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSampleDetailsFromRaw.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSampleDetailsFromRaw.h index 235c06636a20..de323912878e 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSampleDetailsFromRaw.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSampleDetailsFromRaw.h @@ -51,14 +51,16 @@ class DLLExport LoadSampleDetailsFromRaw : public Mantid::API::Algorithm virtual ~LoadSampleDetailsFromRaw() {} /// Algorithm's name virtual const std::string name() const { return "LoadSampleDetailsFromRaw"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads the simple sample geometry that is defined within an ISIS raw file.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "DataHandling\\Raw;Sample"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSassena.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSassena.h index e34d51e3fd77..284dd583d7eb 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSassena.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSassena.h @@ -62,6 +62,9 @@ namespace Mantid virtual ~LoadSassena() {} /// Algorithm's name virtual const std::string name() const { return "LoadSassena"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return " load a Sassena output file into a group workspace.";} + /// Algorithm's version virtual int version() const { return 1; } /// Algorithm's category for identification @@ -85,8 +88,7 @@ namespace Mantid void loadFQT(const hid_t& h5file, API::WorkspaceGroup_sptr gws, const std::string setName, const MantidVec &qvmod, const std::vector &sorting_indexes); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); // Sets documentation strings for this algorithm + /// Initialization code void init(); // Overwrites Algorithm method. /// Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSpec.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSpec.h index febcca93852e..2cc7f40c4af7 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSpec.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSpec.h @@ -50,12 +50,14 @@ namespace Mantid LoadSpec(); ~LoadSpec() {} virtual const std::string name() const { return "LoadSpec"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads data from a text file and stores it in a 2D workspace (Workspace2D class).";} + virtual int version() const { return 1; } virtual const std::string category() const { return "DataHandling"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + void init(); void exec(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSpice2D.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSpice2D.h index b2a91890f017..f1fac58e59ef 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSpice2D.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadSpice2D.h @@ -58,6 +58,9 @@ namespace Mantid ~LoadSpice2D(); /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "LoadSpice2D"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a SANS data file produce by the HFIR instruments at ORNL. The instrument geometry is also loaded. The center of the detector is placed at (0,0,D), where D is the sample-to-detector distance.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -69,8 +72,7 @@ namespace Mantid virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadTOFRawNexus.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadTOFRawNexus.h index ea7295055cce..3fd8036d8d1f 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadTOFRawNexus.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/LoadTOFRawNexus.h @@ -50,9 +50,13 @@ class DLLExport LoadTOFRawNexus : public API::IFileLoader validateInputs(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialisation code void init(); ///Execution code diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/SetScalingPSD.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/SetScalingPSD.h index 69c06c9ca5d8..fe449dd82c1b 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/SetScalingPSD.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/SetScalingPSD.h @@ -59,14 +59,16 @@ namespace Mantid ~SetScalingPSD() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "SetScalingPSD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "For an instrument with Position Sensitive Detectors (PSDs) the 'engineering' positions of individual detectors may not match the true areas where neutrons are detected. This algorithm reads data on the calibrated location of the detectors and adjusts the parametrized instrument geometry accordingly.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "CorrectionFunctions\\InstrumentCorrections";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/UpdateInstrumentFromFile.h b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/UpdateInstrumentFromFile.h index 8d80bc9c5bb1..bb3aee9e9630 100644 --- a/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/UpdateInstrumentFromFile.h +++ b/Code/Mantid/Framework/DataHandling/inc/MantidDataHandling/UpdateInstrumentFromFile.h @@ -66,6 +66,9 @@ namespace Mantid /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "UpdateInstrumentFromFile"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Updates detector positions initially loaded in from the Instrument Definition File (IDF) with information from the provided file.";} + /// Algorithm's alias for the old UpdateInstrumentFromRaw virtual const std::string alias() const { return "UpdateInstrumentFromRaw"; } @@ -76,8 +79,7 @@ namespace Mantid virtual const std::string category() const { return "DataHandling\\Instrument;DataHandling\\Raw";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. Does nothing at present void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/DataHandling/src/AppendGeometryToSNSNexus.cpp b/Code/Mantid/Framework/DataHandling/src/AppendGeometryToSNSNexus.cpp index 0bbfdf883024..e97b2f7adc30 100644 --- a/Code/Mantid/Framework/DataHandling/src/AppendGeometryToSNSNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/AppendGeometryToSNSNexus.cpp @@ -58,12 +58,6 @@ namespace DataHandling const std::string AppendGeometryToSNSNexus::category() const { return "DataHandling\\DataAcquisition";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void AppendGeometryToSNSNexus::initDocs() - { - this->setWikiSummary("Appends the resolved instrument geometry (detectors and monitors for now) to a SNS ADARA NeXus file."); - this->setOptionalMessage("Appends the resolved instrument geometry (detectors and monitors for now) to a SNS ADARA NeXus file."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/CompressEvents.cpp b/Code/Mantid/Framework/DataHandling/src/CompressEvents.cpp index cf50dd1b5861..2b6790562dad 100644 --- a/Code/Mantid/Framework/DataHandling/src/CompressEvents.cpp +++ b/Code/Mantid/Framework/DataHandling/src/CompressEvents.cpp @@ -34,13 +34,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(CompressEvents) -/// Sets documentation strings for this algorithm -void CompressEvents::initDocs() -{ - this->setWikiSummary("Reduce the number of events in an [[EventWorkspace]] by grouping together events with identical or similar X-values (time-of-flight). "); - this->setOptionalMessage("Reduce the number of events in an EventWorkspace by grouping together events with identical or similar X-values (time-of-flight)."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/CreateChopperModel.cpp b/Code/Mantid/Framework/DataHandling/src/CreateChopperModel.cpp index 6618284e087a..614087fdbbd9 100644 --- a/Code/Mantid/Framework/DataHandling/src/CreateChopperModel.cpp +++ b/Code/Mantid/Framework/DataHandling/src/CreateChopperModel.cpp @@ -45,12 +45,6 @@ namespace Mantid const std::string CreateChopperModel::category() const { return "DataHandling";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CreateChopperModel::initDocs() - { - this->setWikiSummary("Creates a chopper model for a given workspace"); - this->setOptionalMessage("Creates a chopper model for a given workspace"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/CreateModeratorModel.cpp b/Code/Mantid/Framework/DataHandling/src/CreateModeratorModel.cpp index 70104d16cc96..1257579216be 100644 --- a/Code/Mantid/Framework/DataHandling/src/CreateModeratorModel.cpp +++ b/Code/Mantid/Framework/DataHandling/src/CreateModeratorModel.cpp @@ -39,12 +39,6 @@ namespace DataHandling const std::string CreateModeratorModel::category() const { return "DataHandling";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CreateModeratorModel::initDocs() - { - this->setWikiSummary("Creates the given moderator model and attaches it to the input workspace."); - this->setOptionalMessage("Creates the given moderator model and attaches it to the input workspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/CreateSampleShape.cpp b/Code/Mantid/Framework/DataHandling/src/CreateSampleShape.cpp index 94504b5df54d..ad4159e0fd76 100644 --- a/Code/Mantid/Framework/DataHandling/src/CreateSampleShape.cpp +++ b/Code/Mantid/Framework/DataHandling/src/CreateSampleShape.cpp @@ -19,13 +19,6 @@ namespace DataHandling // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CreateSampleShape) - /// Sets documentation strings for this algorithm - void CreateSampleShape::initDocs() - { - this->setWikiSummary("Create a shape object to model the sample. "); - this->setOptionalMessage("Create a shape object to model the sample."); - } - using namespace Mantid::DataHandling; using namespace Mantid::API; diff --git a/Code/Mantid/Framework/DataHandling/src/CreateSimulationWorkspace.cpp b/Code/Mantid/Framework/DataHandling/src/CreateSimulationWorkspace.cpp index d4f2e177c3f7..4be691c07479 100644 --- a/Code/Mantid/Framework/DataHandling/src/CreateSimulationWorkspace.cpp +++ b/Code/Mantid/Framework/DataHandling/src/CreateSimulationWorkspace.cpp @@ -42,12 +42,6 @@ namespace Mantid const std::string CreateSimulationWorkspace::category() const { return "Quantification";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CreateSimulationWorkspace::initDocs() - { - this->setWikiSummary("Create a blank workspace for a given instrument."); - this->setOptionalMessage("Create a blank workspace for a given instrument."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/DefineGaugeVolume.cpp b/Code/Mantid/Framework/DataHandling/src/DefineGaugeVolume.cpp index a81bf58f7ff2..90ae0511a310 100644 --- a/Code/Mantid/Framework/DataHandling/src/DefineGaugeVolume.cpp +++ b/Code/Mantid/Framework/DataHandling/src/DefineGaugeVolume.cpp @@ -27,13 +27,6 @@ using namespace Mantid::API; // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(DefineGaugeVolume) -/// Sets documentation strings for this algorithm -void DefineGaugeVolume::initDocs() -{ - this->setWikiSummary("Defines a geometrical shape object to be used as the gauge volume in the [[AbsorptionCorrection]] algorithm. "); - this->setOptionalMessage("Defines a geometrical shape object to be used as the gauge volume in the AbsorptionCorrection algorithm."); -} - /** * Initialize the algorithm diff --git a/Code/Mantid/Framework/DataHandling/src/DeleteTableRows.cpp b/Code/Mantid/Framework/DataHandling/src/DeleteTableRows.cpp index c7993c9b9d4e..565ca8ea3c34 100644 --- a/Code/Mantid/Framework/DataHandling/src/DeleteTableRows.cpp +++ b/Code/Mantid/Framework/DataHandling/src/DeleteTableRows.cpp @@ -23,13 +23,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(DeleteTableRows); - /// Sets documentation strings for this algorithm - void DeleteTableRows::initDocs() - { - this->setWikiSummary("Deletes rows from a TableWorkspace."); - this->setOptionalMessage("Deletes rows from a TableWorkspace."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/DetermineChunking.cpp b/Code/Mantid/Framework/DataHandling/src/DetermineChunking.cpp index 61b8291595a1..7e5deceeaa5e 100644 --- a/Code/Mantid/Framework/DataHandling/src/DetermineChunking.cpp +++ b/Code/Mantid/Framework/DataHandling/src/DetermineChunking.cpp @@ -94,14 +94,6 @@ namespace DataHandling return "DataHandling\\PreNexus;Workflow\\DataHandling"; } - //---------------------------------------------------------------------------------------------- - /// @copydoc Mantid::API::Algorithm::initDocs() - void DetermineChunking::initDocs() - { - this->setWikiSummary("Workflow algorithm to determine chunking strategy for event nexus, runinfo.xml, raw, or histo nexus files."); - this->setOptionalMessage("Workflow algorithm to determine chunking strategy for event nexus, runinfo.xml, raw, or histo nexus files."); - } - //---------------------------------------------------------------------------------------------- /// @copydoc Mantid::API::Algorithm::init() void DetermineChunking::init() diff --git a/Code/Mantid/Framework/DataHandling/src/FilterEventsByLogValuePreNexus.cpp b/Code/Mantid/Framework/DataHandling/src/FilterEventsByLogValuePreNexus.cpp index a9bac1d071e3..fea2f0ddee25 100644 --- a/Code/Mantid/Framework/DataHandling/src/FilterEventsByLogValuePreNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/FilterEventsByLogValuePreNexus.cpp @@ -269,16 +269,6 @@ namespace DataHandling return 0; } - //---------------------------------------------------------------------------------------------- - /** Sets documentation strings for this algorithm - */ - void FilterEventsByLogValuePreNexus::initDocs() - { - setWikiSummary("Load and split SNS raw neutron event data format and stores it in a [[workspace]]" - "([[EventWorkspace]] class). "); - setOptionalMessage("Load and split SNS raw neutron event data format and stores it in a workspace" - "(EventWorkspace class)."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm diff --git a/Code/Mantid/Framework/DataHandling/src/FindDetectorsInShape.cpp b/Code/Mantid/Framework/DataHandling/src/FindDetectorsInShape.cpp index 02839133346e..4bc3b774ed28 100644 --- a/Code/Mantid/Framework/DataHandling/src/FindDetectorsInShape.cpp +++ b/Code/Mantid/Framework/DataHandling/src/FindDetectorsInShape.cpp @@ -24,13 +24,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(FindDetectorsInShape) - /// Sets documentation strings for this algorithm - void FindDetectorsInShape::initDocs() - { - this->setWikiSummary("An algorithm for finding which detectors are contained within a user defined 3 dimensional shape within the instrument. "); - this->setOptionalMessage("An algorithm for finding which detectors are contained within a user defined 3 dimensional shape within the instrument."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/FindDetectorsPar.cpp b/Code/Mantid/Framework/DataHandling/src/FindDetectorsPar.cpp index c0d9fdb4d5ee..e3b01b97a8e7 100644 --- a/Code/Mantid/Framework/DataHandling/src/FindDetectorsPar.cpp +++ b/Code/Mantid/Framework/DataHandling/src/FindDetectorsPar.cpp @@ -53,14 +53,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(FindDetectorsPar) -/// Sets documentation strings for this algorithm -void FindDetectorsPar::initDocs() -{ - this->setWikiSummary("Calculates angular positions and sizes of detectors and groups of detectors after the workspace was grouped using ASCII or XML map file. " - "The results can be used to identify the positions of detectors in reciprocal space. Primary usage -- Child Algorithm of [[SaveNXSPE]], [[SavePAR]] or [[SavePHX]] algorithm."); - this->setOptionalMessage("The algorithm returns the angular parameters and second flight path for a workspace detectors (data, usually availble in par or phx file)"); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/GenerateGroupingPowder.cpp b/Code/Mantid/Framework/DataHandling/src/GenerateGroupingPowder.cpp index c81f49e792cd..d3db3d8abd5f 100644 --- a/Code/Mantid/Framework/DataHandling/src/GenerateGroupingPowder.cpp +++ b/Code/Mantid/Framework/DataHandling/src/GenerateGroupingPowder.cpp @@ -72,12 +72,6 @@ namespace DataHandling const std::string GenerateGroupingPowder::category() const { return "DataHandling";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void GenerateGroupingPowder::initDocs() - { - this->setWikiSummary("Generate grouping by angles."); - this->setOptionalMessage("Generate grouping by angles."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/GroupDetectors.cpp b/Code/Mantid/Framework/DataHandling/src/GroupDetectors.cpp index bc97c506b309..ccf941cfc131 100644 --- a/Code/Mantid/Framework/DataHandling/src/GroupDetectors.cpp +++ b/Code/Mantid/Framework/DataHandling/src/GroupDetectors.cpp @@ -77,13 +77,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(GroupDetectors) -/// Sets documentation strings for this algorithm -void GroupDetectors::initDocs() -{ - this->setWikiSummary("Sums spectra bin-by-bin, equivalent to grouping the data from a set of detectors. Individual groups can be specified by passing the algorithm a list of spectrum numbers, detector IDs or workspace indices. Many spectra groups can be created in one execution via an input file. "); - this->setOptionalMessage("Sums spectra bin-by-bin, equivalent to grouping the data from a set of detectors. Individual groups can be specified by passing the algorithm a list of spectrum numbers, detector IDs or workspace indices. Many spectra groups can be created in one execution via an input file."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/GroupDetectors2.cpp b/Code/Mantid/Framework/DataHandling/src/GroupDetectors2.cpp index 99c7406f09eb..c4d581bc162a 100644 --- a/Code/Mantid/Framework/DataHandling/src/GroupDetectors2.cpp +++ b/Code/Mantid/Framework/DataHandling/src/GroupDetectors2.cpp @@ -105,13 +105,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(GroupDetectors2) -/// Sets documentation strings for this algorithm -void GroupDetectors2::initDocs() -{ - this->setWikiSummary("Sums spectra bin-by-bin, equivalent to grouping the data from a set of detectors. Individual groups can be specified by passing the algorithm a list of spectrum numbers, detector IDs or workspace indices. Many spectra groups can be created in one execution via an input file. "); - this->setOptionalMessage("Sums spectra bin-by-bin, equivalent to grouping the data from a set of detectors. Individual groups can be specified by passing the algorithm a list of spectrum numbers, detector IDs or workspace indices. Many spectra groups can be created in one execution via an input file."); -} - using namespace Kernel; using namespace API; using namespace DataObjects; diff --git a/Code/Mantid/Framework/DataHandling/src/Load.cpp b/Code/Mantid/Framework/DataHandling/src/Load.cpp index 367d15471cbb..b5a333190876 100644 --- a/Code/Mantid/Framework/DataHandling/src/Load.cpp +++ b/Code/Mantid/Framework/DataHandling/src/Load.cpp @@ -148,13 +148,6 @@ namespace Mantid // The mutex Poco::Mutex Load::m_mutex; - - /// Sets documentation strings for this algorithm - void Load::initDocs() - { - this->setWikiSummary("Attempts to load a given file by finding an appropriate Load algorithm. "); - this->setOptionalMessage("Attempts to load a given file by finding an appropriate Load algorithm."); - } using namespace Kernel; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadAscii.cpp b/Code/Mantid/Framework/DataHandling/src/LoadAscii.cpp index c0697f85e383..61bb049bb96d 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadAscii.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadAscii.cpp @@ -41,13 +41,6 @@ namespace Mantid { DECLARE_FILELOADER_ALGORITHM(LoadAscii); - /// Sets documentation strings for this algorithm - void LoadAscii::initDocs() - { - this->setWikiSummary("Loads data from a text file and stores it in a 2D [[workspace]] ([[Workspace2D]] class). "); - this->setOptionalMessage("Loads data from a text file and stores it in a 2D workspace (Workspace2D class)."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadAscii2.cpp b/Code/Mantid/Framework/DataHandling/src/LoadAscii2.cpp index 310a15f23bfe..508d47828847 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadAscii2.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadAscii2.cpp @@ -49,13 +49,6 @@ namespace Mantid { DECLARE_FILELOADER_ALGORITHM(LoadAscii2); - /// Sets documentation strings for this algorithm - void LoadAscii2::initDocs() - { - this->setWikiSummary("Loads data from a text file and stores it in a 2D [[workspace]] ([[Workspace2D]] class). "); - this->setOptionalMessage("Loads data from a text file and stores it in a 2D workspace (Workspace2D class)."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadCalFile.cpp b/Code/Mantid/Framework/DataHandling/src/LoadCalFile.cpp index 966597172651..83c04194c809 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadCalFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadCalFile.cpp @@ -57,12 +57,6 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadCalFile::initDocs() - { - this->setWikiSummary("Loads a 5-column ASCII .cal file into up to 3 workspaces: a GroupingWorkspace, OffsetsWorkspace and/or MaskWorkspace."); - this->setOptionalMessage("Loads a 5-column ASCII .cal file into up to 3 workspaces: a GroupingWorkspace, OffsetsWorkspace and/or MaskWorkspace."); - } //---------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/DataHandling/src/LoadCanSAS1D.cpp b/Code/Mantid/Framework/DataHandling/src/LoadCanSAS1D.cpp index c1b8599d9c4c..a5f4705bb5aa 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadCanSAS1D.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadCanSAS1D.cpp @@ -48,13 +48,6 @@ namespace DataHandling DECLARE_FILELOADER_ALGORITHM(LoadCanSAS1D); -/// Sets documentation strings for this algorithm -void LoadCanSAS1D::initDocs() -{ - this->setWikiSummary("Load a file written in the canSAS 1-D data format "); - this->setOptionalMessage("Load a file written in the canSAS 1-D data format"); -} - /// constructor LoadCanSAS1D::LoadCanSAS1D() : m_groupNumber(0) diff --git a/Code/Mantid/Framework/DataHandling/src/LoadDaveGrp.cpp b/Code/Mantid/Framework/DataHandling/src/LoadDaveGrp.cpp index cc9a8e2e42ce..753315dfba4c 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadDaveGrp.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadDaveGrp.cpp @@ -23,13 +23,6 @@ namespace DataHandling { DECLARE_FILELOADER_ALGORITHM(LoadDaveGrp); -/// Sets documentation strings for this algorithm -void LoadDaveGrp::initDocs() -{ - this->setWikiSummary("Loads data from a DAVE grouped ASCII file and stores it in a 2D [[workspace]] ([[Workspace2D]] class). "); - this->setOptionalMessage("Loads data from a DAVE grouped ASCII file and stores it in a 2D workspace (Workspace2D class)."); -} - LoadDaveGrp::LoadDaveGrp() : ifile(), line(), nGroups(0), xLength(0) { } diff --git a/Code/Mantid/Framework/DataHandling/src/LoadDetectorInfo.cpp b/Code/Mantid/Framework/DataHandling/src/LoadDetectorInfo.cpp index d5c02c6dba66..efe0fb1005e7 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadDetectorInfo.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadDetectorInfo.cpp @@ -321,13 +321,6 @@ namespace Mantid Direction::Input); } - /// Sets documentation strings for this algorithm - void LoadDetectorInfo::initDocs() - { - this->setWikiSummary("Loads delay times, tube pressures and tube wall thicknesses from a given file."); - this->setOptionalMessage("Loads delay times, tube pressures and tube wall thicknesses from a given file."); - } - /** */ void LoadDetectorInfo::exec() diff --git a/Code/Mantid/Framework/DataHandling/src/LoadDetectorsGroupingFile.cpp b/Code/Mantid/Framework/DataHandling/src/LoadDetectorsGroupingFile.cpp index b5a51bd81e0f..052935b23060 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadDetectorsGroupingFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadDetectorsGroupingFile.cpp @@ -146,12 +146,6 @@ namespace DataHandling LoadDetectorsGroupingFile::~LoadDetectorsGroupingFile() { } - - /// Sets documentation strings for this algorithm - void LoadDetectorsGroupingFile::initDocs(){ - this->setWikiSummary("Load an XML or Map file, which contains definition of detectors grouping, to a [[GroupingWorkspace]])."); - this->setOptionalMessage("Load an XML or Map file, which contains definition of detectors grouping, to a GroupingWorkspace)."); - } void LoadDetectorsGroupingFile::init() { diff --git a/Code/Mantid/Framework/DataHandling/src/LoadDspacemap.cpp b/Code/Mantid/Framework/DataHandling/src/LoadDspacemap.cpp index 6640d402d611..34442dfdd139 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadDspacemap.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadDspacemap.cpp @@ -53,12 +53,6 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadDspacemap::initDocs() - { - this->setWikiSummary("Loads a Dspacemap file (POWGEN binary, VULCAN binary or ascii format) into an OffsetsWorkspace."); - this->setOptionalMessage("Loads a Dspacemap file (POWGEN binary, VULCAN binary or ascii format) into an OffsetsWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/LoadEmptyInstrument.cpp b/Code/Mantid/Framework/DataHandling/src/LoadEmptyInstrument.cpp index de870eb288aa..b150101e8005 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadEmptyInstrument.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadEmptyInstrument.cpp @@ -22,13 +22,6 @@ namespace Mantid // Register the algorithm into the algorithm factory as a file loading algorithm DECLARE_FILELOADER_ALGORITHM(LoadEmptyInstrument) - /// Sets documentation strings for this algorithm - void LoadEmptyInstrument::initDocs() - { - this->setWikiSummary("Loads an Instrument Definition File ([[InstrumentDefinitionFile|IDF]]) into a [[workspace]] rather than a data file."); - this->setOptionalMessage("Loads an Instrument Definition File (IDF) into a workspace rather than a data file."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadEventNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadEventNexus.cpp index 863c2f9452a5..7a729169d2c5 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadEventNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadEventNexus.cpp @@ -989,13 +989,6 @@ int LoadEventNexus::confidence(Kernel::NexusDescriptor & descriptor) const return confidence; } -/// Sets documentation strings for this algorithm -void LoadEventNexus::initDocs() -{ - this->setWikiSummary("Loads Event NeXus files (produced by the SNS) and stores it in an [[EventWorkspace]]. Optionally, you can filter out events falling outside a range of times-of-flight and/or a time interval. "); - this->setOptionalMessage("Loads Event NeXus files (produced by the SNS) and stores it in an EventWorkspace. Optionally, you can filter out events falling outside a range of times-of-flight and/or a time interval."); -} - /// Initialisation method. void LoadEventNexus::init() { diff --git a/Code/Mantid/Framework/DataHandling/src/LoadEventPreNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadEventPreNexus.cpp index fec77b525d54..f25f0f29278a 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadEventPreNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadEventPreNexus.cpp @@ -56,13 +56,6 @@ namespace DataHandling DECLARE_FILELOADER_ALGORITHM(LoadEventPreNexus); -/// Sets documentation strings for this algorithm -void LoadEventPreNexus::initDocs() -{ - this->setWikiSummary("Loads SNS raw neutron event data format and stores it in a [[workspace]] ([[EventWorkspace]] class). "); - this->setOptionalMessage("Loads SNS raw neutron event data format and stores it in a workspace (EventWorkspace class)."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadEventPreNexus2.cpp b/Code/Mantid/Framework/DataHandling/src/LoadEventPreNexus2.cpp index 22918048b4fe..ba415777de65 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadEventPreNexus2.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadEventPreNexus2.cpp @@ -258,18 +258,6 @@ namespace DataHandling delete this->eventfile; } - //---------------------------------------------------------------------------------------------- - /** Sets documentation strings for this algorithm - */ - void LoadEventPreNexus2::initDocs() - { - this->setWikiSummary("Loads SNS raw neutron event data format and stores it in a [[workspace]] " - "([[EventWorkspace]] class). "); - this->setOptionalMessage("Loads SNS raw neutron event data format and stores it in a workspace " - "(EventWorkspace class)."); - } - - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm, i.e, declare properties */ diff --git a/Code/Mantid/Framework/DataHandling/src/LoadFullprofResolution.cpp b/Code/Mantid/Framework/DataHandling/src/LoadFullprofResolution.cpp index cb2484811404..91845fd6cbd9 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadFullprofResolution.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadFullprofResolution.cpp @@ -68,19 +68,6 @@ namespace DataHandling { } - //---------------------------------------------------------------------------------------------- - /** Sets documentation strings for this algorithm - */ - void LoadFullprofResolution::initDocs() - { - setWikiSummary("Load Fullprof's resolution (.irf) file to one or multiple TableWorkspace(s) and/or where this is supported." - " See description section, translate fullprof resolution fitting parameter into Mantid equivalent fitting parameters."); - setOptionalMessage("Load Fullprof's resolution (.irf) file to one or multiple TableWorkspace(s) and/or where this is supported." - " See description section, translate fullprof resolution fitting parameter into Mantid equivalent fitting parameters."); - - return; - } - //---------------------------------------------------------------------------------------------- /** Implement abstract Algorithm methods */ diff --git a/Code/Mantid/Framework/DataHandling/src/LoadGSASInstrumentFile.cpp b/Code/Mantid/Framework/DataHandling/src/LoadGSASInstrumentFile.cpp index b2febce0286c..af2c7fd9a79e 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadGSASInstrumentFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadGSASInstrumentFile.cpp @@ -65,14 +65,7 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- /** Sets documentation strings for this algorithm - */ - void LoadGSASInstrumentFile::initDocs() - { - setWikiSummary("Load parameters from a GSAS Instrument file."); - setOptionalMessage("Load parameters from a GSAS Instrument file."); - - return; - } + * //---------------------------------------------------------------------------------------------- /** Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/DataHandling/src/LoadGSS.cpp b/Code/Mantid/Framework/DataHandling/src/LoadGSS.cpp index f0da21c50643..818934c9b1b8 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadGSS.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadGSS.cpp @@ -70,15 +70,6 @@ namespace Mantid return 0; } - /// Sets documentation strings for this algorithm - void LoadGSS::initDocs() - { - this->setWikiSummary( - "

Loads a GSS file such as that saved by [[SaveGSS]]. This is not a lossless process, as SaveGSS truncates some data. There is no instrument assosciated with the resulting workspace.

'''Please Note''': Due to limitations of the GSS file format, the process of going from Mantid to a GSS file and back is not perfect.

"); - this->setOptionalMessage( - "Loads a GSS file such as that saved by SaveGSS. This is not a lossless process, as SaveGSS truncates some data. There is no instrument assosciated with the resulting workspace. 'Please Note': Due to limitations of the GSS file format, the process of going from Mantid to a GSS file and back is not perfect."); - } - /** * Initialise the algorithm */ diff --git a/Code/Mantid/Framework/DataHandling/src/LoadIDFFromNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadIDFFromNexus.cpp index 8122f9e75abc..416a256691af 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadIDFFromNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadIDFFromNexus.cpp @@ -19,13 +19,6 @@ namespace DataHandling DECLARE_ALGORITHM(LoadIDFFromNexus) -/// Sets documentation strings for this algorithm -void LoadIDFFromNexus::initDocs() -{ - this->setWikiSummary("Load an IDF from a Nexus file, if found there."); - this->setOptionalMessage("Load an IDF from a Nexus file, if found there. You may need to tell this algorithm where to find the Instrument folder in the Nexus file"); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadILL.cpp b/Code/Mantid/Framework/DataHandling/src/LoadILL.cpp index 98edfc584a8d..37fea8632be8 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadILL.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadILL.cpp @@ -51,13 +51,6 @@ namespace Mantid << c.nxclass; } - /// Sets documentation strings for this algorithm - void LoadILL::initDocs() - { - this->setWikiSummary("Loads a ILL nexus file. "); - this->setOptionalMessage("Loads a ILL nexus file."); - } - /** * Return the confidence with with this algorithm can load the file * @param descriptor A descriptor for the file diff --git a/Code/Mantid/Framework/DataHandling/src/LoadILLIndirect.cpp b/Code/Mantid/Framework/DataHandling/src/LoadILLIndirect.cpp index bd62aa6a03dc..17e32784426f 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadILLIndirect.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadILLIndirect.cpp @@ -64,11 +64,6 @@ const std::string LoadILLIndirect::category() const { } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm -void LoadILLIndirect::initDocs() { - this->setWikiSummary("Loads a ILL/IN16B nexus file. "); - this->setOptionalMessage("Loads a ILL/IN16B nexus file."); -} /** diff --git a/Code/Mantid/Framework/DataHandling/src/LoadILLSANS.cpp b/Code/Mantid/Framework/DataHandling/src/LoadILLSANS.cpp index 2a68ff2e1a39..1a034b1fa3f0 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadILLSANS.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadILLSANS.cpp @@ -56,11 +56,6 @@ const std::string LoadILLSANS::category() const { } //---------------------------------------------------------------------------------------------- -/// Sets documentation strings for this algorithm -void LoadILLSANS::initDocs() { - this->setWikiSummary("Loads a ILL nexus files for SANS instruments."); - this->setOptionalMessage("Loads a ILL nexus files for SANS instruments."); -} /** diff --git a/Code/Mantid/Framework/DataHandling/src/LoadISISNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadISISNexus.cpp index 6100c52d32fb..e6285f75a675 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadISISNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadISISNexus.cpp @@ -19,11 +19,6 @@ namespace Mantid useAlgorithm("LoadISISNexus Version 2"); } - void LoadISISNexus::initDocs() - { - setOptionalMessage("*** This version of LoadISISNexus has been removed from Mantid. You should use the current version of this algorithm or try an earlier release of Mantid. ***"); - } - /** Initialises the algorithm with the properties as they were when this algorithm was removed from Mantid, * though all validators have been removed */ diff --git a/Code/Mantid/Framework/DataHandling/src/LoadInstrument.cpp b/Code/Mantid/Framework/DataHandling/src/LoadInstrument.cpp index 4aec499f0b65..b42e910096a2 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadInstrument.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadInstrument.cpp @@ -60,13 +60,6 @@ namespace Mantid DECLARE_ALGORITHM(LoadInstrument) - /// Sets documentation strings for this algorithm - void LoadInstrument::initDocs() - { - this->setWikiSummary("Loads an Instrument Definition File ([[InstrumentDefinitionFile|IDF]]) into a [[workspace]]. This algorithm is typically run as a child algorithm to the data loading algorithm, rather than as a top-level algorithm. After the IDF has been read this algorithm will attempt to run the child algorithm [[LoadParameterFile]]; where if IDF filename is of the form IDENTIFIER_Definition.xml then the instrument parameters in the file named IDENTIFIER_Parameters.xml would be loaded (in the directory specified by the ParameterDefinition.directory [[Properties_File|Mantid property]])."); - this->setOptionalMessage("Loads an Instrument Definition File (IDF) into a workspace. After the IDF has been read this algorithm will attempt to run the Child Algorithm LoadParameterFile; where if IDF filename is of the form IDENTIFIER_Definition.xml then the instrument parameters in the file named IDENTIFIER_Parameters.xml would be loaded (in the directory specified by the parameterDefinition.directory Mantid property)."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadInstrumentFromNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadInstrumentFromNexus.cpp index 2e4e86422edb..9a695be04bc1 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadInstrumentFromNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadInstrumentFromNexus.cpp @@ -30,13 +30,6 @@ namespace DataHandling DECLARE_ALGORITHM(LoadInstrumentFromNexus) -/// Sets documentation strings for this algorithm -void LoadInstrumentFromNexus::initDocs() -{ - this->setWikiSummary("Attempts to load some information about the instrument from a Nexus file."); - this->setOptionalMessage("Attempts to load some information about the instrument from a Nexus file. In particular attempt to read L2 and 2-theta detector position values and add detectors which are positioned relative to the sample in spherical coordinates as (r,theta,phi)=(L2,2-theta,phi). Also adds dummy source and samplepos components to instrument. Later this will be extended to use any further available details about the instrument in the Nexus file. If the L1 source - sample distance is not available in the file then it may be read from the mantid properties file using the key instrument.L1, as a final fallback a default distance of 10m will be used."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadInstrumentFromRaw.cpp b/Code/Mantid/Framework/DataHandling/src/LoadInstrumentFromRaw.cpp index 70e774dab0cf..c86e506e3073 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadInstrumentFromRaw.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadInstrumentFromRaw.cpp @@ -25,13 +25,6 @@ namespace DataHandling DECLARE_ALGORITHM(LoadInstrumentFromRaw) -/// Sets documentation strings for this algorithm -void LoadInstrumentFromRaw::initDocs() -{ - this->setWikiSummary("

Attempts to load information about the instrument from a ISIS raw file. In particular attempt to read L2 and 2-theta detector position values and add detectors which are positioned relative to the sample in spherical coordinates as (r,theta,phi)=(L2,2-theta,0.0). Also adds dummy source and samplepos components to instrument.

If the L1 source - sample distance is not available in the file then it may be read from the [[Properties File|mantid properties]] file using the key instrument.L1, as a final fallback a default distance of 10m will be used.

"); - this->setOptionalMessage("Attempts to load information about the instrument from a ISIS raw file. In particular attempt to read L2 and 2-theta detector position values and add detectors which are positioned relative to the sample in spherical coordinates as (r,theta,phi)=(L2,2-theta,0.0). Also adds dummy source and samplepos components to instrument. If the L1 source - sample distance is not available in the file then it may be read from the mantid properties file using the key instrument.L1, as a final fallback a default distance of 10m will be used."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadIsawDetCal.cpp b/Code/Mantid/Framework/DataHandling/src/LoadIsawDetCal.cpp index c09cfe2d3a4c..10eccedd47e0 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadIsawDetCal.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadIsawDetCal.cpp @@ -45,13 +45,6 @@ namespace DataHandling // Register the class into the algorithm factory DECLARE_ALGORITHM(LoadIsawDetCal) - /// Sets documentation strings for this algorithm - void LoadIsawDetCal::initDocs() - { - this->setWikiSummary("Since ISAW already has the capability to calibrate the instrument using single crystal peaks, this algorithm leverages this in mantid. It loads in a detcal file from ISAW and moves all of the detector panels accordingly. The target instruments for this feature are SNAP and TOPAZ. "); - this->setOptionalMessage("Since ISAW already has the capability to calibrate the instrument using single crystal peaks, this algorithm leverages this in mantid. It loads in a detcal file from ISAW and moves all of the detector panels accordingly. The target instruments for this feature are SNAP and TOPAZ."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadLLB.cpp b/Code/Mantid/Framework/DataHandling/src/LoadLLB.cpp index a45aaaecf9a7..6ae0bf9876d3 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadLLB.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadLLB.cpp @@ -80,11 +80,6 @@ int LoadLLB::confidence(Kernel::NexusDescriptor & descriptor) const { } //---------------------------------------------------------------------------------------------- -/// Sets documentation strings for this algorithm -void LoadLLB::initDocs() { - this->setWikiSummary("Loads LLB nexus file."); - this->setOptionalMessage("Loads LLB nexus file."); -} //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/LoadLOQDistancesFromRaw.cpp b/Code/Mantid/Framework/DataHandling/src/LoadLOQDistancesFromRaw.cpp index 5b9efddbc669..650d0e43b9a4 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadLOQDistancesFromRaw.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadLOQDistancesFromRaw.cpp @@ -30,13 +30,6 @@ namespace DataHandling // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(LoadLOQDistancesFromRaw) - /// Sets documentation strings for this algorithm - void LoadLOQDistancesFromRaw::initDocs() - { - this->setWikiSummary("Loads distance information that is specific to the ISIS TS1 LOQ instrument."); - this->setOptionalMessage("Loads distance information that is specific to the ISIS TS1 LOQ instrument."); - } - /** * Initialize the algorithm */ diff --git a/Code/Mantid/Framework/DataHandling/src/LoadLog.cpp b/Code/Mantid/Framework/DataHandling/src/LoadLog.cpp index cd7e3145c5c7..06ffdc666413 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadLog.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadLog.cpp @@ -59,13 +59,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(LoadLog) - /// Sets documentation strings for this algorithm - void LoadLog::initDocs() - { - this->setWikiSummary("Load ISIS log file(s) or a SNS text log file into a [[workspace]]."); - this->setOptionalMessage("Load ISIS log file(s) into a workspace."); - } - using namespace Kernel; using API::WorkspaceProperty; using API::MatrixWorkspace; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadLogsForSNSPulsedMagnet.cpp b/Code/Mantid/Framework/DataHandling/src/LoadLogsForSNSPulsedMagnet.cpp index 4d705b939786..703c392f5791 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadLogsForSNSPulsedMagnet.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadLogsForSNSPulsedMagnet.cpp @@ -46,12 +46,6 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadLogsForSNSPulsedMagnet::initDocs() - { - this->setWikiSummary("Load SNS's DelayTime log file and Pulse ID file of Pulsed Magnet "); - this->setOptionalMessage("Both log files are in binary format"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/LoadMappingTable.cpp b/Code/Mantid/Framework/DataHandling/src/LoadMappingTable.cpp index 568d2093e5d0..edf5b63579d1 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadMappingTable.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadMappingTable.cpp @@ -21,13 +21,6 @@ using namespace API; DECLARE_ALGORITHM(LoadMappingTable) -/// Sets documentation strings for this algorithm -void LoadMappingTable::initDocs() -{ - this->setWikiSummary("Builds up the mapping between spectrum number and the detector objects in the [[instrument]] [[Geometry]]."); - this->setOptionalMessage("Builds up the mapping between spectrum number and the detector objects in the instrument Geometry."); -} - LoadMappingTable::LoadMappingTable() : Algorithm() { diff --git a/Code/Mantid/Framework/DataHandling/src/LoadMask.cpp b/Code/Mantid/Framework/DataHandling/src/LoadMask.cpp index 5a462c7b016c..a79699dc70bc 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadMask.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadMask.cpp @@ -115,12 +115,6 @@ namespace DataHandling { // Auto-generated destructor stub } - - /// Sets documentation strings for this algorithm - void LoadMask::initDocs(){ - this->setWikiSummary("Load file containing masking information to a [[SpecialWorkspace2D]] (masking workspace). This algorithm is renamed from [[LoadMaskingFile]]."); - this->setOptionalMessage(""); - } /// Initialise the properties void LoadMask::init() diff --git a/Code/Mantid/Framework/DataHandling/src/LoadMcStas.cpp b/Code/Mantid/Framework/DataHandling/src/LoadMcStas.cpp index b05eb215a4f2..35bd430330dc 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadMcStas.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadMcStas.cpp @@ -97,12 +97,6 @@ namespace DataHandling const std::string LoadMcStas::category() const { return "DataHandling";} //---------------------------------------------------------------------------------------------- - // Sets documentation strings for this algorithm - void LoadMcStas::initDocs() - { - this->setWikiSummary("This algorithm loads a McStas NeXus file into an workspace."); - this->setOptionalMessage("Loads a McStas NeXus file into an workspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/LoadMcStasNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadMcStasNexus.cpp index 2c6cd4b608cd..c83ec76572bf 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadMcStasNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadMcStasNexus.cpp @@ -66,12 +66,6 @@ namespace DataHandling } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadMcStasNexus::initDocs() - { - this->setWikiSummary("This algorithm loads a McStas NeXus file into a group workspace. All data sets are numbered and nested within the WorkspaceGroup."); - this->setOptionalMessage("Loads an McStas NeXus file into a group workspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/LoadMuonLog.cpp b/Code/Mantid/Framework/DataHandling/src/LoadMuonLog.cpp index afd5a69cee89..5c617b5fa04f 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadMuonLog.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadMuonLog.cpp @@ -28,13 +28,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(LoadMuonLog) -/// Sets documentation strings for this algorithm -void LoadMuonLog::initDocs() -{ - this->setWikiSummary("Load log data from within Muon Nexus files into a [[workspace]]. "); - this->setOptionalMessage("Load log data from within Muon Nexus files into a workspace."); -} - using namespace Kernel; using API::WorkspaceProperty; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus.cpp index 69023c301538..d6120b4a6811 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus.cpp @@ -28,13 +28,6 @@ namespace Mantid namespace DataHandling { - /// Sets documentation strings for this algorithm - void LoadMuonNexus::initDocs() - { - this->setWikiSummary("The LoadMuonNexus algorithm will read the given NeXus Muon data file Version 1 and use the results to populate the named workspace. LoadMuonNexus may be invoked by [[LoadNexus]] if it is given a NeXus file of this type. "); - this->setOptionalMessage("The LoadMuonNexus algorithm will read the given NeXus Muon data file Version 1 and use the results to populate the named workspace. LoadMuonNexus may be invoked by LoadNexus if it is given a NeXus file of this type."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus1.cpp b/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus1.cpp index 9c63639b6848..ca4e9b75c794 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus1.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus1.cpp @@ -79,13 +79,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_NEXUS_FILELOADER_ALGORITHM(LoadMuonNexus1); - /// Sets documentation strings for this algorithm - void LoadMuonNexus1::initDocs() - { - this->setWikiSummary("The LoadMuonNexus algorithm will read the given NeXus Muon data file Version 1 and use the results to populate the named workspace. LoadMuonNexus may be invoked by [[LoadNexus]] if it is given a NeXus file of this type. "); - this->setOptionalMessage("The LoadMuonNexus algorithm will read the given NeXus Muon data file Version 1 and use the results to populate the named workspace. LoadMuonNexus may be invoked by LoadNexus if it is given a NeXus file of this type."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus2.cpp b/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus2.cpp index 09f3b56ef8d4..f3ad552aceb1 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus2.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadMuonNexus2.cpp @@ -82,13 +82,6 @@ namespace Mantid using Geometry::Instrument; using namespace Mantid::NeXus; - /// Sets documentation strings for this algorithm - void LoadMuonNexus2::initDocs() - { - this->setWikiSummary("The LoadMuonNexus algorithm will read the given NeXus Muon data file Version 2 and use the results to populate the named workspace. LoadMuonNexus may be invoked by [[LoadNexus]] if it is given a NeXus file of this type. "); - this->setOptionalMessage("The LoadMuonNexus algorithm will read the given NeXus Muon data file Version 2 and use the results to populate the named workspace. LoadMuonNexus may be invoked by LoadNexus if it is given a NeXus file of this type."); - } - /// Empty default constructor LoadMuonNexus2::LoadMuonNexus2() : LoadMuonNexus() diff --git a/Code/Mantid/Framework/DataHandling/src/LoadNXSPE.cpp b/Code/Mantid/Framework/DataHandling/src/LoadNXSPE.cpp index fb0d09d6b619..85e5e78a5114 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadNXSPE.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadNXSPE.cpp @@ -52,13 +52,6 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadNXSPE::initDocs() - { - this->setWikiSummary("Algorithm to load an NXSPE file into a workspace2D."); - this->setOptionalMessage(" Algorithm to load an NXSPE file into a workspace2D."); - this->setWikiDescription("Algorithm to load an NXSPE file into a workspace2D. It will create a new instrument, that can be overwritten later by the LoadInstrument algorithm."); - } /** * Return the confidence with with this algorithm can load the file diff --git a/Code/Mantid/Framework/DataHandling/src/LoadNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadNexus.cpp index 8c7324f3a5d7..495e67319d09 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadNexus.cpp @@ -40,13 +40,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(LoadNexus) - /// Sets documentation strings for this algorithm - void LoadNexus::initDocs() - { - this->setWikiSummary("The LoadNexus algorithm will try to identify the type of Nexus file given to it and invoke the appropriate algorithm to read the data and populate the named workspace. "); - this->setOptionalMessage("The LoadNexus algorithm will try to identify the type of Nexus file given to it and invoke the appropriate algorithm to read the data and populate the named workspace."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadNexusLogs.cpp b/Code/Mantid/Framework/DataHandling/src/LoadNexusLogs.cpp index 24d2f08a9b87..833e462d3f17 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadNexusLogs.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadNexusLogs.cpp @@ -32,13 +32,6 @@ namespace Mantid { // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(LoadNexusLogs) - - /// Sets documentation strings for this algorithm - void LoadNexusLogs::initDocs() - { - this->setWikiSummary("Loads sample logs (temperature, pulse charges, etc.) from a NeXus file and adds it to the run information in a [[workspace]]. This is run automatically by [[LoadISISNexus]] and [[LoadEventNexus]]. This is useful when using [[LoadEventPreNexus]], to add sample logs after loading."); - this->setOptionalMessage("Loads run logs (temperature, pulse charges, etc.) from a NeXus file and adds it to the run information in a workspace."); - } using namespace Kernel; using API::WorkspaceProperty; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadNexusMonitors.cpp b/Code/Mantid/Framework/DataHandling/src/LoadNexusMonitors.cpp index 90fce7c24b1e..4770f218869e 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadNexusMonitors.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadNexusMonitors.cpp @@ -30,13 +30,6 @@ namespace DataHandling DECLARE_ALGORITHM(LoadNexusMonitors) -/// Sets documentation strings for this algorithm -void LoadNexusMonitors::initDocs() -{ - this->setWikiSummary("Load all monitors from a NeXus file into a workspace."); - this->setOptionalMessage("Load all monitors from a NeXus file into a workspace."); -} - LoadNexusMonitors::LoadNexusMonitors() : Algorithm(), nMonitors(0) diff --git a/Code/Mantid/Framework/DataHandling/src/LoadNexusProcessed.cpp b/Code/Mantid/Framework/DataHandling/src/LoadNexusProcessed.cpp index d15dd1d9ccda..0bb3ecb508ff 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadNexusProcessed.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadNexusProcessed.cpp @@ -66,13 +66,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_NEXUS_FILELOADER_ALGORITHM(LoadNexusProcessed); -/// Sets documentation strings for this algorithm -void LoadNexusProcessed::initDocs() -{ - this->setWikiSummary("The LoadNexusProcessed algorithm will read the given Nexus Processed data file containing a Mantid Workspace. The data is placed in the named workspace. LoadNexusProcessed may be invoked by [[LoadNexus]] if it is given a Nexus file of this type. "); - this->setOptionalMessage("The LoadNexusProcessed algorithm will read the given Nexus Processed data file containing a Mantid Workspace. The data is placed in the named workspace. LoadNexusProcessed may be invoked by LoadNexus if it is given a Nexus file of this type."); -} - using namespace Mantid::NeXus; using namespace DataObjects; using namespace Kernel; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadPDFgetNFile.cpp b/Code/Mantid/Framework/DataHandling/src/LoadPDFgetNFile.cpp index 1cfe38de9e9b..927dfe48a4c4 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadPDFgetNFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadPDFgetNFile.cpp @@ -61,12 +61,7 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- /** Init documentation - */ - void LoadPDFgetNFile::initDocs() - { - this->setWikiSummary("Loads a PDFgetN file, which is generated by PDFgetN."); - this->setOptionalMessage("Types of PDFgetN data files include .sqa, .sq, .gr, and etc."); - } + * //---------------------------------------------------------------------------------------------- /** diff --git a/Code/Mantid/Framework/DataHandling/src/LoadParameterFile.cpp b/Code/Mantid/Framework/DataHandling/src/LoadParameterFile.cpp index 128ff57d5ba7..59919e9867b4 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadParameterFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadParameterFile.cpp @@ -58,13 +58,6 @@ namespace DataHandling DECLARE_ALGORITHM(LoadParameterFile) -/// Sets documentation strings for this algorithm -void LoadParameterFile::initDocs() -{ - this->setWikiSummary("Loads instrument parameters into a [[workspace]]. where these parameters are associated component names as defined in Instrument Definition File ([[InstrumentDefinitionFile|IDF]]) or a string consisting of the contents of such.."); - this->setOptionalMessage("Loads instrument parameters into a workspace. where these parameters are associated component names as defined in Instrument Definition File (IDF) or a string consisting of the contents of such."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadPreNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadPreNexus.cpp index 1a2233b049fd..83b27e6096f5 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadPreNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadPreNexus.cpp @@ -77,12 +77,7 @@ namespace DataHandling } //---------------------------------------------------------------------------------------------- - /// @copydoc Mantid::API::Algorithm::initDocs() - void LoadPreNexus::initDocs() - { - this->setWikiSummary("Load a collection of PreNexus files."); - this->setOptionalMessage("Load a collection of PreNexus files."); - } + /// @copydoc Mantid::API:: /** * Return the confidence with with this algorithm can load the file diff --git a/Code/Mantid/Framework/DataHandling/src/LoadPreNexusMonitors.cpp b/Code/Mantid/Framework/DataHandling/src/LoadPreNexusMonitors.cpp index bdcde21cb165..e5f48bbbd65d 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadPreNexusMonitors.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadPreNexusMonitors.cpp @@ -48,15 +48,6 @@ using namespace Mantid::Geometry; static const std::string RUNINFO_FILENAME("RunInfoFilename"); static const std::string WORKSPACE_OUT("OutputWorkspace"); -//---------------------------------------------------------------------------------------------- -/** Init documentation -*/ -void LoadPreNexusMonitors::initDocs() -{ - this->setWikiSummary("This is a routine to load in the beam monitors from SNS preNeXus files into a workspace."); - this->setOptionalMessage("This is a routine to load in the beam monitors from SNS preNeXus files into a workspace."); -} - // A reference to the logger is provided by the base class, it is called g_log. // It is used to print out information, warning and error messages diff --git a/Code/Mantid/Framework/DataHandling/src/LoadQKK.cpp b/Code/Mantid/Framework/DataHandling/src/LoadQKK.cpp index d83b040b3172..6e919d11680a 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadQKK.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadQKK.cpp @@ -46,15 +46,6 @@ namespace Mantid else return 0; } - /// Sets documentation strings for this algorithm - void LoadQKK::initDocs() - { - this->setWikiSummary( - "Loads a ANSTO QKK file. "); - this->setOptionalMessage( - "Loads a ANSTO QKK file. "); - } - /** * Initialise the algorithm. Declare properties which can be set before execution (input) or * read from after the execution (output). diff --git a/Code/Mantid/Framework/DataHandling/src/LoadRKH.cpp b/Code/Mantid/Framework/DataHandling/src/LoadRKH.cpp index 4f412b6e5e29..7776c385fd87 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadRKH.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadRKH.cpp @@ -86,14 +86,6 @@ int LoadRKH::confidence(Kernel::FileDescriptor & descriptor) const return 20; // Better than LoadAscii } - -/// Sets documentation strings for this algorithm -void LoadRKH::initDocs() -{ - this->setWikiSummary("Load a file written in the RKH format"); - this->setOptionalMessage("Load a file written in the RKH format"); -} - /** * Initialise the algorithm */ diff --git a/Code/Mantid/Framework/DataHandling/src/LoadRaw.cpp b/Code/Mantid/Framework/DataHandling/src/LoadRaw.cpp index 8f0775b40bda..4e3136c9ff16 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadRaw.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadRaw.cpp @@ -10,12 +10,6 @@ namespace Mantid { // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(LoadRaw) - - /// Sets documentation strings for this algorithm - void LoadRaw::initDocs() - { - setOptionalMessage("*** This version of LoadRaw has been removed from Mantid. You should use the current version of this algorithm or try an earlier release of Mantid. ***"); - } using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadRaw2.cpp b/Code/Mantid/Framework/DataHandling/src/LoadRaw2.cpp index 933e42afa2de..f7bb11917d5a 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadRaw2.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadRaw2.cpp @@ -11,12 +11,6 @@ namespace Mantid { // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(LoadRaw2) - - /// Sets documentation strings for this algorithm - void LoadRaw2::initDocs() - { - setOptionalMessage("*** This version of LoadRaw has been removed from Mantid. You should use the current version of this algorithm or try an earlier release of Mantid. ***"); - } using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp b/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp index fd1854cbd788..fc051b6939e4 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadRaw3.cpp @@ -52,13 +52,6 @@ namespace Mantid { DECLARE_FILELOADER_ALGORITHM(LoadRaw3); - /// Sets documentation strings for this algorithm - void LoadRaw3::initDocs() - { - this->setWikiSummary("Loads a data file in ISIS [[RAW_File | RAW]] format and stores it in a 2D [[workspace]] ([[Workspace2D]] class). "); - this->setOptionalMessage("Loads a data file in ISIS RAW format and stores it in a 2D workspace (Workspace2D class)."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadRawBin0.cpp b/Code/Mantid/Framework/DataHandling/src/LoadRawBin0.cpp index 8bb86d1ab671..490debf3909c 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadRawBin0.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadRawBin0.cpp @@ -33,13 +33,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(LoadRawBin0) -/// Sets documentation strings for this algorithm -void LoadRawBin0::initDocs() -{ - this->setWikiSummary("Loads bin zero from ISIS [[RAW_File | raw]] file and stores it in a 2D [[workspace]] ([[Workspace2D]] class)."); - this->setOptionalMessage("Loads bin zero from ISIS raw file and stores it in a 2D workspace (Workspace2D class)."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadRawSpectrum0.cpp b/Code/Mantid/Framework/DataHandling/src/LoadRawSpectrum0.cpp index a767484718f4..b43fd06a5313 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadRawSpectrum0.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadRawSpectrum0.cpp @@ -32,13 +32,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(LoadRawSpectrum0) -/// Sets documentation strings for this algorithm -void LoadRawSpectrum0::initDocs() -{ - this->setWikiSummary("Loads spectrum zero from ISIS [[RAW_File | raw]] file and stores it in a 2D [[workspace]] ([[Workspace2D]] class)."); - this->setOptionalMessage("Loads spectrum zero from ISIS raw file and stores it in a 2D workspace (Workspace2D class)."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadReflTBL.cpp b/Code/Mantid/Framework/DataHandling/src/LoadReflTBL.cpp index 990b14707128..f96d4a7ddc16 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadReflTBL.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadReflTBL.cpp @@ -31,13 +31,6 @@ namespace Mantid { DECLARE_FILELOADER_ALGORITHM(LoadReflTBL); - /// Sets documentation strings for this algorithm - void LoadReflTBL::initDocs() - { - this->setWikiSummary("Loads data from a reflectometry table file and stores it in a table [[workspace]] ([[TableWorkspace]] class). "); - this->setOptionalMessage("Loads data from a reflectometry table file and stores it in a table workspace (TableWorkspace class)."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadSINQFocus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadSINQFocus.cpp index 566c6e764e79..5ccee5c4703a 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadSINQFocus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadSINQFocus.cpp @@ -63,11 +63,6 @@ const std::string LoadSINQFocus::category() const { } //---------------------------------------------------------------------------------------------- -/// Sets documentation strings for this algorithm -void LoadSINQFocus::initDocs() { - this->setWikiSummary("Loads a FOCUS nexus file from the PSI"); - this->setOptionalMessage("Loads a FOCUS nexus file from the PSI"); -} /** * Return the confidence with with this algorithm can load the file diff --git a/Code/Mantid/Framework/DataHandling/src/LoadSNSspec.cpp b/Code/Mantid/Framework/DataHandling/src/LoadSNSspec.cpp index 4aa76bf2940b..be5df65b7f6f 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadSNSspec.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadSNSspec.cpp @@ -138,14 +138,6 @@ namespace Mantid } return confidence; } - - - /// Sets documentation strings for this algorithm - void LoadSNSspec::initDocs() - { - this->setWikiSummary("Loads data from a text file and stores it in a 2D [[workspace]] ([[Workspace2D]] class)."); - this->setOptionalMessage("Loads data from a text file and stores it in a 2D workspace (Workspace2D class)."); - } using namespace Kernel; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadSPE.cpp b/Code/Mantid/Framework/DataHandling/src/LoadSPE.cpp index 989a4d052dde..72c23733cea7 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadSPE.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadSPE.cpp @@ -64,14 +64,6 @@ int LoadSPE::confidence(Kernel::FileDescriptor & descriptor) const } -/// Sets documentation strings for this algorithm -void LoadSPE::initDocs() -{ - this->setWikiSummary("Loads a file written in the spe format."); - this->setOptionalMessage("Loads a file written in the spe format."); -} - - //--------------------------------------------------- // Private member functions //--------------------------------------------------- diff --git a/Code/Mantid/Framework/DataHandling/src/LoadSampleDetailsFromRaw.cpp b/Code/Mantid/Framework/DataHandling/src/LoadSampleDetailsFromRaw.cpp index d448d540bec9..1a7283f18eec 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadSampleDetailsFromRaw.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadSampleDetailsFromRaw.cpp @@ -49,13 +49,6 @@ using namespace Mantid::DataHandling; // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(LoadSampleDetailsFromRaw) -/// Sets documentation strings for this algorithm -void LoadSampleDetailsFromRaw::initDocs() -{ - this->setWikiSummary("Loads the simple sample geometry that is defined within an ISIS raw file. "); - this->setOptionalMessage("Loads the simple sample geometry that is defined within an ISIS raw file."); -} - /** * Initialize the algorithm */ diff --git a/Code/Mantid/Framework/DataHandling/src/LoadSassena.cpp b/Code/Mantid/Framework/DataHandling/src/LoadSassena.cpp index 704b8470553e..bdcaea04aee8 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadSassena.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadSassena.cpp @@ -45,13 +45,6 @@ namespace DataHandling DECLARE_NEXUS_FILELOADER_ALGORITHM(LoadSassena); -/// Sets documentation strings for this algorithm -void LoadSassena::initDocs() -{ - this->setWikiSummary("This algorithm loads a Sassena output file into a group workspace. It places the data in a workspace for each scattering intensity and one workspace for the Q-values."); - this->setOptionalMessage(" load a Sassena output file into a group workspace."); -} - /** * Return the confidence with with this algorithm can load the file * @param descriptor A descriptor for the file diff --git a/Code/Mantid/Framework/DataHandling/src/LoadSpec.cpp b/Code/Mantid/Framework/DataHandling/src/LoadSpec.cpp index ae52b2b0dcb1..68160662b0e8 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadSpec.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadSpec.cpp @@ -75,13 +75,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(LoadSpec) - /// Sets documentation strings for this algorithm - void LoadSpec::initDocs() - { - this->setWikiSummary("Loads data from a text file and stores it in a 2D [[workspace]] ([[Workspace2D]] class)."); - this->setOptionalMessage("Loads data from a text file and stores it in a 2D workspace (Workspace2D class)."); - } - using namespace Kernel; diff --git a/Code/Mantid/Framework/DataHandling/src/LoadSpice2D.cpp b/Code/Mantid/Framework/DataHandling/src/LoadSpice2D.cpp index 486c9b22299b..3044861c0fab 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadSpice2D.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadSpice2D.cpp @@ -135,13 +135,6 @@ namespace Mantid return confidence; } - /// Sets documentation strings for this algorithm - void LoadSpice2D::initDocs() - { - this->setWikiSummary("Loads a SANS data file produce by the HFIR instruments at ORNL. The instrument geometry is also loaded. The center of the detector is placed at (0,0,D), where D is the sample-to-detector distance."); - this->setOptionalMessage("Loads a SANS data file produce by the HFIR instruments at ORNL. The instrument geometry is also loaded. The center of the detector is placed at (0,0,D), where D is the sample-to-detector distance."); - } - /// Constructor LoadSpice2D::LoadSpice2D() {} diff --git a/Code/Mantid/Framework/DataHandling/src/LoadTOFRawNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadTOFRawNexus.cpp index 6272eea8aaa7..9aa53cafef71 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadTOFRawNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadTOFRawNexus.cpp @@ -44,14 +44,6 @@ LoadTOFRawNexus::LoadTOFRawNexus() { } -//------------------------------------------------------------------------------------------------- -/** Documentation strings */ -void LoadTOFRawNexus::initDocs() -{ - this->setWikiSummary("Loads a NeXus file confirming to the TOFRaw format"); - this->setOptionalMessage("Loads a NeXus file confirming to the TOFRaw format"); -} - //------------------------------------------------------------------------------------------------- /// Initialisation method. void LoadTOFRawNexus::init() diff --git a/Code/Mantid/Framework/DataHandling/src/MaskDetectors.cpp b/Code/Mantid/Framework/DataHandling/src/MaskDetectors.cpp index 5d372ce19754..aefce62eff4e 100644 --- a/Code/Mantid/Framework/DataHandling/src/MaskDetectors.cpp +++ b/Code/Mantid/Framework/DataHandling/src/MaskDetectors.cpp @@ -71,13 +71,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(MaskDetectors) -/// Sets documentation strings for this algorithm -void MaskDetectors::initDocs() -{ - this->setWikiSummary("An algorithm to mask a detector, or set of detectors, as not to be used. The workspace spectra associated with those detectors are zeroed."); - this->setOptionalMessage("An algorithm to mask a detector, or set of detectors, as not to be used. The workspace spectra associated with those detectors are zeroed."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/MergeLogs.cpp b/Code/Mantid/Framework/DataHandling/src/MergeLogs.cpp index 1e3529726166..955e721901f2 100644 --- a/Code/Mantid/Framework/DataHandling/src/MergeLogs.cpp +++ b/Code/Mantid/Framework/DataHandling/src/MergeLogs.cpp @@ -34,14 +34,6 @@ namespace DataHandling Merge2WorkspaceLogs::~Merge2WorkspaceLogs() { } - - void Merge2WorkspaceLogs::initDocs(){ - - this->setWikiSummary("Merge 2 logs of [[TimeSeriesProperty]] in a workspace to a new [[TimeSeriesProperty]] log."); - this->setOptionalMessage("Merge 2 TimeSeries logs in a given Workspace."); - - return; - } void Merge2WorkspaceLogs::init(){ diff --git a/Code/Mantid/Framework/DataHandling/src/ModifyDetectorDotDatFile.cpp b/Code/Mantid/Framework/DataHandling/src/ModifyDetectorDotDatFile.cpp index 707cdca1f0bd..6425a2a6e8f6 100644 --- a/Code/Mantid/Framework/DataHandling/src/ModifyDetectorDotDatFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/ModifyDetectorDotDatFile.cpp @@ -61,12 +61,6 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ModifyDetectorDotDatFile::initDocs() - { - this->setWikiSummary("Modifies an ISIS detector dot data file, so that the detector positions are as in the given workspace"); - this->setOptionalMessage("Modifies an ISIS detector dot data file, so that the detector positions are as in the given workspace"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/MoveInstrumentComponent.cpp b/Code/Mantid/Framework/DataHandling/src/MoveInstrumentComponent.cpp index 4c26af0d0f24..f545c43e9c7d 100644 --- a/Code/Mantid/Framework/DataHandling/src/MoveInstrumentComponent.cpp +++ b/Code/Mantid/Framework/DataHandling/src/MoveInstrumentComponent.cpp @@ -24,13 +24,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(MoveInstrumentComponent) -/// Sets documentation strings for this algorithm -void MoveInstrumentComponent::initDocs() -{ - this->setWikiSummary("Moves an instrument component to a new position."); - this->setOptionalMessage("Moves an instrument component to a new position."); -} - using namespace Kernel; using namespace Geometry; diff --git a/Code/Mantid/Framework/DataHandling/src/NexusTester.cpp b/Code/Mantid/Framework/DataHandling/src/NexusTester.cpp index e20e3d8dd99b..8f3b667ddde1 100644 --- a/Code/Mantid/Framework/DataHandling/src/NexusTester.cpp +++ b/Code/Mantid/Framework/DataHandling/src/NexusTester.cpp @@ -65,12 +65,6 @@ namespace DataHandling const std::string NexusTester::category() const { return "Utility\\Development";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void NexusTester::initDocs() - { - this->setWikiSummary("Algorithm for testing and debugging purposes only!"); - this->setOptionalMessage("Algorithm for testing and debugging purposes only!"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/PDLoadCharacterizations.cpp b/Code/Mantid/Framework/DataHandling/src/PDLoadCharacterizations.cpp index ade3d2fe47d1..4ed12c2da54c 100644 --- a/Code/Mantid/Framework/DataHandling/src/PDLoadCharacterizations.cpp +++ b/Code/Mantid/Framework/DataHandling/src/PDLoadCharacterizations.cpp @@ -56,15 +56,6 @@ namespace DataHandling /// Algorithm's category for identification. @see Algorithm::category const std::string PDLoadCharacterizations::category() const { return "Workflow\\DataHandling";} - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void PDLoadCharacterizations::initDocs() - { - std::string descr("Load a characterization file used in Powder Diffraction Reduction."); - this->setWikiSummary(descr); - this->setOptionalMessage(descr); - } - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/DataHandling/src/ProcessDasNexusLog.cpp b/Code/Mantid/Framework/DataHandling/src/ProcessDasNexusLog.cpp index 11d35d9019e7..e24a93371f38 100644 --- a/Code/Mantid/Framework/DataHandling/src/ProcessDasNexusLog.cpp +++ b/Code/Mantid/Framework/DataHandling/src/ProcessDasNexusLog.cpp @@ -38,13 +38,6 @@ namespace DataHandling ProcessDasNexusLog::~ProcessDasNexusLog() { } - - void ProcessDasNexusLog::initDocs(){ - this->setWikiSummary("Some sample logs recorded by the SNS data acquisition group (DAS) are not usable. This very specialized algorithm will process sample logs of this type. "); - this->setOptionalMessage("Very specialized algorithm to fix certain SNS DAS logs that cannot be used directly."); - - return; - } void ProcessDasNexusLog::init() { diff --git a/Code/Mantid/Framework/DataHandling/src/RawFileInfo.cpp b/Code/Mantid/Framework/DataHandling/src/RawFileInfo.cpp index 6b8202ee3590..1c957869cf8e 100644 --- a/Code/Mantid/Framework/DataHandling/src/RawFileInfo.cpp +++ b/Code/Mantid/Framework/DataHandling/src/RawFileInfo.cpp @@ -25,13 +25,6 @@ using namespace Mantid::DataHandling; DECLARE_ALGORITHM(RawFileInfo) -/// Sets documentation strings for this algorithm -void RawFileInfo::initDocs() -{ - this->setWikiSummary("Extract run parameters from a [[RAW_File | RAW]] file as output properties. "); - this->setOptionalMessage("Extract run parameters from a RAW file as output properties."); -} - /// Initialise void RawFileInfo::init() { diff --git a/Code/Mantid/Framework/DataHandling/src/RemoveLogs.cpp b/Code/Mantid/Framework/DataHandling/src/RemoveLogs.cpp index 2a58e6859342..702f53eed341 100644 --- a/Code/Mantid/Framework/DataHandling/src/RemoveLogs.cpp +++ b/Code/Mantid/Framework/DataHandling/src/RemoveLogs.cpp @@ -37,13 +37,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(RemoveLogs) -/// Sets documentation strings for this algorithm -void RemoveLogs::initDocs() -{ - this->setWikiSummary("Remove logs from a [[workspace]]. "); - this->setOptionalMessage("Remove logs from a workspace."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/RenameLog.cpp b/Code/Mantid/Framework/DataHandling/src/RenameLog.cpp index 147e7f8fd20d..07b2639863e1 100644 --- a/Code/Mantid/Framework/DataHandling/src/RenameLog.cpp +++ b/Code/Mantid/Framework/DataHandling/src/RenameLog.cpp @@ -31,14 +31,6 @@ namespace DataHandling RenameLog::~RenameLog() { } - - void RenameLog::initDocs(){ - - this->setWikiSummary("Rename a TimeSeries log in a given Workspace."); - this->setOptionalMessage("Rename a TimeSeries log in a given Workspace."); - - return; - } void RenameLog::init(){ diff --git a/Code/Mantid/Framework/DataHandling/src/RotateInstrumentComponent.cpp b/Code/Mantid/Framework/DataHandling/src/RotateInstrumentComponent.cpp index 4f18da43dc6e..b01258a7fefe 100644 --- a/Code/Mantid/Framework/DataHandling/src/RotateInstrumentComponent.cpp +++ b/Code/Mantid/Framework/DataHandling/src/RotateInstrumentComponent.cpp @@ -21,13 +21,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(RotateInstrumentComponent) -/// Sets documentation strings for this algorithm -void RotateInstrumentComponent::initDocs() -{ - this->setWikiSummary("Rotates an instrument component. "); - this->setOptionalMessage("Rotates an instrument component."); -} - using namespace Kernel; using namespace Geometry; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveANSTOAscii.cpp b/Code/Mantid/Framework/DataHandling/src/SaveANSTOAscii.cpp index 5dab4fb6f924..c9e02c4bca6c 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveANSTOAscii.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveANSTOAscii.cpp @@ -18,13 +18,6 @@ namespace Mantid using namespace Kernel; using namespace API; - /// Sets documentation strings for this algorithm - void SaveANSTOAscii::initDocs() - { - this->setWikiSummary("Saves a 2D [[workspace]] to a tab separated ascii file. "); - this->setOptionalMessage("Saves a 2D workspace to a ascii file."); - } - /** virtual method to add information to the file before the data * however this class doesn't have any but must implement it. diff --git a/Code/Mantid/Framework/DataHandling/src/SaveAscii.cpp b/Code/Mantid/Framework/DataHandling/src/SaveAscii.cpp index 9896af799131..40cf0faa783e 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveAscii.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveAscii.cpp @@ -28,13 +28,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(SaveAscii) - /// Sets documentation strings for this algorithm - void SaveAscii::initDocs() - { - this->setWikiSummary("Saves a 2D [[workspace]] to a comma separated ascii file. "); - this->setOptionalMessage("Saves a 2D workspace to a ascii file."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveAscii2.cpp b/Code/Mantid/Framework/DataHandling/src/SaveAscii2.cpp index a1aea634f61e..e8355279513d 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveAscii2.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveAscii2.cpp @@ -28,13 +28,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(SaveAscii2) - /// Sets documentation strings for this algorithm - void SaveAscii2::initDocs() - { - this->setWikiSummary("Saves a 2D [[workspace]] to a comma separated ascii file. "); - this->setOptionalMessage("Saves a 2D workspace to a ascii file."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveCSV.cpp b/Code/Mantid/Framework/DataHandling/src/SaveCSV.cpp index 97b63aa97472..767407c725c6 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveCSV.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveCSV.cpp @@ -76,13 +76,6 @@ namespace DataHandling // Register the class into the algorithm factory DECLARE_ALGORITHM(SaveCSV) -/// Sets documentation strings for this algorithm -void SaveCSV::initDocs() -{ - this->setWikiSummary("Saves a 1D or 2D [[workspace]] to a CSV file. "); - this->setOptionalMessage("Saves a 1D or 2D workspace to a CSV file."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveCalFile.cpp b/Code/Mantid/Framework/DataHandling/src/SaveCalFile.cpp index eb015981233a..6044805b6837 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveCalFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveCalFile.cpp @@ -50,12 +50,6 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveCalFile::initDocs() - { - this->setWikiSummary("Saves a 5-column ASCII .cal file from up to 3 workspaces: a GroupingWorkspace, OffsetsWorkspace and/or MaskWorkspace."); - this->setOptionalMessage("Saves a 5-column ASCII .cal file from up to 3 workspaces: a GroupingWorkspace, OffsetsWorkspace and/or MaskWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/SaveCanSAS1D.cpp b/Code/Mantid/Framework/DataHandling/src/SaveCanSAS1D.cpp index 98c9bfd9b22b..06d8f79b9347 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveCanSAS1D.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveCanSAS1D.cpp @@ -31,13 +31,6 @@ namespace DataHandling // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SaveCanSAS1D) -/// Sets documentation strings for this algorithm -void SaveCanSAS1D::initDocs() -{ - this->setWikiSummary("Save a file in the canSAS 1-D format "); - this->setOptionalMessage("Save a file in the canSAS 1-D format"); -} - /// constructor SaveCanSAS1D::SaveCanSAS1D() diff --git a/Code/Mantid/Framework/DataHandling/src/SaveDaveGrp.cpp b/Code/Mantid/Framework/DataHandling/src/SaveDaveGrp.cpp index 3f21d99198db..52ea1f41d5d2 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveDaveGrp.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveDaveGrp.cpp @@ -36,12 +36,6 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveDaveGrp::initDocs() - { - this->setWikiSummary("Saves a 2D [[workspace]] to DAVE grouped data format file."); - this->setOptionalMessage("Saves a 2D workspace to DAVE grouped data format file.See http://www.ncnr.nist.gov/dave/documentation/ascii_help.pdf"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/SaveDetectorsGrouping.cpp b/Code/Mantid/Framework/DataHandling/src/SaveDetectorsGrouping.cpp index fce349a2bed7..a7406a2e10d7 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveDetectorsGrouping.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveDetectorsGrouping.cpp @@ -76,11 +76,6 @@ namespace DataHandling SaveDetectorsGrouping::~SaveDetectorsGrouping() { } - - void SaveDetectorsGrouping::initDocs(){ - this->setWikiSummary("Save a GroupingWorkspace to an XML file."); - this->setOptionalMessage("Save a GroupingWorkspace to an XML file."); - } /// Define input parameters void SaveDetectorsGrouping::init() diff --git a/Code/Mantid/Framework/DataHandling/src/SaveDspacemap.cpp b/Code/Mantid/Framework/DataHandling/src/SaveDspacemap.cpp index a70ab19e729c..e5bf035aa2e3 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveDspacemap.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveDspacemap.cpp @@ -44,12 +44,6 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveDspacemap::initDocs() - { - this->setWikiSummary("Saves an [[OffsetsWorkspace]] into a POWGEN-format binary dspace map file."); - this->setOptionalMessage("Saves an OffsetsWorkspace into a POWGEN-format binary dspace map file."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/SaveFocusedXYE.cpp b/Code/Mantid/Framework/DataHandling/src/SaveFocusedXYE.cpp index 2fceb14a3115..71ca330884ae 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveFocusedXYE.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveFocusedXYE.cpp @@ -31,15 +31,6 @@ using namespace Mantid::DataHandling; // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SaveFocusedXYE) -/// Sets documentation strings for this algorithm -void SaveFocusedXYE::initDocs() -{ - this->setWikiSummary( - "Saves a focused data set (usually the output of a diffraction focusing routine but not exclusively) into a three column format containing X_i, Y_i, and E_i. "); - this->setOptionalMessage( - "Saves a focused data set (usually the output of a diffraction focusing routine but not exclusively) into a three column format containing X_i, Y_i, and E_i."); -} - //--------------------------------------------------- // Private member functions //--------------------------------------------------- diff --git a/Code/Mantid/Framework/DataHandling/src/SaveFullprofResolution.cpp b/Code/Mantid/Framework/DataHandling/src/SaveFullprofResolution.cpp index 7891233a88b0..b820dd2aa658 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveFullprofResolution.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveFullprofResolution.cpp @@ -71,12 +71,7 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- /** Wiki docs - */ - void SaveFullprofResolution::initDocs() - { - this->setWikiSummary("Save a Table workspace, which contains peak profile parameters' values, to a Fullprof resolution (.irf) file."); - this->setOptionalMessage("Save a Table workspace, which contains peak profile parameters' values, to a Fullprof resolution (.irf) file."); - } + * //---------------------------------------------------------------------------------------------- /** Init to define parameters diff --git a/Code/Mantid/Framework/DataHandling/src/SaveGSS.cpp b/Code/Mantid/Framework/DataHandling/src/SaveGSS.cpp index 562ea98b2367..623ef2199ac5 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveGSS.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveGSS.cpp @@ -35,13 +35,6 @@ namespace Mantid // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SaveGSS) - /// Sets documentation strings for this algorithm - void SaveGSS::initDocs() - { - this->setWikiSummary("Saves a focused data set into a three column GSAS format. "); - this->setOptionalMessage("Saves a focused data set into a three column GSAS format."); - } - const std::string RALF("RALF"); const std::string SLOG("SLOG"); diff --git a/Code/Mantid/Framework/DataHandling/src/SaveILLCosmosAscii.cpp b/Code/Mantid/Framework/DataHandling/src/SaveILLCosmosAscii.cpp index 9b638370f3f5..3a08ccf963aa 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveILLCosmosAscii.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveILLCosmosAscii.cpp @@ -19,13 +19,6 @@ namespace Mantid DECLARE_ALGORITHM(SaveILLCosmosAscii) using namespace Kernel; using namespace API; - - /// Sets documentation strings for this algorithm - void SaveILLCosmosAscii::initDocs() - { - this->setWikiSummary("Saves a 2D [[workspace]] to a tab separated ascii file with headers for extra information. "); - this->setOptionalMessage("Saves a 2D workspace to a ascii file."); - } /// virtual method to set the extra properties required for this algorithm void SaveILLCosmosAscii::extraProps() diff --git a/Code/Mantid/Framework/DataHandling/src/SaveISISNexus.cpp b/Code/Mantid/Framework/DataHandling/src/SaveISISNexus.cpp index 5727ff0c335e..c69bdc09dd3e 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveISISNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveISISNexus.cpp @@ -38,13 +38,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(SaveISISNexus) -/// Sets documentation strings for this algorithm -void SaveISISNexus::initDocs() -{ - this->setWikiSummary("The SaveISISNexus algorithm will convert a RAW file to a NeXus file."); - this->setOptionalMessage("The SaveISISNexus algorithm will convert a RAW file to a NeXus file."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveIsawDetCal.cpp b/Code/Mantid/Framework/DataHandling/src/SaveIsawDetCal.cpp index f60842d97aa9..955e743b8f97 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveIsawDetCal.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveIsawDetCal.cpp @@ -51,12 +51,6 @@ namespace DataHandling //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveIsawDetCal::initDocs() - { - this->setWikiSummary("Saves an instrument with RectangularDetectors to an ISAW .DetCal file."); - this->setOptionalMessage("Saves an instrument with RectangularDetectors to an ISAW .DetCal file."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/DataHandling/src/SaveMask.cpp b/Code/Mantid/Framework/DataHandling/src/SaveMask.cpp index 71501e0252fa..d0f29e39d398 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveMask.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveMask.cpp @@ -89,13 +89,6 @@ namespace DataHandling SaveMask::~SaveMask() { } - - /// Sets documentation strings for this algorithm - void SaveMask::initDocs() - { - this->setWikiSummary("Save a MaskWorkspace/SpecialWorkspace2D to an XML file."); - this->setOptionalMessage("Save a MaskWorkspace/SpecialWorkspace2D to an XML file."); - } /// Define input parameters void SaveMask::init() diff --git a/Code/Mantid/Framework/DataHandling/src/SaveNISTDAT.cpp b/Code/Mantid/Framework/DataHandling/src/SaveNISTDAT.cpp index 590d230aac14..975c9838476c 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveNISTDAT.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveNISTDAT.cpp @@ -21,13 +21,6 @@ namespace DataHandling // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SaveNISTDAT) -/// Sets documentation strings for this algorithm -void SaveNISTDAT::initDocs() -{ - this->setWikiSummary("Save I(Qx,Qy) data to a text file compatible with NIST and DANSE readers."); - this->setOptionalMessage("Save I(Qx,Qy) data to a text file compatible with NIST and DANSE readers."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveNXSPE.cpp b/Code/Mantid/Framework/DataHandling/src/SaveNXSPE.cpp index 934c46a17692..8369b45ff771 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveNXSPE.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveNXSPE.cpp @@ -48,13 +48,6 @@ namespace Mantid { } - /// Sets documentation strings for this algorithm - void SaveNXSPE::initDocs() - { - this->setWikiSummary("Writes a workspace into a file in the nxspe format."); - this->setOptionalMessage("Writes a workspace into a file in the nxspe format."); - } - /** * Initialise the algorithm */ diff --git a/Code/Mantid/Framework/DataHandling/src/SaveNexus.cpp b/Code/Mantid/Framework/DataHandling/src/SaveNexus.cpp index 25a28381391b..8e710b0acfdb 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveNexus.cpp @@ -54,13 +54,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(SaveNexus) -/// Sets documentation strings for this algorithm -void SaveNexus::initDocs() -{ - this->setWikiSummary("The SaveNexus algorithm will write the given Mantid workspace to a NeXus file. SaveNexus currently just invokes [[SaveNexusProcessed]]. "); - this->setOptionalMessage("The SaveNexus algorithm will write the given Mantid workspace to a NeXus file. SaveNexus currently just invokes SaveNexusProcessed."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveNexusProcessed.cpp b/Code/Mantid/Framework/DataHandling/src/SaveNexusProcessed.cpp index 24eaeb9e5eab..9c4a224b4db1 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveNexusProcessed.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveNexusProcessed.cpp @@ -69,13 +69,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(SaveNexusProcessed) - /// Sets documentation strings for this algorithm - void SaveNexusProcessed::initDocs() - { - this->setWikiSummary("The SaveNexusProcessed algorithm will write the given Mantid workspace to a Nexus file. SaveNexusProcessed may be invoked by [[SaveNexus]]. "); - this->setOptionalMessage("The SaveNexusProcessed algorithm will write the given Mantid workspace to a Nexus file. SaveNexusProcessed may be invoked by SaveNexus."); - } - /// Empty default constructor diff --git a/Code/Mantid/Framework/DataHandling/src/SavePAR.cpp b/Code/Mantid/Framework/DataHandling/src/SavePAR.cpp index 3c2b5a7dff26..3bc0b9338482 100644 --- a/Code/Mantid/Framework/DataHandling/src/SavePAR.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SavePAR.cpp @@ -46,14 +46,7 @@ using namespace Mantid::API; using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -/// Sets documentation strings for this algorithm -void SavePAR::initDocs() -{ - this->setWikiSummary("Writes the detector geometry information of a workspace into a Tobyfit PAR format file. Uses [[FindDetectorsPar]] child algorithm to calculate actual detector's parameters. "); - this->setOptionalMessage("Writes the detector geometry information of a workspace into a Tobyfit PAR format file."); -} +// It is used to print out information, void SavePAR::init() { declareProperty(new WorkspaceProperty<> ("InputWorkspace", "", diff --git a/Code/Mantid/Framework/DataHandling/src/SavePHX.cpp b/Code/Mantid/Framework/DataHandling/src/SavePHX.cpp index 7f115144ec20..1cb79c55b19b 100644 --- a/Code/Mantid/Framework/DataHandling/src/SavePHX.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SavePHX.cpp @@ -46,14 +46,7 @@ using namespace Mantid::API; using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -/// Sets documentation strings for this algorithm -void SavePHX::initDocs() -{ - this->setWikiSummary("Writes the detector geometry information of a workspace into a PHX format file. Uses [[FindDetectorsPar]] child algorithm to calculate actual detector's parameters."); - this->setOptionalMessage("Writes the detector geometry information of a workspace into a PHX format file."); -} +// It is used to print out information, void SavePHX::init() { declareProperty(new WorkspaceProperty<> ("InputWorkspace", "", diff --git a/Code/Mantid/Framework/DataHandling/src/SaveRKH.cpp b/Code/Mantid/Framework/DataHandling/src/SaveRKH.cpp index cc17426e59d8..1efdccd7883e 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveRKH.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveRKH.cpp @@ -24,13 +24,6 @@ namespace DataHandling // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SaveRKH) -/// Sets documentation strings for this algorithm -void SaveRKH::initDocs() -{ - this->setWikiSummary("Save a file in the LOQ RKH/'FISH' format "); - this->setOptionalMessage("Save a file in the LOQ RKH/'FISH' format"); -} - using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveReflTBL.cpp b/Code/Mantid/Framework/DataHandling/src/SaveReflTBL.cpp index 06005ddb6401..97a75264f2e1 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveReflTBL.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveReflTBL.cpp @@ -35,13 +35,6 @@ namespace Mantid // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(SaveReflTBL) - /// Sets documentation strings for this algorithm - void SaveReflTBL::initDocs() - { - this->setWikiSummary("Saves a table [[workspace]] to a reflectometry tbl format ascii file. "); - this->setOptionalMessage("Saves a table workspace to a reflectometry tbl format ascii file."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveSPE.cpp b/Code/Mantid/Framework/DataHandling/src/SaveSPE.cpp index 08b2c95d4365..c574f42e3457 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveSPE.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveSPE.cpp @@ -40,13 +40,6 @@ namespace Mantid {\ throw std::runtime_error("Error writing to file. Check folder permissions and disk space.");\ } - - /// Sets documentation strings for this algorithm - void SaveSPE::initDocs() - { - this->setWikiSummary("Writes a workspace into a file the spe format. "); - this->setOptionalMessage("Writes a workspace into a file the spe format."); - } using namespace Kernel; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveToSNSHistogramNexus.cpp b/Code/Mantid/Framework/DataHandling/src/SaveToSNSHistogramNexus.cpp index d3204af35df5..ab239dbc34de 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveToSNSHistogramNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveToSNSHistogramNexus.cpp @@ -45,13 +45,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(SaveToSNSHistogramNexus) - /// Sets documentation strings for this algorithm - void SaveToSNSHistogramNexus::initDocs() - { - this->setWikiSummary("Saves a workspace into SNS histogrammed NeXus format, using an original file as the starting point. This only works for instruments with Rectangular Detectors. "); - this->setOptionalMessage("Saves a workspace into SNS histogrammed NeXus format, using an original file as the starting point. This only works for instruments with Rectangular Detectors."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/SaveVTK.cpp b/Code/Mantid/Framework/DataHandling/src/SaveVTK.cpp index 78aa90d53d97..301df0948805 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveVTK.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveVTK.cpp @@ -24,13 +24,6 @@ namespace Mantid // Register algorithm with AlgorithmFactory DECLARE_ALGORITHM(SaveVTK) - /// Sets documentation strings for this algorithm - void SaveVTK::initDocs() - { - this->setWikiSummary("Save a workspace out to a VTK file format for use with 3D visualisation tools such as Paraview. "); - this->setOptionalMessage("Save a workspace out to a VTK file format for use with 3D visualisation tools such as Paraview."); - } - using namespace Kernel; using namespace DataObjects; diff --git a/Code/Mantid/Framework/DataHandling/src/SetSampleMaterial.cpp b/Code/Mantid/Framework/DataHandling/src/SetSampleMaterial.cpp index d5f41acc5706..98a3b4e76adf 100644 --- a/Code/Mantid/Framework/DataHandling/src/SetSampleMaterial.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SetSampleMaterial.cpp @@ -71,13 +71,6 @@ namespace Mantid return "Sample;DataHandling"; } - /// Sets documentation strings for this algorithm - void SetSampleMaterial::initDocs() - { - this->setWikiSummary("Sets the neutrons information in the sample."); - this->setOptionalMessage("Sets the neutrons information in the sample."); - } - using namespace Mantid::DataHandling; using namespace Mantid::API; using namespace Kernel; diff --git a/Code/Mantid/Framework/DataHandling/src/SetScalingPSD.cpp b/Code/Mantid/Framework/DataHandling/src/SetScalingPSD.cpp index 3579a3fca8d0..d8e8d19ced07 100644 --- a/Code/Mantid/Framework/DataHandling/src/SetScalingPSD.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SetScalingPSD.cpp @@ -73,13 +73,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(SetScalingPSD) - /// Sets documentation strings for this algorithm - void SetScalingPSD::initDocs() - { - this->setWikiSummary("For an instrument with Position Sensitive Detectors (PSDs) the \"engineering\" positions of individual detectors may not match the true areas where neutrons are detected. This algorithm reads data on the calibrated location of the detectors and adjusts the parametrized instrument geometry accordingly. "); - this->setOptionalMessage("For an instrument with Position Sensitive Detectors (PSDs) the 'engineering' positions of individual detectors may not match the true areas where neutrons are detected. This algorithm reads data on the calibrated location of the detectors and adjusts the parametrized instrument geometry accordingly."); - } - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/DataHandling/src/UpdateInstrumentFromFile.cpp b/Code/Mantid/Framework/DataHandling/src/UpdateInstrumentFromFile.cpp index 0936e932c141..c8e1bbe6be61 100644 --- a/Code/Mantid/Framework/DataHandling/src/UpdateInstrumentFromFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/UpdateInstrumentFromFile.cpp @@ -62,13 +62,6 @@ namespace Mantid { DECLARE_ALGORITHM(UpdateInstrumentFromFile) - - /// Sets documentation strings for this algorithm - void UpdateInstrumentFromFile::initDocs() - { - this->setWikiSummary("Update detector positions initially loaded in from Instrument Definition File ([[InstrumentDefinitionFile|IDF]]) from information the given file. Note doing this will results in a slower performance (likely slightly slower performance) compared to specifying the correct detector positions in the IDF in the first place. It is assumed that the positions specified in the raw file are all with respect to the a coordinate system defined with its origin at the sample position. Note that this algorithm moves the detectors without subsequent rotation, hence this means that detectors may not for example face the sample perfectly after this algorithm has been applied."); - this->setOptionalMessage("Updates detector positions initially loaded in from the Instrument Definition File (IDF) with information from the provided file."); - } using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogDownloadDataFiles.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogDownloadDataFiles.h index b267d01339b5..60bb8671a4e6 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogDownloadDataFiles.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogDownloadDataFiles.h @@ -52,6 +52,9 @@ namespace Mantid ~CatalogDownloadDataFiles(){} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CatalogDownloadDataFiles"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Downloads the given data files from the data server";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -66,8 +69,7 @@ namespace Mantid std::string testDownload(const std::string& URL,const std::string& fileName); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogGetDataFiles.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogGetDataFiles.h index f0d8d6d7fa59..1334f90360e9 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogGetDataFiles.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogGetDataFiles.h @@ -52,14 +52,16 @@ namespace Mantid /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CatalogGetDataFiles"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Gets the files associated to the selected investigation.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogGetDataSets.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogGetDataSets.h index 570a70472eb7..0b35a6d6a255 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogGetDataSets.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogGetDataSets.h @@ -51,14 +51,16 @@ namespace Mantid /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CatalogGetDataSets"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Gets the datasets associated to the selected investigation.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm init method. void init(); /// Overwrites Algorithm exec method diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogKeepAlive.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogKeepAlive.h index b9550f818d24..06aa17ce0c4c 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogKeepAlive.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogKeepAlive.h @@ -45,14 +45,16 @@ namespace Mantid CatalogKeepAlive() : API::Algorithm(){} /// Algorithm's name for identification. virtual const std::string name() const { return "CatalogKeepAlive"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Refreshes the current session to the maximum amount provided by the catalog API";} + /// Algorithm's version for identification. virtual int version() const { return 1; } /// Algorithm's category for identification. virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Override algorithm initialisation method. void init(); /// Override algorithm execute method. diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogListInstruments.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogListInstruments.h index dff6b55089ab..300eee4bb76a 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogListInstruments.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogListInstruments.h @@ -42,14 +42,16 @@ namespace Mantid ~CatalogListInstruments(){} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CatalogListInstruments"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Lists the name of instruments from Information catalog.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm init method. void init(); /// Overwrites Algorithm exec method diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogListInvestigationTypes.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogListInvestigationTypes.h index 15ecd288f0ea..113ac6bfa0ae 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogListInvestigationTypes.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogListInvestigationTypes.h @@ -43,14 +43,16 @@ namespace Mantid ~CatalogListInvestigationTypes(){} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CatalogListInvestigationTypes"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Lists the name of investigation types from the Information catalog.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm init method. void init(); /// Overwrites Algorithm exec method diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogLogin.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogLogin.h index 63a0f1f12daf..64cd8160c0ba 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogLogin.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogLogin.h @@ -48,14 +48,16 @@ namespace Mantid ~CatalogLogin(){} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CatalogLogin"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Connects to information catalog using user name and password.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm method. void init(); /// Overwrites Algorithm method diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogLogout.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogLogout.h index de7b0fd1fecc..0cf3582e818f 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogLogout.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogLogout.h @@ -43,13 +43,15 @@ namespace Mantid ~CatalogLogout(){} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CatalogLogout"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Logs out of a specific catalog using the session information provided.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogMyDataSearch.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogMyDataSearch.h index 964003d61d09..35270e2a4623 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogMyDataSearch.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogMyDataSearch.h @@ -49,14 +49,16 @@ namespace Mantid ~CatalogMyDataSearch() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CatalogMyDataSearch"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm loads the logged in users' investigations into a workspace.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm init method. void init(); /// Overwrites Algorithm exec method diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogPublish.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogPublish.h index 41bcb481f9de..aaa904bb5db1 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogPublish.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogPublish.h @@ -51,14 +51,16 @@ namespace Mantid ~CatalogPublish(){} /// Algorithm's name for identification. virtual const std::string name() const { return "CatalogPublish"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Allows the user to publish datafiles or workspaces to the information catalog.";} + /// Algorithm's version for identification. virtual int version() const { return 1; } /// Algorithm's category for identification. virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Override algorithm initialisation method. void init(); /// Override algorithm execute method. diff --git a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogSearch.h b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogSearch.h index 863e3978feae..5f33e9d4b73d 100644 --- a/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogSearch.h +++ b/Code/Mantid/Framework/ICat/inc/MantidICat/CatalogSearch.h @@ -60,14 +60,16 @@ namespace Mantid ~CatalogSearch() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "CatalogSearch"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Searches investigations in the catalog using the properties set.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\Catalog"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Overwrites Algorithm init method. void init(); /// Overwrites Algorithm exec method diff --git a/Code/Mantid/Framework/ICat/src/CatalogDownloadDataFiles.cpp b/Code/Mantid/Framework/ICat/src/CatalogDownloadDataFiles.cpp index 5ffa842e3f5a..bb841a9eac98 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogDownloadDataFiles.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogDownloadDataFiles.cpp @@ -38,13 +38,6 @@ namespace Mantid DECLARE_ALGORITHM(CatalogDownloadDataFiles) - /// Sets documentation strings for this algorithm - void CatalogDownloadDataFiles::initDocs() - { - this->setWikiSummary("Downloads the given data files from the data server "); - this->setOptionalMessage("Downloads the given data files from the data server"); - } - /// declaring algorithm properties void CatalogDownloadDataFiles::init() diff --git a/Code/Mantid/Framework/ICat/src/CatalogGetDataFiles.cpp b/Code/Mantid/Framework/ICat/src/CatalogGetDataFiles.cpp index c9cb5bc98cff..31d4900c21b3 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogGetDataFiles.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogGetDataFiles.cpp @@ -15,13 +15,6 @@ namespace Mantid { DECLARE_ALGORITHM(CatalogGetDataFiles) - /// Sets documentation strings for this algorithm - void CatalogGetDataFiles::initDocs() - { - this->setWikiSummary("Gets the files associated to the selected investigation."); - this->setOptionalMessage("Gets the files associated to the selected investigation."); - } - /// Initialising the algorithm void CatalogGetDataFiles::init() { diff --git a/Code/Mantid/Framework/ICat/src/CatalogGetDataSets.cpp b/Code/Mantid/Framework/ICat/src/CatalogGetDataSets.cpp index fff0b3f0d22a..cae8a0c1fc00 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogGetDataSets.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogGetDataSets.cpp @@ -14,13 +14,6 @@ namespace Mantid { DECLARE_ALGORITHM(CatalogGetDataSets) - /// Sets documentation strings for this algorithm - void CatalogGetDataSets::initDocs() - { - this->setWikiSummary("Gets the datasets associated to the selected investigation. "); - this->setOptionalMessage("Gets the datasets associated to the selected investigation."); - } - /// Initialisation methods void CatalogGetDataSets::init() { diff --git a/Code/Mantid/Framework/ICat/src/CatalogKeepAlive.cpp b/Code/Mantid/Framework/ICat/src/CatalogKeepAlive.cpp index 2d7b70e9f0e4..56fd8ee1a7d8 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogKeepAlive.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogKeepAlive.cpp @@ -15,12 +15,6 @@ namespace Mantid { DECLARE_ALGORITHM(CatalogKeepAlive) - void CatalogKeepAlive::initDocs() - { - this->setWikiSummary("Refreshes the current session to the maximum amount provided by the catalog API"); - this->setOptionalMessage("Refreshes the current session to the maximum amount provided by the catalog API"); - } - void CatalogKeepAlive::init() { declareProperty("Session","","The session information of the catalog to use."); diff --git a/Code/Mantid/Framework/ICat/src/CatalogListInstruments.cpp b/Code/Mantid/Framework/ICat/src/CatalogListInstruments.cpp index bf4d3d4459e6..6fcd1b35b46d 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogListInstruments.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogListInstruments.cpp @@ -15,13 +15,6 @@ namespace Mantid DECLARE_ALGORITHM(CatalogListInstruments) - /// Sets documentation strings for this algorithm - void CatalogListInstruments::initDocs() - { - this->setWikiSummary("Lists the name of instruments from Information catalog. "); - this->setOptionalMessage("Lists the name of instruments from Information catalog."); - } - /// Init method void CatalogListInstruments::init() { diff --git a/Code/Mantid/Framework/ICat/src/CatalogListInvestigationTypes.cpp b/Code/Mantid/Framework/ICat/src/CatalogListInvestigationTypes.cpp index 76b8c1926e59..191cdc13b4db 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogListInvestigationTypes.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogListInvestigationTypes.cpp @@ -14,13 +14,6 @@ namespace Mantid { DECLARE_ALGORITHM(CatalogListInvestigationTypes) - /// Sets documentation strings for this algorithm - void CatalogListInvestigationTypes::initDocs() - { - this->setWikiSummary("Lists the name of investigation types from the Information catalog. "); - this->setOptionalMessage("Lists the name of investigation types from the Information catalog."); - } - /// Init method void CatalogListInvestigationTypes::init() { diff --git a/Code/Mantid/Framework/ICat/src/CatalogLogin.cpp b/Code/Mantid/Framework/ICat/src/CatalogLogin.cpp index f9225a0fc091..d0660173e756 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogLogin.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogLogin.cpp @@ -22,13 +22,6 @@ namespace Mantid { DECLARE_ALGORITHM(CatalogLogin) - /// Sets documentation strings for this algorithm - void CatalogLogin::initDocs() - { - this->setWikiSummary("Connects to information catalog using user name and password."); - this->setOptionalMessage("Connects to information catalog using user name and password."); - } - /// Init method to declare algorithm properties void CatalogLogin::init() { diff --git a/Code/Mantid/Framework/ICat/src/CatalogLogout.cpp b/Code/Mantid/Framework/ICat/src/CatalogLogout.cpp index 8625105dc83b..2c76aeeebeca 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogLogout.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogLogout.cpp @@ -15,13 +15,6 @@ namespace Mantid { DECLARE_ALGORITHM(CatalogLogout) - /// Sets documentation strings for this algorithm - void CatalogLogout::initDocs() - { - this->setWikiSummary("Logs out of a specific catalog using the session information provided."); - this->setOptionalMessage("Logs out of a specific catalog using the session information provided."); - } - /// Init method to declare algorithm properties void CatalogLogout::init() { diff --git a/Code/Mantid/Framework/ICat/src/CatalogMyDataSearch.cpp b/Code/Mantid/Framework/ICat/src/CatalogMyDataSearch.cpp index 3254c34f6351..cdf64f20d64a 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogMyDataSearch.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogMyDataSearch.cpp @@ -13,13 +13,6 @@ namespace Mantid { DECLARE_ALGORITHM(CatalogMyDataSearch) - /// Sets documentation strings for this algorithm - void CatalogMyDataSearch::initDocs() - { - this->setWikiSummary("This algorithm loads the logged in users' investigations into a workspace."); - this->setOptionalMessage("This algorithm loads the logged in users' investigations into a workspace."); - } - /// Initialisation method. void CatalogMyDataSearch::init() { diff --git a/Code/Mantid/Framework/ICat/src/CatalogPublish.cpp b/Code/Mantid/Framework/ICat/src/CatalogPublish.cpp index a57ef6571c93..72efd80a16e8 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogPublish.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogPublish.cpp @@ -43,14 +43,6 @@ namespace Mantid { DECLARE_ALGORITHM(CatalogPublish) - /// Sets documentation strings for this algorithm - void CatalogPublish::initDocs() - { - this->setWikiSummary("Allows the user to publish datafiles or workspaces to the information catalog. " - "Workspaces are converted to nexus files (store in the default save directory), and then uploaded from there."); - this->setOptionalMessage("Allows the user to publish datafiles or workspaces to the information catalog."); - } - /// Init method to declare algorithm properties void CatalogPublish::init() { diff --git a/Code/Mantid/Framework/ICat/src/CatalogSearch.cpp b/Code/Mantid/Framework/ICat/src/CatalogSearch.cpp index d411bb113d12..240f17647d7b 100644 --- a/Code/Mantid/Framework/ICat/src/CatalogSearch.cpp +++ b/Code/Mantid/Framework/ICat/src/CatalogSearch.cpp @@ -27,13 +27,6 @@ namespace Mantid { DECLARE_ALGORITHM(CatalogSearch) - /// Sets documentation strings for this algorithm - void CatalogSearch::initDocs() - { - this->setWikiSummary("Searches investigations in the catalog using the properties set."); - this->setOptionalMessage("Searches investigations in the catalog using the properties set."); - } - /// Initialisation method. void CatalogSearch::init() { diff --git a/Code/Mantid/Framework/ISISLiveData/inc/MantidISISLiveData/FakeISISEventDAE.h b/Code/Mantid/Framework/ISISLiveData/inc/MantidISISLiveData/FakeISISEventDAE.h index 541f1f57ae71..67a2e8cdee99 100644 --- a/Code/Mantid/Framework/ISISLiveData/inc/MantidISISLiveData/FakeISISEventDAE.h +++ b/Code/Mantid/Framework/ISISLiveData/inc/MantidISISLiveData/FakeISISEventDAE.h @@ -54,9 +54,12 @@ class FakeISISEventDAE : public API::Algorithm virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\DataAcquisition";} + + /// Algorithm's summary + virtual const std::string summary() const { return "Simulates ISIS event DAE."; } + private: - void initDocs(); void init(); void exec(); /// Poco TCP server diff --git a/Code/Mantid/Framework/ISISLiveData/src/FakeISISEventDAE.cpp b/Code/Mantid/Framework/ISISLiveData/src/FakeISISEventDAE.cpp index 111b7437be0f..c62bcf1d9cb3 100644 --- a/Code/Mantid/Framework/ISISLiveData/src/FakeISISEventDAE.cpp +++ b/Code/Mantid/Framework/ISISLiveData/src/FakeISISEventDAE.cpp @@ -135,13 +135,6 @@ class TestServerConnectionFactory: public Poco::Net::TCPServerConnectionFactory } }; -/// Sets documentation strings for this algorithm -void FakeISISEventDAE::initDocs() -{ - this->setWikiSummary("Simulates ISIS event DAE. "); - this->setOptionalMessage("Simulates ISIS event DAE."); -} - using namespace Kernel; using namespace API; From 396c2ad714fed2c0d39e829a0eee032906faa0d7 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 17:46:49 +0100 Subject: [PATCH 083/126] Fix MantidPlot screenshot test. The extension is now expected as part of the filename. Refs #5321 --- .../Mantid/MantidPlot/test/MantidPlotAlgorithmDialogTest.py | 6 +++--- Code/Mantid/scripts/WikiMaker/ScreenshotAlgDialogs.py | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Code/Mantid/MantidPlot/test/MantidPlotAlgorithmDialogTest.py b/Code/Mantid/MantidPlot/test/MantidPlotAlgorithmDialogTest.py index 4d612a3407af..3bb0da5fca89 100644 --- a/Code/Mantid/MantidPlot/test/MantidPlotAlgorithmDialogTest.py +++ b/Code/Mantid/MantidPlot/test/MantidPlotAlgorithmDialogTest.py @@ -23,10 +23,10 @@ def test_ScreenShotDialog(self): interface_manager = mantidqtpython.MantidQt.API.InterfaceManager() dialog = threadsafe_call( interface_manager.createDialogFromName, self.__target_algorithm__, self.__clean_properties__) screenshotdir = tempfile.gettempdir(); - file = "CreateMDWorkspace_screenshot" - screenshot_to_dir(widget=dialog, filename=file, screenshot_dir=screenshotdir) + filename = "CreateMDWorkspace_screenshot.png" + screenshot_to_dir(widget=dialog, filename=filename, screenshot_dir=screenshotdir) threadsafe_call(dialog.close) - file_abs = os.path.join(screenshotdir, file + ".png") + file_abs = os.path.join(screenshotdir, filename) file_exists = os.path.isfile(file_abs) self.assertEquals(file_exists, True, "Screenshot was not written out as expected.") if file_exists: diff --git a/Code/Mantid/scripts/WikiMaker/ScreenshotAlgDialogs.py b/Code/Mantid/scripts/WikiMaker/ScreenshotAlgDialogs.py index 2017cf855904..ff9be6948c72 100644 --- a/Code/Mantid/scripts/WikiMaker/ScreenshotAlgDialogs.py +++ b/Code/Mantid/scripts/WikiMaker/ScreenshotAlgDialogs.py @@ -14,10 +14,10 @@ def screenShotAlgorithm(alg_name): interface_manager = mantidqtpython.MantidQt.API.InterfaceManager() dlg = threadsafe_call( interface_manager.createDialogFromName, alg_name, True) - file = alg_name + "_dlg" - screenshot_to_dir(widget=dlg, filename=file, screenshot_dir=screenshotdir) + filename = alg_name + "_dlg.png" + screenshot_to_dir(widget=dlg, filename=filename, screenshot_dir=screenshotdir) threadsafe_call(dlg.close) - file_abs = os.path.join(screenshotdir, file + ".png") + file_abs = os.path.join(screenshotdir, filename) """ Screenshot all registered algorithms. From ca9b3bf99a3af2660c96d57c28cf07ec5f0e9256 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 22:42:51 +0100 Subject: [PATCH 084/126] Allow doc migrate tool to use subdirectories Refs #9523 --- Code/Tools/DocMigration/MigrateOptMessage.py | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/Code/Tools/DocMigration/MigrateOptMessage.py b/Code/Tools/DocMigration/MigrateOptMessage.py index 8d7ed3a719ba..9cd9ef764ae4 100644 --- a/Code/Tools/DocMigration/MigrateOptMessage.py +++ b/Code/Tools/DocMigration/MigrateOptMessage.py @@ -16,12 +16,20 @@ def main(): for filename in fnmatch.filter(filenames, '*.cpp'): cppFiles.append(os.path.join(root, filename)) + cppFiles.sort() for cppFile in cppFiles: cppdir = os.path.dirname(cppFile) (cppname,cppext) = os.path.splitext(os.path.basename(cppFile)) print cppname,"\t", #get .h file + subdir = "" + if not cppdir.endswith("src"): + idx = cppdir.find("src") + if idx >= 0: + subdir = cppdir[idx+3:] + cppdir = cppdir[0:idx+3] + moduledir = os.path.dirname(cppdir) incdir = os.path.join(moduledir,"inc") #this should contain only one directory @@ -31,11 +39,11 @@ def main(): pass else: hdir = os.path.join(incdir,x) - hFile = os.path.join(hdir,cppname+".h") + hFile = os.path.join(hdir + subdir,cppname+".h") if not os.path.isfile(hFile): print "HEADER NOT FOUND" #next file - break + continue #read cppFile cppText= "" @@ -50,6 +58,7 @@ def main(): summary = readOptionalMessage(cppText) summary = striplinks(summary) + if summary != "": hText=insertSummaryCommand(hText,summary) hText=removeHeaderInitDocs(hText) @@ -90,7 +99,7 @@ def removeOptionalMessage(cppText): return retVal def removeHeaderInitDocs(hText): - retVal = regexReplace(r'//[\w\s/]*initDocs.*?$','',hText,re.MULTILINE+re.DOTALL) + retVal = regexReplace(r'[\w\s/]*initDocs.*?$','',hText,re.MULTILINE+re.DOTALL) return retVal def insertSummaryCommand(hText,summary): @@ -115,4 +124,4 @@ def regexReplace(regex,replaceString,inputString,regexOpts): -main() \ No newline at end of file +main() From 2e6e5515b41febdabbeb08450edd7ad940739007 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 22:44:19 +0100 Subject: [PATCH 085/126] Convert to summary method in MDEvent/MDAlgorithms Refs #9523 --- .../MDAlgorithms/inc/MantidMDAlgorithms/BinMD.h | 5 +++-- .../BooleanBinaryOperationMD.h | 5 +++-- .../inc/MantidMDAlgorithms/CentroidPeaksMD.h | 5 +++-- .../inc/MantidMDAlgorithms/CentroidPeaksMD2.h | 5 +++-- .../inc/MantidMDAlgorithms/CloneMDWorkspace.h | 5 +++-- .../inc/MantidMDAlgorithms/CompareMDWorkspaces.h | 4 +++- .../MantidMDAlgorithms/ConvertToDetectorFaceMD.h | 4 +++- .../ConvertToDiffractionMDWorkspace.h | 5 +++-- .../ConvertToDiffractionMDWorkspace2.h | 5 +++-- .../inc/MantidMDAlgorithms/ConvertToMD.h | 5 +++-- .../MantidMDAlgorithms/ConvertToMDMinMaxGlobal.h | 4 +++- .../MantidMDAlgorithms/ConvertToMDMinMaxLocal.h | 4 +++- .../inc/MantidMDAlgorithms/ConvertToMDParent.h | 5 ----- .../MantidMDAlgorithms/CreateMDHistoWorkspace.h | 4 +++- .../inc/MantidMDAlgorithms/CreateMDWorkspace.h | 5 +++-- .../inc/MantidMDAlgorithms/DivideMD.h | 4 +++- .../inc/MantidMDAlgorithms/ExponentialMD.h | 4 +++- .../inc/MantidMDAlgorithms/FakeMDEventData.h | 5 +++-- .../inc/MantidMDAlgorithms/FindPeaksMD.h | 5 +++-- .../inc/MantidMDAlgorithms/GreaterThanMD.h | 5 +++-- .../inc/MantidMDAlgorithms/IntegratePeaksMD.h | 5 +++-- .../inc/MantidMDAlgorithms/IntegratePeaksMD2.h | 5 +++-- .../MDAlgorithms/inc/MantidMDAlgorithms/LoadMD.h | 5 +++-- .../inc/MantidMDAlgorithms/LoadSQW.h | 5 +++-- .../inc/MantidMDAlgorithms/LogarithmMD.h | 4 +++- .../MDAlgorithms/inc/MantidMDAlgorithms/MaskMD.h | 4 +++- .../inc/MantidMDAlgorithms/MergeMD.h | 4 +++- .../inc/MantidMDAlgorithms/MergeMDFiles.h | 5 +++-- .../inc/MantidMDAlgorithms/MinusMD.h | 4 +++- .../inc/MantidMDAlgorithms/MultiplyMD.h | 4 +++- .../MDAlgorithms/inc/MantidMDAlgorithms/NotMD.h | 4 +++- .../MDAlgorithms/inc/MantidMDAlgorithms/PlusMD.h | 5 +++-- .../inc/MantidMDAlgorithms/PowerMD.h | 4 +++- .../MantidMDAlgorithms/PreprocessDetectorsToMD.h | 5 +++-- .../Quantification/FitResolutionConvolvedModel.h | 4 +++- .../SimulateResolutionConvolvedModel.h | 4 +++- .../MDAlgorithms/inc/MantidMDAlgorithms/SaveMD.h | 5 +++-- .../inc/MantidMDAlgorithms/SaveZODS.h | 4 +++- .../inc/MantidMDAlgorithms/SetMDUsingMask.h | 4 +++- .../inc/MantidMDAlgorithms/SliceMD.h | 5 +++-- .../inc/MantidMDAlgorithms/Stitch1DMD.h | 5 +++-- .../inc/MantidMDAlgorithms/ThresholdMD.h | 4 +++- .../inc/MantidMDAlgorithms/TransformMD.h | 4 +++- .../inc/MantidMDAlgorithms/WeightedMeanMD.h | 5 +++-- Code/Mantid/Framework/MDAlgorithms/src/BinMD.cpp | 6 ------ .../src/BooleanBinaryOperationMD.cpp | 7 +++---- .../MDAlgorithms/src/CentroidPeaksMD.cpp | 6 ------ .../MDAlgorithms/src/CentroidPeaksMD2.cpp | 6 ------ .../MDAlgorithms/src/CloneMDWorkspace.cpp | 6 ------ .../MDAlgorithms/src/CompareMDWorkspaces.cpp | 6 ------ .../MDAlgorithms/src/ConvertToDetectorFaceMD.cpp | 6 ------ .../src/ConvertToDiffractionMDWorkspace.cpp | 7 ------- .../src/ConvertToDiffractionMDWorkspace2.cpp | 7 ------- .../Framework/MDAlgorithms/src/ConvertToMD.cpp | 16 ---------------- .../MDAlgorithms/src/ConvertToMDMinMaxGlobal.cpp | 6 ------ .../MDAlgorithms/src/ConvertToMDMinMaxLocal.cpp | 7 ------- .../MDAlgorithms/src/CreateMDHistoWorkspace.cpp | 6 ------ .../MDAlgorithms/src/CreateMDWorkspace.cpp | 7 ------- .../Framework/MDAlgorithms/src/DivideMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/ExponentialMD.cpp | 6 ------ .../MDAlgorithms/src/FakeMDEventData.cpp | 6 ------ .../Framework/MDAlgorithms/src/FindPeaksMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/GreaterThanMD.cpp | 7 ------- .../MDAlgorithms/src/IntegratePeaksMD.cpp | 6 ------ .../MDAlgorithms/src/IntegratePeaksMD2.cpp | 6 ------ .../Mantid/Framework/MDAlgorithms/src/LoadMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/LoadSQW.cpp | 5 ----- .../Framework/MDAlgorithms/src/LogarithmMD.cpp | 6 ------ .../Mantid/Framework/MDAlgorithms/src/MaskMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/MergeMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/MergeMDFiles.cpp | 6 ------ .../Framework/MDAlgorithms/src/MinusMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/MultiplyMD.cpp | 6 ------ Code/Mantid/Framework/MDAlgorithms/src/NotMD.cpp | 6 ------ .../Mantid/Framework/MDAlgorithms/src/PlusMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/PowerMD.cpp | 6 ------ .../MDAlgorithms/src/PreprocessDetectorsToMD.cpp | 10 ---------- .../FitResolutionConvolvedModel.cpp | 7 ------- .../SimulateResolutionConvolvedModel.cpp | 7 ------- .../Mantid/Framework/MDAlgorithms/src/SaveMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/SaveZODS.cpp | 6 ------ .../MDAlgorithms/src/SetMDUsingMask.cpp | 6 ------ .../Framework/MDAlgorithms/src/SliceMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/Stitch1DMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/ThresholdMD.cpp | 6 ------ .../Framework/MDAlgorithms/src/TransformMD.cpp | 6 ------ .../MDAlgorithms/src/WeightedMeanMD.cpp | 6 ------ .../inc/MantidMDEvents/ConvertToReflectometryQ.h | 4 +++- .../inc/MantidMDEvents/ImportMDEventWorkspace.h | 6 ++++-- .../inc/MantidMDEvents/ImportMDHistoWorkspace.h | 6 ++++-- .../inc/MantidMDEvents/IntegrateEllipsoids.h | 4 +++- .../MDEvents/inc/MantidMDEvents/OneStepMDEW.h | 6 ++++-- .../inc/MantidMDEvents/QueryMDWorkspace.h | 6 ++++-- .../inc/MantidMDEvents/SaveIsawQvector.h | 4 +++- .../MDEvents/src/ConvertToReflectometryQ.cpp | 6 ------ .../MDEvents/src/ImportMDEventWorkspace.cpp | 6 ------ .../MDEvents/src/ImportMDHistoWorkspace.cpp | 6 ------ .../MDEvents/src/IntegrateEllipsoids.cpp | 7 ------- .../Framework/MDEvents/src/OneStepMDEW.cpp | 6 ------ .../Framework/MDEvents/src/QueryMDWorkspace.cpp | 7 ------- .../Framework/MDEvents/src/SaveIsawQvector.cpp | 9 --------- 101 files changed, 157 insertions(+), 405 deletions(-) diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BinMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BinMD.h index 19f63d679437..c956b6d736fc 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BinMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BinMD.h @@ -41,14 +41,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "BinMD";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Take a MDEventWorkspace and bin into into a dense, multi-dimensional histogram workspace (MDHistoWorkspace).";} + /// Algorithm's version for identification virtual int version() const { return 1;} /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BooleanBinaryOperationMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BooleanBinaryOperationMD.h index fbf58abe3a6f..fe8d9bf1c7b5 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BooleanBinaryOperationMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BooleanBinaryOperationMD.h @@ -41,6 +41,9 @@ namespace MDAlgorithms virtual ~BooleanBinaryOperationMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const; + virtual int version() const; protected: @@ -48,8 +51,6 @@ namespace MDAlgorithms virtual bool acceptScalar() const { return true; } virtual bool commutative() const; - - virtual void initDocs(); void checkInputs(); void execEvent(); virtual void execHistoScalar(Mantid::MDEvents::MDHistoWorkspace_sptr out, Mantid::DataObjects::WorkspaceSingleValue_const_sptr scalar); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CentroidPeaksMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CentroidPeaksMD.h index c6bb196550e6..9871a2313131 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CentroidPeaksMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CentroidPeaksMD.h @@ -25,14 +25,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "CentroidPeaksMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Find the centroid of single-crystal peaks in a MDEventWorkspace, in order to refine their positions.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CentroidPeaksMD2.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CentroidPeaksMD2.h index f12b6036318b..f13adae6c6ee 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CentroidPeaksMD2.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CentroidPeaksMD2.h @@ -25,14 +25,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "CentroidPeaksMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Find the centroid of single-crystal peaks in a MDEventWorkspace, in order to refine their positions.";} + /// Algorithm's version for identification virtual int version() const { return 2;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CloneMDWorkspace.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CloneMDWorkspace.h index 9e71263ab687..09439381b107 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CloneMDWorkspace.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CloneMDWorkspace.h @@ -44,14 +44,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "CloneMDWorkspace";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Clones (copies) an existing MDEventWorkspace or MDHistoWorkspace into a new one.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CompareMDWorkspaces.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CompareMDWorkspaces.h index cdda4db98fe1..2305689b958b 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CompareMDWorkspaces.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CompareMDWorkspaces.h @@ -43,11 +43,13 @@ namespace MDAlgorithms virtual ~CompareMDWorkspaces(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Compare two MDWorkspaces for equality.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); void doComparison(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDetectorFaceMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDetectorFaceMD.h index 6d2c229e5bf3..e7e51e5e9d96 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDetectorFaceMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDetectorFaceMD.h @@ -47,11 +47,13 @@ namespace MDAlgorithms virtual ~ConvertToDetectorFaceMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Convert a MatrixWorkspace containing to a MD workspace for viewing the detector face.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDiffractionMDWorkspace.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDiffractionMDWorkspace.h index d30bdb0b335d..0686cf0c2ca0 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDiffractionMDWorkspace.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDiffractionMDWorkspace.h @@ -33,14 +33,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "ConvertToDiffractionMDWorkspace";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz) for an elastic diffraction experiment.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDiffractionMDWorkspace2.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDiffractionMDWorkspace2.h index 1c9bef7a9468..6bf422540906 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDiffractionMDWorkspace2.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToDiffractionMDWorkspace2.h @@ -38,14 +38,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "ConvertToDiffractionMDWorkspace";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz) for an elastic diffraction experiment.";} + /// Algorithm's version for identification virtual int version() const { return 2;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMD.h index 03c721a1825f..83565bf31bb6 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMD.h @@ -57,6 +57,9 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create a MDEventWorkspace with selected dimensions, e.g. the reciprocal space of momentums (Qx, Qy, Qz) or momentums modules |Q|, energy transfer dE if availible and any other user specified log values which can be treated as dimensions.";} + /// Algorithm's version for identification virtual int version() const; @@ -65,8 +68,6 @@ namespace MDAlgorithms std::map validateInputs(); void exec(); void init(); - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// progress reporter boost::scoped_ptr m_Progress; diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDMinMaxGlobal.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDMinMaxGlobal.h index f9cb9a450152..9151bc75235d 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDMinMaxGlobal.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDMinMaxGlobal.h @@ -39,11 +39,13 @@ namespace MDAlgorithms virtual ~ConvertToMDMinMaxGlobal(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate limits required for ConvertToMD";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDMinMaxLocal.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDMinMaxLocal.h index 5551816cd328..2e2ffb4216ae 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDMinMaxLocal.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDMinMaxLocal.h @@ -39,13 +39,15 @@ namespace MDAlgorithms virtual ~ConvertToMDMinMaxLocal(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Calculate limits required for ConvertToMD";} + virtual int version() const{return 1;} protected: // for testing void findMinMaxValues(MDEvents::MDWSDescription &targWSDescr, MDEvents::MDTransfInterface *const qTransf,Kernel::DeltaEMode::Type dEMode, std::vector &MinValues,std::vector &MaxValues); private: - virtual void initDocs(); void exec(); void init(); /// pointer to the input workspace; diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDParent.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDParent.h index c58e303afed2..3413ca876386 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDParent.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ConvertToMDParent.h @@ -58,11 +58,6 @@ namespace MDAlgorithms /// Algorithm's category for identification virtual const std::string category() const; - private: - virtual void exec()=0; - /// Sets documentation strings for this algorithm - virtual void initDocs()=0; - //------------------------------------------------------------------------------------------------------------------------------------------ protected: void init(); // diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CreateMDHistoWorkspace.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CreateMDHistoWorkspace.h index 5fa20bb6ea8b..abdbbdc4b431 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CreateMDHistoWorkspace.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CreateMDHistoWorkspace.h @@ -40,11 +40,13 @@ namespace MDAlgorithms virtual ~CreateMDHistoWorkspace(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates an MDHistoWorkspace from supplied lists of signal and error values.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CreateMDWorkspace.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CreateMDWorkspace.h index 0673607c6635..0fc7c3cbf4ff 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CreateMDWorkspace.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/CreateMDWorkspace.h @@ -28,14 +28,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "CreateMDWorkspace";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Creates an empty MDEventWorkspace with a given number of dimensions.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/DivideMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/DivideMD.h index 6ecd27603707..fc02882580a9 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/DivideMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/DivideMD.h @@ -41,10 +41,12 @@ namespace MDAlgorithms virtual ~DivideMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Divide MDHistoWorkspace's";} + virtual int version() const; private: - virtual void initDocs(); /// Is the operation commutative? bool commutative() const; diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ExponentialMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ExponentialMD.h index 89bf8a8ff7e2..c442f8f6e0c3 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ExponentialMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ExponentialMD.h @@ -41,10 +41,12 @@ namespace MDAlgorithms virtual ~ExponentialMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Applies the exponential function on a MDHistoWorkspace.";} + virtual int version() const; private: - virtual void initDocs(); /// Check the inputs and throw if the algorithm cannot be run void checkInputs(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/FakeMDEventData.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/FakeMDEventData.h index edc3c2dc3980..0e595a509f3b 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/FakeMDEventData.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/FakeMDEventData.h @@ -31,14 +31,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "FakeMDEventData";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Adds fake multi-dimensional event data to an existing MDEventWorkspace, for use in testing.\nYou can create a blank MDEventWorkspace with CreateMDWorkspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/FindPeaksMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/FindPeaksMD.h index 0fa8f911576e..614f6920640f 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/FindPeaksMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/FindPeaksMD.h @@ -30,14 +30,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "FindPeaksMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Find peaks in reciprocal space in a MDEventWorkspace or a MDHistoWorkspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Optimization\\PeakFinding;MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/GreaterThanMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/GreaterThanMD.h index ec36bf02a2b3..32f638985810 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/GreaterThanMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/GreaterThanMD.h @@ -41,11 +41,12 @@ namespace MDAlgorithms virtual ~GreaterThanMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Perform the GreaterThan boolean operation on two MDHistoWorkspaces.";} + virtual int version() const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); bool acceptScalar() const { return true; } bool commutative() const { return false; } diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD.h index e99e3cc0cce1..e8e9e346a0ab 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD.h @@ -26,14 +26,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "IntegratePeaksMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Integrate single-crystal peaks in reciprocal space, for MDEventWorkspaces.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD2.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD2.h index 74a78a88ac97..b8c77ee874e9 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD2.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/IntegratePeaksMD2.h @@ -26,14 +26,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "IntegratePeaksMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Integrate single-crystal peaks in reciprocal space, for MDEventWorkspaces.";} + /// Algorithm's version for identification virtual int version() const { return 2;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LoadMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LoadMD.h index e7f8a06d268d..cca26490fb30 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LoadMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LoadMD.h @@ -45,6 +45,9 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "LoadMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load a MDEventWorkspace in .nxs format.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification @@ -54,8 +57,6 @@ namespace MDAlgorithms int confidence(Kernel::NexusDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LoadSQW.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LoadSQW.h index 035ffcb32283..a908be6d995e 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LoadSQW.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LoadSQW.h @@ -73,6 +73,9 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "LoadSQW";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz, Energy) from a SQW file.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification @@ -82,8 +85,6 @@ namespace MDAlgorithms virtual int confidence(Kernel::FileDescriptor & descriptor) const; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LogarithmMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LogarithmMD.h index 0923368898b3..21a117aad525 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LogarithmMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/LogarithmMD.h @@ -41,10 +41,12 @@ namespace MDAlgorithms virtual ~LogarithmMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Perform a natural logarithm of a MDHistoWorkspace.";} + virtual int version() const; private: - virtual void initDocs(); virtual void initExtraProperties(); /// Check the inputs and throw if the algorithm cannot be run diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MaskMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MaskMD.h index d09fa8abab24..d78a85c82166 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MaskMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MaskMD.h @@ -40,11 +40,13 @@ namespace MDAlgorithms virtual ~MaskMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Mask an MDWorkspace in-situ marking specified boxes as masked";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MergeMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MergeMD.h index ef9d374a9730..d188310e0fec 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MergeMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MergeMD.h @@ -44,11 +44,13 @@ namespace MDAlgorithms virtual ~MergeMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Merge several MDWorkspaces into one.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); void createOutputWorkspace(std::vector & inputs); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MergeMDFiles.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MergeMDFiles.h index eb11f43734ef..0a7de0036724 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MergeMDFiles.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MergeMDFiles.h @@ -47,14 +47,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "MergeMDFiles";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Merge multiple MDEventWorkspaces from files that obey a common box format.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MinusMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MinusMD.h index 4dcc9df1555a..2ffb1e611378 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MinusMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MinusMD.h @@ -41,10 +41,12 @@ namespace MDAlgorithms virtual ~MinusMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Subtract two MDWorkspaces.";} + virtual int version() const; private: - virtual void initDocs(); /// Is the operation commutative? bool commutative() const; diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MultiplyMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MultiplyMD.h index 27e2bca06d06..34bca98719ef 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MultiplyMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/MultiplyMD.h @@ -42,10 +42,12 @@ namespace MDAlgorithms virtual ~MultiplyMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Multiply a MDHistoWorkspace by another one or a scalar.";} + virtual int version() const; private: - virtual void initDocs(); /// Is the operation commutative? bool commutative() const; diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/NotMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/NotMD.h index 39d96910d23a..bb2e49e407c2 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/NotMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/NotMD.h @@ -41,10 +41,12 @@ namespace MDAlgorithms virtual ~NotMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs a boolean negation on a MDHistoWorkspace.";} + virtual int version() const; private: - virtual void initDocs(); /// Check the inputs and throw if the algorithm cannot be run void checkInputs(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PlusMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PlusMD.h index ff02c8207765..6928caddef92 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PlusMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PlusMD.h @@ -44,12 +44,13 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "PlusMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Sum two MDHistoWorkspaces or merges two MDEventWorkspaces together by combining their events together in one workspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Is the operation commutative? bool commutative() const; diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PowerMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PowerMD.h index cb3aee682948..37c2778c5d54 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PowerMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PowerMD.h @@ -41,10 +41,12 @@ namespace MDAlgorithms virtual ~PowerMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Raise a MDHistoWorkspace to a power";} + virtual int version() const; private: - virtual void initDocs(); virtual void initExtraProperties(); /// Check the inputs and throw if the algorithm cannot be run diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PreprocessDetectorsToMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PreprocessDetectorsToMD.h index 758baf298dc9..204cfd92e950 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PreprocessDetectorsToMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/PreprocessDetectorsToMD.h @@ -45,6 +45,9 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "PreprocessDetectorsToMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "'''PreprocessDetectorsToMD''' is helper algorithm, used to make common part of transformation from real to reciprocal space. It is used by ConvertToMD algorithm to save time spent on this transformation when the algorithm used multiple times for multiple measurements on the same instrument. It is also should be used to calculate limits of transformation in Q-space and the detectors trajectories in Q-space.\n\n";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification @@ -52,8 +55,6 @@ namespace MDAlgorithms private: void init(); void exec(); - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// the variable specifies if one needs to calculate efixed for detectors (make sence for indirect instruments) bool m_getEFixed; /// the variable specifies if one needs to return the state of detector mask e.g if the detector is masked diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Quantification/FitResolutionConvolvedModel.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Quantification/FitResolutionConvolvedModel.h index 0574d185c9b0..0f8e56d71dca 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Quantification/FitResolutionConvolvedModel.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Quantification/FitResolutionConvolvedModel.h @@ -32,9 +32,11 @@ namespace Mantid { public: const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Fits a cuts/slices from an MDEventWorkspace using a resolution function convolved with a foreground model";} + int version() const; const std::string category() const; - void initDocs(); protected: /// Returns the number of iterations that should be performed diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Quantification/SimulateResolutionConvolvedModel.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Quantification/SimulateResolutionConvolvedModel.h index 65a2ee3bbf81..f48c51f5a41b 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Quantification/SimulateResolutionConvolvedModel.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Quantification/SimulateResolutionConvolvedModel.h @@ -41,10 +41,12 @@ namespace Mantid { public: virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Runs a simulation of a model with a selected resolution function";} + virtual int version() const; private: - virtual void initDocs(); /// Returns the number of iterations that should be performed virtual int niterations() const; void init(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SaveMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SaveMD.h index 292b1dd7be32..83d356f99b2e 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SaveMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SaveMD.h @@ -44,14 +44,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "SaveMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Save a MDEventWorkspace or MDHistoWorkspace to a .nxs file.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SaveZODS.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SaveZODS.h index f518e5826a3f..63f5a0d52a7b 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SaveZODS.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SaveZODS.h @@ -41,11 +41,13 @@ namespace MDAlgorithms virtual ~SaveZODS(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Save a MDHistoWorkspace in HKL space to a HDF5 format for use with the ZODS analysis software.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SetMDUsingMask.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SetMDUsingMask.h index f0a61bd747bf..4d818b59e904 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SetMDUsingMask.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SetMDUsingMask.h @@ -40,11 +40,13 @@ namespace MDAlgorithms virtual ~SetMDUsingMask(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Algorithm to set a MDHistoWorkspace in points determined by a mask boolean MDHistoWorkspace.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SliceMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SliceMD.h index cb3f8def477d..1b30a1175be0 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SliceMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/SliceMD.h @@ -54,14 +54,15 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "SliceMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Make a MDEventWorkspace containing the events in a slice of an input MDEventWorkspace.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Stitch1DMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Stitch1DMD.h index 0b3358a7ba76..445880c3c58c 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Stitch1DMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/Stitch1DMD.h @@ -40,6 +40,9 @@ namespace MDAlgorithms virtual ~Stitch1DMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Sticch two MD ReflectometryQ group workspaces together.";} + virtual int version() const; virtual const std::string category() const; @@ -53,8 +56,6 @@ namespace MDAlgorithms Mantid::MDEvents::MDHistoWorkspace_sptr create1DHistoWorkspace(const MantidVec& signals,const MantidVec& errors, const MantidVec& extents, const std::vector& vecNBins, const std::vector names, const std::vector& units); void overlayOverlap(Mantid::MDEvents::MDHistoWorkspace_sptr original, Mantid::API::IMDHistoWorkspace_sptr overlap); Mantid::MDEvents::MDHistoWorkspace_sptr extractOverlapAsWorkspace(Mantid::API::IMDHistoWorkspace_sptr ws, const double& startOverlap, const double& endOverlap); - - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ThresholdMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ThresholdMD.h index 738c966c30f1..1a42128f7b33 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ThresholdMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/ThresholdMD.h @@ -38,11 +38,13 @@ namespace MDAlgorithms virtual ~ThresholdMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Threshold an MDHistoWorkspace.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/TransformMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/TransformMD.h index ebc79906748e..919dc9073062 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/TransformMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/TransformMD.h @@ -41,11 +41,13 @@ namespace MDAlgorithms virtual ~TransformMD(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Scale and/or offset the coordinates of a MDWorkspace";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/WeightedMeanMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/WeightedMeanMD.h index f0243675dba1..f60addec3e29 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/WeightedMeanMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/WeightedMeanMD.h @@ -42,12 +42,13 @@ namespace MDAlgorithms /// Algorithm's name for identification virtual const std::string name() const { return "WeightedMeanMD";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Find weighted mean of two MDHistoWorkspaces.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Is the operation commutative? bool commutative() const; diff --git a/Code/Mantid/Framework/MDAlgorithms/src/BinMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/BinMD.cpp index 349003580200..e2b97f7f3183 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/BinMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/BinMD.cpp @@ -128,12 +128,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void BinMD::initDocs() - { - this->setWikiSummary("Take a [[MDEventWorkspace]] and bin into into a dense, multi-dimensional histogram workspace ([[MDHistoWorkspace]])."); - this->setOptionalMessage("Take a MDEventWorkspace and bin into into a dense, multi-dimensional histogram workspace (MDHistoWorkspace)."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/BooleanBinaryOperationMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/BooleanBinaryOperationMD.cpp index 553f3dbe74e0..07c6a4ce1c74 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/BooleanBinaryOperationMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/BooleanBinaryOperationMD.cpp @@ -30,13 +30,12 @@ namespace MDAlgorithms int BooleanBinaryOperationMD::version() const { return 1;}; //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void BooleanBinaryOperationMD::initDocs() + /// + const std::string BooleanBinaryOperationMD::summary() const { std::string algo = this->name(); algo = algo.substr(0, algo.size()-2); - this->setWikiSummary("Perform the " + algo + " boolean operation on two MDHistoWorkspaces"); - this->setOptionalMessage("Perform the " + algo + " boolean operation on two MDHistoWorkspaces"); + return "Perform the " + algo + " boolean operation on two MDHistoWorkspaces"; } //---------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/MDAlgorithms/src/CentroidPeaksMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/CentroidPeaksMD.cpp index e0e4deb6faee..1ef00b3af260 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/CentroidPeaksMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/CentroidPeaksMD.cpp @@ -48,12 +48,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CentroidPeaksMD::initDocs() - { - this->setWikiSummary("Find the centroid of single-crystal peaks in a MDEventWorkspace, in order to refine their positions."); - this->setOptionalMessage("Find the centroid of single-crystal peaks in a MDEventWorkspace, in order to refine their positions."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp b/Code/Mantid/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp index 276c673edf7b..6b956ae81894 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/CentroidPeaksMD2.cpp @@ -48,12 +48,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CentroidPeaksMD2::initDocs() - { - this->setWikiSummary("Find the centroid of single-crystal peaks in a MDEventWorkspace, in order to refine their positions."); - this->setOptionalMessage("Find the centroid of single-crystal peaks in a MDEventWorkspace, in order to refine their positions."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/CloneMDWorkspace.cpp b/Code/Mantid/Framework/MDAlgorithms/src/CloneMDWorkspace.cpp index bd6adba4fabf..ba496eea8fb7 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/CloneMDWorkspace.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/CloneMDWorkspace.cpp @@ -51,12 +51,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CloneMDWorkspace::initDocs() - { - this->setWikiSummary("Clones (copies) an existing [[MDEventWorkspace]] or [[MDHistoWorkspace]] into a new one."); - this->setOptionalMessage("Clones (copies) an existing MDEventWorkspace or MDHistoWorkspace into a new one."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/CompareMDWorkspaces.cpp b/Code/Mantid/Framework/MDAlgorithms/src/CompareMDWorkspaces.cpp index 6e55cb2c939e..06b923139b8a 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/CompareMDWorkspaces.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/CompareMDWorkspaces.cpp @@ -79,12 +79,6 @@ namespace Mantid const std::string CompareMDWorkspaces::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CompareMDWorkspaces::initDocs() - { - this->setWikiSummary("Compare two MDWorkspaces for equality."); - this->setOptionalMessage("Compare two MDWorkspaces for equality."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDetectorFaceMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDetectorFaceMD.cpp index b1ca4ad1328e..2edf51f61985 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDetectorFaceMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDetectorFaceMD.cpp @@ -89,12 +89,6 @@ namespace MDAlgorithms const std::string ConvertToDetectorFaceMD::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ConvertToDetectorFaceMD::initDocs() - { - this->setWikiSummary("Convert a MatrixWorkspace containing to a MD workspace for viewing the detector face."); - this->setOptionalMessage("Convert a MatrixWorkspace containing to a MD workspace for viewing the detector face."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp index c237157f0229..b96b3fd151cf 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace.cpp @@ -93,13 +93,6 @@ namespace MDAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ConvertToDiffractionMDWorkspace) - - /// Sets documentation strings for this algorithm - void ConvertToDiffractionMDWorkspace::initDocs() - { - this->setWikiSummary("Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz) for an elastic diffraction experiment."); - this->setOptionalMessage("Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz) for an elastic diffraction experiment."); - } //---------------------------------------------------------------------------------------------- /** Constructor diff --git a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace2.cpp b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace2.cpp index 6e11cc039fa3..048595244533 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace2.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToDiffractionMDWorkspace2.cpp @@ -89,13 +89,6 @@ namespace MDAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ConvertToDiffractionMDWorkspace2) - - /// Sets documentation strings for this algorithm - void ConvertToDiffractionMDWorkspace2::initDocs() - { - this->setWikiSummary("Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz) for an elastic diffraction experiment."); - this->setOptionalMessage("Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz) for an elastic diffraction experiment."); - } /**Small class to diable propery on interface */ class DisabledProperty: public EnabledWhenProperty diff --git a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMD.cpp index cb70aca1d66b..4a1c42fddd01 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMD.cpp @@ -213,22 +213,6 @@ namespace Mantid setPropertyGroup("MinRecursionDepth", getBoxSettingsGroupName()); } - - - // Sets documentation strings for this algorithm - void ConvertToMD::initDocs() - { - this->setWikiSummary("

Transforms a workspace into MDEvent workspace with dimensions defined by user.

" - - "Gateway for set of subalgorithms, combined together to convert an input 2D matrix workspace or an event workspace with any units along X-axis into multidimensional event workspace.

" - - "Depending on the user input and the data found in the input workspace, the algorithms transform the input workspace into 1 to 4 dimensional MDEvent workspace and adds to this workspace additional dimensions, which are described by the workspace properties, and requested by user.

" - - "The table contains the description of the main algorithm dialogue. More detailed description of the properties, relevant for each MD conversion type can be found on [[MD Transformation factory]] page.

" - - "The '''Box Splitting Settings''' specifies the controller parameters, which define the target workspace binning: (see [[CreateMDWorkspace]] description)

"); - this->setOptionalMessage("Create a MDEventWorkspace with selected dimensions, e.g. the reciprocal space of momentums (Qx, Qy, Qz) or momentums modules |Q|, energy transfer dE if availible and any other user specified log values which can be treated as dimensions."); - } //---------------------------------------------------------------------------------------------- /** Destructor */ diff --git a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMDMinMaxGlobal.cpp b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMDMinMaxGlobal.cpp index 2b50063c3e82..7e96177db826 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMDMinMaxGlobal.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMDMinMaxGlobal.cpp @@ -64,12 +64,6 @@ namespace MDAlgorithms const std::string ConvertToMDMinMaxGlobal::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ConvertToMDMinMaxGlobal::initDocs() - { - this->setWikiSummary("Calculate limits of ConvertToMD transformation which can be theoretically achieved on an instrument with unlimited coverage"); - this->setOptionalMessage("Calculate limits required for ConvertToMD"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMDMinMaxLocal.cpp b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMDMinMaxLocal.cpp index 13e84b36c7ef..95e161f4707c 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMDMinMaxLocal.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/ConvertToMDMinMaxLocal.cpp @@ -64,13 +64,6 @@ namespace Mantid //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - - void ConvertToMDMinMaxLocal::initDocs() - { - this->setWikiSummary("Calculate limits required for ConvertToMD"); - this->setOptionalMessage("Calculate limits required for ConvertToMD"); - } void ConvertToMDMinMaxLocal::init() { ConvertToMDParent::init(); diff --git a/Code/Mantid/Framework/MDAlgorithms/src/CreateMDHistoWorkspace.cpp b/Code/Mantid/Framework/MDAlgorithms/src/CreateMDHistoWorkspace.cpp index 3ea667beb889..65e95cabf177 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/CreateMDHistoWorkspace.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/CreateMDHistoWorkspace.cpp @@ -84,12 +84,6 @@ namespace MDAlgorithms const std::string CreateMDHistoWorkspace::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void CreateMDHistoWorkspace::initDocs() - { - this->setWikiSummary("Creates an MDHistoWorkspace from supplied lists of signal and error values."); - this->setOptionalMessage("Creates an MDHistoWorkspace from supplied lists of signal and error values."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/CreateMDWorkspace.cpp b/Code/Mantid/Framework/MDAlgorithms/src/CreateMDWorkspace.cpp index 876fc24daa00..f20b77b1182e 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/CreateMDWorkspace.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/CreateMDWorkspace.cpp @@ -38,13 +38,6 @@ namespace MDAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(CreateMDWorkspace) - - /// Sets documentation strings for this algorithm - void CreateMDWorkspace::initDocs() - { - this->setWikiSummary("Creates an empty MDEventWorkspace with a given number of dimensions. "); - this->setOptionalMessage("Creates an empty MDEventWorkspace with a given number of dimensions."); - } //---------------------------------------------------------------------------------------------- /** Constructor diff --git a/Code/Mantid/Framework/MDAlgorithms/src/DivideMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/DivideMD.cpp index a90a9de831e4..7b887fcb90f6 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/DivideMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/DivideMD.cpp @@ -66,12 +66,6 @@ namespace MDAlgorithms int DivideMD::version() const { return 1;}; //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void DivideMD::initDocs() - { - this->setWikiSummary("Divide [[MDHistoWorkspace]]'s"); - this->setOptionalMessage("Divide MDHistoWorkspace's"); - } //---------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/MDAlgorithms/src/ExponentialMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/ExponentialMD.cpp index ad9ccfeb3fdf..e12a28616fdf 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/ExponentialMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/ExponentialMD.cpp @@ -44,12 +44,6 @@ namespace MDAlgorithms int ExponentialMD::version() const { return 1;}; //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ExponentialMD::initDocs() - { - this->setWikiSummary("Applies the exponential function on a [[MDHistoWorkspace]]."); - this->setOptionalMessage("Applies the exponential function on a MDHistoWorkspace."); - } //---------------------------------------------------------------------------------------------- /// Check the inputs and throw if the algorithm cannot be run diff --git a/Code/Mantid/Framework/MDAlgorithms/src/FakeMDEventData.cpp b/Code/Mantid/Framework/MDAlgorithms/src/FakeMDEventData.cpp index cc2de1a38a37..4a1a4985e29f 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/FakeMDEventData.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/FakeMDEventData.cpp @@ -58,12 +58,6 @@ namespace MDAlgorithms } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void FakeMDEventData::initDocs() - { - this->setWikiSummary("Adds fake multi-dimensional event data to an existing MDEventWorkspace, for use in testing.\nYou can create a blank MDEventWorkspace with CreateMDWorkspace."); - this->setOptionalMessage("Adds fake multi-dimensional event data to an existing MDEventWorkspace, for use in testing.\nYou can create a blank MDEventWorkspace with CreateMDWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/FindPeaksMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/FindPeaksMD.cpp index df1ec63fe10a..bd3b61e35932 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/FindPeaksMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/FindPeaksMD.cpp @@ -153,12 +153,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void FindPeaksMD::initDocs() - { - this->setWikiSummary("Find peaks in reciprocal space in a MDEventWorkspace or a MDHistoWorkspace."); - this->setOptionalMessage("Find peaks in reciprocal space in a MDEventWorkspace or a MDHistoWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/GreaterThanMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/GreaterThanMD.cpp index cb02fbaddbc5..bca81b5e339c 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/GreaterThanMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/GreaterThanMD.cpp @@ -31,13 +31,6 @@ namespace MDAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(GreaterThanMD) - /// Sets documentation strings for this algorithm - void GreaterThanMD::initDocs() - { - this->setWikiSummary("Perform the GreaterThan boolean operation on two MDHistoWorkspaces."); - this->setOptionalMessage("Perform the GreaterThan boolean operation on two MDHistoWorkspaces."); - } - //---------------------------------------------------------------------------------------------- /** Constructor diff --git a/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp index bddf8d3a9860..e99d4bc98631 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD.cpp @@ -120,12 +120,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void IntegratePeaksMD::initDocs() - { - this->setWikiSummary("Integrate single-crystal peaks in reciprocal space, for [[MDEventWorkspace]]s."); - this->setOptionalMessage("Integrate single-crystal peaks in reciprocal space, for MDEventWorkspaces."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD2.cpp b/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD2.cpp index b9edecd1e54d..0cd01c12e4e2 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD2.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/IntegratePeaksMD2.cpp @@ -120,12 +120,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void IntegratePeaksMD2::initDocs() - { - this->setWikiSummary("Integrate single-crystal peaks in reciprocal space, for [[MDEventWorkspace]]s."); - this->setOptionalMessage("Integrate single-crystal peaks in reciprocal space, for MDEventWorkspaces."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/LoadMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/LoadMD.cpp index 8b081b39ea0d..badda8feba3b 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/LoadMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/LoadMD.cpp @@ -95,12 +95,6 @@ namespace Mantid //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadMD::initDocs() - { - this->setWikiSummary("Load a MDEventWorkspace in .nxs format."); - this->setOptionalMessage("Load a MDEventWorkspace in .nxs format."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/LoadSQW.cpp b/Code/Mantid/Framework/MDAlgorithms/src/LoadSQW.cpp index d4a61ccb2d39..a280282c6fde 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/LoadSQW.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/LoadSQW.cpp @@ -225,11 +225,6 @@ namespace Mantid } /// Provide wiki documentation. - void LoadSQW::initDocs() - { - this->setWikiSummary("Create an IMDEventWorkspace with events in reciprocal space (Qx, Qy, Qz) from a [http://horace.isis.rl.ac.uk/Main_Page Horace ] SQW file."); - this->setOptionalMessage("Create a MDEventWorkspace with events in reciprocal space (Qx, Qy, Qz, Energy) from a SQW file."); - } /// Initalize the algorithm void LoadSQW::init() diff --git a/Code/Mantid/Framework/MDAlgorithms/src/LogarithmMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/LogarithmMD.cpp index 19a52ba31801..6b0cf123a51b 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/LogarithmMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/LogarithmMD.cpp @@ -49,12 +49,6 @@ namespace MDAlgorithms int LogarithmMD::version() const { return 1;}; //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LogarithmMD::initDocs() - { - this->setWikiSummary("Perform a natural logarithm of a [[MDHistoWorkspace]]."); - this->setOptionalMessage("Perform a natural logarithm of a MDHistoWorkspace."); - } //---------------------------------------------------------------------------------------------- /// Optional method to be subclassed to add properties diff --git a/Code/Mantid/Framework/MDAlgorithms/src/MaskMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/MaskMD.cpp index 7dfa224fbef1..0a2f9d32af69 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/MaskMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/MaskMD.cpp @@ -83,12 +83,6 @@ namespace MDAlgorithms const std::string MaskMD::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void MaskMD::initDocs() - { - this->setWikiSummary("Mask an [[MDWorkspace]] in-situ"); - this->setOptionalMessage("Mask an MDWorkspace in-situ marking specified boxes as masked"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/MergeMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/MergeMD.cpp index 8ac7b19690ff..187ea41aed0e 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/MergeMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/MergeMD.cpp @@ -64,12 +64,6 @@ namespace MDAlgorithms const std::string MergeMD::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void MergeMD::initDocs() - { - this->setWikiSummary("Merge several [[MDWorkspace]]s into one."); - this->setOptionalMessage("Merge several MDWorkspaces into one."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/MergeMDFiles.cpp b/Code/Mantid/Framework/MDAlgorithms/src/MergeMDFiles.cpp index 6ae373309b40..27db1b038f36 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/MergeMDFiles.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/MergeMDFiles.cpp @@ -60,12 +60,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void MergeMDFiles::initDocs() - { - this->setWikiSummary("Merge multiple MDEventWorkspaces from files that obey a common box format."); - this->setOptionalMessage("Merge multiple MDEventWorkspaces from files that obey a common box format."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/MinusMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/MinusMD.cpp index 10687297f121..77a43a30da88 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/MinusMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/MinusMD.cpp @@ -61,12 +61,6 @@ namespace MDAlgorithms int MinusMD::version() const { return 1;}; //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void MinusMD::initDocs() - { - this->setWikiSummary("Subtract two [[MDWorkspace]]s"); - this->setOptionalMessage("Subtract two MDWorkspaces."); - } //---------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/MDAlgorithms/src/MultiplyMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/MultiplyMD.cpp index 5ce49ba050de..9f9e50992594 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/MultiplyMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/MultiplyMD.cpp @@ -59,12 +59,6 @@ namespace MDAlgorithms int MultiplyMD::version() const { return 1;}; //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void MultiplyMD::initDocs() - { - this->setWikiSummary("Multiply a [[MDHistoWorkspace]] by another one or a scalar."); - this->setOptionalMessage("Multiply a MDHistoWorkspace by another one or a scalar."); - } //---------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/MDAlgorithms/src/NotMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/NotMD.cpp index 1351706251fc..15d95490545c 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/NotMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/NotMD.cpp @@ -48,12 +48,6 @@ namespace MDAlgorithms int NotMD::version() const { return 1;}; //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void NotMD::initDocs() - { - this->setWikiSummary("Performs a boolean negation on a [[MDHistoWorkspace]]."); - this->setOptionalMessage("Performs a boolean negation on a MDHistoWorkspace."); - } //---------------------------------------------------------------------------------------------- /// Check the inputs and throw if the algorithm cannot be run diff --git a/Code/Mantid/Framework/MDAlgorithms/src/PlusMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/PlusMD.cpp index 50b8de67f206..9d15b6e3667e 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/PlusMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/PlusMD.cpp @@ -68,12 +68,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void PlusMD::initDocs() - { - this->setWikiSummary("Sum two [[MDHistoWorkspace]]s or merges two [[MDEventWorkspace]]s together by combining their events together in one workspace."); - this->setOptionalMessage("Sum two MDHistoWorkspaces or merges two MDEventWorkspaces together by combining their events together in one workspace."); - } //---------------------------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/MDAlgorithms/src/PowerMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/PowerMD.cpp index 43d42749f24e..69be4eaf9a3f 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/PowerMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/PowerMD.cpp @@ -44,12 +44,6 @@ namespace MDAlgorithms int PowerMD::version() const { return 1;}; //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void PowerMD::initDocs() - { - this->setWikiSummary("Raise a [[MDHistoWorkspace]] to a power."); - this->setOptionalMessage("Raise a MDHistoWorkspace to a power"); - } //---------------------------------------------------------------------------------------------- /// Optional method to be subclassed to add properties diff --git a/Code/Mantid/Framework/MDAlgorithms/src/PreprocessDetectorsToMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/PreprocessDetectorsToMD.cpp index 473eff403fe0..9ae726296677 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/PreprocessDetectorsToMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/PreprocessDetectorsToMD.cpp @@ -115,16 +115,6 @@ namespace Mantid PreprocessDetectorsToMD::PreprocessDetectorsToMD() {}; - - // Sets documentation strings for this algorithm - void PreprocessDetectorsToMD::initDocs() - { - this->setWikiSummary("'''PreprocessDetectorsToMD''' is helper algorithm, used to make common part of transformation from real to reciprocal space. It is used by [[ConvertToMD]] algorithm to save time spent on this transformation when the algorithm used multiple times for multiple measurements on the same instrument. It is also should be used to calculate limits of transformation in Q-space and the detectors trajectories in Q-space.\n\n"); - - this->setOptionalMessage("Pre-process detector's positions namely perform generic part of the transformation \n" - "from a physical space of a real instrument to\n" - "physical MD workspace of an experimental results (e.g Q-space)."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ void PreprocessDetectorsToMD::init() diff --git a/Code/Mantid/Framework/MDAlgorithms/src/Quantification/FitResolutionConvolvedModel.cpp b/Code/Mantid/Framework/MDAlgorithms/src/Quantification/FitResolutionConvolvedModel.cpp index 51361f80642a..e7fe3f2325c7 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/Quantification/FitResolutionConvolvedModel.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/Quantification/FitResolutionConvolvedModel.cpp @@ -53,13 +53,6 @@ namespace Mantid /// Algorithm's category for identification. @see Algorithm::category const std::string FitResolutionConvolvedModel::category() const { return "Quantification"; } - /// Sets documentation strings for this algorithm - void FitResolutionConvolvedModel::initDocs() - { - this->setWikiSummary("Fits a cuts/slices from an MDEventWorkspace using a resolution function convolved with a foreground model"); - this->setOptionalMessage("Fits a cuts/slices from an MDEventWorkspace using a resolution function convolved with a foreground model"); - } - //---------------------------------------------------------------------------------------------- /// Returns the number of iterations that should be performed diff --git a/Code/Mantid/Framework/MDAlgorithms/src/Quantification/SimulateResolutionConvolvedModel.cpp b/Code/Mantid/Framework/MDAlgorithms/src/Quantification/SimulateResolutionConvolvedModel.cpp index 80f87cb4a7cf..2f0f643fa623 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/Quantification/SimulateResolutionConvolvedModel.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/Quantification/SimulateResolutionConvolvedModel.cpp @@ -54,13 +54,6 @@ namespace Mantid /// Algorithm's version for identification. @see Algorithm::version int SimulateResolutionConvolvedModel::version() const { return 1;} - /// Sets documentation strings for this algorithm - void SimulateResolutionConvolvedModel::initDocs() - { - this->setWikiSummary("Runs a simulation of a model with a selected resolution function"); - this->setOptionalMessage("Runs a simulation of a model with a selected resolution function"); - } - /** * Returns the number of iterations that should be performed * @returns 1 for the simulation diff --git a/Code/Mantid/Framework/MDAlgorithms/src/SaveMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/SaveMD.cpp index 2228404973e3..f1e6bbb4a68f 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/SaveMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/SaveMD.cpp @@ -61,12 +61,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveMD::initDocs() - { - this->setWikiSummary("Save a MDEventWorkspace or MDHistoWorkspace to a .nxs file."); - this->setOptionalMessage("Save a MDEventWorkspace or MDHistoWorkspace to a .nxs file."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/SaveZODS.cpp b/Code/Mantid/Framework/MDAlgorithms/src/SaveZODS.cpp index 7c02eff15b1a..cac4e2f46298 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/SaveZODS.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/SaveZODS.cpp @@ -78,12 +78,6 @@ namespace MDAlgorithms const std::string SaveZODS::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveZODS::initDocs() - { - this->setWikiSummary("Save a [[MDHistoWorkspace]] in HKL space to a HDF5 format for use with the ZODS analysis software."); - this->setOptionalMessage("Save a MDHistoWorkspace in HKL space to a HDF5 format for use with the ZODS analysis software."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/SetMDUsingMask.cpp b/Code/Mantid/Framework/MDAlgorithms/src/SetMDUsingMask.cpp index 86a1a6ef40a9..f141c351d541 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/SetMDUsingMask.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/SetMDUsingMask.cpp @@ -67,12 +67,6 @@ namespace MDAlgorithms const std::string SetMDUsingMask::category() const { return "MDAlgorithms\\MDArithmetic";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SetMDUsingMask::initDocs() - { - this->setWikiSummary("Algorithm to set a [[MDHistoWorkspace]] in points determined by a mask boolean MDHistoWorkspace."); - this->setOptionalMessage("Algorithm to set a MDHistoWorkspace in points determined by a mask boolean MDHistoWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/SliceMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/SliceMD.cpp index 2f6f6ad093ed..aa912daec1db 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/SliceMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/SliceMD.cpp @@ -86,12 +86,6 @@ namespace MDAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SliceMD::initDocs() - { - this->setWikiSummary("Make a MDEventWorkspace containing the events in a slice of an input MDEventWorkspace."); - this->setOptionalMessage("Make a MDEventWorkspace containing the events in a slice of an input MDEventWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/Stitch1DMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/Stitch1DMD.cpp index cf75000a9bd5..f4368e62d44a 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/Stitch1DMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/Stitch1DMD.cpp @@ -69,12 +69,6 @@ namespace MDAlgorithms const std::string Stitch1DMD::category() const { return "Reflectometry\\ISIS";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void Stitch1DMD::initDocs() - { - this->setWikiSummary("Stitch two MD ReflectometryQ group workspaces together"); - this->setOptionalMessage("Sticch two MD ReflectometryQ group workspaces together."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/ThresholdMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/ThresholdMD.cpp index a0f7c342c84a..2b6005952938 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/ThresholdMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/ThresholdMD.cpp @@ -72,12 +72,6 @@ namespace Mantid } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ThresholdMD::initDocs() - { - this->setWikiSummary("Threshold an MDHistoWorkspace."); - this->setOptionalMessage(this->getWikiSummary()); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/TransformMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/TransformMD.cpp index 87ca070b2578..16c3a1a3087e 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/TransformMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/TransformMD.cpp @@ -80,12 +80,6 @@ namespace MDAlgorithms const std::string TransformMD::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void TransformMD::initDocs() - { - this->setWikiSummary("Scale and/or offset the coordinates of a MDWorkspace"); - this->setOptionalMessage("Scale and/or offset the coordinates of a MDWorkspace"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDAlgorithms/src/WeightedMeanMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/WeightedMeanMD.cpp index 5b8ac4c2cd5f..0e567cee2de3 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/WeightedMeanMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/WeightedMeanMD.cpp @@ -68,12 +68,6 @@ namespace MDAlgorithms } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void WeightedMeanMD::initDocs() - { - this->setWikiSummary("Find weighted mean of two [[MDHistoWorkspace]]s."); - this->setOptionalMessage("Find weighted mean of two MDHistoWorkspaces."); - } //---------------------------------------------------------------------------------------------- /// Is the operation commutative? diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ConvertToReflectometryQ.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ConvertToReflectometryQ.h index 1765dcd3a9c5..7885c0a3b725 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ConvertToReflectometryQ.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ConvertToReflectometryQ.h @@ -39,11 +39,13 @@ namespace MDEvents virtual ~ConvertToReflectometryQ(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Transforms from real-space to Q or momentum space for reflectometry workspaces";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ImportMDEventWorkspace.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ImportMDEventWorkspace.h index 3c717b108dec..9ae36d98036a 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ImportMDEventWorkspace.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ImportMDEventWorkspace.h @@ -43,6 +43,9 @@ namespace MDEvents virtual ~ImportMDEventWorkspace(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Reads an ASCII file containing MDEvent data and constructs an MDEventWorkspace.";} + virtual int version() const; virtual const std::string category() const; @@ -77,8 +80,7 @@ namespace MDEvents void quickFileCheck(); /// Check that the a flag exists in the file. bool fileDoesContain(const std::string& flag); - /// Initialize documentation - virtual void initDocs(); + void init(); void exec(); }; diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ImportMDHistoWorkspace.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ImportMDHistoWorkspace.h index 0028145986ad..db4b37d52c11 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ImportMDHistoWorkspace.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/ImportMDHistoWorkspace.h @@ -41,11 +41,13 @@ namespace MDEvents virtual ~ImportMDHistoWorkspace(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Reads a text file and generates an MDHistoWorkspace from it.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); @@ -55,4 +57,4 @@ namespace MDEvents } // namespace MDEvents } // namespace Mantid -#endif /* MANTID_MDEVENTS_IMPORTMDHISTOWORKSPACE_H_ */ \ No newline at end of file +#endif /* MANTID_MDEVENTS_IMPORTMDHISTOWORKSPACE_H_ */ diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/IntegrateEllipsoids.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/IntegrateEllipsoids.h index 3e1cb2818d89..6a61165dd28e 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/IntegrateEllipsoids.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/IntegrateEllipsoids.h @@ -17,11 +17,13 @@ namespace MDEvents virtual ~IntegrateEllipsoids(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Integrate SCD Bragg peaks using 3D ellipsoids.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/OneStepMDEW.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/OneStepMDEW.h index e88e56e4e342..b6a7cacbdcda 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/OneStepMDEW.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/OneStepMDEW.h @@ -22,14 +22,16 @@ namespace MDEvents /// Algorithm's name for identification virtual const std::string name() const { return "OneStepMDEW";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Create a MDEventWorkspace in one step from a EventNexus file. For use by Paraview loader.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/QueryMDWorkspace.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/QueryMDWorkspace.h index 782b6ded5fff..f6c6350bc9c4 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/QueryMDWorkspace.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/QueryMDWorkspace.h @@ -42,14 +42,16 @@ namespace MDEvents /// Algorithm's name for identification virtual const std::string name() const { return "QueryMDWorkspace";}; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Query the IMDWorkspace in order to extract summary information.";} + /// Algorithm's version for identification virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "MDAlgorithms";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); + /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/SaveIsawQvector.h b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/SaveIsawQvector.h index 16930dc93acb..d49db07d46cd 100644 --- a/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/SaveIsawQvector.h +++ b/Code/Mantid/Framework/MDEvents/inc/MantidMDEvents/SaveIsawQvector.h @@ -39,11 +39,13 @@ namespace MDEvents virtual ~SaveIsawQvector(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Save an event workspace as an ISAW Q-vector file";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/MDEvents/src/ConvertToReflectometryQ.cpp b/Code/Mantid/Framework/MDEvents/src/ConvertToReflectometryQ.cpp index 999f6306ae64..6d4b4d978f47 100644 --- a/Code/Mantid/Framework/MDEvents/src/ConvertToReflectometryQ.cpp +++ b/Code/Mantid/Framework/MDEvents/src/ConvertToReflectometryQ.cpp @@ -195,12 +195,6 @@ namespace MDEvents const std::string ConvertToReflectometryQ::category() const { return "Reflectometry\\ISIS";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ConvertToReflectometryQ::initDocs() - { - this->setWikiSummary("Transforms from real-space to Q or momentum space for reflectometry workspaces"); - this->setOptionalMessage("Transforms from real-space to Q or momentum space for reflectometry workspaces"); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDEvents/src/ImportMDEventWorkspace.cpp b/Code/Mantid/Framework/MDEvents/src/ImportMDEventWorkspace.cpp index fea292a4ba56..ced64e6ece54 100644 --- a/Code/Mantid/Framework/MDEvents/src/ImportMDEventWorkspace.cpp +++ b/Code/Mantid/Framework/MDEvents/src/ImportMDEventWorkspace.cpp @@ -192,12 +192,6 @@ namespace MDEvents const std::string ImportMDEventWorkspace::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ImportMDEventWorkspace::initDocs() - { - this->setWikiSummary("Reads an ASCII file containing MDEvent data and constructs an MDEventWorkspace."); - this->setOptionalMessage("Reads an ASCII file containing MDEvent data and constructs an MDEventWorkspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDEvents/src/ImportMDHistoWorkspace.cpp b/Code/Mantid/Framework/MDEvents/src/ImportMDHistoWorkspace.cpp index ca61f0a4444d..cf24e090740f 100644 --- a/Code/Mantid/Framework/MDEvents/src/ImportMDHistoWorkspace.cpp +++ b/Code/Mantid/Framework/MDEvents/src/ImportMDHistoWorkspace.cpp @@ -82,12 +82,6 @@ namespace MDEvents const std::string ImportMDHistoWorkspace::category() const { return "MDAlgorithms";} //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void ImportMDHistoWorkspace::initDocs() - { - this->setWikiSummary("Reads a text file and generates an MDHistoWorkspace from it."); - this->setOptionalMessage("Reads a text file and generates an MDHistoWorkspace from it."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDEvents/src/IntegrateEllipsoids.cpp b/Code/Mantid/Framework/MDEvents/src/IntegrateEllipsoids.cpp index 54100c4df701..767ccda0085c 100644 --- a/Code/Mantid/Framework/MDEvents/src/IntegrateEllipsoids.cpp +++ b/Code/Mantid/Framework/MDEvents/src/IntegrateEllipsoids.cpp @@ -160,13 +160,6 @@ namespace MDEvents } //--------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void IntegrateEllipsoids::initDocs() - { - std::string text("Integrate SCD Bragg peaks using 3D ellipsoids."); - this->setWikiSummary(text); - this->setOptionalMessage(text); - } //--------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDEvents/src/OneStepMDEW.cpp b/Code/Mantid/Framework/MDEvents/src/OneStepMDEW.cpp index b34a4fade04e..c0a45f377244 100644 --- a/Code/Mantid/Framework/MDEvents/src/OneStepMDEW.cpp +++ b/Code/Mantid/Framework/MDEvents/src/OneStepMDEW.cpp @@ -46,12 +46,6 @@ namespace Mantid //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void OneStepMDEW::initDocs() - { - this->setWikiSummary("Create a MDEventWorkspace in one step from a EventNexus file. For use by Paraview loader."); - this->setOptionalMessage("Create a MDEventWorkspace in one step from a EventNexus file. For use by Paraview loader."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/MDEvents/src/QueryMDWorkspace.cpp b/Code/Mantid/Framework/MDEvents/src/QueryMDWorkspace.cpp index 5c8f4d724387..7de863ea016b 100644 --- a/Code/Mantid/Framework/MDEvents/src/QueryMDWorkspace.cpp +++ b/Code/Mantid/Framework/MDEvents/src/QueryMDWorkspace.cpp @@ -99,13 +99,6 @@ namespace MDEvents { } - - /// Documentation initalisation - void QueryMDWorkspace::initDocs() - { - this->setWikiSummary("Query the IMDWorkspace in order to extract summary information."); - } - /// Initialise the properties void QueryMDWorkspace::init() { diff --git a/Code/Mantid/Framework/MDEvents/src/SaveIsawQvector.cpp b/Code/Mantid/Framework/MDEvents/src/SaveIsawQvector.cpp index 878282dbeea0..81074b923d69 100644 --- a/Code/Mantid/Framework/MDEvents/src/SaveIsawQvector.cpp +++ b/Code/Mantid/Framework/MDEvents/src/SaveIsawQvector.cpp @@ -58,15 +58,6 @@ namespace MDEvents /// Algorithm's category for identification. @see Algorithm::category const std::string SaveIsawQvector::category() const { return "DataHandling\\Isaw";} - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void SaveIsawQvector::initDocs() - { - std::string text("Save an event workspace as an ISAW Q-vector file"); - this->setWikiSummary(text); - this->setOptionalMessage(text); - } - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ From b518ab92dee3903316c0ad55da6bdf6276cb8495 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 22:45:31 +0100 Subject: [PATCH 086/126] Fix warnings in DataHandling. Refs #9523 --- .../Framework/DataHandling/src/LoadGSASInstrumentFile.cpp | 4 ---- .../Framework/DataHandling/src/SaveFullprofResolution.cpp | 4 ---- 2 files changed, 8 deletions(-) diff --git a/Code/Mantid/Framework/DataHandling/src/LoadGSASInstrumentFile.cpp b/Code/Mantid/Framework/DataHandling/src/LoadGSASInstrumentFile.cpp index af2c7fd9a79e..d8402f88d5be 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadGSASInstrumentFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadGSASInstrumentFile.cpp @@ -63,10 +63,6 @@ namespace DataHandling { } - //---------------------------------------------------------------------------------------------- - /** Sets documentation strings for this algorithm - * - //---------------------------------------------------------------------------------------------- /** Implement abstract Algorithm methods */ diff --git a/Code/Mantid/Framework/DataHandling/src/SaveFullprofResolution.cpp b/Code/Mantid/Framework/DataHandling/src/SaveFullprofResolution.cpp index b820dd2aa658..d2c31f5a4879 100644 --- a/Code/Mantid/Framework/DataHandling/src/SaveFullprofResolution.cpp +++ b/Code/Mantid/Framework/DataHandling/src/SaveFullprofResolution.cpp @@ -69,10 +69,6 @@ namespace DataHandling { } - //---------------------------------------------------------------------------------------------- - /** Wiki docs - * - //---------------------------------------------------------------------------------------------- /** Init to define parameters */ From 5106ea756f80627338a9246cf9008b28f9928ce0 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Wed, 28 May 2014 22:46:49 +0100 Subject: [PATCH 087/126] Deprecated algorothm wiki methods in Python Refs #9523 --- .../api/Algorithms/RunPythonScript.h | 2 +- .../api/PythonAlgorithm/AlgorithmAdapter.h | 11 +++++ .../api/src/Algorithms/RunPythonScript.cpp | 8 +--- .../mantid/api/src/Exports/Algorithm.cpp | 4 +- .../mantid/api/src/Exports/IAlgorithm.cpp | 36 +++++++++++++--- .../src/PythonAlgorithm/AlgorithmAdapter.cpp | 41 ++++++++++++++++++- 6 files changed, 87 insertions(+), 15 deletions(-) diff --git a/Code/Mantid/Framework/PythonInterface/inc/MantidPythonInterface/api/Algorithms/RunPythonScript.h b/Code/Mantid/Framework/PythonInterface/inc/MantidPythonInterface/api/Algorithms/RunPythonScript.h index 45461d976897..d01b785e1dd3 100644 --- a/Code/Mantid/Framework/PythonInterface/inc/MantidPythonInterface/api/Algorithms/RunPythonScript.h +++ b/Code/Mantid/Framework/PythonInterface/inc/MantidPythonInterface/api/Algorithms/RunPythonScript.h @@ -39,9 +39,9 @@ namespace Mantid const std::string name() const; int version() const; const std::string category() const; + const std::string summary() const; private: - virtual void initDocs(); virtual bool checkGroups(); void init(); void exec(); diff --git a/Code/Mantid/Framework/PythonInterface/inc/MantidPythonInterface/api/PythonAlgorithm/AlgorithmAdapter.h b/Code/Mantid/Framework/PythonInterface/inc/MantidPythonInterface/api/PythonAlgorithm/AlgorithmAdapter.h index 8db9a90accfa..55d0522c94d2 100644 --- a/Code/Mantid/Framework/PythonInterface/inc/MantidPythonInterface/api/PythonAlgorithm/AlgorithmAdapter.h +++ b/Code/Mantid/Framework/PythonInterface/inc/MantidPythonInterface/api/PythonAlgorithm/AlgorithmAdapter.h @@ -59,6 +59,10 @@ namespace Mantid virtual int version() const; /// A default version, chosen if there is no override int defaultVersion() const; + /// Returns the summary for the algorithm + virtual const std::string summary() const; + /// Returns the summary for the algorithm + std::string defaultSummary() const; /// Returns a category of the algorithm. virtual const std::string category() const; /// A default category, chosen if there is no override @@ -75,6 +79,10 @@ namespace Mantid std::map validateInputs(); ///@} + // -- Deprecated methods -- + /// Set the summary text + void setWikiSummary(const std::string & summary); + /** @name Property declarations * The first function matches the base-classes signature so a different * name is used consistently to avoid accidentally calling the wrong function internally @@ -120,6 +128,9 @@ namespace Mantid PyObject *m_self; /// A pointer to an overridden isRunning method PyObject *m_isRunningObj; + + /// Here for deprecated setWikiSummary method + std::string m_wikiSummary; }; } } diff --git a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Algorithms/RunPythonScript.cpp b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Algorithms/RunPythonScript.cpp index 876cae241d58..3ae065d092ff 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Algorithms/RunPythonScript.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Algorithms/RunPythonScript.cpp @@ -34,12 +34,8 @@ namespace Mantid /// Algorithm's category for identification. @see Algorithm::category const std::string RunPythonScript::category() const { return "DataHandling\\LiveData\\Support"; } - /// Sets documentation strings for this algorithm - void RunPythonScript::initDocs() - { - this->setWikiSummary("Executes a snippet of Python code"); - this->setOptionalMessage("Executes a snippet of Python code"); - } + /// @copydoc Algorithm::summary + const std::string RunPythonScript::summary() const { return "Executes a snippet of Python code"; } /** * Override standard group behaviour so that the algorithm is only diff --git a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/Algorithm.cpp b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/Algorithm.cpp index 43e1e1c0726d..71dd4571e321 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/Algorithm.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/Algorithm.cpp @@ -51,7 +51,6 @@ void export_leaf_classes() .def("fromString", &Algorithm::fromString, "Initialize the algorithm from a string representation") .staticmethod("fromString") - .def("setOptionalMessage", &Algorithm::setOptionalMessage) .def("createChildAlgorithm", &Algorithm::createChildAlgorithm, (arg("name"),arg("startProgress")=-1.0,arg("endProgress")=-1.0, arg("enableLogging")=true,arg("version")=-1), "Creates and intializes a named child algorithm. Output workspaces are given a dummy name.") @@ -81,6 +80,9 @@ void export_leaf_classes() "Returns a reference to this algorithm's logger") .def("log", &PythonAlgorithm::getLogger, return_value_policy(), "Returns a reference to this algorithm's logger") // Traditional name + + // deprecated methods + .def("setWikiSummary", &PythonAlgorithm::setWikiSummary, "(Deprecated.) Set summary for the help.") ; // Prior to version 3.2 there was a separate C++ PythonAlgorithm class that inherited from Algorithm and the "PythonAlgorithm" diff --git a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/IAlgorithm.cpp b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/IAlgorithm.cpp index 8fe99fe1e88a..cf6b48bce350 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/IAlgorithm.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/api/src/Exports/IAlgorithm.cpp @@ -136,7 +136,7 @@ namespace // Put in the quick overview message std::stringstream buffer; - std::string temp = self.getOptionalMessage(); + std::string temp = self.summary(); if (temp.size() > 0) buffer << temp << EOL << EOL; @@ -225,6 +225,29 @@ namespace else Py_RETURN_NONE; } + //-------------------------------------------------------------------------------------- + // Deprecated wrappers + //-------------------------------------------------------------------------------------- + /** + * @param self Reference to the calling object + * @return Algorithm summary + */ + std::string getOptionalMessage(IAlgorithm & self) + { + PyErr_Warn(PyExc_DeprecationWarning, ".getOptionalMessage() is deprecated. Use .summary() instead."); + return self.summary(); + } + + /** + * @param self Reference to the calling object + * @return Algorithm summary + */ + std::string getWikiSummary(IAlgorithm & self) + { + PyErr_Warn(PyExc_DeprecationWarning, ".getWikiSummary() is deprecated. Use .summary() instead."); + return self.summary(); + } + } void export_ialgorithm() @@ -244,6 +267,7 @@ void export_ialgorithm() .def("cancel", &IAlgorithm::cancel, "Request that the algorithm stop running") .def("category", &IAlgorithm::category, "Returns the category containing the algorithm") .def("categories", &IAlgorithm::categories, "Returns the list of categories this algorithm belongs to") + .def("summary", &IAlgorithm::summary, "Returns a summary message describing the algorithm") .def("workspaceMethodName",&IAlgorithm::workspaceMethodName, "Returns a name that will be used when attached as a workspace method. Empty string indicates do not attach") .def("workspaceMethodOn", &IAlgorithm::workspaceMethodOn, return_value_policy(), // creates a list for strings @@ -251,9 +275,6 @@ void export_ialgorithm() .def("workspaceMethodInputProperty", &IAlgorithm::workspaceMethodInputProperty, "Returns the name of the input workspace property used by the calling object") .def("getAlgorithmID", &getAlgorithmID, "Returns a unique identifier for this algorithm object") - .def("getOptionalMessage", &IAlgorithm::getOptionalMessage, "Returns the optional user message attached to the algorithm") - .def("getWikiSummary", &IAlgorithm::getWikiSummary, "Returns the summary found on the wiki page") - .def("getWikiDescription", &IAlgorithm::getWikiDescription, "Returns the description found on the wiki page using wiki markup") .def("docString", &createDocString, "Returns a doc string for the algorithm") .def("mandatoryProperties",&getInputPropertiesWithMandatoryFirst, "Returns a list of input and in/out property names that is ordered " "such that the mandatory properties are first followed by the optional ones.") @@ -274,10 +295,15 @@ void export_ialgorithm() "are NOT stored in the Analysis Data Service but must be retrieved from the property.") .def("setLogging", &IAlgorithm::setLogging, "Toggle logging on/off.") .def("setRethrows", &IAlgorithm::setRethrows) - .def("setWikiSummary", &IAlgorithm::setWikiSummary) .def("initialize", &IAlgorithm::initialize, "Initializes the algorithm") .def("execute", &executeWhileReleasingGIL, "Runs the algorithm and returns whether it has been successful") // Special methods .def("__str__", &IAlgorithm::toString) + + // deprecated methods + .def("getOptionalMessage", &getOptionalMessage, + "Returns the optional user message attached to the algorithm") + .def("getWikiSummary", &getWikiSummary, + "Returns the summary found on the wiki page") ; } diff --git a/Code/Mantid/Framework/PythonInterface/mantid/api/src/PythonAlgorithm/AlgorithmAdapter.cpp b/Code/Mantid/Framework/PythonInterface/mantid/api/src/PythonAlgorithm/AlgorithmAdapter.cpp index 8509654f5443..f14c1145242a 100644 --- a/Code/Mantid/Framework/PythonInterface/mantid/api/src/PythonAlgorithm/AlgorithmAdapter.cpp +++ b/Code/Mantid/Framework/PythonInterface/mantid/api/src/PythonAlgorithm/AlgorithmAdapter.cpp @@ -24,7 +24,7 @@ namespace Mantid */ template AlgorithmAdapter::AlgorithmAdapter(PyObject* self) - : BaseAlgorithm(), m_self(self), m_isRunningObj(NULL) + : BaseAlgorithm(), m_self(self), m_isRunningObj(NULL), m_wikiSummary("") { // Cache the isRunning call to save the lookup each time it is called // as it is most likely called in a loop @@ -87,7 +87,7 @@ namespace Mantid /** * Returns the category of the algorithm. If not overridden - * it returns "AlgorithmAdapter" + * it return defaultCategory() */ template const std::string AlgorithmAdapter::category() const @@ -105,6 +105,26 @@ namespace Mantid return "PythonAlgorithms"; } + /** + * Returns the summary of the algorithm. If not overridden + * it returns defaultSummary + */ + template + const std::string AlgorithmAdapter::summary() const + { + return CallMethod0::dispatchWithDefaultReturn(getSelf(), "summary", defaultSummary()); + } + + /** + * A default summary, chosen if there is no override + * @returns A default summary + */ + template + std::string AlgorithmAdapter::defaultSummary() const + { + return m_wikiSummary; + } + /** * @return True if the algorithm is considered to be running */ @@ -191,6 +211,23 @@ namespace Mantid return resultMap; } + /// Set the summary text + /// @param summary Wiki text + template + void AlgorithmAdapter::setWikiSummary(const std::string & summary) + { + std::string msg = \ + "self.setWikiSummary() is deprecated and will be removed in a future release.\n" + "To ensure continued functionality remove the line containing 'self.setWikiSummary'\n" + "and add a new function outside of the current one defined like so:\n" + "def summary(self):\n" + " \"" + summary + "\"\n"; + + PyErr_Warn(PyExc_DeprecationWarning, msg.c_str()); + m_wikiSummary = summary; + } + + /** * Declare a preconstructed property. * @param self A reference to the calling Python object From 3bdb013fc60ff4d15ab37b8e678e5fb0f0caf380 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 09:48:47 +0100 Subject: [PATCH 088/126] Added summary method to MantidRemoteAlgorithms. Refs #9523. --- .../inc/MantidRemoteAlgorithms/AbortRemoteJob.h | 5 +++-- .../inc/MantidRemoteAlgorithms/Authenticate.h | 5 +++-- .../inc/MantidRemoteAlgorithms/DownloadRemoteFile.h | 5 +++-- .../inc/MantidRemoteAlgorithms/QueryAllRemoteJobs.h | 5 +++-- .../inc/MantidRemoteAlgorithms/QueryRemoteFile.h | 5 +++-- .../inc/MantidRemoteAlgorithms/QueryRemoteJob.h | 5 +++-- .../inc/MantidRemoteAlgorithms/StartRemoteTransaction.h | 5 +++-- .../inc/MantidRemoteAlgorithms/StopRemoteTransaction.h | 5 +++-- .../inc/MantidRemoteAlgorithms/SubmitRemoteJob.h | 5 +++-- .../inc/MantidRemoteAlgorithms/UploadRemoteFile.h | 5 +++-- .../Framework/RemoteAlgorithms/src/AbortRemoteJob.cpp | 8 -------- .../Framework/RemoteAlgorithms/src/Authenticate.cpp | 8 -------- .../Framework/RemoteAlgorithms/src/DownloadRemoteFile.cpp | 7 ------- .../Framework/RemoteAlgorithms/src/QueryAllRemoteJobs.cpp | 7 ------- .../Framework/RemoteAlgorithms/src/QueryRemoteFile.cpp | 7 ------- .../Framework/RemoteAlgorithms/src/QueryRemoteJob.cpp | 7 ------- .../RemoteAlgorithms/src/StartRemoteTransaction.cpp | 7 ------- .../RemoteAlgorithms/src/StopRemoteTransaction.cpp | 7 ------- .../Framework/RemoteAlgorithms/src/SubmitRemoteJob.cpp | 7 ------- .../Framework/RemoteAlgorithms/src/UploadRemoteFile.cpp | 7 ------- 20 files changed, 30 insertions(+), 92 deletions(-) diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/AbortRemoteJob.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/AbortRemoteJob.h index 86a96b45cf27..382fced2f1a2 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/AbortRemoteJob.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/AbortRemoteJob.h @@ -15,14 +15,15 @@ class AbortRemoteJob : public Mantid::API::Algorithm virtual ~AbortRemoteJob() {} /// Algorithm's name virtual const std::string name() const { return "AbortRemoteJob"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Abort a previously submitted job.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/Authenticate.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/Authenticate.h index fdd8598e7649..f295bc7eeefd 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/Authenticate.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/Authenticate.h @@ -52,14 +52,15 @@ class Authenticate : public Mantid::API::Algorithm virtual ~Authenticate() {} /// Algorithm's name virtual const std::string name() const { return "Authenticate"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Authenticate to the remote compute resource.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/DownloadRemoteFile.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/DownloadRemoteFile.h index 60285ac050f1..0e8b86977217 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/DownloadRemoteFile.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/DownloadRemoteFile.h @@ -15,14 +15,15 @@ class DownloadRemoteFile : public Mantid::API::Algorithm virtual ~DownloadRemoteFile() {} /// Algorithm's name virtual const std::string name() const { return "DownloadRemoteFile"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Download a file from a remote compute resource.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryAllRemoteJobs.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryAllRemoteJobs.h index 27730ecf58fa..0da8ce2f75c2 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryAllRemoteJobs.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryAllRemoteJobs.h @@ -15,14 +15,15 @@ class QueryAllRemoteJobs : public Mantid::API::Algorithm virtual ~QueryAllRemoteJobs() {} /// Algorithm's name virtual const std::string name() const { return "QueryAllRemoteJobs"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Query a remote compute resource for all jobs the user has submitted.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryRemoteFile.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryRemoteFile.h index 9b683d6d91d3..c2c8260aedc8 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryRemoteFile.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryRemoteFile.h @@ -15,14 +15,15 @@ class QueryRemoteFile : public Mantid::API::Algorithm virtual ~QueryRemoteFile() {} /// Algorithm's name virtual const std::string name() const { return "QueryRemoteFile"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Retrieve a list of the files from a remote compute resource.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryRemoteJob.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryRemoteJob.h index c2c8a263bfea..8acae19ed4f0 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryRemoteJob.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/QueryRemoteJob.h @@ -15,14 +15,15 @@ class QueryRemoteJob : public Mantid::API::Algorithm virtual ~QueryRemoteJob() {} /// Algorithm's name virtual const std::string name() const { return "QueryRemoteJob"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Query a remote compute resource for a specific job";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/StartRemoteTransaction.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/StartRemoteTransaction.h index 0884b3e9979e..39a84b1bc4fa 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/StartRemoteTransaction.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/StartRemoteTransaction.h @@ -15,14 +15,15 @@ class StartRemoteTransaction : public Mantid::API::Algorithm virtual ~StartRemoteTransaction() {} /// Algorithm's name virtual const std::string name() const { return "StartRemoteTransaction"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Start a job transaction on a remote compute resource.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/StopRemoteTransaction.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/StopRemoteTransaction.h index 6666f6714b70..78c84f85a177 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/StopRemoteTransaction.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/StopRemoteTransaction.h @@ -15,14 +15,15 @@ class StopRemoteTransaction : public Mantid::API::Algorithm virtual ~StopRemoteTransaction() {} /// Algorithm's name virtual const std::string name() const { return "StopRemoteTransaction"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Stop a job transaction on a remote compute resource.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/SubmitRemoteJob.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/SubmitRemoteJob.h index 28ff121a5849..f65b75507d76 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/SubmitRemoteJob.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/SubmitRemoteJob.h @@ -57,14 +57,15 @@ class SubmitRemoteJob : public Mantid::API::Algorithm virtual ~SubmitRemoteJob() {} /// Algorithm's name virtual const std::string name() const { return "SubmitRemoteJob"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Submit a job to be executed on the specified remote compute resource.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/UploadRemoteFile.h b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/UploadRemoteFile.h index b7bd4a5d0e8e..2005b9fa76a6 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/UploadRemoteFile.h +++ b/Code/Mantid/Framework/RemoteAlgorithms/inc/MantidRemoteAlgorithms/UploadRemoteFile.h @@ -53,14 +53,15 @@ class DLLExport UploadRemoteFile : public API::Algorithm virtual ~UploadRemoteFile() {} /// Algorithm's name virtual const std::string name() const { return "UploadRemoteFile"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Uploads a file to the specified compute resource.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Remote"; } private: - /// Initialisation code - void initDocs(); void init(); ///Execution code void exec(); diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/AbortRemoteJob.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/AbortRemoteJob.cpp index 7d9a14d8eb02..55e35bb7c133 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/AbortRemoteJob.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/AbortRemoteJob.cpp @@ -29,14 +29,6 @@ using namespace Mantid::API; using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -/// Sets documentation strings for this algorithm -void AbortRemoteJob::initDocs() -{ - this->setWikiSummary("Abort a previously submitted job."); - this->setOptionalMessage("Abort a previously submitted job."); -} void AbortRemoteJob::init() { diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/Authenticate.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/Authenticate.cpp index 34cd0b56f8eb..35d4a4e8f93a 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/Authenticate.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/Authenticate.cpp @@ -34,14 +34,6 @@ using namespace Mantid::Kernel; //using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -/// Sets documentation strings for this algorithm -void Authenticate::initDocs() -{ - this->setWikiSummary("Authenticate to the remote compute resource."); - this->setOptionalMessage("Authenticate to the remote compute resource."); -} void Authenticate::init() { diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/DownloadRemoteFile.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/DownloadRemoteFile.cpp index 4e4244240f8a..166cb67a5d95 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/DownloadRemoteFile.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/DownloadRemoteFile.cpp @@ -31,13 +31,6 @@ using namespace Mantid::API; using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -void DownloadRemoteFile::initDocs() -{ - this->setWikiSummary("Download a file from a remote compute resource."); - this->setOptionalMessage("Download a file from a remote compute resource."); -} void DownloadRemoteFile::init() { diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/QueryAllRemoteJobs.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/QueryAllRemoteJobs.cpp index 12d9c4459b14..2eaf5071717f 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/QueryAllRemoteJobs.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/QueryAllRemoteJobs.cpp @@ -31,13 +31,6 @@ using namespace Mantid::API; using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -void QueryAllRemoteJobs::initDocs() - { - this->setWikiSummary("Query a remote compute resource for all jobs the user has submitted."); - this->setOptionalMessage("Query a remote compute resource for all jobs the user has submitted."); - } void QueryAllRemoteJobs::init() { diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/QueryRemoteFile.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/QueryRemoteFile.cpp index b92a4d2ad504..d836fe433134 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/QueryRemoteFile.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/QueryRemoteFile.cpp @@ -31,13 +31,6 @@ using namespace Mantid::API; using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -void QueryRemoteFile::initDocs() -{ - this->setWikiSummary("Retrieve a list of the files from a remote compute resource."); - this->setOptionalMessage("Retrieve a list of the files from a remote compute resource."); -} void QueryRemoteFile::init() { diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/QueryRemoteJob.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/QueryRemoteJob.cpp index f9209d3a675b..dbc6432f598a 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/QueryRemoteJob.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/QueryRemoteJob.cpp @@ -29,13 +29,6 @@ using namespace Mantid::API; using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -void QueryRemoteJob::initDocs() -{ - this->setWikiSummary("Query a remote compute resource for a specific job"); - this->setOptionalMessage("Query a remote compute resource for a specific job"); -} void QueryRemoteJob::init() { diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/StartRemoteTransaction.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/StartRemoteTransaction.cpp index c2c8736eb639..db14ba25fd01 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/StartRemoteTransaction.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/StartRemoteTransaction.cpp @@ -26,13 +26,6 @@ DECLARE_ALGORITHM(StartRemoteTransaction) using namespace Mantid::Kernel; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -void StartRemoteTransaction::initDocs() -{ - this->setWikiSummary("Start a job transaction on a remote compute resource."); - this->setOptionalMessage("Start a job transaction on a remote compute resource."); -} void StartRemoteTransaction::init() { diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/StopRemoteTransaction.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/StopRemoteTransaction.cpp index e722e0d8d5d7..eb545aac01e5 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/StopRemoteTransaction.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/StopRemoteTransaction.cpp @@ -27,13 +27,6 @@ DECLARE_ALGORITHM(StopRemoteTransaction) using namespace Mantid::Kernel; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -void StopRemoteTransaction::initDocs() -{ - this->setWikiSummary("Stop a job transaction on a remote compute resource."); - this->setOptionalMessage("Stop a job transaction on a remote compute resource."); -} void StopRemoteTransaction::init() { diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/SubmitRemoteJob.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/SubmitRemoteJob.cpp index 861fa03fb1a6..9ead38384dbd 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/SubmitRemoteJob.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/SubmitRemoteJob.cpp @@ -33,13 +33,6 @@ using namespace Mantid::Kernel; //using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -void SubmitRemoteJob::initDocs() -{ - this->setWikiSummary("Submit a job to be executed on the specified remote compute resource."); - this->setOptionalMessage("Submit a job to be executed on the specified remote compute resource."); -} void SubmitRemoteJob::init() { diff --git a/Code/Mantid/Framework/RemoteAlgorithms/src/UploadRemoteFile.cpp b/Code/Mantid/Framework/RemoteAlgorithms/src/UploadRemoteFile.cpp index 931a1e289158..9c275aaf5577 100644 --- a/Code/Mantid/Framework/RemoteAlgorithms/src/UploadRemoteFile.cpp +++ b/Code/Mantid/Framework/RemoteAlgorithms/src/UploadRemoteFile.cpp @@ -32,13 +32,6 @@ using namespace Mantid::API; using namespace Mantid::Geometry; // A reference to the logger is provided by the base class, it is called g_log. -// It is used to print out information, warning and error messages - -void UploadRemoteFile::initDocs() -{ - this->setWikiSummary("Uploads a file to the specified compute resource."); - this->setOptionalMessage("Uploads a file to the specified compute resource."); -} void UploadRemoteFile::init() { From 31a67ca8427715fda8792cd9228648c607a8f444 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 10:12:18 +0100 Subject: [PATCH 089/126] Added summary method to SINQ algorithms. Refs #9523. --- Code/Mantid/Framework/SINQ/inc/MantidSINQ/InvertMDDim.h | 5 +++-- .../Mantid/Framework/SINQ/inc/MantidSINQ/LoadFlexiNexus.h | 5 +++-- .../Framework/SINQ/inc/MantidSINQ/MDHistoToWorkspace2D.h | 5 +++-- .../Framework/SINQ/inc/MantidSINQ/PoldiAutoCorrelation5.h | 5 +++-- .../Framework/SINQ/inc/MantidSINQ/PoldiFitPeaks1D.h | 4 +++- .../Framework/SINQ/inc/MantidSINQ/PoldiLoadChopperSlits.h | 5 +++-- Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadIPP.h | 5 +++-- Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadLog.h | 5 +++-- .../Framework/SINQ/inc/MantidSINQ/PoldiLoadSpectra.h | 5 +++-- .../Framework/SINQ/inc/MantidSINQ/PoldiPeakDetection2.h | 5 +++-- .../Framework/SINQ/inc/MantidSINQ/PoldiPeakSearch.h | 4 +++- .../Framework/SINQ/inc/MantidSINQ/PoldiRemoveDeadWires.h | 5 +++-- Code/Mantid/Framework/SINQ/inc/MantidSINQ/ProjectMD.h | 5 +++-- .../Framework/SINQ/inc/MantidSINQ/SINQTranspose3D.h | 5 +++-- Code/Mantid/Framework/SINQ/inc/MantidSINQ/SliceMDHisto.h | 5 +++-- Code/Mantid/Framework/SINQ/src/InvertMDDim.cpp | 4 ---- Code/Mantid/Framework/SINQ/src/LoadFlexiNexus.cpp | 4 ---- Code/Mantid/Framework/SINQ/src/MDHistoToWorkspace2D.cpp | 4 ---- Code/Mantid/Framework/SINQ/src/PoldiAutoCorrelation5.cpp | 7 ------- Code/Mantid/Framework/SINQ/src/PoldiFitPeaks1D.cpp | 8 -------- Code/Mantid/Framework/SINQ/src/PoldiLoadChopperSlits.cpp | 7 ------- Code/Mantid/Framework/SINQ/src/PoldiLoadIPP.cpp | 7 ------- Code/Mantid/Framework/SINQ/src/PoldiLoadLog.cpp | 7 ------- Code/Mantid/Framework/SINQ/src/PoldiLoadSpectra.cpp | 7 ------- Code/Mantid/Framework/SINQ/src/PoldiPeakDetection2.cpp | 7 ------- Code/Mantid/Framework/SINQ/src/PoldiPeakSearch.cpp | 5 ----- Code/Mantid/Framework/SINQ/src/PoldiRemoveDeadWires.cpp | 7 ------- Code/Mantid/Framework/SINQ/src/ProjectMD.cpp | 5 ----- Code/Mantid/Framework/SINQ/src/SINQTranspose3D.cpp | 5 ----- Code/Mantid/Framework/SINQ/src/SliceMDHisto.cpp | 5 ----- 30 files changed, 45 insertions(+), 117 deletions(-) diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/InvertMDDim.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/InvertMDDim.h index b30319cd2782..b948e913a0d8 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/InvertMDDim.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/InvertMDDim.h @@ -41,6 +41,9 @@ class MANTID_SINQ_DLL InvertMDDim : public Mantid::API::Algorithm virtual ~InvertMDDim() {} /// Algorithm's name virtual const std::string name() const { return "InvertMDDim"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Inverts dimensions of a MDHistoWorkspace";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -59,8 +62,6 @@ class MANTID_SINQ_DLL InvertMDDim : public Mantid::API::Algorithm unsigned int calcIndex(Mantid::API::IMDHistoWorkspace_sptr ws, int *dim); unsigned int calcInvertedIndex(Mantid::API::IMDHistoWorkspace_sptr ws, int *dim); - virtual void initDocs(); - }; #endif /*INVERTMDDIM_H_*/ diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/LoadFlexiNexus.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/LoadFlexiNexus.h index a36b312dcd21..b725dec35adb 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/LoadFlexiNexus.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/LoadFlexiNexus.h @@ -58,6 +58,9 @@ class MANTID_SINQ_DLL LoadFlexiNexus : public Mantid::API::Algorithm virtual ~LoadFlexiNexus() {} /// Algorithm's name virtual const std::string name() const { return "LoadFlexiNexus"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a NeXus file directed by a dictionary file";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -93,8 +96,6 @@ class MANTID_SINQ_DLL LoadFlexiNexus : public Mantid::API::Algorithm int calculateCAddress(int *pos, int* dim, int rank); int calculateF77Address(int *pos, int rank); size_t *indexMaker; - - virtual void initDocs(); }; #endif /*FLEXINEXUSLOADER_H_*/ diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/MDHistoToWorkspace2D.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/MDHistoToWorkspace2D.h index b07133a405ac..96fd85bb1646 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/MDHistoToWorkspace2D.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/MDHistoToWorkspace2D.h @@ -42,6 +42,9 @@ class MANTID_SINQ_DLL MDHistoToWorkspace2D : public Mantid::API::Algorithm virtual ~MDHistoToWorkspace2D() {} /// Algorithm's name virtual const std::string name() const { return "MDHistoToWorkspace2D"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Flattens a n dimensional MDHistoWorkspace into a Workspace2D with many spectra";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -53,8 +56,6 @@ class MANTID_SINQ_DLL MDHistoToWorkspace2D : public Mantid::API::Algorithm ///Execution code void exec(); - virtual void initDocs(); - size_t rank; size_t currentSpectra; size_t calculateNSpectra( Mantid::API::IMDHistoWorkspace_sptr inws); diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiAutoCorrelation5.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiAutoCorrelation5.h index 9eb094d73d9d..da7717a1ecca 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiAutoCorrelation5.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiAutoCorrelation5.h @@ -68,6 +68,9 @@ class MANTID_SINQ_DLL PoldiAutoCorrelation5 : public API::Algorithm virtual ~PoldiAutoCorrelation5() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PoldiAutoCorrelation"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Proceed to autocorrelation on Poldi data.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 5; } /// Algorithm's category for identification overriding a virtual method @@ -84,8 +87,6 @@ class MANTID_SINQ_DLL PoldiAutoCorrelation5 : public API::Algorithm private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiFitPeaks1D.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiFitPeaks1D.h index 30547723f03e..5d98b439e0c6 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiFitPeaks1D.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiFitPeaks1D.h @@ -51,6 +51,9 @@ namespace Poldi virtual ~PoldiFitPeaks1D(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "PoldiPeakFit1D fits peak profiles to POLDI auto-correlation data.";} + virtual int version() const; virtual const std::string category() const; @@ -82,7 +85,6 @@ namespace Poldi double m_fwhmMultiples; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadChopperSlits.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadChopperSlits.h index 3e6b90aa657c..14f923dd0d24 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadChopperSlits.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadChopperSlits.h @@ -49,6 +49,9 @@ namespace Mantid virtual ~PoldiLoadChopperSlits() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PoldiLoadChopperSlits"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load Poldi chopper slits data file.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -63,8 +66,6 @@ namespace Mantid private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadIPP.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadIPP.h index 80e1beedc255..694ab5c56e37 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadIPP.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadIPP.h @@ -55,6 +55,9 @@ namespace Mantid virtual ~PoldiLoadIPP() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PoldiLoadIPP"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load Poldi IPP data.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -68,8 +71,6 @@ namespace Mantid private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadLog.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadLog.h index bfad1ad2f021..c56d22730c78 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadLog.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadLog.h @@ -53,6 +53,9 @@ namespace Mantid virtual ~PoldiLoadLog() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PoldiLoadLog"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load Poldi log data.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -69,8 +72,6 @@ namespace Mantid private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadSpectra.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadSpectra.h index 502d88aa8cb8..ea8c96d89d6b 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadSpectra.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiLoadSpectra.h @@ -50,6 +50,9 @@ namespace Mantid virtual ~PoldiLoadSpectra() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PoldiLoadSpectra"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load Poldi data file.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -66,8 +69,6 @@ namespace Mantid private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiPeakDetection2.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiPeakDetection2.h index fec55b575a72..fc7808660f8b 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiPeakDetection2.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiPeakDetection2.h @@ -61,6 +61,9 @@ class MANTID_SINQ_DLL PoldiPeakDetection2 : public API::Algorithm virtual ~PoldiPeakDetection2() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PoldiPeakDetection"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Peak detection used on a diffractogram, with peak refinement thru a peak fit with a gaussian function.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 2; } /// Algorithm's category for identification overriding a virtual method @@ -72,8 +75,6 @@ class MANTID_SINQ_DLL PoldiPeakDetection2 : public API::Algorithm void exec(); private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiPeakSearch.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiPeakSearch.h index a78ee1c98d27..98aba2536d61 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiPeakSearch.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiPeakSearch.h @@ -54,10 +54,12 @@ namespace Poldi virtual int version() const { return 1; } virtual const std::string name() const { return "PoldiPeakSearch"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "This algorithm finds the peaks in a POLDI auto-correlation spectrum.";} + virtual const std::string category() const { return "SINQ\\Poldi"; } protected: - void initDocs(); MantidVec getNeighborSums(MantidVec correlationCounts) const; diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiRemoveDeadWires.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiRemoveDeadWires.h index d7408468285a..efbf5b943d3c 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiRemoveDeadWires.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/PoldiRemoveDeadWires.h @@ -60,6 +60,9 @@ namespace Mantid virtual ~PoldiRemoveDeadWires() {} /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "PoldiRemoveDeadWires"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Remove dead wires from Poldi data.";} + /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } /// Algorithm's category for identification overriding a virtual method @@ -90,8 +93,6 @@ namespace Mantid private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Overwrites Algorithm method. void init(); diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/ProjectMD.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/ProjectMD.h index ff6c192eb593..4e2a6217e75a 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/ProjectMD.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/ProjectMD.h @@ -40,6 +40,9 @@ class MANTID_SINQ_DLL ProjectMD : public Mantid::API::Algorithm virtual ~ProjectMD() {} /// Algorithm's name virtual const std::string name() const { return "ProjectMD"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Sum a MDHistoWorkspace along a choosen dimension";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -58,8 +61,6 @@ class MANTID_SINQ_DLL ProjectMD : public Mantid::API::Algorithm double getValue(Mantid::API::IMDHistoWorkspace_sptr ws, int *dim); void putValue(Mantid::API::IMDHistoWorkspace_sptr ws, int *dim, double val); unsigned int calcIndex(Mantid::API::IMDHistoWorkspace_sptr ws, int *dim); - - virtual void initDocs(); }; #endif /*PROJECTMD_H_*/ diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/SINQTranspose3D.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/SINQTranspose3D.h index c466d0e42f0b..f57b2b44f30f 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/SINQTranspose3D.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/SINQTranspose3D.h @@ -44,6 +44,9 @@ class MANTID_SINQ_DLL SINQTranspose3D : public Mantid::API::Algorithm virtual ~SINQTranspose3D() {} /// Algorithm's name virtual const std::string name() const { return "Transpose3D"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "SINQ specific MD data reordering";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -60,8 +63,6 @@ class MANTID_SINQ_DLL SINQTranspose3D : public Mantid::API::Algorithm void doTRICS( Mantid::API::IMDHistoWorkspace_sptr inws); void doAMOR( Mantid::API::IMDHistoWorkspace_sptr inws); - virtual void initDocs(); - void copyMetaData( Mantid::API::IMDHistoWorkspace_sptr inws, Mantid::API::IMDHistoWorkspace_sptr outws); }; diff --git a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/SliceMDHisto.h b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/SliceMDHisto.h index 81040771f737..5231c53a735e 100644 --- a/Code/Mantid/Framework/SINQ/inc/MantidSINQ/SliceMDHisto.h +++ b/Code/Mantid/Framework/SINQ/inc/MantidSINQ/SliceMDHisto.h @@ -40,6 +40,9 @@ class MANTID_SINQ_DLL SliceMDHisto : public Mantid::API::Algorithm virtual ~SliceMDHisto() {} /// Algorithm's name virtual const std::string name() const { return "SliceMDHisto"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Extracts a hyperslab of data from a MDHistoWorkspace";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification @@ -60,8 +63,6 @@ class MANTID_SINQ_DLL SliceMDHisto : public Mantid::API::Algorithm void copyMetaData( Mantid::API::IMDHistoWorkspace_sptr inws, Mantid::API::IMDHistoWorkspace_sptr outws); - virtual void initDocs(); - }; #endif /*SLICEMDHISTO_H_*/ diff --git a/Code/Mantid/Framework/SINQ/src/InvertMDDim.cpp b/Code/Mantid/Framework/SINQ/src/InvertMDDim.cpp index b978b1401115..900da9f43dd8 100644 --- a/Code/Mantid/Framework/SINQ/src/InvertMDDim.cpp +++ b/Code/Mantid/Framework/SINQ/src/InvertMDDim.cpp @@ -135,7 +135,3 @@ unsigned int InvertMDDim::calcInvertedIndex(IMDHistoWorkspace_sptr ws, int dim[] } return static_cast(idx); } -void InvertMDDim::initDocs() -{ - this->setWikiSummary("Inverts dimensions of a MDHistoWorkspace"); -} diff --git a/Code/Mantid/Framework/SINQ/src/LoadFlexiNexus.cpp b/Code/Mantid/Framework/SINQ/src/LoadFlexiNexus.cpp index 836ba42a2c61..f6eba25f9cca 100644 --- a/Code/Mantid/Framework/SINQ/src/LoadFlexiNexus.cpp +++ b/Code/Mantid/Framework/SINQ/src/LoadFlexiNexus.cpp @@ -437,7 +437,3 @@ int LoadFlexiNexus::safeOpenpath(NeXus::File *fin, std::string path) } return 1; } -void LoadFlexiNexus::initDocs() -{ - this->setWikiSummary("Loads a NeXus file directed by a dictionary file"); -} diff --git a/Code/Mantid/Framework/SINQ/src/MDHistoToWorkspace2D.cpp b/Code/Mantid/Framework/SINQ/src/MDHistoToWorkspace2D.cpp index 104ca017b8c3..8dcdf3a54ecf 100644 --- a/Code/Mantid/Framework/SINQ/src/MDHistoToWorkspace2D.cpp +++ b/Code/Mantid/Framework/SINQ/src/MDHistoToWorkspace2D.cpp @@ -131,10 +131,6 @@ void MDHistoToWorkspace2D::checkW2D(Mantid::DataObjects::Workspace2D_sptr outWS) } } } -void MDHistoToWorkspace2D::initDocs() -{ - this->setWikiSummary("Flattens a n dimensional MDHistoWorkspace into a Workspace2D with many spectra"); -} void MDHistoToWorkspace2D::copyMetaData(Mantid::API::IMDHistoWorkspace_sptr inWS, Mantid::DataObjects::Workspace2D_sptr outWS) { diff --git a/Code/Mantid/Framework/SINQ/src/PoldiAutoCorrelation5.cpp b/Code/Mantid/Framework/SINQ/src/PoldiAutoCorrelation5.cpp index 7f7caae72dc3..1137b62adfc4 100644 --- a/Code/Mantid/Framework/SINQ/src/PoldiAutoCorrelation5.cpp +++ b/Code/Mantid/Framework/SINQ/src/PoldiAutoCorrelation5.cpp @@ -40,13 +40,6 @@ namespace Poldi // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(PoldiAutoCorrelation5) -/// Sets documentation strings for this algorithm -void PoldiAutoCorrelation5::initDocs() -{ - this->setWikiSummary("Calculates auto-correlation function for POLDI data."); - this->setOptionalMessage("Proceed to autocorrelation on Poldi data."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/SINQ/src/PoldiFitPeaks1D.cpp b/Code/Mantid/Framework/SINQ/src/PoldiFitPeaks1D.cpp index 858831c1b915..4dd5cd75c5df 100644 --- a/Code/Mantid/Framework/SINQ/src/PoldiFitPeaks1D.cpp +++ b/Code/Mantid/Framework/SINQ/src/PoldiFitPeaks1D.cpp @@ -67,14 +67,6 @@ int PoldiFitPeaks1D::version() const { return 1;} /// Algorithm's category for identification. @see Algorithm::category const std::string PoldiFitPeaks1D::category() const { return "SINQ\\Poldi\\PoldiSet"; } - -/// Sets documentation strings for this algorithm -void PoldiFitPeaks1D::initDocs() -{ - this->setWikiSummary("PoldiPeakFit1D fits peak profiles to POLDI auto-correlation data."); - this->setOptionalMessage("PoldiPeakFit1D fits peak profiles to POLDI auto-correlation data."); -} - void PoldiFitPeaks1D::init() { declareProperty(new WorkspaceProperty("InputWorkspace","",Direction::Input), "An input workspace containing a POLDI auto-correlation spectrum."); diff --git a/Code/Mantid/Framework/SINQ/src/PoldiLoadChopperSlits.cpp b/Code/Mantid/Framework/SINQ/src/PoldiLoadChopperSlits.cpp index 8613797f8af9..5fc5a60aa5e9 100644 --- a/Code/Mantid/Framework/SINQ/src/PoldiLoadChopperSlits.cpp +++ b/Code/Mantid/Framework/SINQ/src/PoldiLoadChopperSlits.cpp @@ -31,13 +31,6 @@ namespace Poldi // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(PoldiLoadChopperSlits) -// Sets documentation strings for this algorithm -void PoldiLoadChopperSlits::initDocs() -{ - this->setWikiSummary("Load Poldi chopper slits data file. "); - this->setOptionalMessage("Load Poldi chopper slits data file."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/SINQ/src/PoldiLoadIPP.cpp b/Code/Mantid/Framework/SINQ/src/PoldiLoadIPP.cpp index 4140508c4adb..b8ded546396d 100644 --- a/Code/Mantid/Framework/SINQ/src/PoldiLoadIPP.cpp +++ b/Code/Mantid/Framework/SINQ/src/PoldiLoadIPP.cpp @@ -30,13 +30,6 @@ namespace Poldi // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(PoldiLoadIPP) -/// Sets documentation strings for this algorithm -void PoldiLoadIPP::initDocs() -{ - this->setWikiSummary("Load Poldi IPP data. "); - this->setOptionalMessage("Load Poldi IPP data."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/SINQ/src/PoldiLoadLog.cpp b/Code/Mantid/Framework/SINQ/src/PoldiLoadLog.cpp index dd099385d3b3..fcdb82e1ab50 100644 --- a/Code/Mantid/Framework/SINQ/src/PoldiLoadLog.cpp +++ b/Code/Mantid/Framework/SINQ/src/PoldiLoadLog.cpp @@ -35,13 +35,6 @@ namespace Poldi // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(PoldiLoadLog) -/// Sets documentation strings for this algorithm -void PoldiLoadLog::initDocs() -{ - this->setWikiSummary("Load Poldi log data. "); - this->setOptionalMessage("Load Poldi log data."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/SINQ/src/PoldiLoadSpectra.cpp b/Code/Mantid/Framework/SINQ/src/PoldiLoadSpectra.cpp index dea66a967386..a090f7151918 100644 --- a/Code/Mantid/Framework/SINQ/src/PoldiLoadSpectra.cpp +++ b/Code/Mantid/Framework/SINQ/src/PoldiLoadSpectra.cpp @@ -35,13 +35,6 @@ namespace DataHandling // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(PoldiLoadSpectra) -// Sets documentation strings for this algorithm -void PoldiLoadSpectra::initDocs() -{ - this->setWikiSummary("Load Poldi data file. "); - this->setOptionalMessage("Load Poldi data file."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/SINQ/src/PoldiPeakDetection2.cpp b/Code/Mantid/Framework/SINQ/src/PoldiPeakDetection2.cpp index a13696ccbd2b..f6d8165ae853 100644 --- a/Code/Mantid/Framework/SINQ/src/PoldiPeakDetection2.cpp +++ b/Code/Mantid/Framework/SINQ/src/PoldiPeakDetection2.cpp @@ -34,13 +34,6 @@ namespace Poldi // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(PoldiPeakDetection2) -/// Sets documentation strings for this algorithm -void PoldiPeakDetection2::initDocs() -{ - this->setWikiSummary("Peak detection used on a diffractogram, with peak refinement thru a peak fit with a gaussian function."); - this->setOptionalMessage("Peak detection used on a diffractogram, with peak refinement thru a peak fit with a gaussian function."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/SINQ/src/PoldiPeakSearch.cpp b/Code/Mantid/Framework/SINQ/src/PoldiPeakSearch.cpp index 691540f970c3..d9c4e91d3f67 100644 --- a/Code/Mantid/Framework/SINQ/src/PoldiPeakSearch.cpp +++ b/Code/Mantid/Framework/SINQ/src/PoldiPeakSearch.cpp @@ -71,11 +71,6 @@ PoldiPeakSearch::PoldiPeakSearch() : { } -void PoldiPeakSearch::initDocs() -{ - setWikiSummary("This algorithm finds the peaks in a POLDI auto-correlation spectrum."); -} - /** Sums the counts of neighboring d-values * * This method takes a vector of counts y with N elements and produces a new vector y' diff --git a/Code/Mantid/Framework/SINQ/src/PoldiRemoveDeadWires.cpp b/Code/Mantid/Framework/SINQ/src/PoldiRemoveDeadWires.cpp index 7e3ad1484e4f..00070b15a08d 100644 --- a/Code/Mantid/Framework/SINQ/src/PoldiRemoveDeadWires.cpp +++ b/Code/Mantid/Framework/SINQ/src/PoldiRemoveDeadWires.cpp @@ -29,13 +29,6 @@ namespace Poldi // Register the algorithm into the algorithm factory DECLARE_ALGORITHM(PoldiRemoveDeadWires) -/// Sets documentation strings for this algorithm -void PoldiRemoveDeadWires::initDocs() -{ - this->setWikiSummary("Remove dead wires from Poldi data. "); - this->setOptionalMessage("Remove dead wires from Poldi data."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/SINQ/src/ProjectMD.cpp b/Code/Mantid/Framework/SINQ/src/ProjectMD.cpp index 3650053df0b4..3d0db88157b9 100644 --- a/Code/Mantid/Framework/SINQ/src/ProjectMD.cpp +++ b/Code/Mantid/Framework/SINQ/src/ProjectMD.cpp @@ -219,8 +219,3 @@ void ProjectMD::sumData(IMDHistoWorkspace_sptr inWS, IMDHistoWorkspace_sptr outW } } } - -void ProjectMD::initDocs() -{ - this->setWikiSummary("Sum a MDHistoWorkspace along a choosen dimension"); -} diff --git a/Code/Mantid/Framework/SINQ/src/SINQTranspose3D.cpp b/Code/Mantid/Framework/SINQ/src/SINQTranspose3D.cpp index 2ec737c2e31c..c2d70951e4e9 100644 --- a/Code/Mantid/Framework/SINQ/src/SINQTranspose3D.cpp +++ b/Code/Mantid/Framework/SINQ/src/SINQTranspose3D.cpp @@ -242,8 +242,3 @@ void SINQTranspose3D::copyMetaData( Mantid::API::IMDHistoWorkspace_sptr inws, M outws->addExperimentInfo(info); } } - -void SINQTranspose3D::initDocs() -{ - this->setWikiSummary("SINQ specific MD data reordering"); -} diff --git a/Code/Mantid/Framework/SINQ/src/SliceMDHisto.cpp b/Code/Mantid/Framework/SINQ/src/SliceMDHisto.cpp index 53162cba23f4..65503848665f 100644 --- a/Code/Mantid/Framework/SINQ/src/SliceMDHisto.cpp +++ b/Code/Mantid/Framework/SINQ/src/SliceMDHisto.cpp @@ -142,8 +142,3 @@ void SliceMDHisto::copyMetaData( Mantid::API::IMDHistoWorkspace_sptr inws, Mant } } -void SliceMDHisto::initDocs() -{ - this->setWikiSummary("Extracts a hyperslab of data from a MDHistoWorkspace"); -} - From cfa2912ec1a50f9d1cbe7e3ac3df573657d01a34 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 10:23:08 +0100 Subject: [PATCH 090/126] Added summary method to WorkFlow algorithms. Refs #9523. --- .../MantidWorkflowAlgorithms/AlignAndFocusPowder.h | 7 ++++--- .../inc/MantidWorkflowAlgorithms/ComputeSensitivity.h | 4 ++-- .../DgsAbsoluteUnitsReduction.h | 4 ++-- .../DgsConvertToEnergyTransfer.h | 4 ++-- .../inc/MantidWorkflowAlgorithms/DgsDiagnose.h | 4 +++- .../inc/MantidWorkflowAlgorithms/DgsPreprocessData.h | 4 +++- .../DgsProcessDetectorVanadium.h | 4 +++- .../inc/MantidWorkflowAlgorithms/DgsReduction.h | 4 +++- .../inc/MantidWorkflowAlgorithms/DgsRemap.h | 4 +++- .../EQSANSDarkCurrentSubtraction.h | 4 ++-- .../inc/MantidWorkflowAlgorithms/EQSANSLoad.h | 5 ++--- .../inc/MantidWorkflowAlgorithms/EQSANSMonitorTOF.h | 4 ++-- .../MantidWorkflowAlgorithms/EQSANSPatchSensitivity.h | 4 ++-- .../inc/MantidWorkflowAlgorithms/EQSANSQ2D.h | 4 ++-- .../inc/MantidWorkflowAlgorithms/EQSANSReduce.h | 4 ++-- .../HFIRDarkCurrentSubtraction.h | 4 ++-- .../inc/MantidWorkflowAlgorithms/HFIRLoad.h | 5 ++--- .../inc/MantidWorkflowAlgorithms/HFIRSANSNormalise.h | 4 ++-- .../MantidWorkflowAlgorithms/MuonCalculateAsymmetry.h | 4 +++- .../inc/MantidWorkflowAlgorithms/MuonLoad.h | 4 +++- .../inc/MantidWorkflowAlgorithms/RefReduction.h | 4 ++-- .../inc/MantidWorkflowAlgorithms/RefRoi.h | 4 ++-- .../inc/MantidWorkflowAlgorithms/SANSBeamFinder.h | 4 ++-- .../MantidWorkflowAlgorithms/SANSBeamFluxCorrection.h | 4 ++-- .../SANSSensitivityCorrection.h | 4 ++-- .../SANSSolidAngleCorrection.h | 4 ++-- .../MantidWorkflowAlgorithms/SetupEQSANSReduction.h | 5 ++--- .../inc/MantidWorkflowAlgorithms/SetupHFIRReduction.h | 5 ++--- .../MantidWorkflowAlgorithms/SetupILLD33Reduction.h | 6 +++--- .../inc/MantidWorkflowAlgorithms/StepScan.h | 4 +++- .../WorkflowAlgorithms/src/AlignAndFocusPowder.cpp | 11 ----------- .../WorkflowAlgorithms/src/ComputeSensitivity.cpp | 7 ------- .../src/DgsAbsoluteUnitsReduction.cpp | 6 ------ .../src/DgsConvertToEnergyTransfer.cpp | 6 ------ .../Framework/WorkflowAlgorithms/src/DgsDiagnose.cpp | 6 ------ .../WorkflowAlgorithms/src/DgsPreprocessData.cpp | 6 ------ .../src/DgsProcessDetectorVanadium.cpp | 6 ------ .../Framework/WorkflowAlgorithms/src/DgsReduction.cpp | 6 ------ .../Framework/WorkflowAlgorithms/src/DgsRemap.cpp | 6 ------ .../src/EQSANSDarkCurrentSubtraction.cpp | 7 ------- .../Framework/WorkflowAlgorithms/src/EQSANSLoad.cpp | 7 ------- .../WorkflowAlgorithms/src/EQSANSMonitorTOF.cpp | 7 ------- .../WorkflowAlgorithms/src/EQSANSPatchSensitivity.cpp | 7 ------- .../Framework/WorkflowAlgorithms/src/EQSANSQ2D.cpp | 7 ------- .../src/HFIRDarkCurrentSubtraction.cpp | 7 ------- .../Framework/WorkflowAlgorithms/src/HFIRLoad.cpp | 7 ------- .../WorkflowAlgorithms/src/HFIRSANSNormalise.cpp | 7 ------- .../WorkflowAlgorithms/src/MuonCalculateAsymmetry.cpp | 7 ------- .../Framework/WorkflowAlgorithms/src/MuonLoad.cpp | 7 ------- .../Framework/WorkflowAlgorithms/src/RefReduction.cpp | 7 ------- .../Framework/WorkflowAlgorithms/src/RefRoi.cpp | 7 ------- .../WorkflowAlgorithms/src/SANSBeamFinder.cpp | 7 ------- .../WorkflowAlgorithms/src/SANSBeamFluxCorrection.cpp | 7 ------- .../src/SANSSensitivityCorrection.cpp | 7 ------- .../src/SANSSolidAngleCorrection.cpp | 7 ------- .../WorkflowAlgorithms/src/SetupEQSANSReduction.cpp | 7 ------- .../WorkflowAlgorithms/src/SetupHFIRReduction.cpp | 7 ------- .../WorkflowAlgorithms/src/SetupILLD33Reduction.cpp | 7 ------- .../Framework/WorkflowAlgorithms/src/StepScan.cpp | 6 ------ 59 files changed, 71 insertions(+), 257 deletions(-) diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/AlignAndFocusPowder.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/AlignAndFocusPowder.h index ccaae6a81dc0..59f7f26e97e1 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/AlignAndFocusPowder.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/AlignAndFocusPowder.h @@ -67,10 +67,11 @@ namespace Mantid virtual int version() const; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const; - + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Algorithm to focus powder diffraction data into a number of histograms " + "according to a grouping scheme defined in a CalFile.";} + private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/ComputeSensitivity.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/ComputeSensitivity.h index c81aeb014f68..e9404c0cf4e2 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/ComputeSensitivity.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/ComputeSensitivity.h @@ -42,14 +42,14 @@ class DLLExport ComputeSensitivity : public API::DataProcessorAlgorithm virtual ~ComputeSensitivity() {} /// Algorithm's name virtual const std::string name() const { return "ComputeSensitivity"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Workflow to calculate EQSANS sensitivity correction.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS\\UsesPropertyManager"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsAbsoluteUnitsReduction.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsAbsoluteUnitsReduction.h index d4c7fa8c8b2c..d7845d62cd2e 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsAbsoluteUnitsReduction.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsAbsoluteUnitsReduction.h @@ -39,13 +39,13 @@ namespace Mantid public: DgsAbsoluteUnitsReduction(); virtual ~DgsAbsoluteUnitsReduction(); - virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Process the absolute units sample.";} virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsConvertToEnergyTransfer.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsConvertToEnergyTransfer.h index ee076fd54a7f..de0c84bb934c 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsConvertToEnergyTransfer.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsConvertToEnergyTransfer.h @@ -39,13 +39,13 @@ namespace Mantid public: DgsConvertToEnergyTransfer(); virtual ~DgsConvertToEnergyTransfer(); - virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Algorithm to convert from TOF to energy transfer.";} virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsDiagnose.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsDiagnose.h index c71cfcd62b49..24c64360863f 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsDiagnose.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsDiagnose.h @@ -42,11 +42,13 @@ namespace Mantid virtual ~DgsDiagnose(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Setup and run DetectorDiagnostic.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsPreprocessData.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsPreprocessData.h index c4e5293482a6..289f38a50fc0 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsPreprocessData.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsPreprocessData.h @@ -42,11 +42,13 @@ namespace Mantid virtual ~DgsPreprocessData(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Preprocess data via an incident beam parameter.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsProcessDetectorVanadium.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsProcessDetectorVanadium.h index 7f4f5adac599..532e338dcbb8 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsProcessDetectorVanadium.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsProcessDetectorVanadium.h @@ -42,11 +42,13 @@ namespace Mantid virtual ~DgsProcessDetectorVanadium(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Algorithm to process detector vanadium.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); }; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsReduction.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsReduction.h index 8239418f2070..0ab2636359cd 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsReduction.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsReduction.h @@ -42,11 +42,13 @@ namespace Mantid virtual ~DgsReduction(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Top-level workflow algorithm for DGS reduction.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); API::Workspace_sptr loadInputData(const std::string prop, diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsRemap.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsRemap.h index c16743ab7fd2..0d771fd77c1d 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsRemap.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/DgsRemap.h @@ -42,11 +42,13 @@ namespace WorkflowAlgorithms virtual ~DgsRemap(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Mask and/or group the given workspace.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); void execGrouping(API::MatrixWorkspace_sptr iWS, API::MatrixWorkspace_sptr &oWS); diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSDarkCurrentSubtraction.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSDarkCurrentSubtraction.h index fc45b858d55e..31ac70d38503 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSDarkCurrentSubtraction.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSDarkCurrentSubtraction.h @@ -40,14 +40,14 @@ class DLLExport EQSANSDarkCurrentSubtraction : public API::Algorithm virtual ~EQSANSDarkCurrentSubtraction() {} /// Algorithm's name virtual const std::string name() const { return "EQSANSDarkCurrentSubtraction"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Perform EQSANS dark current subtraction.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS\\UsesPropertyManager"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSLoad.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSLoad.h index eab8fd5933fe..af4fe8a06ce9 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSLoad.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSLoad.h @@ -58,15 +58,14 @@ namespace WorkflowAlgorithms virtual ~EQSANSLoad() {} /// Algorithm's name virtual const std::string name() const { return "EQSANSLoad"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load EQSANS data.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS"; } private: - - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSMonitorTOF.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSMonitorTOF.h index 66677f243e0e..942f0d7a70a3 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSMonitorTOF.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSMonitorTOF.h @@ -55,14 +55,14 @@ class DLLExport EQSANSMonitorTOF : public API::Algorithm virtual ~EQSANSMonitorTOF() {} /// Algorithm's name virtual const std::string name() const { return "EQSANSMonitorTOF"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts the TOF into a wavelength for the beam monitor. This algorithm needs to be run once on every data set.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSPatchSensitivity.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSPatchSensitivity.h index f4628ae94cbd..333f9e46d5c5 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSPatchSensitivity.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSPatchSensitivity.h @@ -42,14 +42,14 @@ class DLLExport EQSANSPatchSensitivity : public API::Algorithm virtual ~EQSANSPatchSensitivity() {} /// Algorithm's name virtual const std::string name() const { return "EQSANSPatchSensitivity"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Patch EQSANS sensitivity correction.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSQ2D.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSQ2D.h index 19855b57a660..05051195e3e8 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSQ2D.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSQ2D.h @@ -28,14 +28,14 @@ class DLLExport EQSANSQ2D : public API::Algorithm virtual ~EQSANSQ2D() {} /// Algorithm's name virtual const std::string name() const { return "EQSANSQ2D"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Workflow algorithm to process a reduced EQSANS workspace and produce I(Qx,Qy).";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSReduce.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSReduce.h index 579b7455e4de..e022a3fe0e3c 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSReduce.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/EQSANSReduce.h @@ -47,10 +47,10 @@ class DLLExport EQSANSReduce : public API::DataProcessorAlgorithm virtual int version() const { return (1); } /// Algorithm's category for identification. @see Algorithm::category virtual const std::string category() const { return "Workflow\\SANS\\UsesPropertyManager"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Perform EQSANS data reduction.";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRDarkCurrentSubtraction.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRDarkCurrentSubtraction.h index 337e78ca41e2..e006184848c7 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRDarkCurrentSubtraction.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRDarkCurrentSubtraction.h @@ -41,14 +41,14 @@ class DLLExport HFIRDarkCurrentSubtraction : public API::Algorithm virtual ~HFIRDarkCurrentSubtraction() {} /// Algorithm's name virtual const std::string name() const { return "HFIRDarkCurrentSubtraction"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Perform HFIR SANS dark current subtraction.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS\\UsesPropertyManager"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRLoad.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRLoad.h index 81372f7e52a5..7773aac3d804 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRLoad.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRLoad.h @@ -51,15 +51,14 @@ class DLLExport HFIRLoad : public API::Algorithm virtual ~HFIRLoad() {} /// Algorithm's name virtual const std::string name() const { return "HFIRLoad"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load HFIR SANS data.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS\\UsesPropertyManager"; } private: - - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRSANSNormalise.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRSANSNormalise.h index 206f9d1f8f07..c03683bb33f7 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRSANSNormalise.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/HFIRSANSNormalise.h @@ -20,14 +20,14 @@ class DLLExport HFIRSANSNormalise : public API::Algorithm virtual ~HFIRSANSNormalise() {} /// Algorithm's name virtual const std::string name() const { return "HFIRSANSNormalise"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Apply normalisation correction to HFIR SANS data.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/MuonCalculateAsymmetry.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/MuonCalculateAsymmetry.h index a86e132c5411..d4ad5fd4cb6d 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/MuonCalculateAsymmetry.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/MuonCalculateAsymmetry.h @@ -37,11 +37,13 @@ namespace WorkflowAlgorithms virtual ~MuonCalculateAsymmetry(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Converts loaded/prepared Muon data to a data suitable for analysis.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/MuonLoad.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/MuonLoad.h index 269dbc2ada00..8c620871390e 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/MuonLoad.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/MuonLoad.h @@ -38,11 +38,13 @@ namespace WorkflowAlgorithms virtual ~MuonLoad(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Loads Muon workspace ready for analysis.";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/RefReduction.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/RefReduction.h index 449436fadd2d..b15e39afd5ee 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/RefReduction.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/RefReduction.h @@ -45,14 +45,14 @@ class DLLExport RefReduction : public API::Algorithm virtual ~RefReduction() {} /// Algorithm's name virtual const std::string name() const { return "RefReduction"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Data reduction for reflectometry.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\Reflectometry"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/RefRoi.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/RefRoi.h index 5946b9e9cae8..7b54cf10ca7d 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/RefRoi.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/RefRoi.h @@ -44,14 +44,14 @@ class DLLExport RefRoi : public API::Algorithm virtual ~RefRoi() {} /// Algorithm's name virtual const std::string name() const { return "RefRoi"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Workflow algorithm for reflectometry to sum up a region of interest on a 2D detector.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\Reflectometry"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSBeamFinder.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSBeamFinder.h index ebb10d4fa189..4493d813778c 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSBeamFinder.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSBeamFinder.h @@ -44,14 +44,14 @@ class DLLExport SANSBeamFinder : public API::Algorithm virtual ~SANSBeamFinder() {} /// Algorithm's name virtual const std::string name() const { return "SANSBeamFinder"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Beam finder workflow algorithm for SANS instruments.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS\\UsesPropertyManager"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSBeamFluxCorrection.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSBeamFluxCorrection.h index 3c5826380968..57199379799a 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSBeamFluxCorrection.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSBeamFluxCorrection.h @@ -25,14 +25,14 @@ class DLLExport SANSBeamFluxCorrection : public API::DataProcessorAlgorithm virtual ~SANSBeamFluxCorrection() {} /// Algorithm's name virtual const std::string name() const { return "SANSBeamFluxCorrection"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs beam flux correction on TOF SANS data.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS\\UsesPropertyManager;CorrectionFunctions\\InstrumentCorrections"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSSensitivityCorrection.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSSensitivityCorrection.h index 06815d8f154d..bdcd5deed0ed 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSSensitivityCorrection.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSSensitivityCorrection.h @@ -45,14 +45,14 @@ class DLLExport SANSSensitivityCorrection : public API::Algorithm virtual ~SANSSensitivityCorrection() {} /// Algorithm's name virtual const std::string name() const { return "SANSSensitivityCorrection"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Perform SANS sensitivity correction.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS\\UsesPropertyManager"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSSolidAngleCorrection.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSSolidAngleCorrection.h index 484135dc06dc..3c7fc782113f 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSSolidAngleCorrection.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SANSSolidAngleCorrection.h @@ -43,14 +43,14 @@ class DLLExport SANSSolidAngleCorrection : public API::Algorithm virtual ~SANSSolidAngleCorrection() {} /// Algorithm's name virtual const std::string name() const { return "SANSSolidAngleCorrection"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Performs solid angle correction on SANS 2D data.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS\\UsesPropertyManager;CorrectionFunctions\\InstrumentCorrections"; } private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupEQSANSReduction.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupEQSANSReduction.h index b9c497bab967..3f68b8e98859 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupEQSANSReduction.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupEQSANSReduction.h @@ -46,15 +46,14 @@ class DLLExport SetupEQSANSReduction : public API::Algorithm virtual ~SetupEQSANSReduction() {} /// Algorithm's name virtual const std::string name() const { return "SetupEQSANSReduction"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Set up EQSANS SANS reduction options.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS"; } private: - - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupHFIRReduction.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupHFIRReduction.h index e6f6d8dcd375..7e0b392f572e 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupHFIRReduction.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupHFIRReduction.h @@ -47,15 +47,14 @@ class DLLExport SetupHFIRReduction : public API::Algorithm virtual ~SetupHFIRReduction() {} /// Algorithm's name virtual const std::string name() const { return "SetupHFIRReduction"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Set up HFIR SANS reduction options.";} /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS"; } private: - - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupILLD33Reduction.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupILLD33Reduction.h index 8364e1c88db9..bf3ba6b3d58c 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupILLD33Reduction.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/SetupILLD33Reduction.h @@ -46,15 +46,15 @@ class DLLExport SetupILLD33Reduction : public API::Algorithm virtual ~SetupILLD33Reduction() {} /// Algorithm's name virtual const std::string name() const { return "SetupILLD33Reduction"; } + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Set up ILL D33 SANS reduction options.";} + /// Algorithm's version virtual int version() const { return (1); } /// Algorithm's category for identification virtual const std::string category() const { return "Workflow\\SANS"; } private: - - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialisation code void init(); /// Execution code diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/StepScan.h b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/StepScan.h index 358dcd68d57f..3369759def9e 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/StepScan.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/inc/MantidWorkflowAlgorithms/StepScan.h @@ -40,11 +40,13 @@ namespace WorkflowAlgorithms virtual ~StepScan(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Workflow algorithm for analysis of an alignment scan from an SNS Adara-enabled beam line";} + virtual int version() const; virtual const std::string category() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/AlignAndFocusPowder.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/AlignAndFocusPowder.cpp index 7f2ebf865e3e..dfa6f92b3da6 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/AlignAndFocusPowder.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/AlignAndFocusPowder.cpp @@ -81,17 +81,6 @@ namespace WorkflowAlgorithms return "Workflow\\Diffraction"; } - //---------------------------------------------------------------------------------------------- - /** Sets documentation strings for this algorithm - */ - void AlignAndFocusPowder::initDocs() - { - this->setWikiSummary("Algorithm to focus powder diffraction data into a number of histograms " - "according to a grouping scheme defined in a [[CalFile]]. "); - this->setOptionalMessage("Algorithm to focus powder diffraction data into a number of histograms " - "according to a grouping scheme defined in a CalFile."); - } - //---------------------------------------------------------------------------------------------- /** Initialisation method. Declares properties to be used in algorithm. */ diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/ComputeSensitivity.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/ComputeSensitivity.cpp index 558ad312a79d..609069a8adde 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/ComputeSensitivity.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/ComputeSensitivity.cpp @@ -28,13 +28,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(ComputeSensitivity) -/// Sets documentation strings for this algorithm -void ComputeSensitivity::initDocs() -{ - this->setWikiSummary("Workflow to calculate EQSANS sensitivity correction."); - this->setOptionalMessage("Workflow to calculate EQSANS sensitivity correction."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsAbsoluteUnitsReduction.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsAbsoluteUnitsReduction.cpp index c4b986eb299f..d7f0b0d179e8 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsAbsoluteUnitsReduction.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsAbsoluteUnitsReduction.cpp @@ -101,12 +101,6 @@ namespace Mantid const std::string DgsAbsoluteUnitsReduction::category() const { return "Workflow\\Inelastic\\UsesPropertyManager"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void DgsAbsoluteUnitsReduction::initDocs() - { - this->setWikiSummary("Process the absolute units sample."); - this->setOptionalMessage("Process the absolute units sample."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsConvertToEnergyTransfer.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsConvertToEnergyTransfer.cpp index 3ed127c1d8f5..845048876c80 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsConvertToEnergyTransfer.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsConvertToEnergyTransfer.cpp @@ -90,12 +90,6 @@ namespace Mantid const std::string DgsConvertToEnergyTransfer::category() const { return "Workflow\\Inelastic\\UsesPropertyManager"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void DgsConvertToEnergyTransfer::initDocs() - { - this->setWikiSummary("Algorithm to convert from TOF to energy transfer."); - this->setOptionalMessage("Algorithm to convert from TOF to energy transfer."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsDiagnose.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsDiagnose.cpp index 47393b4519f4..e4a26ec2f53f 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsDiagnose.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsDiagnose.cpp @@ -133,12 +133,6 @@ namespace Mantid const std::string DgsDiagnose::category() const { return "Workflow\\Inelastic\\UsesPropertyManager"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void DgsDiagnose::initDocs() - { - this->setWikiSummary("Setup and run DetectorDiagnostic."); - this->setOptionalMessage("Setup and run DetectorDiagnostic."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsPreprocessData.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsPreprocessData.cpp index e79ab8dee766..0c9da40c4a19 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsPreprocessData.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsPreprocessData.cpp @@ -81,12 +81,6 @@ namespace Mantid const std::string DgsPreprocessData::category() const { return "Workflow\\Inelastic\\UsesPropertyManager"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void DgsPreprocessData::initDocs() - { - this->setWikiSummary("Preprocess data via an incident beam parameter."); - this->setOptionalMessage("Preprocess data via an incident beam parameter."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsProcessDetectorVanadium.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsProcessDetectorVanadium.cpp index 246a2d6c8221..add6c8b607ef 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsProcessDetectorVanadium.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsProcessDetectorVanadium.cpp @@ -74,12 +74,6 @@ namespace Mantid const std::string DgsProcessDetectorVanadium::category() const { return "Workflow\\Inelastic\\UsesPropertyManager"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void DgsProcessDetectorVanadium::initDocs() - { - this->setWikiSummary("Algorithm to process detector vanadium."); - this->setOptionalMessage("Algorithm to process detector vanadium."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsReduction.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsReduction.cpp index 1848b57fe139..5af5380ec3f2 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsReduction.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsReduction.cpp @@ -70,12 +70,6 @@ namespace Mantid const std::string DgsReduction::category() const { return "Workflow\\Inelastic"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void DgsReduction::initDocs() - { - this->setWikiSummary("Top-level workflow algorithm for DGS reduction."); - this->setOptionalMessage("Top-level workflow algorithm for DGS reduction."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsRemap.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsRemap.cpp index 847e21819651..e3d6e0ee1712 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsRemap.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/DgsRemap.cpp @@ -49,12 +49,6 @@ namespace WorkflowAlgorithms const std::string DgsRemap::category() const { return "Workflow\\Inelastic"; } //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void DgsRemap::initDocs() - { - this->setWikiSummary("Mask and/or group the given workspace."); - this->setOptionalMessage("Mask and/or group the given workspace."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction.cpp index b37ea6eefa3d..aed0e4532158 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSDarkCurrentSubtraction.cpp @@ -33,13 +33,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(EQSANSDarkCurrentSubtraction) -/// Sets documentation strings for this algorithm -void EQSANSDarkCurrentSubtraction::initDocs() -{ - this->setWikiSummary("Perform EQSANS dark current subtraction."); - this->setOptionalMessage("Perform EQSANS dark current subtraction."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSLoad.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSLoad.cpp index 210fc5045ae1..d8fdfb62d90f 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSLoad.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSLoad.cpp @@ -48,13 +48,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(EQSANSLoad) -/// Sets documentation strings for this algorithm -void EQSANSLoad::initDocs() -{ - this->setWikiSummary("Load EQSANS data."); - this->setOptionalMessage("Load EQSANS data."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSMonitorTOF.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSMonitorTOF.cpp index fbd906ab5955..b412a374fc1d 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSMonitorTOF.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSMonitorTOF.cpp @@ -25,13 +25,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(EQSANSMonitorTOF) -/// Sets documentation strings for this algorithm -void EQSANSMonitorTOF::initDocs() -{ - this->setWikiSummary("Converts the TOF into a wavelength for the beam monitor. This algorithm needs to be run once on every data set. "); - this->setOptionalMessage("Converts the TOF into a wavelength for the beam monitor. This algorithm needs to be run once on every data set."); -} - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSPatchSensitivity.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSPatchSensitivity.cpp index a13b323c07a2..684cbe83adc2 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSPatchSensitivity.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSPatchSensitivity.cpp @@ -15,13 +15,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(EQSANSPatchSensitivity) -/// Sets documentation strings for this algorithm -void EQSANSPatchSensitivity::initDocs() -{ - this->setWikiSummary("Patch EQSANS sensitivity correction."); - this->setOptionalMessage("Patch EQSANS sensitivity correction."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSQ2D.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSQ2D.cpp index 0492405c945d..48af8be0a8d7 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSQ2D.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/EQSANSQ2D.cpp @@ -20,13 +20,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(EQSANSQ2D) -/// Sets documentation strings for this algorithm -void EQSANSQ2D::initDocs() -{ - this->setWikiSummary("Workflow algorithm to process a reduced EQSANS workspace and produce I(Qx,Qy)."); - this->setOptionalMessage("Workflow algorithm to process a reduced EQSANS workspace and produce I(Qx,Qy)."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRDarkCurrentSubtraction.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRDarkCurrentSubtraction.cpp index 8c07a9ae4d3f..f0dd03e31a62 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRDarkCurrentSubtraction.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRDarkCurrentSubtraction.cpp @@ -33,13 +33,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(HFIRDarkCurrentSubtraction) -/// Sets documentation strings for this algorithm -void HFIRDarkCurrentSubtraction::initDocs() -{ - this->setWikiSummary("Perform HFIR SANS dark current subtraction."); - this->setOptionalMessage("Perform HFIR SANS dark current subtraction."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRLoad.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRLoad.cpp index 838d7afedffe..0405f6cc6efe 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRLoad.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRLoad.cpp @@ -33,13 +33,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(HFIRLoad) -/// Sets documentation strings for this algorithm -void HFIRLoad::initDocs() -{ - this->setWikiSummary("Load HFIR SANS data."); - this->setOptionalMessage("Load HFIR SANS data."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRSANSNormalise.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRSANSNormalise.cpp index 8fffc9ad1a70..910fcb8c7d86 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRSANSNormalise.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/HFIRSANSNormalise.cpp @@ -22,13 +22,6 @@ using namespace API; // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(HFIRSANSNormalise) -/// Sets documentation strings for this algorithm -void HFIRSANSNormalise::initDocs() -{ - this->setWikiSummary("Apply normalisation correction to HFIR SANS data."); - this->setOptionalMessage("Apply normalisation correction to HFIR SANS data."); -} - void HFIRSANSNormalise::init() { declareProperty(new WorkspaceProperty<>("InputWorkspace","",Direction::Input), diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/MuonCalculateAsymmetry.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/MuonCalculateAsymmetry.cpp index 90caec9beeeb..56a8305468da 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/MuonCalculateAsymmetry.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/MuonCalculateAsymmetry.cpp @@ -51,13 +51,6 @@ namespace WorkflowAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void MuonCalculateAsymmetry::initDocs() - { - this->setWikiSummary("Converts loaded/prepared Muon data to a data suitable for analysis."); - this->setOptionalMessage("Converts loaded/prepared Muon data to a data suitable for analysis."); - } - //---------------------------------------------------------------------------------------------- /** diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/MuonLoad.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/MuonLoad.cpp index 6d91a13aeb5e..802169f12551 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/MuonLoad.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/MuonLoad.cpp @@ -61,13 +61,6 @@ namespace WorkflowAlgorithms //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void MuonLoad::initDocs() - { - this->setWikiSummary("Loads Muon workspace ready for analysis."); - this->setOptionalMessage("Loads Muon workspace ready for analysis."); - } - //---------------------------------------------------------------------------------------------- /* * Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/RefReduction.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/RefReduction.cpp index d0294433c546..68fffc91dd24 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/RefReduction.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/RefReduction.cpp @@ -38,13 +38,6 @@ const int RefReduction::NX_PIXELS(304); const int RefReduction::NY_PIXELS(256); const double RefReduction::PIXEL_SIZE(0.0007); -/// Sets documentation strings for this algorithm -void RefReduction::initDocs() -{ - this->setWikiSummary("Data reduction for reflectometry."); - this->setOptionalMessage("Data reduction for reflectometry."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/RefRoi.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/RefRoi.cpp index aa9afc0a6619..947983a59ab0 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/RefRoi.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/RefRoi.cpp @@ -19,13 +19,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(RefRoi) -/// Sets documentation strings for this algorithm -void RefRoi::initDocs() -{ - this->setWikiSummary("Workflow algorithm for reflectometry to sum up a region of interest on a 2D detector."); - this->setOptionalMessage("Workflow algorithm for reflectometry to sum up a region of interest on a 2D detector."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSBeamFinder.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSBeamFinder.cpp index 26aa89553931..32fbf4f520ac 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSBeamFinder.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSBeamFinder.cpp @@ -28,13 +28,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SANSBeamFinder) -/// Sets documentation strings for this algorithm -void SANSBeamFinder::initDocs() -{ - this->setWikiSummary("Beam finder workflow algorithm for SANS instruments."); - this->setOptionalMessage("Beam finder workflow algorithm for SANS instruments."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSBeamFluxCorrection.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSBeamFluxCorrection.cpp index a969019e6a14..b447873e4cd4 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSBeamFluxCorrection.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSBeamFluxCorrection.cpp @@ -32,13 +32,6 @@ using namespace Geometry; // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SANSBeamFluxCorrection) -/// Sets documentation strings for this algorithm -void SANSBeamFluxCorrection::initDocs() -{ - this->setWikiSummary("Performs beam flux correction on TOF SANS data."); - this->setOptionalMessage("Performs beam flux correction on TOF SANS data."); -} - void SANSBeamFluxCorrection::init() { declareProperty(new WorkspaceProperty<>("InputWorkspace","",Direction::Input), diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSSensitivityCorrection.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSSensitivityCorrection.cpp index 3ae6697f887f..030dba8869ab 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSSensitivityCorrection.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSSensitivityCorrection.cpp @@ -43,13 +43,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SANSSensitivityCorrection) -/// Sets documentation strings for this algorithm -void SANSSensitivityCorrection::initDocs() -{ - this->setWikiSummary("Perform SANS sensitivity correction."); - this->setOptionalMessage("Perform SANS sensitivity correction."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSSolidAngleCorrection.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSSolidAngleCorrection.cpp index a02865b37b93..ae5146e1bd7f 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSSolidAngleCorrection.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/SANSSolidAngleCorrection.cpp @@ -60,13 +60,6 @@ static double getYTubeAngle(IDetector_const_sptr det, return sampleDetVec.angle(beamLine); } -/// Sets documentation strings for this algorithm -void SANSSolidAngleCorrection::initDocs() -{ - this->setWikiSummary("Performs solid angle correction on SANS 2D data."); - this->setOptionalMessage("Performs solid angle correction on SANS 2D data."); -} - void SANSSolidAngleCorrection::init() { auto wsValidator = boost::make_shared(); diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupEQSANSReduction.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupEQSANSReduction.cpp index 3e39ddb494f3..80fdee8e7cda 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupEQSANSReduction.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupEQSANSReduction.cpp @@ -29,13 +29,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SetupEQSANSReduction) -/// Sets documentation strings for this algorithm -void SetupEQSANSReduction::initDocs() -{ - this->setWikiSummary("Set up EQSANS SANS reduction options."); - this->setOptionalMessage("Set up EQSANS SANS reduction options."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupHFIRReduction.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupHFIRReduction.cpp index 67688faec021..de840ffa1ae9 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupHFIRReduction.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupHFIRReduction.cpp @@ -27,13 +27,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SetupHFIRReduction) -/// Sets documentation strings for this algorithm -void SetupHFIRReduction::initDocs() -{ - this->setWikiSummary("Set up HFIR SANS reduction options."); - this->setOptionalMessage("Set up HFIR SANS reduction options."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupILLD33Reduction.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupILLD33Reduction.cpp index ba718cca98fc..a4a9faccf323 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupILLD33Reduction.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/SetupILLD33Reduction.cpp @@ -29,13 +29,6 @@ namespace WorkflowAlgorithms // Register the algorithm into the AlgorithmFactory DECLARE_ALGORITHM(SetupILLD33Reduction) -/// Sets documentation strings for this algorithm -void SetupILLD33Reduction::initDocs() -{ - this->setWikiSummary("Set up ILL D33 SANS reduction options."); - this->setOptionalMessage("Set up ILL D33 SANS reduction options."); -} - using namespace Kernel; using namespace API; using namespace Geometry; diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/src/StepScan.cpp b/Code/Mantid/Framework/WorkflowAlgorithms/src/StepScan.cpp index d1fd1c9aa5f6..6976177df9d0 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/src/StepScan.cpp +++ b/Code/Mantid/Framework/WorkflowAlgorithms/src/StepScan.cpp @@ -42,12 +42,6 @@ namespace WorkflowAlgorithms /// Algorithm's category for identification. @see Algorithm::category const std::string StepScan::category() const { return "Workflow\\Alignment";} - void StepScan::initDocs() - { - this->setWikiSummary("Workflow algorithm for analysis of an alignment scan. CAN ONLY BE USED WITH SNS DATA FROM AN ADARA-ENABLED BEAMLINE."); - this->setOptionalMessage("Workflow algorithm for analysis of an alignment scan from an SNS Adara-enabled beam line"); - } - void StepScan::init() { // TODO: Validator to ensure that this is 'fresh' data??? From e3662a0f52babc205de053bd7dcaaa65bb858093 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 10:39:11 +0100 Subject: [PATCH 091/126] Added summary method to LiveData algorithms. Refs #9523. --- .../LiveData/inc/MantidLiveData/FakeISISHistoDAE.h | 4 ++-- .../Framework/LiveData/inc/MantidLiveData/LoadLiveData.h | 4 +++- .../LiveData/inc/MantidLiveData/MonitorLiveData.h | 4 +++- .../Framework/LiveData/inc/MantidLiveData/StartLiveData.h | 4 +++- Code/Mantid/Framework/LiveData/src/FakeISISHistoDAE.cpp | 8 -------- Code/Mantid/Framework/LiveData/src/LoadLiveData.cpp | 8 -------- Code/Mantid/Framework/LiveData/src/MonitorLiveData.cpp | 8 -------- Code/Mantid/Framework/LiveData/src/StartLiveData.cpp | 8 -------- 8 files changed, 11 insertions(+), 37 deletions(-) diff --git a/Code/Mantid/Framework/LiveData/inc/MantidLiveData/FakeISISHistoDAE.h b/Code/Mantid/Framework/LiveData/inc/MantidLiveData/FakeISISHistoDAE.h index 3df3e84c5e1a..ae67b4c51c15 100644 --- a/Code/Mantid/Framework/LiveData/inc/MantidLiveData/FakeISISHistoDAE.h +++ b/Code/Mantid/Framework/LiveData/inc/MantidLiveData/FakeISISHistoDAE.h @@ -54,10 +54,10 @@ class DLLExport FakeISISHistoDAE : public API::Algorithm virtual int version() const { return 1;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "DataHandling\\DataAcquisition";} + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Simulates ISIS histogram DAE.";} private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); // Implement abstract Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/LiveData/inc/MantidLiveData/LoadLiveData.h b/Code/Mantid/Framework/LiveData/inc/MantidLiveData/LoadLiveData.h index 743439603ca8..9efe15bcdb05 100644 --- a/Code/Mantid/Framework/LiveData/inc/MantidLiveData/LoadLiveData.h +++ b/Code/Mantid/Framework/LiveData/inc/MantidLiveData/LoadLiveData.h @@ -43,6 +43,9 @@ namespace LiveData virtual ~LoadLiveData(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Load a chunk of live data. You should call StartLiveData, and not this algorithm directly.";} + virtual const std::string category() const; virtual int version() const; @@ -51,7 +54,6 @@ namespace LiveData void exec(); private: - virtual void initDocs(); void init(); Mantid::API::Workspace_sptr runProcessing(Mantid::API::Workspace_sptr inputWS, bool PostProcess); diff --git a/Code/Mantid/Framework/LiveData/inc/MantidLiveData/MonitorLiveData.h b/Code/Mantid/Framework/LiveData/inc/MantidLiveData/MonitorLiveData.h index b93a6f71f600..3a3c646876bf 100644 --- a/Code/Mantid/Framework/LiveData/inc/MantidLiveData/MonitorLiveData.h +++ b/Code/Mantid/Framework/LiveData/inc/MantidLiveData/MonitorLiveData.h @@ -43,11 +43,13 @@ namespace LiveData virtual ~MonitorLiveData(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Call LoadLiveData at a given update frequency. Do not call this algorithm directly; instead call StartLiveData.";} + virtual const std::string category() const; virtual int version() const; private: - virtual void initDocs(); void init(); void exec(); void doClone(const std::string & originalName, const std::string & newName); diff --git a/Code/Mantid/Framework/LiveData/inc/MantidLiveData/StartLiveData.h b/Code/Mantid/Framework/LiveData/inc/MantidLiveData/StartLiveData.h index f199839cf329..7707b5b8dce5 100644 --- a/Code/Mantid/Framework/LiveData/inc/MantidLiveData/StartLiveData.h +++ b/Code/Mantid/Framework/LiveData/inc/MantidLiveData/StartLiveData.h @@ -50,10 +50,12 @@ namespace LiveData virtual ~StartLiveData(); virtual const std::string name() const; + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Begin live data monitoring.";} + virtual int version() const; private: - virtual void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/LiveData/src/FakeISISHistoDAE.cpp b/Code/Mantid/Framework/LiveData/src/FakeISISHistoDAE.cpp index 9e2da783c568..ed6113c9135e 100644 --- a/Code/Mantid/Framework/LiveData/src/FakeISISHistoDAE.cpp +++ b/Code/Mantid/Framework/LiveData/src/FakeISISHistoDAE.cpp @@ -331,14 +331,6 @@ class TestServerConnectionFactory: public Poco::Net::TCPServerConnectionFactory } }; -/// Sets documentation strings for this algorithm -void FakeISISHistoDAE::initDocs() -{ - this->setWikiSummary("Simulates ISIS histogram DAE. "); - this->setOptionalMessage("Simulates ISIS histogram DAE."); -} - - using namespace Kernel; using namespace API; diff --git a/Code/Mantid/Framework/LiveData/src/LoadLiveData.cpp b/Code/Mantid/Framework/LiveData/src/LoadLiveData.cpp index 62c8de7e43b8..8141279d7ab1 100644 --- a/Code/Mantid/Framework/LiveData/src/LoadLiveData.cpp +++ b/Code/Mantid/Framework/LiveData/src/LoadLiveData.cpp @@ -109,14 +109,6 @@ namespace LiveData /// Returns the run number, if one is stored in the extracted chunk (returns 0 if not) int LoadLiveData::runNumber() const { return m_runNumber; } - - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void LoadLiveData::initDocs() - { - this->setWikiSummary("Load a chunk of live data. You should call StartLiveData, and not this algorithm directly."); - this->setOptionalMessage("Load a chunk of live data. You should call StartLiveData, and not this algorithm directly."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/LiveData/src/MonitorLiveData.cpp b/Code/Mantid/Framework/LiveData/src/MonitorLiveData.cpp index b515531e05d1..8194ef86c277 100644 --- a/Code/Mantid/Framework/LiveData/src/MonitorLiveData.cpp +++ b/Code/Mantid/Framework/LiveData/src/MonitorLiveData.cpp @@ -58,14 +58,6 @@ namespace LiveData /// Algorithm's version for identification. @see Algorithm::version int MonitorLiveData::version() const { return 1;}; - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void MonitorLiveData::initDocs() - { - this->setWikiSummary("Call LoadLiveData at a given update frequency. Do not call this algorithm directly; instead call StartLiveData."); - this->setOptionalMessage("Call LoadLiveData at a given update frequency. Do not call this algorithm directly; instead call StartLiveData."); - } - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ diff --git a/Code/Mantid/Framework/LiveData/src/StartLiveData.cpp b/Code/Mantid/Framework/LiveData/src/StartLiveData.cpp index b59d8d5ec73a..5157a2b79c78 100644 --- a/Code/Mantid/Framework/LiveData/src/StartLiveData.cpp +++ b/Code/Mantid/Framework/LiveData/src/StartLiveData.cpp @@ -139,14 +139,6 @@ namespace LiveData /// Algorithm's version for identification. @see Algorithm::version int StartLiveData::version() const { return 1;}; - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void StartLiveData::initDocs() - { - this->setWikiSummary("Begin live data monitoring."); - this->setOptionalMessage("Begin live data monitoring."); - } - //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. */ From 686ab2154655215dbfe55aa0e11441ac5c3d3d08 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 10:55:08 +0100 Subject: [PATCH 092/126] Fix warnings left by Python script. Refs #9523. --- .../Framework/Algorithms/src/CreateLogTimeCorrection.cpp | 6 +----- .../Mantid/Framework/Algorithms/src/ExtractMaskToTable.cpp | 4 ---- .../Mantid/Framework/Algorithms/src/FindPeakBackground.cpp | 4 ---- Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp | 4 ---- Code/Mantid/Framework/Algorithms/src/FitPeak.cpp | 4 ---- .../Framework/Algorithms/src/FixGSASInstrumentFile.cpp | 4 ---- Code/Mantid/Framework/Algorithms/src/GeneratePeaks.cpp | 4 ---- Code/Mantid/Framework/Algorithms/src/Rebin2D.cpp | 7 ------- Code/Mantid/Framework/DataHandling/src/LoadPDFgetNFile.cpp | 4 ---- 9 files changed, 1 insertion(+), 40 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/src/CreateLogTimeCorrection.cpp b/Code/Mantid/Framework/Algorithms/src/CreateLogTimeCorrection.cpp index adb75ca99768..508374c7ae13 100644 --- a/Code/Mantid/Framework/Algorithms/src/CreateLogTimeCorrection.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CreateLogTimeCorrection.cpp @@ -42,13 +42,9 @@ namespace Algorithms { } - //---------------------------------------------------------------------------------------------- - /** Init documentation - * - //---------------------------------------------------------------------------------------------- /** Declare properties - */ + */ void CreateLogTimeCorrection::init() { auto inpwsprop = new WorkspaceProperty("InputWorkspace", "", Direction::Input, boost::make_shared()); diff --git a/Code/Mantid/Framework/Algorithms/src/ExtractMaskToTable.cpp b/Code/Mantid/Framework/Algorithms/src/ExtractMaskToTable.cpp index 6587dfa01913..b8eeed1b0530 100644 --- a/Code/Mantid/Framework/Algorithms/src/ExtractMaskToTable.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ExtractMaskToTable.cpp @@ -53,10 +53,6 @@ namespace Algorithms { } - //---------------------------------------------------------------------------------------------- - /** Documentation - * - //---------------------------------------------------------------------------------------------- /** Declare properties */ diff --git a/Code/Mantid/Framework/Algorithms/src/FindPeakBackground.cpp b/Code/Mantid/Framework/Algorithms/src/FindPeakBackground.cpp index b5795550488f..0b20723442bf 100644 --- a/Code/Mantid/Framework/Algorithms/src/FindPeakBackground.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FindPeakBackground.cpp @@ -59,10 +59,6 @@ namespace Algorithms { } - //---------------------------------------------------------------------------------------------- - /** WIKI: - * - //---------------------------------------------------------------------------------------------- /** Define properties */ diff --git a/Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp b/Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp index bf0075855ca8..7275f14711db 100644 --- a/Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FindPeaks.cpp @@ -86,10 +86,6 @@ namespace Algorithms m_minimizer = "Levenberg-MarquardtMD"; } - //---------------------------------------------------------------------------------------------- - /** Sets documentation strings for this algorithm - * - //---------------------------------------------------------------------------------------------- /** Initialize and declare properties. */ diff --git a/Code/Mantid/Framework/Algorithms/src/FitPeak.cpp b/Code/Mantid/Framework/Algorithms/src/FitPeak.cpp index ca9dfb408032..45d89097136d 100644 --- a/Code/Mantid/Framework/Algorithms/src/FitPeak.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FitPeak.cpp @@ -1128,10 +1128,6 @@ namespace Algorithms { } - //---------------------------------------------------------------------------------------------- - /** Document - * - //---------------------------------------------------------------------------------------------- /** Declare properties */ diff --git a/Code/Mantid/Framework/Algorithms/src/FixGSASInstrumentFile.cpp b/Code/Mantid/Framework/Algorithms/src/FixGSASInstrumentFile.cpp index b263ca097b4e..da0a14b98e63 100644 --- a/Code/Mantid/Framework/Algorithms/src/FixGSASInstrumentFile.cpp +++ b/Code/Mantid/Framework/Algorithms/src/FixGSASInstrumentFile.cpp @@ -50,10 +50,6 @@ namespace Algorithms FixGSASInstrumentFile::~FixGSASInstrumentFile() { } - - //---------------------------------------------------------------------------------------------- - /** Sets documentation strings for this algorithm - * //---------------------------------------------------------------------------------------------- /** Implement abstract Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/src/GeneratePeaks.cpp b/Code/Mantid/Framework/Algorithms/src/GeneratePeaks.cpp index 4dbc895be27e..69d143d5322b 100644 --- a/Code/Mantid/Framework/Algorithms/src/GeneratePeaks.cpp +++ b/Code/Mantid/Framework/Algorithms/src/GeneratePeaks.cpp @@ -69,10 +69,6 @@ namespace Algorithms GeneratePeaks::~GeneratePeaks() { } - - //---------------------------------------------------------------------------------------------- - /** Wiki documentation - * //---------------------------------------------------------------------------------------------- /** Define algorithm's properties diff --git a/Code/Mantid/Framework/Algorithms/src/Rebin2D.cpp b/Code/Mantid/Framework/Algorithms/src/Rebin2D.cpp index 774e5df5bd6c..1d7d0423a275 100644 --- a/Code/Mantid/Framework/Algorithms/src/Rebin2D.cpp +++ b/Code/Mantid/Framework/Algorithms/src/Rebin2D.cpp @@ -38,13 +38,6 @@ namespace Mantid using Geometry::Quadrilateral; using Kernel::V2D; - //-------------------------------------------------------------------------- - // Public methods - //-------------------------------------------------------------------------- - /** - * Sets documentation strings for this algorithm - * - //-------------------------------------------------------------------------- // Private methods //-------------------------------------------------------------------------- diff --git a/Code/Mantid/Framework/DataHandling/src/LoadPDFgetNFile.cpp b/Code/Mantid/Framework/DataHandling/src/LoadPDFgetNFile.cpp index 927dfe48a4c4..b7f9d5215960 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadPDFgetNFile.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadPDFgetNFile.cpp @@ -59,10 +59,6 @@ namespace DataHandling { } - //---------------------------------------------------------------------------------------------- - /** Init documentation - * - //---------------------------------------------------------------------------------------------- /** * Return the confidence with with this algorithm can load the file From e53d82f1f9f0774efc1553026656af323bf27baa Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 10:55:34 +0100 Subject: [PATCH 093/126] Update calls to getOptionalMessage to be summary. Refs #9523. --- Code/Mantid/MantidPlot/src/Mantid/MantidUI.cpp | 4 ++-- Code/Mantid/MantidQt/API/src/AlgorithmDialog.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Code/Mantid/MantidPlot/src/Mantid/MantidUI.cpp b/Code/Mantid/MantidPlot/src/Mantid/MantidUI.cpp index e60ed7899145..b1e1ca1a6eea 100644 --- a/Code/Mantid/MantidPlot/src/Mantid/MantidUI.cpp +++ b/Code/Mantid/MantidPlot/src/Mantid/MantidUI.cpp @@ -1417,7 +1417,7 @@ MantidQt::API::AlgorithmDialog* MantidUI::createAlgorithmDialog(Mantid::API::IA //Check if a workspace is selected in the dock and set this as a preference for the input workspace //This is an optional message displayed at the top of the GUI. - QString optional_msg(alg->getOptionalMessage().c_str()); + QString optional_msg(alg->summary().c_str()); MantidQt::API::InterfaceManager interfaceManager; MantidQt::API::AlgorithmDialog *dlg = @@ -1658,7 +1658,7 @@ void MantidUI::renameWorkspace(QStringList wsName) InterfaceManager interfaceManager; AlgorithmDialog *dialog = interfaceManager.createDialog(alg.get(), m_appWindow, false, presets, - QString(alg->getOptionalMessage().c_str())); + QString(alg->summary().c_str())); executeAlgorithm(dialog,alg); } diff --git a/Code/Mantid/MantidQt/API/src/AlgorithmDialog.cpp b/Code/Mantid/MantidQt/API/src/AlgorithmDialog.cpp index 1e9cc725ba5d..20e80fd48bcd 100644 --- a/Code/Mantid/MantidQt/API/src/AlgorithmDialog.cpp +++ b/Code/Mantid/MantidQt/API/src/AlgorithmDialog.cpp @@ -829,7 +829,7 @@ void AlgorithmDialog::isForScript(bool forScript) void AlgorithmDialog::setOptionalMessage(const QString & message) { m_strMessage = message; - if( message.isEmpty() ) m_strMessage = QString::fromStdString(getAlgorithm()->getOptionalMessage()); + if( message.isEmpty() ) m_strMessage = QString::fromStdString(getAlgorithm()->summary()); if( m_strMessage.isEmpty() ) m_msgAvailable = false; else m_msgAvailable = true; } From b1ad521f3b345253bd3cc21beeb6832aee137201 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 11:31:07 +0100 Subject: [PATCH 094/126] Add summary to user algorithms. Refs #9523. - Default implementation is not provided in Algorithm.cpp, so we must add it to all files that inherit from IAlgorithm. --- Code/Mantid/Framework/UserAlgorithms/HelloWorldAlgorithm.h | 1 + Code/Mantid/Framework/UserAlgorithms/LorentzianTest.h | 2 ++ Code/Mantid/Framework/UserAlgorithms/ModifyData.h | 1 + Code/Mantid/Framework/UserAlgorithms/Muon_ExpDecayOscTest.h | 5 +++++ Code/Mantid/Framework/UserAlgorithms/PropertyAlgorithm.h | 2 ++ Code/Mantid/Framework/UserAlgorithms/WorkspaceAlgorithm.h | 2 ++ 6 files changed, 13 insertions(+) diff --git a/Code/Mantid/Framework/UserAlgorithms/HelloWorldAlgorithm.h b/Code/Mantid/Framework/UserAlgorithms/HelloWorldAlgorithm.h index 135ff333ac30..376b2106d1cd 100644 --- a/Code/Mantid/Framework/UserAlgorithms/HelloWorldAlgorithm.h +++ b/Code/Mantid/Framework/UserAlgorithms/HelloWorldAlgorithm.h @@ -45,6 +45,7 @@ class HelloWorldAlgorithm : public API::Algorithm virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Examples";} + virtual const std::string summary() const { return "Summary of this algorithm - Outputs Hello World!."; } private: ///Initialisation code diff --git a/Code/Mantid/Framework/UserAlgorithms/LorentzianTest.h b/Code/Mantid/Framework/UserAlgorithms/LorentzianTest.h index c7df7c58f0a1..c8cb5a1ed89c 100644 --- a/Code/Mantid/Framework/UserAlgorithms/LorentzianTest.h +++ b/Code/Mantid/Framework/UserAlgorithms/LorentzianTest.h @@ -108,6 +108,8 @@ namespace Mantid /// "Muon\\Custom" virtual const std::string category() const { return "C++ User Defined";} + virtual const std::string summary() const { return "C++ User defined algorithm."; } + protected: virtual void functionLocal(double* out, const double* xValues, const size_t nData)const; virtual void functionDerivLocal(API::Jacobian* out, const double* xValues, const size_t nData); diff --git a/Code/Mantid/Framework/UserAlgorithms/ModifyData.h b/Code/Mantid/Framework/UserAlgorithms/ModifyData.h index 637bc28fcf86..30261f40183f 100644 --- a/Code/Mantid/Framework/UserAlgorithms/ModifyData.h +++ b/Code/Mantid/Framework/UserAlgorithms/ModifyData.h @@ -45,6 +45,7 @@ class ModifyData : public API::Algorithm virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Examples";} + virtual const std::string summary() const { return "An example summary"; } private: ///Initialisation code diff --git a/Code/Mantid/Framework/UserAlgorithms/Muon_ExpDecayOscTest.h b/Code/Mantid/Framework/UserAlgorithms/Muon_ExpDecayOscTest.h index 9c13065412dc..dd7e11691818 100644 --- a/Code/Mantid/Framework/UserAlgorithms/Muon_ExpDecayOscTest.h +++ b/Code/Mantid/Framework/UserAlgorithms/Muon_ExpDecayOscTest.h @@ -67,6 +67,11 @@ namespace Mantid virtual const std::string category() const { return "C++ User Defined";} virtual void functionDeriv(const API::FunctionDomain& domain, API::Jacobian& out); + // ** OPTIONALLY MODIFY THIS ** + virtual const std::string summary() const { + return "An example of a peak shape function which is a combination of an exponential decay and cos function."; + } + protected: virtual void functionLocal(double* out, const double* xValues, const size_t nData)const; virtual void functionDerivLocal(API::Jacobian* , const double* , const size_t ){} diff --git a/Code/Mantid/Framework/UserAlgorithms/PropertyAlgorithm.h b/Code/Mantid/Framework/UserAlgorithms/PropertyAlgorithm.h index 74852c1b3d45..1afb7c33005f 100644 --- a/Code/Mantid/Framework/UserAlgorithms/PropertyAlgorithm.h +++ b/Code/Mantid/Framework/UserAlgorithms/PropertyAlgorithm.h @@ -45,6 +45,8 @@ class PropertyAlgorithm : public API::Algorithm virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Examples";} + // Algorithm's summary. Overriding a virtual method. + virtual const std::string summary() const { return "Example summary text."; } private: ///Initialisation code diff --git a/Code/Mantid/Framework/UserAlgorithms/WorkspaceAlgorithm.h b/Code/Mantid/Framework/UserAlgorithms/WorkspaceAlgorithm.h index 74a9280ecb92..84f19ac89d9b 100644 --- a/Code/Mantid/Framework/UserAlgorithms/WorkspaceAlgorithm.h +++ b/Code/Mantid/Framework/UserAlgorithms/WorkspaceAlgorithm.h @@ -45,6 +45,8 @@ class WorkspaceAlgorithm : public API::Algorithm virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Examples";} + // Algorithm's summary. Overriding a virtual method. + virtual const std::string summary() const { return "Example summary text."; } private: ///Initialisation code From 1f251559f9bdcf2a0c885e9e04a1c0fc7682e757 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 13:53:14 +0100 Subject: [PATCH 095/126] Update tests to have a dummy summary. Refs #9523. --- Code/Mantid/Framework/API/test/AlgorithmHasPropertyTest.h | 3 +++ Code/Mantid/Framework/API/test/AlgorithmHistoryTest.h | 1 + Code/Mantid/Framework/API/test/AlgorithmManagerTest.h | 5 +++++ Code/Mantid/Framework/API/test/AlgorithmPropertyTest.h | 7 +++++-- Code/Mantid/Framework/API/test/AlgorithmProxyTest.h | 3 ++- Code/Mantid/Framework/API/test/AlgorithmTest.h | 5 ++++- Code/Mantid/Framework/API/test/AsynchronousTest.h | 1 + .../Mantid/Framework/API/test/DataProcessorAlgorithmTest.h | 4 ++++ Code/Mantid/Framework/API/test/FakeAlgorithms.h | 6 +++++- Code/Mantid/Framework/API/test/FrameworkManagerTest.h | 1 + .../Framework/API/test/MultiPeriodGroupAlgorithmTest.h | 4 ++++ Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h | 1 + .../Algorithms/inc/MantidAlgorithms/FilterByTime2.h | 2 ++ .../Algorithms/inc/MantidAlgorithms/UnaryOperation.h | 3 ++- .../Mantid/Framework/Algorithms/test/BinaryOperationTest.h | 2 ++ .../Mantid/Framework/Algorithms/test/ChainedOperatorTest.h | 2 +- .../Algorithms/test/CommutativeBinaryOperationTest.h | 3 +++ .../Framework/Algorithms/test/GeneratePythonScriptTest.h | 2 ++ Code/Mantid/Framework/Algorithms/test/UnaryOperationTest.h | 3 ++- .../DataObjects/test/TableWorkspacePropertyTest.h | 1 + .../Mantid/Framework/LiveData/test/LiveDataAlgorithmTest.h | 1 + .../inc/MantidMDAlgorithms/BinaryOperationMD.h | 1 + .../MDAlgorithms/inc/MantidMDAlgorithms/UnaryOperationMD.h | 1 + .../Framework/MDAlgorithms/test/SlicingAlgorithmTest.h | 1 + .../MDEvents/test/BoxControllerSettingsAlgorithmTest.h | 1 + .../inc/MantidTestHelpers/WorkspaceCreationHelper.h | 2 ++ .../Framework/WorkflowAlgorithms/test/StepScanTest.h | 2 +- 27 files changed, 59 insertions(+), 9 deletions(-) diff --git a/Code/Mantid/Framework/API/test/AlgorithmHasPropertyTest.h b/Code/Mantid/Framework/API/test/AlgorithmHasPropertyTest.h index 780de495fe8f..2991d80f4e97 100644 --- a/Code/Mantid/Framework/API/test/AlgorithmHasPropertyTest.h +++ b/Code/Mantid/Framework/API/test/AlgorithmHasPropertyTest.h @@ -18,6 +18,7 @@ class AlgorithmHasPropertyTest : public CxxTest::TestSuite const std::string name() const { return "AlgorithmWithWorkspace";} int version() const { return 1;} const std::string category() const { return "Cat";} + const std::string summary() const { return "Test summary"; } void init() { @@ -33,6 +34,7 @@ class AlgorithmHasPropertyTest : public CxxTest::TestSuite const std::string name() const { return "AlgorithmWithNoWorkspace";} int version() const { return 1;} const std::string category() const { return "Cat";} + const std::string summary() const { return "Test summary"; } void init() { @@ -47,6 +49,7 @@ class AlgorithmHasPropertyTest : public CxxTest::TestSuite const std::string name() const { return "AlgorithmWithInvalidProperty";} int version() const { return 1; } const std::string category() const { return "Cat";} + const std::string summary() const { return "Test summary"; } void init() { diff --git a/Code/Mantid/Framework/API/test/AlgorithmHistoryTest.h b/Code/Mantid/Framework/API/test/AlgorithmHistoryTest.h index 8772c81149ed..923461002489 100644 --- a/Code/Mantid/Framework/API/test/AlgorithmHistoryTest.h +++ b/Code/Mantid/Framework/API/test/AlgorithmHistoryTest.h @@ -19,6 +19,7 @@ class testalg : public Algorithm const std::string name() const { return "testalg";} ///< Algorithm's name for identification int version() const { return 1;} ///< Algorithm's version for identification const std::string category() const { return "Cat";} ///< Algorithm's category for identification + const std::string summary() const { return "Test summary"; } void init() { diff --git a/Code/Mantid/Framework/API/test/AlgorithmManagerTest.h b/Code/Mantid/Framework/API/test/AlgorithmManagerTest.h index 415545297559..e66dd51828c5 100644 --- a/Code/Mantid/Framework/API/test/AlgorithmManagerTest.h +++ b/Code/Mantid/Framework/API/test/AlgorithmManagerTest.h @@ -25,6 +25,7 @@ class AlgTest : public Algorithm virtual const std::string name() const {return "AlgTest";} virtual int version() const {return(1);} virtual const std::string category() const {return("Cat1");} + virtual const std::string summary() const { return "Test summary"; } }; class AlgTestFail : public Algorithm @@ -38,6 +39,7 @@ class AlgTestFail : public Algorithm virtual const std::string name() const {return "AlgTest";} virtual int version() const {return(1);} virtual const std::string category() const {return("Cat2");} + virtual const std::string summary() const { return "Test summary"; } }; @@ -52,6 +54,7 @@ class AlgTestPass : public Algorithm virtual const std::string name() const {return "AlgTest";} virtual int version() const {return(2);} virtual const std::string category() const {return("Cat4");} + virtual const std::string summary() const { return "Test summary"; } }; @@ -66,6 +69,7 @@ class AlgTestSecond : public Algorithm virtual const std::string name() const {return "AlgTestSecond";} virtual int version() const {return(1);} virtual const std::string category() const {return("Cat3");} + virtual const std::string summary() const { return "Test summary"; } }; @@ -82,6 +86,7 @@ class AlgRunsForever : public Algorithm virtual const std::string name() const {return "AlgRunsForever";} virtual int version() const {return(1);} virtual const std::string category() const {return("Cat1");} + virtual const std::string summary() const { return "Test summary"; } // Override method so we can manipulate whether it appears to be running virtual bool isRunning() const { return isRunningFlag; } void setIsRunningTo(bool runningFlag) { isRunningFlag = runningFlag; } diff --git a/Code/Mantid/Framework/API/test/AlgorithmPropertyTest.h b/Code/Mantid/Framework/API/test/AlgorithmPropertyTest.h index 76fe87390d0e..5f6edfe417a3 100644 --- a/Code/Mantid/Framework/API/test/AlgorithmPropertyTest.h +++ b/Code/Mantid/Framework/API/test/AlgorithmPropertyTest.h @@ -26,6 +26,7 @@ class AlgorithmPropertyTest : public CxxTest::TestSuite const std::string name() const { return "SimpleSum";} int version() const { return 1;} const std::string category() const { return "Dummy";} + const std::string summary() const { return "Test summary"; } void init() { @@ -49,7 +50,8 @@ class AlgorithmPropertyTest : public CxxTest::TestSuite public: const std::string name() const { return "HasAlgProp";} int version() const { return 1;} - const std::string category() const { return "Dummy";} + const std::string category() const { return "Dummy";} + const std::string summary() const { return "Test summary"; } void init() { declareProperty(new AlgorithmProperty("CalculateStep")); @@ -64,7 +66,8 @@ class AlgorithmPropertyTest : public CxxTest::TestSuite public: const std::string name() const { return "HasAlgPropAndValidator";} int version() const { return 1;} - const std::string category() const { return "Dummy";} + const std::string category() const { return "Dummy";} + const std::string summary() const { return "Test summary"; } void init() { declareProperty(new AlgorithmProperty("CalculateStep", boost::make_shared("Output1"))); diff --git a/Code/Mantid/Framework/API/test/AlgorithmProxyTest.h b/Code/Mantid/Framework/API/test/AlgorithmProxyTest.h index 3de2e191bfd3..146d08aa90ce 100644 --- a/Code/Mantid/Framework/API/test/AlgorithmProxyTest.h +++ b/Code/Mantid/Framework/API/test/AlgorithmProxyTest.h @@ -23,6 +23,7 @@ class ToyAlgorithmProxy : public Algorithm int version() const { return 1;} ///< Algorithm's version for identification const std::string category() const { return "ProxyCat";} ///< Algorithm's category for identification const std::string alias() const { return "Dog";} ///< Algorithm's alias + const std::string summary() const { return "Test summary"; } const std::string workspaceMethodName() const { return "toyalgorithm"; } const std::string workspaceMethodOnTypes() const { return "MatrixWorkspace;ITableWorkspace"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } @@ -61,7 +62,7 @@ class ToyAlgorithmProxyMultipleCategory : public Algorithm int version() const { return 1;} ///< Algorithm's version for identification const std::string category() const { return "ProxyCat;ProxyLeopard";} ///< Algorithm's category for identification const std::string alias() const { return "Dog";} ///< Algorithm's alias - + const std::string summary() const { return "Test summary"; } void init() { declareProperty("prop1","value"); diff --git a/Code/Mantid/Framework/API/test/AlgorithmTest.h b/Code/Mantid/Framework/API/test/AlgorithmTest.h index 725bf004f9c2..5fdff7bd995f 100644 --- a/Code/Mantid/Framework/API/test/AlgorithmTest.h +++ b/Code/Mantid/Framework/API/test/AlgorithmTest.h @@ -28,6 +28,7 @@ class StubbedWorkspaceAlgorithm : public Algorithm const std::string name() const { return "StubbedWorkspaceAlgorithm";} int version() const { return 1;} const std::string category() const { return "Cat;Leopard;Mink";} + const std::string summary() const { return "Test summary"; } void init() { declareProperty(new WorkspaceProperty<>("InputWorkspace1", "", Direction::Input)); @@ -67,6 +68,7 @@ class StubbedWorkspaceAlgorithm2 : public Algorithm const std::string name() const { return "StubbedWorkspaceAlgorithm2";} int version() const { return 2;} const std::string category() const { return "Cat;Leopard;Mink";} + const std::string summary() const { return "Test summary"; } void init() { declareProperty(new WorkspaceProperty<>("NonLockingInputWorkspace","",Direction::Input, PropertyMode::Optional, LockMode::NoLock)); @@ -86,6 +88,7 @@ class AlgorithmWithValidateInputs : public Algorithm const std::string name() const { return "StubbedWorkspaceAlgorithm2";} int version() const { return 1;} const std::string category() const { return "Cat;Leopard;Mink";} + const std::string summary() const { return "Test summary"; } const std::string workspaceMethodName() const { return "methodname"; } const std::string workspaceMethodOnTypes() const { return "MatrixWorkspace;ITableWorkspace"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } @@ -119,7 +122,7 @@ class FailingAlgorithm : public Algorithm virtual ~FailingAlgorithm() {} const std::string name() const { return "FailingAlgorithm"; } int version() const { return 1; } - + const std::string summary() const { return "Test summary"; } static const std::string FAIL_MSG; void init() diff --git a/Code/Mantid/Framework/API/test/AsynchronousTest.h b/Code/Mantid/Framework/API/test/AsynchronousTest.h index b1d68eac462f..6a93cf70c489 100644 --- a/Code/Mantid/Framework/API/test/AsynchronousTest.h +++ b/Code/Mantid/Framework/API/test/AsynchronousTest.h @@ -23,6 +23,7 @@ class AsyncAlgorithm : public Algorithm const std::string name() const { return "AsyncAlgorithm";} ///< Algorithm's name for identification int version() const { return 1;} ///< Algorithm's version for identification const std::string category() const { return "Cat";} ///< Algorithm's category for identification + const std::string summary() const { return "Test summary"; } void init() {} void exec() diff --git a/Code/Mantid/Framework/API/test/DataProcessorAlgorithmTest.h b/Code/Mantid/Framework/API/test/DataProcessorAlgorithmTest.h index 9af077ce2ab8..51f0c47ebbb3 100644 --- a/Code/Mantid/Framework/API/test/DataProcessorAlgorithmTest.h +++ b/Code/Mantid/Framework/API/test/DataProcessorAlgorithmTest.h @@ -21,6 +21,7 @@ class SubAlgorithm : public Algorithm const std::string name() const { return "SubAlgorithm";} int version() const { return 1;} const std::string category() const { return "Cat;Leopard;Mink";} + const std::string summary() const { return "Test summary"; } const std::string workspaceMethodName() const { return "methodname"; } const std::string workspaceMethodOnTypes() const { return "MatrixWorkspace;ITableWorkspace"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } @@ -46,6 +47,7 @@ class BasicAlgorithm : public Algorithm const std::string name() const { return "BasicAlgorithm";} int version() const { return 1;} const std::string category() const { return "Cat;Leopard;Mink";} + const std::string summary() const { return "Test summary"; } const std::string workspaceMethodName() const { return "methodname"; } const std::string workspaceMethodOnTypes() const { return "MatrixWorkspace;ITableWorkspace"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } @@ -75,6 +77,7 @@ class NestedAlgorithm : public DataProcessorAlgorithm const std::string name() const { return "NestedAlgorithm";} int version() const { return 1;} const std::string category() const { return "Cat;Leopard;Mink";} + const std::string summary() const { return "Test summary"; } const std::string workspaceMethodName() const { return "methodname"; } const std::string workspaceMethodOnTypes() const { return "MatrixWorkspace;ITableWorkspace"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } @@ -104,6 +107,7 @@ class TopLevelAlgorithm : public DataProcessorAlgorithm const std::string name() const { return "TopLevelAlgorithm";} int version() const { return 1;} const std::string category() const { return "Cat;Leopard;Mink";} + const std::string summary() const { return "Test summary"; } const std::string workspaceMethodName() const { return "methodname"; } const std::string workspaceMethodOnTypes() const { return "Workspace;MatrixWorkspace;ITableWorkspace"; } const std::string workspaceMethodInputProperty() const { return "InputWorkspace"; } diff --git a/Code/Mantid/Framework/API/test/FakeAlgorithms.h b/Code/Mantid/Framework/API/test/FakeAlgorithms.h index 7e326db1cbea..a347392a9a8a 100644 --- a/Code/Mantid/Framework/API/test/FakeAlgorithms.h +++ b/Code/Mantid/Framework/API/test/FakeAlgorithms.h @@ -17,6 +17,7 @@ class ToyAlgorithm : public Algorithm int version() const { return 1;} ///< Algorithm's version for identification const std::string category() const { return "Cat";} ///< Algorithm's category for identification const std::string alias() const { return "Dog";} + const std::string summary() const { return "Test summary"; } void init() { @@ -46,6 +47,7 @@ class ToyAlgorithmTwo : public Algorithm const std::string category() const { return "Cat,Leopard,Mink";} const std::string categorySeparator() const { return ",";} ///< testing the ability to change the seperator const std::string alias() const { return "Dog";} + const std::string summary() const { return "Test summary"; } void init() { declareProperty("prop1","value"); @@ -71,6 +73,7 @@ class ToyAlgorithmThree : public Algorithm int version() const { return 2;} ///< Algorithm's version for identification const std::string category() const { return "Cat;Leopard;Mink";} const std::string alias() const { return "Dog";} + const std::string summary() const { return "Test summary"; } void init() { declareProperty("prop1","value"); @@ -90,6 +93,7 @@ class CategoryAlgorithm : public Algorithm int version() const { return 1;} ///< Algorithm's version for identification const std::string category() const { return "Fake";} const std::string alias() const { return "CategoryTester";} + const std::string summary() const { return "Test summary"; } void init() { declareProperty("prop1","value"); @@ -98,4 +102,4 @@ class CategoryAlgorithm : public Algorithm } void exec() {} }; -#endif \ No newline at end of file +#endif diff --git a/Code/Mantid/Framework/API/test/FrameworkManagerTest.h b/Code/Mantid/Framework/API/test/FrameworkManagerTest.h index 058b2bff3889..fe99ca82b169 100644 --- a/Code/Mantid/Framework/API/test/FrameworkManagerTest.h +++ b/Code/Mantid/Framework/API/test/FrameworkManagerTest.h @@ -19,6 +19,7 @@ class ToyAlgorithm2 : public Algorithm virtual ~ToyAlgorithm2() {} virtual const std::string name() const { return "ToyAlgorithm2";};///< Algorithm's name for identification virtual int version() const { return 1;};///< Algorithm's version for identification + virtual const std::string summary() const { return "Test summary"; } void init() { declareProperty("Prop",""); declareProperty("P2",""); diff --git a/Code/Mantid/Framework/API/test/MultiPeriodGroupAlgorithmTest.h b/Code/Mantid/Framework/API/test/MultiPeriodGroupAlgorithmTest.h index 523800e17947..1038a976dcf0 100644 --- a/Code/Mantid/Framework/API/test/MultiPeriodGroupAlgorithmTest.h +++ b/Code/Mantid/Framework/API/test/MultiPeriodGroupAlgorithmTest.h @@ -18,6 +18,7 @@ class TestAlgorithmA : public MultiPeriodGroupAlgorithm TestAlgorithmA(){} virtual const std::string name() const {return "TestAlgorithmA";} virtual int version() const {return 1;} + virtual const std::string summary() const { return "Test summary"; } virtual void init() { declareProperty(new ArrayProperty("MyInputWorkspaces")); @@ -52,6 +53,7 @@ class TestAlgorithmB : public MultiPeriodGroupAlgorithm TestAlgorithmB(){} virtual const std::string name() const {return "TestAlgorithmB";} virtual int version() const {return 1;} + virtual const std::string summary() const { return "Test summary"; } virtual void init() { declareProperty(new WorkspaceProperty<>("PropertyA", "ws1", Direction::Input)); @@ -144,6 +146,7 @@ class MultiPeriodGroupAlgorithmTest : public CxxTest::TestSuite public: virtual const std::string name() const {return "BrokenAlgorithm";} virtual int version() const {return 1;} + virtual const std::string summary() const { return "Test summary"; } virtual void init() { declareProperty(new WorkspaceProperty("InputWorkspaces","",Direction::Input), ""); @@ -185,6 +188,7 @@ class MultiPeriodGroupAlgorithmTest : public CxxTest::TestSuite public: virtual const std::string name() const {return "BrokenAlgorithm";} virtual int version() const {return 1;} + virtual const std::string summary() const { return "Test summary"; } virtual void init() { declareProperty(new ArrayProperty("InputWorkspaces")); diff --git a/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h b/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h index bbf731872dce..3b728aee6f39 100644 --- a/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h +++ b/Code/Mantid/Framework/API/test/WorkspaceHistoryTest.h @@ -27,6 +27,7 @@ class WorkspaceHistoryTest : public CxxTest::TestSuite const std::string name() const { return "SimpleSum";} int version() const { return 1;} const std::string category() const { return "Dummy";} + const std::string summary() const { return "Dummy summary"; } void init() { diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime2.h index 2a892ef786ab..0542a19ea857 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/FilterByTime2.h @@ -46,6 +46,8 @@ namespace Algorithms virtual int version() const { return 2;}; /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Events\\EventFiltering";} + /// Algorithm's summary for identification overriding a virtual method + virtual const std::string summary() const { return "Filter event data by time."; } private: /// Sets documentation strings for this algorithm diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnaryOperation.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnaryOperation.h index 14e19926667f..3e9a03f0a90c 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnaryOperation.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/UnaryOperation.h @@ -52,9 +52,10 @@ namespace Mantid UnaryOperation(); /// Destructor virtual ~UnaryOperation(); - /// Algorithm's category for identification virtual const std::string category() const { return "Arithmetic";} + /// Summary of algorithms purpose + virtual const std::string summary() const { return "Supports the implementation of a Unary operation on an input workspace."; } protected: // Overridden Algorithm methods diff --git a/Code/Mantid/Framework/Algorithms/test/BinaryOperationTest.h b/Code/Mantid/Framework/Algorithms/test/BinaryOperationTest.h index 67a1efa8899c..f0d432f733d1 100644 --- a/Code/Mantid/Framework/Algorithms/test/BinaryOperationTest.h +++ b/Code/Mantid/Framework/Algorithms/test/BinaryOperationTest.h @@ -32,6 +32,8 @@ class BinaryOpHelper : public Mantid::Algorithms::BinaryOperation virtual int version() const { return 1; } /// function to return a category of the algorithm. A default implementation is provided virtual const std::string category() const {return "Helper";} + /// function to return the summary of the algorithm. A default implementation is provided. + virtual const std::string summary() const { return "Summary of this test."; } std::string checkSizeCompatibility(const MatrixWorkspace_const_sptr ws1,const MatrixWorkspace_const_sptr ws2) { diff --git a/Code/Mantid/Framework/Algorithms/test/ChainedOperatorTest.h b/Code/Mantid/Framework/Algorithms/test/ChainedOperatorTest.h index 22a8496b01a0..d9409180d8c4 100644 --- a/Code/Mantid/Framework/Algorithms/test/ChainedOperatorTest.h +++ b/Code/Mantid/Framework/Algorithms/test/ChainedOperatorTest.h @@ -40,7 +40,7 @@ class ComplexOpTest : public Algorithm } virtual const std::string name() const {return "ComplexOpTest";} virtual int version() const {return(1);} - + virtual const std::string summary() const { return "Summary of this test."; } }; class ChainedOperatorTest : public CxxTest::TestSuite diff --git a/Code/Mantid/Framework/Algorithms/test/CommutativeBinaryOperationTest.h b/Code/Mantid/Framework/Algorithms/test/CommutativeBinaryOperationTest.h index c50ae77e94bf..6f7833638c84 100644 --- a/Code/Mantid/Framework/Algorithms/test/CommutativeBinaryOperationTest.h +++ b/Code/Mantid/Framework/Algorithms/test/CommutativeBinaryOperationTest.h @@ -22,6 +22,9 @@ class CommutativeBinaryOpHelper : public Mantid::Algorithms::CommutativeBinaryOp virtual const std::string name() const { return "CommutativeBinaryOperationHelper"; } /// Algorithm's version for identification overriding a virtual method virtual int version() const { return 1; } + /// Algorithm's summary for identification overriding a virtual method + virtual const std::string summary() const { return "Sommutative binary operation helper."; } + std::string checkSizeCompatibility(const MatrixWorkspace_const_sptr ws1,const MatrixWorkspace_const_sptr ws2) { m_lhs = ws1; diff --git a/Code/Mantid/Framework/Algorithms/test/GeneratePythonScriptTest.h b/Code/Mantid/Framework/Algorithms/test/GeneratePythonScriptTest.h index 9a0f948cb008..3960e99063f8 100644 --- a/Code/Mantid/Framework/Algorithms/test/GeneratePythonScriptTest.h +++ b/Code/Mantid/Framework/Algorithms/test/GeneratePythonScriptTest.h @@ -30,6 +30,8 @@ class NonExistingAlgorithm : public Algorithm virtual int version() const { return 1;} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Rubbish";} + /// Summary of algorithms purpose + virtual const std::string summary() const { return "I do not exist, or do I?"; } void init() diff --git a/Code/Mantid/Framework/Algorithms/test/UnaryOperationTest.h b/Code/Mantid/Framework/Algorithms/test/UnaryOperationTest.h index f36cbad28d59..c6171c807fa3 100644 --- a/Code/Mantid/Framework/Algorithms/test/UnaryOperationTest.h +++ b/Code/Mantid/Framework/Algorithms/test/UnaryOperationTest.h @@ -20,7 +20,8 @@ class UnaryOpHelper : public Mantid::Algorithms::UnaryOperation const std::string name() const { return "None"; } int version() const { return 0; } - + const std::string summary() const { return "Test summary"; } + // Pass-throughs to UnaryOperation methods const std::string inputPropName() const { return UnaryOperation::inputPropName(); } const std::string outputPropName() const { return UnaryOperation::outputPropName(); } diff --git a/Code/Mantid/Framework/DataObjects/test/TableWorkspacePropertyTest.h b/Code/Mantid/Framework/DataObjects/test/TableWorkspacePropertyTest.h index 32c8e1436907..109db310844d 100644 --- a/Code/Mantid/Framework/DataObjects/test/TableWorkspacePropertyTest.h +++ b/Code/Mantid/Framework/DataObjects/test/TableWorkspacePropertyTest.h @@ -30,6 +30,7 @@ class TableWorkspaceAlgorithm : public Algorithm virtual int version()const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Examples";} + virtual const std::string summary() const { return "Test summary"; } private: ///Initialisation code diff --git a/Code/Mantid/Framework/LiveData/test/LiveDataAlgorithmTest.h b/Code/Mantid/Framework/LiveData/test/LiveDataAlgorithmTest.h index 2e1f1c52001a..d7ab925a4a1f 100644 --- a/Code/Mantid/Framework/LiveData/test/LiveDataAlgorithmTest.h +++ b/Code/Mantid/Framework/LiveData/test/LiveDataAlgorithmTest.h @@ -29,6 +29,7 @@ class LiveDataAlgorithmImpl : public LiveDataAlgorithm virtual const std::string name() const { return "LiveDataAlgorithmImpl";} virtual int version() const { return 1;} virtual const std::string category() const { return "Testing";} + virtual const std::string summary() const { return "Test summary"; } void init() { this->initProps(); } void exec() {} diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BinaryOperationMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BinaryOperationMD.h index 6102acc45021..7fa6cc0a8a7b 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BinaryOperationMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/BinaryOperationMD.h @@ -53,6 +53,7 @@ namespace MDAlgorithms virtual const std::string name() const; virtual int version() const; virtual const std::string category() const; + virtual const std::string summary() const { return "Abstract base class for binary operations on IMDWorkspaces, e.g. A = B + C or A = B / C."; } protected: /// Is the operation commutative? diff --git a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/UnaryOperationMD.h b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/UnaryOperationMD.h index 8bc5f1225227..cd3d793619d7 100644 --- a/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/UnaryOperationMD.h +++ b/Code/Mantid/Framework/MDAlgorithms/inc/MantidMDAlgorithms/UnaryOperationMD.h @@ -44,6 +44,7 @@ namespace MDAlgorithms virtual const std::string name() const; virtual int version() const; virtual const std::string category() const; + virtual const std::string summary() const { return "Abstract base class for unary operations on MDWorkspaces."; } protected: /// The name of the input workspace property diff --git a/Code/Mantid/Framework/MDAlgorithms/test/SlicingAlgorithmTest.h b/Code/Mantid/Framework/MDAlgorithms/test/SlicingAlgorithmTest.h index 6543caa18cd3..6224fc2f9b71 100644 --- a/Code/Mantid/Framework/MDAlgorithms/test/SlicingAlgorithmTest.h +++ b/Code/Mantid/Framework/MDAlgorithms/test/SlicingAlgorithmTest.h @@ -31,6 +31,7 @@ class SlicingAlgorithmImpl : public SlicingAlgorithm virtual const std::string name() const { return "SlicingAlgorithmImpl";}; virtual int version() const { return 1;}; virtual const std::string category() const { return "Testing";} + virtual const std::string summary() const { return "Summary of this test."; } void init() {} void exec() {} }; diff --git a/Code/Mantid/Framework/MDEvents/test/BoxControllerSettingsAlgorithmTest.h b/Code/Mantid/Framework/MDEvents/test/BoxControllerSettingsAlgorithmTest.h index a55cbf7b9a71..b54466c963a5 100644 --- a/Code/Mantid/Framework/MDEvents/test/BoxControllerSettingsAlgorithmTest.h +++ b/Code/Mantid/Framework/MDEvents/test/BoxControllerSettingsAlgorithmTest.h @@ -32,6 +32,7 @@ class BoxControllerSettingsAlgorithmImpl : public BoxControllerSettingsAlgorithm virtual const std::string name() const { return "BoxControllerSettingsAlgorithmImpl";}; virtual int version() const { return 1;}; virtual const std::string category() const { return "Testing";} + virtual const std::string summary() const { return "Summary of this test."; } void init() {} void exec() {} }; diff --git a/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/WorkspaceCreationHelper.h b/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/WorkspaceCreationHelper.h index be30445c3da7..a7f8fa80f5d1 100644 --- a/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/WorkspaceCreationHelper.h +++ b/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/WorkspaceCreationHelper.h @@ -58,6 +58,8 @@ namespace WorkspaceCreationHelper virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "Test";} + /// Algorithm's summary. + virtual const std::string summary() const { return "Test summary."; } Mantid::Kernel::Logger & getLogger(){return g_log;} diff --git a/Code/Mantid/Framework/WorkflowAlgorithms/test/StepScanTest.h b/Code/Mantid/Framework/WorkflowAlgorithms/test/StepScanTest.h index 6629fad1cd69..bfd5873b0527 100644 --- a/Code/Mantid/Framework/WorkflowAlgorithms/test/StepScanTest.h +++ b/Code/Mantid/Framework/WorkflowAlgorithms/test/StepScanTest.h @@ -56,7 +56,7 @@ class StepScanTest : public CxxTest::TestSuite TS_ASSERT_EQUALS( stepScan->name(), "StepScan" ); TS_ASSERT_EQUALS( stepScan->version(), 1 ); TS_ASSERT_EQUALS( stepScan->category(), "Workflow\\Alignment" ); - TS_ASSERT( !stepScan->getWikiSummary().empty() ); + TS_ASSERT( !stepScan->summary().empty() ); } void test_fail_on_invalid_inputs() From 148d85bbc6df2038d49c2adeb4f5d903168e7f77 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 13:53:42 +0100 Subject: [PATCH 096/126] Fix additional Python generated warnings. Refs #9523. --- Code/Mantid/Framework/Algorithms/src/CalculateZscore.cpp | 4 ---- Code/Mantid/Framework/CurveFitting/src/FitPowderDiffPeaks.cpp | 4 ---- Code/Mantid/Framework/CurveFitting/src/LeBailFit.cpp | 4 ---- .../CurveFitting/src/RefinePowderInstrumentParameters.cpp | 4 ---- .../CurveFitting/src/RefinePowderInstrumentParameters3.cpp | 4 ---- 5 files changed, 20 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/src/CalculateZscore.cpp b/Code/Mantid/Framework/Algorithms/src/CalculateZscore.cpp index 4f744827c1d4..79c86b24b582 100644 --- a/Code/Mantid/Framework/Algorithms/src/CalculateZscore.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CalculateZscore.cpp @@ -42,10 +42,6 @@ namespace Algorithms { } - //---------------------------------------------------------------------------------------------- - /** WIKI: - * - //---------------------------------------------------------------------------------------------- /** Define properties */ diff --git a/Code/Mantid/Framework/CurveFitting/src/FitPowderDiffPeaks.cpp b/Code/Mantid/Framework/CurveFitting/src/FitPowderDiffPeaks.cpp index ac95b0aa477c..2bfbcbc367c4 100644 --- a/Code/Mantid/Framework/CurveFitting/src/FitPowderDiffPeaks.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/FitPowderDiffPeaks.cpp @@ -140,10 +140,6 @@ namespace CurveFitting FitPowderDiffPeaks::~FitPowderDiffPeaks() { } - - //---------------------------------------------------------------------------------------------- - /** Set up documention - * //---------------------------------------------------------------------------------------------- /** Parameter declaration diff --git a/Code/Mantid/Framework/CurveFitting/src/LeBailFit.cpp b/Code/Mantid/Framework/CurveFitting/src/LeBailFit.cpp index aadd8ccb53f7..b9cbfce907e1 100644 --- a/Code/Mantid/Framework/CurveFitting/src/LeBailFit.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/LeBailFit.cpp @@ -102,10 +102,6 @@ namespace CurveFitting LeBailFit::~LeBailFit() { } - - //---------------------------------------------------------------------------------------------- - /** Sets documentation strings for this algorithm - * //---------------------------------------------------------------------------------------------- /** Declare the input properties for this algorithm diff --git a/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters.cpp b/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters.cpp index c83682905da8..22560c6b5ac1 100644 --- a/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters.cpp @@ -58,10 +58,6 @@ namespace CurveFitting { } - //---------------------------------------------------------------------------------------------- - /** Set up documention - * - //---------------------------------------------------------------------------------------------- /** Parameter declaration */ diff --git a/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters3.cpp b/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters3.cpp index b3dfdfb1abd4..22f0f65b1bb7 100644 --- a/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters3.cpp +++ b/Code/Mantid/Framework/CurveFitting/src/RefinePowderInstrumentParameters3.cpp @@ -69,10 +69,6 @@ namespace CurveFitting { } - //---------------------------------------------------------------------------------------------- - /** Set up documention - * - //---------------------------------------------------------------------------------------------- /** Declare properties */ From 333cb547ebc04f93849d796a5de9da3346a20797 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 15:17:53 +0100 Subject: [PATCH 097/126] No initDocs left behind. Refs #9523. --- .../MantidAlgorithms/CountEventsInPulses.h | 3 +-- .../Algorithms/inc/MantidAlgorithms/Max.h | 11 +++++---- .../Algorithms/inc/MantidAlgorithms/MaxMin.h | 6 ++--- .../Algorithms/inc/MantidAlgorithms/Min.h | 11 +++++---- .../MantidAlgorithms/StripVanadiumPeaks2.h | 24 ++++++------------- .../MantidAlgorithms/SumEventsByLogValue.h | 10 ++++---- .../inc/MantidAlgorithms/WorkspaceJoiners.h | 3 --- .../Algorithms/src/CountEventsInPulses.cpp | 5 ---- .../inc/MantidGPUAlgorithms/GPUTester.h | 6 ++--- .../Framework/GPUAlgorithms/src/GPUTester.cpp | 9 ------- .../WorkspaceCreationHelper.h | 2 -- .../VatesAPI/inc/MantidVatesAPI/LoadVTK.h | 7 +++--- Code/Mantid/Vates/VatesAPI/src/LoadVTK.cpp | 6 ----- 13 files changed, 36 insertions(+), 67 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CountEventsInPulses.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CountEventsInPulses.h index 762e8c8ca800..8fc123dd02e3 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CountEventsInPulses.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/CountEventsInPulses.h @@ -43,10 +43,9 @@ namespace Algorithms virtual const std::string name() const {return "CountEventsInPulses"; } virtual int version() const {return 1; } virtual const std::string category() const {return "Utility"; } + virtual const std::string summary() const {return "Counts the number of events in pulses.";} private: - virtual void initDocs(); - /// Properties definition void init(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Max.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Max.h index d78d4064fb0d..c62fd2b6303c 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Max.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Max.h @@ -59,16 +59,19 @@ class DLLExport Max : public API::Algorithm virtual ~Max() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Max";} - ///Summary of algorithms purpose - virtual const std::string summary() const {return "Takes a 2D workspace as input and find the maximum in each 1D spectrum. The algorithm creates a new 1D workspace containing all maxima as well as their X boundaries and error. This is used in particular for single crystal as a quick way to find strong peaks.";} - /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic";} + ///Summary of algorithms purpose + virtual const std::string summary() const + { + return "Takes a 2D workspace as input and find the maximum in each 1D spectrum." + "The algorithm creates a new 1D workspace containing all maxima as well as their X boundaries and error." + "This is used in particular for single crystal as a quick way to find strong peaks."; + } private: - void initDocs(); // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaxMin.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaxMin.h index 3ca95ab307b9..8650e6779ce7 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaxMin.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/MaxMin.h @@ -59,16 +59,14 @@ class DLLExport MaxMin : public API::Algorithm virtual ~MaxMin() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "MaxMin";} - ///Summary of algorithms purpose - virtual const std::string summary() const {return "Takes a 2D workspace as input and find the maximum (minimum) in each 1D spectrum.";} - + ///Summary of algorithms purpose + virtual const std::string summary() const {return "Takes a 2D workspace as input and find the maximum (minimum) in each 1D spectrum.";} /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic";} private: - void initDocs(); // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Min.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Min.h index bc24e25a9532..327fb75e9fab 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Min.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/Min.h @@ -59,16 +59,19 @@ class DLLExport Min : public API::Algorithm virtual ~Min() {}; /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "Min";} - ///Summary of algorithms purpose - virtual const std::string summary() const {return "Takes a 2D workspace as input and find the minimum in each 1D spectrum. The algorithm creates a new 1D workspace containing all minima as well as their X boundaries and error. This is used in particular for single crystal as a quick way to find strong peaks.";} - /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Arithmetic";} + ///Summary of algorithms purpose + virtual const std::string summary() const + { + return "Takes a 2D workspace as input and find the minimum in each 1D spectrum. " + "The algorithm creates a new 1D workspace containing all minima as well as their X boundaries and error. " + "This is used in particular for single crystal as a quick way to find strong peaks."; + } private: - void initDocs(); // Overridden Algorithm methods void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks2.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks2.h index bfa08637d094..1a7c5ab467b6 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks2.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/StripVanadiumPeaks2.h @@ -42,28 +42,18 @@ namespace Algorithms ~StripVanadiumPeaks2(); /// Algorithm's name for identification overriding a virtual method - virtual const std::string name() const - { - return "StripVanadiumPeaks"; - } - - ///Summary of algorithms purpose - virtual const std::string summary() const {return "This algorithm removes peaks (at vanadium d-spacing positions by default) out of a background by linearly/quadratically interpolating over the expected peak positions. ";} - - + virtual const std::string name() const { return "StripVanadiumPeaks"; } /// Algorithm's version for identification overriding a virtual method - virtual int version() const - { - return 2; - } + virtual int version() const { return 2; } /// Algorithm's category for identification - virtual const std::string category() const + virtual const std::string category() const { return "CorrectionFunctions;Optimization\\PeakFinding;Diffraction";} + ///Summary of algorithms purpose + virtual const std::string summary() const { - return "CorrectionFunctions;Optimization\\PeakFinding;Diffraction"; + return "This algorithm removes peaks (at vanadium d-spacing positions by default)" + " out of a background by linearly/quadratically interpolating over the expected peak positions. "; } - private: - void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumEventsByLogValue.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumEventsByLogValue.h index 00656e92d039..720e105ffe60 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumEventsByLogValue.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/SumEventsByLogValue.h @@ -45,18 +45,20 @@ namespace Algorithms /// Algorithm's name for identification overriding a virtual method virtual const std::string name() const { return "SumEventsByLogValue";} - ///Summary of algorithms purpose - virtual const std::string summary() const {return "Produces a single spectrum workspace containing the total summed events in the workspace as a function of a specified log.";} - /// Algorithm's version for identification overriding a virtual method virtual int version() const { return (1);} /// Algorithm's category for identification overriding a virtual method virtual const std::string category() const { return "Events";} + ///Summary of algorithms purpose + virtual const std::string summary() const + { + return "Produces a single spectrum workspace containing the " + "total summed events in the workspace as a function of a specified log."; + } std::map validateInputs(); private: - void initDocs(); void init(); void exec(); diff --git a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WorkspaceJoiners.h b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WorkspaceJoiners.h index c7d6e0995473..c45f6cfc97a8 100644 --- a/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WorkspaceJoiners.h +++ b/Code/Mantid/Framework/Algorithms/inc/MantidAlgorithms/WorkspaceJoiners.h @@ -63,9 +63,6 @@ namespace Algorithms API::Progress *m_progress; ///< Progress reporting object DataObjects::EventWorkspace_const_sptr event_ws1; ///< First event workspace input. DataObjects::EventWorkspace_const_sptr event_ws2; ///< Second event workspace input. - - private: - void initDocs(); }; diff --git a/Code/Mantid/Framework/Algorithms/src/CountEventsInPulses.cpp b/Code/Mantid/Framework/Algorithms/src/CountEventsInPulses.cpp index 91402d0f90a2..c8c84e0713c0 100644 --- a/Code/Mantid/Framework/Algorithms/src/CountEventsInPulses.cpp +++ b/Code/Mantid/Framework/Algorithms/src/CountEventsInPulses.cpp @@ -36,11 +36,6 @@ namespace Algorithms { } - void CountEventsInPulses::initDocs() - { - return; - } - void CountEventsInPulses::init() { // Input workspace diff --git a/Code/Mantid/Framework/GPUAlgorithms/inc/MantidGPUAlgorithms/GPUTester.h b/Code/Mantid/Framework/GPUAlgorithms/inc/MantidGPUAlgorithms/GPUTester.h index 8ad71e1e136c..132e5ebff86a 100644 --- a/Code/Mantid/Framework/GPUAlgorithms/inc/MantidGPUAlgorithms/GPUTester.h +++ b/Code/Mantid/Framework/GPUAlgorithms/inc/MantidGPUAlgorithms/GPUTester.h @@ -49,10 +49,10 @@ namespace GPUAlgorithms virtual int version() const { return 1;}; /// Algorithm's category for identification virtual const std::string category() const { return "GPUAlgorithms";} - + /// Summary of algorithms purpose + virtual const std::string summary() const {return "A dummy algorithm to test the capabilities of the GPU card for computation.";} + private: - /// Sets documentation strings for this algorithm - virtual void initDocs(); /// Initialise the properties void init(); /// Run the algorithm diff --git a/Code/Mantid/Framework/GPUAlgorithms/src/GPUTester.cpp b/Code/Mantid/Framework/GPUAlgorithms/src/GPUTester.cpp index 310067d25287..ac15a64b860b 100644 --- a/Code/Mantid/Framework/GPUAlgorithms/src/GPUTester.cpp +++ b/Code/Mantid/Framework/GPUAlgorithms/src/GPUTester.cpp @@ -37,15 +37,6 @@ namespace GPUAlgorithms GPUTester::~GPUTester() { } - - - //---------------------------------------------------------------------------------------------- - /// Sets documentation strings for this algorithm - void GPUTester::initDocs() - { - this->setWikiSummary("A dummy algorithm to test the capabilities of the GPU card for computation."); - this->setOptionalMessage("A dummy algorithm to test the capabilities of the GPU card for computation."); - } //---------------------------------------------------------------------------------------------- /** Initialize the algorithm's properties. diff --git a/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/WorkspaceCreationHelper.h b/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/WorkspaceCreationHelper.h index a7f8fa80f5d1..175a8417954e 100644 --- a/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/WorkspaceCreationHelper.h +++ b/Code/Mantid/Framework/TestHelpers/inc/MantidTestHelpers/WorkspaceCreationHelper.h @@ -71,8 +71,6 @@ namespace WorkspaceCreationHelper private: void init(){}; void exec(){}; - /// Sets documentation strings for this algorithm - virtual void initDocs(){}; std::auto_ptr m_Progress; /// logger -> to provide logging, diff --git a/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/LoadVTK.h b/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/LoadVTK.h index 9e6cfbde125b..dca708bdd2b0 100644 --- a/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/LoadVTK.h +++ b/Code/Mantid/Vates/VatesAPI/inc/MantidVatesAPI/LoadVTK.h @@ -26,13 +26,12 @@ namespace Mantid virtual const std::string category() const; + /// Summary of algorithms purpose + virtual const std::string summary() const {return "Loads a legacy binary format VTK uniform structured image as an MDWorkspace.";} + /// Returns a confidence value that this algorithm can load a file virtual int confidence(Kernel::FileDescriptor & descriptor) const; - protected: - - virtual void initDocs(); - private: void execMDHisto(vtkUnsignedShortArray* signals, vtkUnsignedShortArray* errorsSQ, Mantid::Geometry::MDHistoDimension_sptr dimX, Mantid::Geometry::MDHistoDimension_sptr dimY, Mantid::Geometry::MDHistoDimension_sptr dimZ, Mantid::API::Progress& prog, const int64_t nPoints, const int64_t frequency); diff --git a/Code/Mantid/Vates/VatesAPI/src/LoadVTK.cpp b/Code/Mantid/Vates/VatesAPI/src/LoadVTK.cpp index ebb98ae279ef..29c450db97fe 100644 --- a/Code/Mantid/Vates/VatesAPI/src/LoadVTK.cpp +++ b/Code/Mantid/Vates/VatesAPI/src/LoadVTK.cpp @@ -111,12 +111,6 @@ namespace Mantid return "MDAlgorithms"; } - void LoadVTK::initDocs() - { - this->setWikiSummary("Loads a legacy binary format VTK uniform structured image as an MDWorkspace."); - this->setOptionalMessage(this->getWikiDescription()); - } - void LoadVTK::init() { std::vector exts; From d973996852574ceae1770cc00cc97044ca43354c Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 17:04:38 +0100 Subject: [PATCH 098/126] Add summary method to Python algorithms. Refs #9523. --- .../plugins/algorithms/BASISReduction.py | 6 +- .../CalibrateRectangularDetectors.py | 8 +- .../plugins/algorithms/CheckForSampleLogs.py | 5 +- .../plugins/algorithms/ConjoinFiles.py | 5 +- .../plugins/algorithms/ConjoinSpectra.py | 5 +- .../algorithms/ConvertSnsRoiFileToMask.py | 4 +- .../plugins/algorithms/CorrectLogTimes.py | 7 +- .../algorithms/CreateEmptyTableWorkspace.py | 7 +- .../algorithms/CreateLeBailFitInput.py | 9 +- .../CreateTransmissionWorkspaceAuto.py | 7 +- .../plugins/algorithms/DSFinterp.py | 9 +- .../plugins/algorithms/DakotaChiSquared.py | 6 +- .../algorithms/ExaminePowderDiffProfile.py | 8 +- .../plugins/algorithms/ExportExperimentLog.py | 10 +- .../algorithms/ExportSampleLogsToCSVFile.py | 3 + .../plugins/algorithms/FilterLogByTime.py | 5 +- .../algorithms/FindReflectometryLines.py | 6 +- .../GenerateGroupingSNSInelastic.py | 11 +- .../plugins/algorithms/GetEiMonDet.py | 9 +- .../plugins/algorithms/GetEiT0atSNS.py | 9 +- .../plugins/algorithms/LoadFullprofFile.py | 12 +- .../algorithms/LoadLogPropertyTable.py | 11 +- .../plugins/algorithms/LoadMultipleGSS.py | 4 +- .../plugins/algorithms/LoadSINQ.py | 5 +- .../plugins/algorithms/LoadSINQFile.py | 5 +- .../plugins/algorithms/LoadVesuvio.py | 4 +- .../plugins/algorithms/MaskAngle.py | 8 +- .../plugins/algorithms/MaskBTP.py | 10 +- .../algorithms/MaskWorkspaceToCalFile.py | 8 +- .../plugins/algorithms/Mean.py | 3 + .../plugins/algorithms/MergeCalFiles.py | 6 +- .../PDDetermineCharacterizations.py | 3 + .../plugins/algorithms/PearlMCAbsorption.py | 5 +- .../plugins/algorithms/PoldiMerge.py | 7 +- .../plugins/algorithms/PoldiProjectAddDir.py | 5 +- .../plugins/algorithms/PoldiProjectAddFile.py | 5 +- .../plugins/algorithms/PoldiProjectRun.py | 11 +- .../plugins/algorithms/RefLReduction.py | 5 +- .../algorithms/RefinePowderDiffProfileSeq.py | 6 +- .../ReflectometryReductionOneAuto.py | 11 +- .../plugins/algorithms/RetrieveRunInfo.py | 5 +- .../plugins/algorithms/SANSSubtract.py | 5 +- .../algorithms/SANSWideAngleCorrection.py | 5 +- .../plugins/algorithms/SNSPowderReduction.py | 3 + .../algorithms/SelectPowderDiffPeaks.py | 4 +- .../plugins/algorithms/SortByQVectors.py | 4 +- .../plugins/algorithms/SortDetectors.py | 8 +- .../plugins/algorithms/SortXAxis.py | 6 +- .../plugins/algorithms/Stitch1D.py | 5 +- .../plugins/algorithms/Stitch1DMany.py | 8 +- .../plugins/algorithms/SuggestTibCNCS.py | 9 +- .../plugins/algorithms/SuggestTibHYSPEC.py | 9 +- .../algorithms/TestWorkspaceGroupProperty.py | 5 +- .../plugins/algorithms/USANSSimulation.py | 3 + .../UpdatePeakParameterTableValue.py | 5 +- .../plugins/algorithms/ViewBOA.py | 5 +- .../WorkflowAlgorithms/DensityOfStates.py | 11 +- .../EQSANSAzimuthalAverage1D.py | 7 +- .../EQSANSDirectBeamTransmission.py | 7 +- .../WorkflowAlgorithms/EQSANSNormalise.py | 5 +- .../WorkflowAlgorithms/FuryFitMultiple.py | 4 +- .../WorkflowAlgorithms/HFIRSANSReduction.py | 7 +- .../IndirectTransmission.py | 5 +- .../WorkflowAlgorithms/MuscatData.py | 6 +- .../WorkflowAlgorithms/MuscatFunc.py | 6 +- .../NormaliseByThickness.py | 5 +- .../OSIRISDiffractionReduction.py | 8 +- .../algorithms/WorkflowAlgorithms/QLines.py | 5 +- .../algorithms/WorkflowAlgorithms/Quest.py | 5 +- .../WorkflowAlgorithms/REFLReprocess.py | 8 +- .../ReactorSANSResolution.py | 5 +- .../algorithms/WorkflowAlgorithms/ResNorm.py | 105 +++++++++--------- .../WorkflowAlgorithms/SANSAbsoluteScale.py | 5 +- .../SANSAzimuthalAverage1D.py | 7 +- .../SANSBeamSpreaderTransmission.py | 7 +- .../SANSDirectBeamTransmission.py | 7 +- .../algorithms/WorkflowAlgorithms/SANSMask.py | 3 + .../WorkflowAlgorithms/SANSReduction.py | 5 +- .../WorkflowAlgorithms/SavePlot1D.py | 6 +- .../WorkflowAlgorithms/SofQWMoments.py | 6 +- .../WorkflowAlgorithms/Symmetrise.py | 6 +- 81 files changed, 361 insertions(+), 252 deletions(-) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/BASISReduction.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/BASISReduction.py index 4805db44305a..7e5a7512a811 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/BASISReduction.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/BASISReduction.py @@ -31,14 +31,14 @@ def category(self): def name(self): return "BASISReduction" + def summary(self): + return "This algorithm is meant to temporarily deal with letting BASIS reduce lots of files via Mantid." + def PyInit(self): self._short_inst = "BSS" self._long_inst = "BASIS" self._extension = "_event.nxs" - self.setWikiSummary("This algorithm is meant to temporarily deal with letting BASIS reduce lots of files via Mantid.") - self.setOptionalMessage("This algorithm is meant to temporarily deal with letting BASIS reduce lots of files via Mantid.") - self.declareProperty("RunNumbers", "", "Sample run numbers") self.declareProperty("DoIndividual", False, "Do each run individually") self.declareProperty("NoMonitorNorm", False, diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py index b2867bd74024..60d92d20d0cc 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CalibrateRectangularDetectors.py @@ -37,10 +37,10 @@ def category(self): def name(self): return "CalibrateRectangularDetectors" - def PyInit(self): - self.setOptionalMessage("Calibrate the detector pixels and write a calibration file") - self.setWikiSummary("Calibrate the detector pixels and write a calibration file") - + def summary(self): + return "Calibrate the detector pixels and write a calibration file" + + def PyInit(self): sns = ConfigService.Instance().getFacility("SNS") instruments = [] diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CheckForSampleLogs.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CheckForSampleLogs.py index 25ad678c2429..d74879f0e594 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CheckForSampleLogs.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CheckForSampleLogs.py @@ -19,7 +19,10 @@ def name(self): """ Return name """ return "CheckForSampleLogs" - + + def summary(self): + return "Check if the workspace has some given sample logs" + def PyInit(self): """ Declare properties """ diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConjoinFiles.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConjoinFiles.py index e3f76bc74460..9a65f7a1ccd5 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConjoinFiles.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConjoinFiles.py @@ -16,6 +16,9 @@ def category(self): def name(self): return "ConjoinFiles" + def summary(self): + return "Conjoin two file-based workspaces." + def __load(self, directory, instr, run, loader, exts, wksp): filename = None for ext in exts: @@ -34,8 +37,6 @@ def __load(self, directory, instr, run, loader, exts, wksp): raise RuntimeError("Failed to load run %s from file %s" % (str(run), filename)) def PyInit(self): - self.setOptionalMessage("Conjoin two file-based workspaces.") - self.setWikiSummary("Conjoin two file-based workspaces.") greaterThanZero = IntArrayBoundedValidator() greaterThanZero.setLower(0) self.declareProperty(IntArrayProperty("RunNumbers",values=[0], validator=greaterThanZero), doc="Run numbers") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConjoinSpectra.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConjoinSpectra.py index 63ce196d1b3e..981597bbfbd2 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConjoinSpectra.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConjoinSpectra.py @@ -23,9 +23,10 @@ def category(self): def name(self): return "ConjoinSpectra" + def summmary(self): + return "Joins individual spectra from a range of workspaces into a single workspace for plotting or further analysis." + def PyInit(self): - self.setWikiSummary("Joins individual spectra from a range of workspaces into a single workspace for plotting or further analysis.") - self.setOptionalMessage("Joins individual spectra from a range of workspaces into a single workspace for plotting or further analysis.") self.declareProperty("InputWorkspaces","", validator=StringMandatoryValidator(), doc="Comma seperated list of workspaces to use, group workspaces will automatically include all members.") self.declareProperty(WorkspaceProperty("OutputWorkspace", "", direction=Direction.Output), doc="Name the workspace that will contain the result") self.declareProperty("WorkspaceIndex", 0, doc="The workspace index of the spectra in each workspace to extract. Default: 0") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConvertSnsRoiFileToMask.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConvertSnsRoiFileToMask.py index 81c8aaa43bf4..5f16406ebce8 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConvertSnsRoiFileToMask.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ConvertSnsRoiFileToMask.py @@ -38,9 +38,11 @@ def name(self): Name of the algorithm. """ return "ConvertSnsRoiFileToMask" + + def summary(self): + return "This algorithm reads in an old SNS reduction ROI file and converts it into a Mantid mask workspace." def PyInit(self): - self.setOptionalMessage("This algorithm reads in an old SNS reduction ROI file and converts it into a Mantid mask workspace.") """ Set the algorithm properties. """ diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CorrectLogTimes.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CorrectLogTimes.py index 0444fed7cfae..280c98bd5b86 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CorrectLogTimes.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CorrectLogTimes.py @@ -21,10 +21,11 @@ def name(self): """ Mantid required """ return "CorrectLogTimes" - - + + def summary(self): + return "This algorithm attempts to make the time series property logs start at the same time as the first time in the proton charge log." + def PyInit(self): - self.setOptionalMessage("This algorithm attempts to make the time series property logs start at the same time as the first time in the proton charge log.") self.declareProperty(mantid.api.WorkspaceProperty("Workspace", "",direction=mantid.kernel.Direction.InOut), "Input workspace") self.declareProperty("LogNames","",doc="Experimental og values to be shifted. If empty, will attempt to shift all logs") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateEmptyTableWorkspace.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateEmptyTableWorkspace.py index ab58bd90e763..9c61971d1df5 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateEmptyTableWorkspace.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateEmptyTableWorkspace.py @@ -9,11 +9,12 @@ # Create an empty table workspace to be populated by a python script. class CreateEmptyTableWorkspace(PythonAlgorithm): - + + def summary(self): + return "Creates an empty table workspace that can be populated by python code" + def PyInit(self): # Declare properties - self.setWikiSummary("Creates an empty table workspace that can be populated by python code.") - self.setOptionalMessage("Creates an empty table workspace that can be populated by python code.") self.declareProperty(ITableWorkspaceProperty("OutputWorkspace", "", Direction.Output), "The name of the table workspace that will be created.") def PyExec(self): diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateLeBailFitInput.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateLeBailFitInput.py index 443121354e6c..232075d518ac 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateLeBailFitInput.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateLeBailFitInput.py @@ -45,12 +45,13 @@ def name(self): """ """ return "CreateLeBailFitInput" - + + def summary(self): + return "Create various input Workspaces required by algorithm LeBailFit." + def PyInit(self): """ Declare properties - """ - self.setWikiSummary("""Create various input Workspaces required by algorithm LeBailFit.""") - + """ #instruments=["POWGEN", "NOMAD", "VULCAN"] #self.declareProperty("Instrument", "POWGEN", StringListValidator(instruments), "Powder diffractometer's name") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateTransmissionWorkspaceAuto.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateTransmissionWorkspaceAuto.py index ae1274492adb..25587ba07e15 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateTransmissionWorkspaceAuto.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/CreateTransmissionWorkspaceAuto.py @@ -20,12 +20,11 @@ def category(self): def name(self): return "CreateTransmissionWorkspaceAuto" + + def summary(self): + return "Creates a transmission run workspace in Wavelength from input TOF workspaces." def PyInit(self): - - self.setOptionalMessage("Creates a transmission run workspace in Wavelength from input TOF workspaces.") - self.setWikiSummary("Creates a transmission run workspace in Wavelength from input TOF workspaces. See [[Reflectometry_Guide]]") - analysis_modes = ["PointDetectorAnalysis", "MultiDetectorAnalysis"] analysis_mode_validator = StringListValidator(analysis_modes) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/DSFinterp.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/DSFinterp.py index bba596a1cc96..566032e2e0b9 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/DSFinterp.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/DSFinterp.py @@ -1,10 +1,5 @@ """*WIKI* -== Summary == - -Given a set of parameter values {T_i} and corresponding structure factors {S(Q,E,T_i)}, this -algorithm interpolates S(Q,E,T) for any value of parameter T within the range spanned by the {T_i} set. - == Usage == DSFinterp(Workspaces,OutputWorkspaces,[LoadErrors],[ParameterValues], @@ -143,6 +138,10 @@ def category(self): def name(self): return 'DSFinterp' + def summmary(self): + return "Given a set of parameter values {T_i} and corresponding structure factors {S(Q,E,T_i)}, this \ +algorithm interpolates S(Q,E,T) for any value of parameter T within the range spanned by the {T_i} set." + def PyInit(self): arrvalidator = StringArrayMandatoryValidator() lrg='Input' diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/DakotaChiSquared.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/DakotaChiSquared.py index f65d416de269..6f3653fb61f2 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/DakotaChiSquared.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/DakotaChiSquared.py @@ -21,11 +21,13 @@ def name(self): """ Return name """ return "DakotaChiSquared" - + + def summmary(self): + return "Compare two nexus files containing matrix workspaces and output chi squared into a file" + def PyInit(self): """ Declare properties """ - self.setOptionalMessage("Compare two nexus files containing matrix workspaces and output chi squared into a file") f1=mantid.api.FileProperty("DataFile","",mantid.api.FileAction.Load,".nxs") self.declareProperty(f1,"Input Nexus file containing data.") f2=mantid.api.FileProperty("CalculatedFile","",mantid.api.FileAction.Load,".nxs") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExaminePowderDiffProfile.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExaminePowderDiffProfile.py index 62e9b0b8a961..824510e98bef 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExaminePowderDiffProfile.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExaminePowderDiffProfile.py @@ -24,13 +24,13 @@ def name(self): """ """ return "ExaminePowderDiffProfile" - + + def summmary(self): + return "Examine peak profile parameters by Le Bail fit." + def PyInit(self): """ Declare properties """ - self.setWikiSummary("""Examine peak profile parameters by Le Bail fit.""") - self.setOptionalMessage("""Examine peak profile parameters by Le Bail fit.""") - # Data file self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", Direction.Input, PropertyMode.Optional), "Name of data workspace containing the diffraction pattern in .prf file. ") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExportExperimentLog.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExportExperimentLog.py index 0f93ab57718e..d2718f1eed10 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExportExperimentLog.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExportExperimentLog.py @@ -51,14 +51,16 @@ import datetime class ExportExperimentLog(PythonAlgorithm): + """ Algorithm to export experiment log """ + + def summmary(self): + return "Exports experimental log." + def PyInit(self): """ Declaration of properties - """ - self.setWikiSummary("Export experimental log.") - self.setOptionalMessage("Export experimental log.") - + """ # wsprop = mantid.api.MatrixWorkspaceProperty("InputWorkspace", "", mantid.kernel.Direction.Input) wsprop = MatrixWorkspaceProperty("InputWorkspace", "", Direction.Input) self.declareProperty(wsprop, "Input workspace containing the sample log information. ") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExportSampleLogsToCSVFile.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExportSampleLogsToCSVFile.py index 37d3bbe14239..35f6599c22c2 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExportSampleLogsToCSVFile.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ExportSampleLogsToCSVFile.py @@ -32,6 +32,9 @@ def name(self): """ return "ExportSampleLogsToCSVFile" + def summary(self): + return "Exports sample logs to spreadsheet file." + def PyInit(self): """ Declare properties """ diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/FilterLogByTime.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/FilterLogByTime.py index 701ee722f738..32426cf67bb5 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/FilterLogByTime.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/FilterLogByTime.py @@ -24,6 +24,9 @@ def category(self): def name(self): return "FilterLogByTime" + def summary(self): + return "Filters a log between time intervals and applies a user defined operation to the result." + def PyInit(self): self.declareProperty(WorkspaceProperty("InputWorkspace", "", direction=Direction.Input), "Input workspace") log_validator = StringMandatoryValidator() @@ -33,8 +36,6 @@ def PyInit(self): self.declareProperty(name="Method",defaultValue="mean", validator=StringListValidator(["mean","min", "max", "median", "mode"]), doc="Statistical method to use to generate ResultStatistic output") self.declareProperty(FloatArrayProperty(name="FilteredResult", direction=Direction.Output), doc="Filtered values between specified times.") self.declareProperty(name="ResultStatistic", defaultValue=0.0, direction=Direction.Output, doc="Requested statistic") - self.setWikiSummary("Filters a log between time intervals and applies a user defined operation to the result.") - self.setOptionalMessage("Filters a log between time intervals and applies a user defined operation to the result.") def PyExec(self): in_ws = self.getProperty("InputWorkspace").value diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/FindReflectometryLines.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/FindReflectometryLines.py index fb38ef504416..6cdc3d0c6a4e 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/FindReflectometryLines.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/FindReflectometryLines.py @@ -48,13 +48,15 @@ def category(self): def name(self): return "FindReflectometryLines" + def summary(self): + return "Finds spectrum numbers corresponding to reflected and transmission lines in a line detector Reflectometry dataset." + def PyInit(self): workspace_validator = CompositeValidator() workspace_validator.add(WorkspaceUnitValidator("Wavelength")) workspace_validator.add(SpectraAxisValidator()) - self.setOptionalMessage("Finds spectrum numbers corresponding to reflected and transmission lines in a line detector Reflectometry dataset.") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", Direction.Input, workspace_validator), "Input Reflectometry Workspace") self.declareProperty(ITableWorkspaceProperty("OutputWorkspace", "", Direction.Output), "Output Spectrum Numbers") self.declareProperty(name="StartWavelength", defaultValue=0.0, validator=FloatBoundedValidator(lower=0.0), doc="Start wavelength to use for x-axis cropping") @@ -104,4 +106,4 @@ def PyExec(self): self.setProperty("OutputWorkspace", output_ws) -AlgorithmFactory.subscribe(FindReflectometryLines()) \ No newline at end of file +AlgorithmFactory.subscribe(FindReflectometryLines()) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GenerateGroupingSNSInelastic.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GenerateGroupingSNSInelastic.py index 0d77dc666148..0714d0f03d89 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GenerateGroupingSNSInelastic.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GenerateGroupingSNSInelastic.py @@ -24,19 +24,22 @@ def category(self): return "Inelastic;PythonAlgorithms;Transforms\\Grouping" def name(self): - """ Mantid require + """ Mantid required """ return "GenerateGroupingSNSInelastic" + def summary(self): + """ Mantid required + """ + return "Generate grouping files for ARCS, CNCS, HYSPEC, and SEQUOIA." + + def PyInit(self): """ Python initialization: Define input parameters """ py = ["1", "2", "4","8","16","32","64","128"] px = ["1", "2", "4","8"] instrument = ["ARCS","CNCS","HYSPEC","SEQUOIA"] - - self.setWikiSummary("Generate grouping files for ARCS, CNCS, HYSPEC, and SEQUOIA.") - self.setOptionalMessage("Generate grouping files for ARCS, CNCS, HYSPEC, and SEQUOIA.") self.declareProperty("AlongTubes", "1",mantid.kernel.StringListValidator(py), "Number of pixels across tubes to be grouped") self.declareProperty("AcrossTubes", "1", mantid.kernel.StringListValidator(px), "Number of pixels across tubes to be grouped") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GetEiMonDet.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GetEiMonDet.py index d03e4944d98a..abcb1c5789df 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GetEiMonDet.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GetEiMonDet.py @@ -22,10 +22,13 @@ def name(self): """ Return name """ return "GetEiMonDet" - + + def summary(self): + """ Return summary + """ + return "Get incident energy from one monitor and some detectors." + def PyInit(self): - self.setWikiSummary("Get incident energy from one monitor and some detectors.") - self.setOptionalMessage("Get incident energy from one monitor and some detectors.") """ Declare properties """ self.declareProperty(WorkspaceProperty("DetectorWorkspace","",Direction.Input),"Workspace containing data from detectors") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GetEiT0atSNS.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GetEiT0atSNS.py index 23f1d7d3d6cb..db75ced6c066 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GetEiT0atSNS.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/GetEiT0atSNS.py @@ -20,10 +20,13 @@ def name(self): """ Return name """ return "GetEiT0atSNS" - + + def summary(self): + """ Return summary + """ + return "Get Ei and T0 on ARCS and SEQUOIA instruments." + def PyInit(self): - self.setWikiSummary("Get Ei and T0 on ARCS and SEQUOIA instruments.") - self.setOptionalMessage("Get Ei and T0 on ARCS and SEQUOIA instruments.") """ Declare properties """ self.declareProperty(mantid.api.WorkspaceProperty("MonitorWorkspace", "",direction=mantid.kernel.Direction.InOut), "Monitor workspace") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadFullprofFile.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadFullprofFile.py index 1bb059b350bb..38202e23ff2d 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadFullprofFile.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadFullprofFile.py @@ -43,13 +43,15 @@ def name(self): """ """ return "LoadFullprofFile" - + + def summary(self): + """ Return summary + """ + return "Load file generated by Fullprof." + def PyInit(self): """ Declare properties - """ - self.setWikiSummary("""Load file generated by Fullprof.""") - self.setOptionalMessage("""Load file generated by Fullprof.""") - + """ self.declareProperty(FileProperty("Filename","", FileAction.Load, ['.hkl', '.prf', '.dat']), "Name of [http://www.ill.eu/sites/fullprof/ Fullprof] .hkl or .prf file.") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadLogPropertyTable.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadLogPropertyTable.py index 54aa9e372b8a..6ad9816c758c 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadLogPropertyTable.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadLogPropertyTable.py @@ -25,6 +25,15 @@ from mantid.simpleapi import * # needed for Load class LoadLogPropertyTable(PythonAlgorithm): + + + + def summary(self): + """ Return summary + """ + return "Creates a table of Run number against the log values for that run for a range of files.\ + It can use a single log value or a list of log values." + # same concept as built in "CreateLogPropertyTable" but loads its own workspaces and needn't hold all in memory at once # select log values to put in table (list) # special cases for: @@ -32,8 +41,6 @@ class LoadLogPropertyTable(PythonAlgorithm): # comment (separate function) # time series, take average for t>0 (if available) def PyInit(self): - self.setWikiSummary("""Creates a table of Run number against the log values for that run for a range of files. It can use a single log value or a list of log values.""") - self.setOptionalMessage("""Creates a table of Run number against the log values for that run for a range of files. It can use a single log value or a list of log values.""") self.declareProperty(FileProperty(name="FirstFile",defaultValue="",action=FileAction.Load,extensions = ["nxs","raw"]),"The first file to load from") self.declareProperty(FileProperty(name="LastFile",defaultValue="",action=FileAction.Load,extensions = ["nxs","raw"]),"The Last file to load from, must be in the same directory, all files in between will also be used") self.declareProperty(StringArrayProperty("LogNames",direction=Direction.Input),"The comma seperated list of properties to include. \nThe full list will be printed if an invalid value is used.") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadMultipleGSS.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadMultipleGSS.py index 0534f699aab8..42e76d296c34 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadMultipleGSS.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadMultipleGSS.py @@ -15,6 +15,9 @@ def category(self): def name(self): return "LoadMultipleGSS" + def summary(self): + return "This algorithm loads multiple gsas files from a single directory into mantid." + def __load(self, directory, prefix): for ext in self.__exts: filename = "%s%s" % (prefix, ext) @@ -31,7 +34,6 @@ def __load(self, directory, prefix): raise RuntimeError("Failed to load run %s" % prefix) def PyInit(self): - self.setOptionalMessage("This algorithm loads multiple gsas files from a single directory into mantid.") self.declareProperty("FilePrefix","") intArrayValidator = IntArrayBoundedValidator() intArrayValidator.setLower(0) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadSINQ.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadSINQ.py index a2b99d83c207..829786560b74 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadSINQ.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadSINQ.py @@ -31,6 +31,9 @@ class LoadSINQ(PythonAlgorithm): def category(self): return "DataHandling;PythonAlgorithms" + def summary(self): + return "SINQ data file loader" + def PyInit(self): instruments=["AMOR","BOA","DMC","FOCUS","HRPT","MARSI","MARSE","POLDI", "RITA-2","SANS","SANS2","TRICS"] @@ -41,8 +44,6 @@ def PyInit(self): self.declareProperty("Year",now.year,"Choose year",direction=Direction.Input) self.declareProperty('Numor',0,'Choose file number',direction=Direction.Input) self.declareProperty(WorkspaceProperty("OutputWorkspace","",direction=Direction.Output)) - self.setWikiSummary("SINQ data file loader") - self.setOptionalMessage("SINQ data file loader") def PyExec(self): inst=self.getProperty('Instrument').value diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadSINQFile.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadSINQFile.py index 88c60d07f1c4..28b3cbc9d71d 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadSINQFile.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadSINQFile.py @@ -27,10 +27,11 @@ class LoadSINQFile(PythonAlgorithm): def category(self): return "DataHandling;PythonAlgorithms" + def summary(self): + return "Load a SINQ file with the right dictionary." + def PyInit(self): global dictsearch - self.setWikiSummary("Load a SINQ file with the right dictionary.") - self.setOptionalMessage("Load a SINQ file with the right dictionary.") instruments=["AMOR","BOA","DMC","FOCUS","HRPT","MARSI","MARSE","POLDI", "RITA-2","SANS","SANS2","TRICS"] self.declareProperty("Instrument","AMOR", diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadVesuvio.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadVesuvio.py index f819bb8cb9c3..ba0d64aa8de3 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadVesuvio.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/LoadVesuvio.py @@ -39,8 +39,10 @@ class LoadVesuvio(PythonAlgorithm): + def summary(self): + return "A Workflow algorithm to load the data from the VESUVIO instrument at ISIS." + def PyInit(self): - self.setOptionalMessage("A Workflow algorithm to load the data from the VESUVIO instrument at ISIS.") self.declareProperty(RUN_PROP, "", StringMandatoryValidator(), doc="The run numbers that should be loaded. E.g." "14188 - for single run" diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskAngle.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskAngle.py index af0cd185b329..2fea29a58b73 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskAngle.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskAngle.py @@ -22,9 +22,13 @@ def name(self): """ Mantid require """ return "MaskAngle" - + + def summary(self): + """ Mantid require + """ + return "Algorithm to mask detectors with scattering angles in a given interval (in degrees)." + def PyInit(self): - self.setOptionalMessage("Algorithm to mask detectors with scattering angles in a given interval (in degrees)") self.declareProperty(mantid.api.WorkspaceProperty("Workspace", "",direction=mantid.kernel.Direction.Input,validator=mantid.api.InstrumentValidator()), "Input workspace") angleValidator=mantid.kernel.FloatBoundedValidator() angleValidator.setBounds(0.,180.) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskBTP.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskBTP.py index e36ac42a23da..e34ae4bc0c1f 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskBTP.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskBTP.py @@ -30,14 +30,16 @@ def category(self): return "PythonAlgorithms;Transforms\\Masking;Inelastic" def name(self): - """ Mantid require + """ Mantid required """ return "MaskBTP" - + def summary(self): + """ Mantid required + """ + return "Algorithm to mask detectors in particular banks, tube, or pixels." + def PyInit(self): - self.setWikiSummary("Algorithm to mask detectors in particular banks, tube, or pixels.") - self.setOptionalMessage("Algorithm to mask detectors in particular banks, tube, or pixels.") self.declareProperty(mantid.api.WorkspaceProperty("Workspace", "",direction=mantid.kernel.Direction.InOut, optional = mantid.api.PropertyMode.Optional), "Input workspace (optional)") allowedInstrumentList=mantid.kernel.StringListValidator(["","ARCS","CNCS","HYSPEC","NOMAD","POWGEN","SEQUOIA","SNAP","TOPAZ"]) self.declareProperty("Instrument","",validator=allowedInstrumentList,doc="One of the following instruments: ARCS, CNCS, HYSPEC, NOMAD, POWGEN, SNAP, SEQUOIA, TOPAZ") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskWorkspaceToCalFile.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskWorkspaceToCalFile.py index 3de15d4d50b1..57f77d2d3b6f 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskWorkspaceToCalFile.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MaskWorkspaceToCalFile.py @@ -54,11 +54,11 @@ def category(self): def name(self): return "MaskWorkspaceToCalFile" - - + + def summary(self): + return "Saves the masking information in a workspace to a Cal File." + def PyInit(self): - self.setWikiSummary("Saves the masking information in a workspace to a [[CalFile| Cal File]].") - self.setOptionalMessage("Saves the masking information in a workspace to a Cal File.") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", Direction.Input), "The workspace containing the Masking to extract.") self.declareProperty(FileProperty(name="OutputFile",defaultValue="",action=FileAction.Save,extensions=['cal']), "The file for the results.") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Mean.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Mean.py index eab3996251bb..84ada79a0db8 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Mean.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Mean.py @@ -13,6 +13,9 @@ def category(self): def name(self): return "Mean" + def summary(self): + return "Calculates the mean of the workspaces provided." + def PyInit(self): mustHaveWorkspaceNames = StringMandatoryValidator() self.declareProperty("Workspaces", "", validator=mustHaveWorkspaceNames, direction=Direction.Input, doc="Input workspaces. Comma separated workspace names") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MergeCalFiles.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MergeCalFiles.py index a78b3fa70a17..8877d42a3fe7 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MergeCalFiles.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/MergeCalFiles.py @@ -15,10 +15,10 @@ def category(self): def name(self): return "MergeCalFiles" - + def summary(self): + return "Combines the data from two Cal Files." + def PyInit(self): - self.setWikiSummary("Combines the data from two [[CalFile| Cal Files]].") - self.setOptionalMessage("Combines the data from two Cal Files.") self.declareProperty(FileProperty("UpdateFile","", FileAction.Load, ['cal']), doc="The cal file containing the updates to merge into another file.") self.declareProperty(FileProperty("MasterFile","", FileAction.Load, ['cal']), doc="The master file to be altered, the file must be sorted by UDET") self.declareProperty(FileProperty("OutputFile","", FileAction.Save, ['cal']), doc="The file to contain the results") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PDDetermineCharacterizations.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PDDetermineCharacterizations.py index f2d801147849..8b902e6102d6 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PDDetermineCharacterizations.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PDDetermineCharacterizations.py @@ -39,6 +39,9 @@ def category(self): def name(self): return "PDDetermineCharacterizations" + def summary(self): + return "Determines the characterizations of a workspace." + def PyInit(self): # input parameters self.declareProperty(WorkspaceProperty("InputWorkspace", "", diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PearlMCAbsorption.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PearlMCAbsorption.py index ce63ddcc28fe..cc0ef924aea2 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PearlMCAbsorption.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PearlMCAbsorption.py @@ -18,9 +18,10 @@ class PearlMCAbsorption(PythonAlgorithm): def category(self): return "CorrectionFunctions\\AbsorptionCorrections;PythonAlgorithms" + def summary(self): + return "Loads pre-calculated or measured absorption correction files for Pearl." + def PyInit(self): - self.setWikiSummary("Loads pre-calculated or measured absorption correction files for Pearl.") - self.setOptionalMessage("Loads pre-calculated or measured absorption correction files for Pearl.") # Input file self.declareProperty(FileProperty("Filename","", FileAction.Load, ['.out','.dat']), doc="The name of the input file.") # Output workspace diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiMerge.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiMerge.py index 8ffb4ffcc946..b4b1a2b002d8 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiMerge.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiMerge.py @@ -25,7 +25,10 @@ def category(self): def name(self): return "PoldiMerge" - + + def summary(self): + return "PoldiMerge takes a list of workspace names and adds the counts, resulting in a new workspace." + def PyInit(self): self.declareProperty(StringArrayProperty(name="WorkspaceNames", direction=Direction.Input), @@ -105,4 +108,4 @@ def handleError(self, error): raise RuntimeError("Workspaces can not be merged. %s. Aborting." % (str(error))) -AlgorithmFactory.subscribe(PoldiMerge) \ No newline at end of file +AlgorithmFactory.subscribe(PoldiMerge) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectAddDir.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectAddDir.py index 00236f93523a..1dcf3921a4a5 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectAddDir.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectAddDir.py @@ -35,12 +35,13 @@ def name(self): """ return "PoldiProjectAddDir" + def summary(self): + return "Add all the .hdf files from the given directory to the queue for automatic processing." + def PyInit(self): """ Mantid required """ - self.setWikiSummary("""Add all the .hdf files from the given directory to the queue for automatic processing.""") - self.declareProperty(FileProperty(name="Directory",defaultValue="",action=FileAction.Directory)) self.declareProperty(ITableWorkspaceProperty("PoldiAnalysis", "PoldiAnalysis", direction=Direction.Output), "Poldi analysis main worksheet") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectAddFile.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectAddFile.py index ea6557afadb5..8d17347c6f67 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectAddFile.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectAddFile.py @@ -29,12 +29,13 @@ def name(self): """ return "PoldiProjectAddDir" + def summary(self): + return "Add all the .hdf files from the given directory to the queue for automatic processing." + def PyInit(self): """ Mantid required """ - self.setWikiSummary("""Add all the .hdf files from the given directory to the queue for automatic processing.""") - self.declareProperty(FileProperty(name="File",defaultValue="",action=FileAction.Load)) self.declareProperty(ITableWorkspaceProperty(name="OutputWorkspace", defaultValue="PoldiAnalysis", direction=Direction.Output), diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectRun.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectRun.py index 408d0a56f51e..d12e511d3527 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectRun.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/PoldiProjectRun.py @@ -245,15 +245,12 @@ def name(self): """ return "PoldiProjectRun" + def summary(self): + return "Run the POLDI analysis process for a bunch of data files stored in a tableWorkspace." + def PyInit(self): """ Mantid required - """ - - self.setWikiSummary("""Run the POLDI analysis process for a bunch of data files stored in a tableWorkspace.""") - self.setOptionalMessage("""Run the POLDI analysis process for a bunch of data files stored in a tableWorkspace.""") - - - + """ self.declareProperty(ITableWorkspaceProperty("InputWorkspace", "PoldiAnalysis", direction=Direction.Input), "Poldi analysis main worksheet") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RefLReduction.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RefLReduction.py index a802bb7c6d2c..c43ae5e27fd8 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RefLReduction.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RefLReduction.py @@ -29,9 +29,10 @@ def name(self): def version(self): return 1 + def summary(self): + return "Liquids Reflectometer (REFL) reduction" + def PyInit(self): - self.setWikiSummary("Liquids Reflectometer (REFL) reduction") - self.setOptionalMessage("Liquids Reflectometer (REFL) reduction") self.declareProperty(IntArrayProperty("RunNumbers"), "List of run numbers to process") self.declareProperty("NormalizationRunNumber", 0, "Run number of the normalization run to use") self.declareProperty(IntArrayProperty("SignalPeakPixelRange"), "Pixel range defining the data peak") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RefinePowderDiffProfileSeq.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RefinePowderDiffProfileSeq.py index 62b0fe8071b4..2a027b190f87 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RefinePowderDiffProfileSeq.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RefinePowderDiffProfileSeq.py @@ -82,12 +82,12 @@ def name(self): """ return "RefinePowderDiffProfileSeq" + def summary(self): + return "Refine powder diffractomer profile parameters sequentially." + def PyInit(self): """ Declare properties """ - self.setWikiSummary("""Refine powder diffractomer profile parameters sequentially.""") - self.setOptionalMessage("""Refine powder diffractomer profile parameters sequentially.""") - self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", Direction.Input, PropertyMode.Optional), "Name of data workspace containing the diffraction pattern in .prf file. ") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ReflectometryReductionOneAuto.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ReflectometryReductionOneAuto.py index 975c443b7606..dffd2a8ed089 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ReflectometryReductionOneAuto.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ReflectometryReductionOneAuto.py @@ -20,12 +20,11 @@ def category(self): def name(self): return "ReflectometryReductionOneAuto" - - def PyInit(self): - - self.setOptionalMessage("Reduces a single TOF reflectometry run into a mod Q vs I/I0 workspace. Performs transmission corrections.") - self.setWikiSummary("Reduces a single TOF reflectometry run into a mod Q vs I/I0 workspace. Performs transmission corrections. See [[Reflectometry_Guide]]") - + + def summary(self): + return "Reduces a single TOF reflectometry run into a mod Q vs I/I0 workspace. Performs transmission corrections." + + def PyInit(self): input_validator = WorkspaceUnitValidator("TOF") self.declareProperty(MatrixWorkspaceProperty(name="InputWorkspace", defaultValue="", direction=Direction.Input, optional=PropertyMode.Mandatory), "Input run in TOF") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RetrieveRunInfo.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RetrieveRunInfo.py index 6b759345d577..5f0cf7466859 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RetrieveRunInfo.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/RetrieveRunInfo.py @@ -192,9 +192,10 @@ class RetrieveRunInfo(PythonAlgorithm): def category(self): return 'Utility;PythonAlgorithms' + def summary(self): + return "Given a range of run numbers and an output workspace name, will compile a table of info for each run of the instrument you have set as default." + def PyInit(self): - self.setWikiSummary("""Given a range of run numbers and an output workspace name, will compile a table of info for each run of the instrument you have set as default.""") - self.setOptionalMessage("""Given a range of run numbers and an output workspace name, will compile a table of info for each run of the instrument you have set as default.""") # Declare algorithm properties. self.declareProperty( 'Runs', diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SANSSubtract.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SANSSubtract.py index 354d84e92475..53a256d951dc 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SANSSubtract.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SANSSubtract.py @@ -36,12 +36,13 @@ def name(self): """ return "SANSSubtract" + def summary(self): + return "Subtract background from an I(Q) distribution." + def PyInit(self): """ Declare properties """ - self.setOptionalMessage("Subtract background from an I(Q) distribution.") - self.setWikiSummary("Subtract background from an I(Q) distribution.") self.declareProperty('DataDistribution', '', direction = Direction.Input, doc='Name of the input workspace or file path') self.declareProperty('Background', '', direction = Direction.Input, diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SANSWideAngleCorrection.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SANSWideAngleCorrection.py index 6d4fc25b046e..f70ae4743b1d 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SANSWideAngleCorrection.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SANSWideAngleCorrection.py @@ -122,6 +122,9 @@ def category(self): def name(self): return "SANSWideAngleCorrection" + def summary(self): + return "Calculate the Wide Angle correction for SANS transmissions." + def PyInit(self): self.declareProperty(MatrixWorkspaceProperty("SampleData", "", direction = Direction.Input), "A workspace cropped to the detector to be reduced (the SAME as the input to [[Q1D]]); used to verify the solid angle. The workspace is not modified, just inspected.") @@ -129,8 +132,6 @@ def PyInit(self): "The transmission data calculated, referred to as T_0 in equations in discussion section") self.declareProperty(MatrixWorkspaceProperty("OutputWorkspace","",direction=Direction.Output), "The transmission corrected SANS data, normalised (divided) by T_0, see discussion section") - self.setWikiSummary("Calculate the Wide Angle correction for SANS transmissions.") - self.setOptionalMessage("Calculate the Wide Angle correction for SANS transmissions.") def PyExec(self): """ Main body of execution diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SNSPowderReduction.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SNSPowderReduction.py index 6f100d5f0916..17f401d11c3c 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SNSPowderReduction.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SNSPowderReduction.py @@ -33,6 +33,9 @@ def category(self): def name(self): return "SNSPowderReduction" + def summary(self): + return "Time filter wall is used in Load Data to load data in a certain range of time. " + def PyInit(self): sns = ConfigService.getFacility("SNS") instruments = [] diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SelectPowderDiffPeaks.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SelectPowderDiffPeaks.py index cf5de5ab66b0..8c156c611dcb 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SelectPowderDiffPeaks.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SelectPowderDiffPeaks.py @@ -22,8 +22,10 @@ def name(self): """ return "SelectPowderDiffPeaks" + def summary(self): + return "Select the powder diffraction peaks for Le Bail Fit" + def PyInit(self): - self.setOptionalMessage("Select the powder diffraction peaks for Le Bail Fit") """ Declare properties """ self.declareProperty(ITableWorkspaceProperty("BraggPeakParameterWorkspace", "", Direction.Input), diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortByQVectors.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortByQVectors.py index 89f8e37c746d..3742d39a90e6 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortByQVectors.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortByQVectors.py @@ -24,8 +24,10 @@ def category(self): def name(self): return "SortByQVectors" + def summary(self): + return "This algorithm sorts a group workspace by the qvectors found in the qvectors file." + def PyInit(self): - self.setOptionalMessage("This algorithm sorts a group workspace by the qvectors found in the qvectors file.") self.declareProperty("InputWorkspace", "", "Group workspace that automatically includes all members.") def PyExec(self): diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortDetectors.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortDetectors.py index 3bf52b2c236c..9ad6d8f05452 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortDetectors.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortDetectors.py @@ -20,9 +20,13 @@ def name(self): """ Return name """ return "SortDetectors" - + + def summary(self): + """ Return summary + """ + return "Algorithm to sort detectors by distance." + def PyInit(self): - self.setOptionalMessage("Algorithm to sort detectors by distance.") """ Declare properties """ self.declareProperty(mantid.api.WorkspaceProperty("Workspace","",direction=mantid.kernel.Direction.Input, validator=mantid.api.InstrumentValidator()), "Input workspace") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortXAxis.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortXAxis.py index 5796e35b5cd1..cfec374da192 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortXAxis.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SortXAxis.py @@ -21,8 +21,10 @@ def category(self): def name(self): return "SortXAxis" + def summary(self): + return "Clones the input MatrixWorkspace(s) and orders the x-axis in an ascending fashion." + def PyInit(self): - self.setOptionalMessage("Clones the input MatrixWorkspace(s) and orders the x-axis in an ascending fashion.") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", defaultValue="", direction=Direction.Input), doc="Input workspace") self.declareProperty(MatrixWorkspaceProperty("OutputWorkspace", defaultValue="", direction=Direction.Output), doc="Sorted Output Workspace") @@ -49,4 +51,4 @@ def PyExec(self): ############################################################################################# -AlgorithmFactory.subscribe(SortXAxis()) \ No newline at end of file +AlgorithmFactory.subscribe(SortXAxis()) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Stitch1D.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Stitch1D.py index f510d4175180..503703c0c84a 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Stitch1D.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Stitch1D.py @@ -22,13 +22,14 @@ def name(self): def version(self): return 3 + + def summary(self): + return "Stitches single histogram matrix workspaces together" def PyInit(self): histogram_validator = HistogramValidator() - self.setWikiSummary("Stitches single histogram matrix workspaces together") - self.setOptionalMessage("Stitches single histogram matrix workspaces together") self.declareProperty(MatrixWorkspaceProperty("LHSWorkspace", "", Direction.Input, validator=histogram_validator), "Input workspace") self.declareProperty(MatrixWorkspaceProperty("RHSWorkspace", "", Direction.Input, validator=histogram_validator), "Input workspace") self.declareProperty(MatrixWorkspaceProperty("OutputWorkspace", "", Direction.Output), "Output stitched workspace") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Stitch1DMany.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Stitch1DMany.py index 9ec651a532e3..c015cbe6b38b 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Stitch1DMany.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/Stitch1DMany.py @@ -23,15 +23,13 @@ def category(self): def name(self): return "Stitch1D" + def summary(self): + return "Stitches single histogram matrix workspaces together" + def PyInit(self): - input_validator = StringMandatoryValidator() - self.declareProperty(name="InputWorkspaces", defaultValue="", direction=Direction.Input, validator=input_validator, doc="Input workspaces") self.declareProperty(WorkspaceProperty("OutputWorkspace", "", Direction.Output), "Output stitched workspace") - - self.setWikiSummary("Stitches single histogram matrix workspaces together") - self.setOptionalMessage("Stitches single histogram matrix workspaces together") self.declareProperty(FloatArrayProperty(name="StartOverlaps", values=[]), doc="Overlap in Q.") self.declareProperty(FloatArrayProperty(name="EndOverlaps", values=[]), doc="End overlap in Q.") self.declareProperty(FloatArrayProperty(name="Params", validator=FloatArrayMandatoryValidator()), doc="Rebinning Parameters. See Rebin for format.") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SuggestTibCNCS.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SuggestTibCNCS.py index 85e4287622db..1bf6821e90bf 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SuggestTibCNCS.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SuggestTibCNCS.py @@ -35,10 +35,13 @@ def name(self): """ Return name """ return "SuggestTibCNCS" - + + def summary(self): + """ Return summary + """ + return "Suggest possible time independent background range for CNCS." + def PyInit(self): - self.setWikiSummary("Suggest possible time independent background range for CNCS.") - self.setOptionalMessage("Suggest possible time independent background range for CNCS.") """ Declare properties """ val=mantid.kernel.FloatBoundedValidator() diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SuggestTibHYSPEC.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SuggestTibHYSPEC.py index eec6a809b676..24947fc8e2fe 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SuggestTibHYSPEC.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/SuggestTibHYSPEC.py @@ -20,10 +20,13 @@ def name(self): """ Return name """ return "SuggestTibHYSPEC" - + + def summary(self): + """ Return summary + """ + return "Suggest possible time independent background range for HYSPEC" + def PyInit(self): - self.setWikiSummary("Suggest possible time independent background range for HYSPEC.") - self.setOptionalMessage("Suggest possible time independent background range for HYSPEC.") """ Declare properties """ val=mantid.kernel.FloatBoundedValidator() diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/TestWorkspaceGroupProperty.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/TestWorkspaceGroupProperty.py index b6e2c4a88cc7..5f47889d3cb0 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/TestWorkspaceGroupProperty.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/TestWorkspaceGroupProperty.py @@ -19,9 +19,10 @@ def category(self): def name(self): return "WorkspaceGroupProperty" + def summary(self): + return "Use only for testing" + def PyInit(self): - self.setWikiSummary("Use only for testing") - self.setOptionalMessage("Use only for testing") self.declareProperty(WorkspaceGroupProperty("InputWorkspace", "", Direction.Input), doc="Group workspace that automatically includes all members.") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace2", "", Direction.Input), doc="asd") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/USANSSimulation.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/USANSSimulation.py index 4f2b96b0737e..1c7373a0d620 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/USANSSimulation.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/USANSSimulation.py @@ -25,6 +25,9 @@ def category(self): def name(self): return "USANSSimulation" + def summary(self): + return "Simulate a USANS workspace" + def PyInit(self): self.declareProperty("TwoTheta", 0.01, "Scattering angle in degrees") self.declareProperty(FloatArrayProperty("WavelengthPeaks", values=[0.9, 1.2, 1.8, 3.6], diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/UpdatePeakParameterTableValue.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/UpdatePeakParameterTableValue.py index 293720c24500..a44d119d9943 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/UpdatePeakParameterTableValue.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/UpdatePeakParameterTableValue.py @@ -41,9 +41,10 @@ def name(self): """ return "UpdatePeakParameterTableValue" + def summary(self): + return "Update cell value(s) in a TableWorkspace containing instrument peak profile parameters." + def PyInit(self): - self.setWikiSummary("Update cell value(s) in a TableWorkspace containing instrument peak profile parameters.") - self.setOptionalMessage("Update cell value(s) in a TableWorkspace containing instrument peak profile parameters.") """ Property definition """ tableprop = mantid.api.ITableWorkspaceProperty("InputWorkspace", "", mantid.kernel.Direction.InOut) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ViewBOA.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ViewBOA.py index 8c703d48ee05..a82123b6c01d 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ViewBOA.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/ViewBOA.py @@ -19,9 +19,10 @@ class ViewBOA(PythonAlgorithm): def category(self): return 'PythonAlgorithms;SINQ' + def summary(self): + return "Load a BOA file and create the 3 BOA plots." + def PyInit(self): - self.setOptionalMessage("Load a BOA file and create the 3 BOA plots.") - self.setWikiSummary("Load a BOA file and create the 3 BOA plots.") now = datetime.datetime.now() self.declareProperty("Year",now.year,"Choose year",direction=Direction.Input) self.declareProperty('Numor',0,'Choose file number',direction=Direction.Input) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/DensityOfStates.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/DensityOfStates.py index f22bfe78b250..a945c0c72b58 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/DensityOfStates.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/DensityOfStates.py @@ -15,10 +15,11 @@ import math class DensityOfStates(PythonAlgorithm): - - def PyInit(self): - self.setWikiSummary("Calculates phonon densities of states, Raman and IR spectrum.") - + + def summary(self): + return "Calculates phonon densities of states, Raman and IR spectrum." + + def PyInit(self): #declare properties self.declareProperty(FileProperty('File', '', action=FileAction.Load, extensions = ["phonon", "castep"]), @@ -621,4 +622,4 @@ def _parse_castep_file(self, file_name): return frequencies, ir_intensities, raman_intensities, warray # Register algorithm with Mantid -AlgorithmFactory.subscribe(DensityOfStates) \ No newline at end of file +AlgorithmFactory.subscribe(DensityOfStates) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSAzimuthalAverage1D.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSAzimuthalAverage1D.py index 37fc7c55b0b0..18cdd767187b 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSAzimuthalAverage1D.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSAzimuthalAverage1D.py @@ -13,10 +13,11 @@ def category(self): def name(self): return 'EQSANSAzimuthalAverage1D' - + + def summary(self): + return "Compute I(q) for reduced EQSANS data" + def PyInit(self): - self.setOptionalMessage("Compute I(q) for reduced EQSANS data") - self.setWikiSummary("Compute I(q) for reduced EQSANS data") self.declareProperty(MatrixWorkspaceProperty('InputWorkspace', '', direction = Direction.Input)) self.declareProperty('NumberOfBins', 100, diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSDirectBeamTransmission.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSDirectBeamTransmission.py index 701e1d195bbb..511d858e9a95 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSDirectBeamTransmission.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSDirectBeamTransmission.py @@ -13,10 +13,11 @@ def category(self): def name(self): return 'EQSANSDirectBeamTransmission' - + + def summary(self): + return "Compute the transmission using the direct beam method on EQSANS" + def PyInit(self): - self.setOptionalMessage("Compute the transmission using the direct beam method on EQSANS") - self.setWikiSummary("Compute the transmission using the direct beam method on EQSANS") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", direction=Direction.Input)) self.declareProperty(FileProperty("SampleDataFilename", "", diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSNormalise.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSNormalise.py index 10ac8be9df39..6640964f3751 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSNormalise.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/EQSANSNormalise.py @@ -20,9 +20,10 @@ def category(self): def name(self): return "EQSANSNormalise" + def summary(self): + return "Normalise detector counts by accelerator current and beam spectrum" + def PyInit(self): - self.setOptionalMessage("Normalise detector counts by accelerator current and beam spectrum") - self.setWikiSummary("Normalise detector counts by accelerator current and beam spectrum") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", direction=Direction.Input)) self.declareProperty("NormaliseToBeam", True, diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/FuryFitMultiple.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/FuryFitMultiple.py index 72eaeddd35e4..d3b52df089fc 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/FuryFitMultiple.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/FuryFitMultiple.py @@ -15,8 +15,10 @@ class FuryFitMultiple(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" + def summary(self): + return "Fits and *_iqt file generated by Fury using one of the specified functions." + def PyInit(self): - self.setWikiSummary("Fits and *_iqt file generated by Fury using one of the specified functions.") self.declareProperty(name="InputType", defaultValue="File",validator=StringListValidator(['File', 'Workspace']), doc='Origin of data input - File (_red.nxs) or Workspace') self.declareProperty(name="Instrument", defaultValue="iris",validator=StringListValidator(['irs', 'iris', 'osi', 'osiris']), diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/HFIRSANSReduction.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/HFIRSANSReduction.py index 1af7f7ac79cd..c7c4b738fa15 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/HFIRSANSReduction.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/HFIRSANSReduction.py @@ -16,10 +16,11 @@ def category(self): def name(self): return "HFIRSANSReduction" - + + def summary(self): + return "HFIR SANS reduction workflow." + def PyInit(self): - self.setOptionalMessage("HFIR SANS reduction workflow") - self.setWikiSummary("HFIR SANS reduction workflow") self.declareProperty('Filename', '', doc='List of input file paths') self.declareProperty('ReductionProperties', '__sans_reduction_properties', validator=StringMandatoryValidator(), doc='Property manager name for the reduction') self.declareProperty('OutputWorkspace', '', doc='Reduced workspace') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/IndirectTransmission.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/IndirectTransmission.py index 7879092900f4..58220db3dd44 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/IndirectTransmission.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/IndirectTransmission.py @@ -16,6 +16,9 @@ class IndirectTransmission(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" + def summary(self): + return "Calculates the scattering & transmission for Indirect Geometry spectrometers." + def PyInit(self): self.declareProperty(name='Instrument',defaultValue='IRIS',validator=StringListValidator(['IRIS','OSIRIS']), doc='Instrument') self.declareProperty(name='Analyser',defaultValue='graphite',validator=StringListValidator(['graphite','fmica']), doc='Analyser') @@ -97,4 +100,4 @@ def PyExec(self): EndTime('IndirectTransmission') # Register algorithm with Mantid -AlgorithmFactory.subscribe(IndirectTransmission) \ No newline at end of file +AlgorithmFactory.subscribe(IndirectTransmission) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatData.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatData.py index b76d24c6aa67..1bc06aa78553 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatData.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatData.py @@ -17,10 +17,10 @@ class MuscatData(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def PyInit(self): - self.setOptionalMessage("Calculates multiple scattering using a sample S(Q,w)") - self.setWikiSummary("Calculates multiple scattering using a sample S(Q,w)") + def summary(self): + return "Calculates multiple scattering using a sample S(Q,w)." + def PyInit(self): self.declareProperty(name='Instrument',defaultValue='iris',validator=StringListValidator(['irs','iris','osi','osiris']), doc='Instrument') self.declareProperty(name='Analyser',defaultValue='graphite002',validator=StringListValidator(['graphite002','graphite004'])) self.declareProperty(name='Geom',defaultValue='Flat',validator=StringListValidator(['Flat','Cyl']), doc='Sample geometry') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatFunc.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatFunc.py index 8167993a979e..6842bd226c86 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatFunc.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatFunc.py @@ -17,10 +17,10 @@ class MuscatFunc(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def PyInit(self): - self.setOptionalMessage("Calculates multiple scattering using S(Q,w) from specified functions") - self.setWikiSummary("Calculates multiple scattering using S(Q,w) from specified functions") + def summary(self): + return "Calculates multiple scattering using S(Q,w) from specified functions." + def PyInit(self): self.declareProperty(name='Instrument',defaultValue='iris',validator=StringListValidator(['irs','iris','osi','osiris']), doc='Instrument') self.declareProperty(name='Analyser',defaultValue='graphite002',validator=StringListValidator(['graphite002','graphite004'])) self.declareProperty(name='Geom',defaultValue='Flat',validator=StringListValidator(['Flat','Cyl']), doc='') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/NormaliseByThickness.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/NormaliseByThickness.py index 154ae835585d..77b157fa5d4c 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/NormaliseByThickness.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/NormaliseByThickness.py @@ -19,9 +19,10 @@ def category(self): def name(self): return "NormaliseByThickness" + def summary(self): + return "Normalise detector counts by the sample thickness." + def PyInit(self): - self.setOptionalMessage("Normalise detector counts by the sample thickness") - self.setWikiSummary("Normalise detector counts by the sample thickness") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", direction=Direction.Input)) self.declareProperty(MatrixWorkspaceProperty("OutputWorkspace", "", diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/OSIRISDiffractionReduction.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/OSIRISDiffractionReduction.py index b71d8c4d6aeb..32ed81cfbb46 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/OSIRISDiffractionReduction.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/OSIRISDiffractionReduction.py @@ -156,11 +156,11 @@ class OSIRISDiffractionReduction(PythonAlgorithm): def category(self): return 'Diffraction;PythonAlgorithms' - def PyInit(self): - wiki="This Python algorithm performs the operations necessary for the reduction of diffraction data from the Osiris instrument at ISIS \ + def summary(self): + return "This Python algorithm performs the operations necessary for the reduction of diffraction data from the Osiris instrument at ISIS \ into dSpacing, by correcting for the monitor and linking the various d-ranges together." - - self.setWikiSummary(wiki) + + def PyInit(self): runs_desc='The list of run numbers that are part of the sample run. \ There should be five of these in most cases. Enter them as comma separated values.' self.declareProperty('Sample', '', doc=runs_desc) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/QLines.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/QLines.py index 8df3a5bcdd27..0f3331e88f4c 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/QLines.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/QLines.py @@ -24,9 +24,10 @@ class QLines(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def PyInit(self): - self.setWikiSummary("The program estimates the quasielastic components of each of the groups of spectra and requires the resolution file (.RES file) and optionally the normalisation file created by ResNorm.") + def summary(self): + return "The program estimates the quasielastic components of each of the groups of spectra and requires the resolution file (.RES file) and optionally the normalisation file created by ResNorm." + def PyInit(self): self.declareProperty(name='InputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of data input - File (*.nxs) or Workspace') self.declareProperty(name='Instrument',defaultValue='iris',validator=StringListValidator(['irs','iris','osi','osiris']), doc='Instrument') self.declareProperty(name='Analyser',defaultValue='graphite002',validator=StringListValidator(['graphite002','graphite004']), doc='Analyser & reflection') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Quest.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Quest.py index 72acdbb4a495..dddccefcd677 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Quest.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Quest.py @@ -17,9 +17,10 @@ class Quest(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def PyInit(self): - self.setWikiSummary("This is a variation of the stretched exponential option of Quasi.") + def summary(self): + return "This is a variation of the stretched exponential option of Quasi." + def PyInit(self): self.declareProperty(name='InputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of data input - File (*.nxs) or Workspace') self.declareProperty(name='Instrument',defaultValue='iris',validator=StringListValidator(['irs','iris','osi','osiris']), doc='Instrument') self.declareProperty(name='Analyser',defaultValue='graphite002',validator=StringListValidator(['graphite002','graphite004']), doc='Analyser & reflection') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/REFLReprocess.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/REFLReprocess.py index da3eb60e6f46..78368a60e765 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/REFLReprocess.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/REFLReprocess.py @@ -30,10 +30,10 @@ def category(self): def name(self): return "REFLReprocess" - def PyInit(self): - self.setOptionalMessage("Re-reduce REFL data for an entire experiment using saved parameters") - self.setWikiSummary("Re-reduce REFL data for an entire experiment using saved parameters") - + def summary(self): + return "Re-reduce REFL data for an entire experiment using saved parameters" + + def PyInit(self): self.declareProperty("IPTS", '0', "IPTS number to process") self.declareProperty(FileProperty(name="OutputDirectory",defaultValue="",action=FileAction.OptionalDirectory)) self.declareProperty("LoadProcessed", False, "If True, data will be loaded instead of being processed") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ReactorSANSResolution.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ReactorSANSResolution.py index 5b4ad8e0df88..2a03380e4ae9 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ReactorSANSResolution.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ReactorSANSResolution.py @@ -21,9 +21,10 @@ def category(self): def name(self): return "ReactorSANSResolution" + def summary(self): + return "Compute the resolution in Q according to Mildner-Carpenter" + def PyInit(self): - self.setOptionalMessage("Compute the resolution in Q according to Mildner-Carpenter") - self.setWikiSummary("Compute the resolution in Q according to Mildner-Carpenter") # Input workspace self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", direction=Direction.Input), diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ResNorm.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ResNorm.py index bab84f3b7182..86051c9cb1b6 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ResNorm.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ResNorm.py @@ -15,67 +15,68 @@ class ResNorm(PythonAlgorithm): - def category(self): - return "Workflow\\MIDAS;PythonAlgorithms" + def category(self): + return "Workflow\\MIDAS;PythonAlgorithms" - def PyInit(self): - self.setWikiSummary("This algorithm creates a group 'normalisation' file by taking a resolution file and fitting it to all the groups in the resolution (vanadium) data file which has the same grouping as the sample data of interest.") + def summary(self): + return "This algorithm creates a group 'normalisation' file by taking a resolution file and fitting it to all the groups in the resolution (vanadium) data file which has the same grouping as the sample data of interest." - self.declareProperty(name='InputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of data input - File (*.nxs) or Workspace') - self.declareProperty(name='Instrument',defaultValue='iris',validator=StringListValidator(['irs','iris','osi','osiris']), doc='Instrument') - self.declareProperty(name='Analyser',defaultValue='graphite002',validator=StringListValidator(['graphite002','graphite004']), doc='Analyser & reflection') - self.declareProperty(name='VanNumber',defaultValue='',validator=StringMandatoryValidator(), doc='Sample run number') - self.declareProperty(name='ResInputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of res input - File (*_res.nxs) or Workspace') - self.declareProperty(name='ResNumber',defaultValue='',validator=StringMandatoryValidator(), doc='Resolution run number') - self.declareProperty(name='EnergyMin', defaultValue=-0.2, doc='Minimum energy for fit. Default=-0.2') - self.declareProperty(name='EnergyMax', defaultValue=0.2, doc='Maximum energy for fit. Default=0.2') - self.declareProperty(name='VanBinning', defaultValue=1, doc='Binning value (integer) for sample. Default=1') - self.declareProperty(name='Plot',defaultValue='None',validator=StringListValidator(['None','Intensity','Stretch','Fit','All']), doc='Plot options') - self.declareProperty(name='Verbose',defaultValue=True, doc='Switch Verbose Off/On') - self.declareProperty(name='Save',defaultValue=False, doc='Switch Save result to nxs file Off/On') + def PyInit(self): + self.declareProperty(name='InputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of data input - File (*.nxs) or Workspace') + self.declareProperty(name='Instrument',defaultValue='iris',validator=StringListValidator(['irs','iris','osi','osiris']), doc='Instrument') + self.declareProperty(name='Analyser',defaultValue='graphite002',validator=StringListValidator(['graphite002','graphite004']), doc='Analyser & reflection') + self.declareProperty(name='VanNumber',defaultValue='',validator=StringMandatoryValidator(), doc='Sample run number') + self.declareProperty(name='ResInputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of res input - File (*_res.nxs) or Workspace') + self.declareProperty(name='ResNumber',defaultValue='',validator=StringMandatoryValidator(), doc='Resolution run number') + self.declareProperty(name='EnergyMin', defaultValue=-0.2, doc='Minimum energy for fit. Default=-0.2') + self.declareProperty(name='EnergyMax', defaultValue=0.2, doc='Maximum energy for fit. Default=0.2') + self.declareProperty(name='VanBinning', defaultValue=1, doc='Binning value (integer) for sample. Default=1') + self.declareProperty(name='Plot',defaultValue='None',validator=StringListValidator(['None','Intensity','Stretch','Fit','All']), doc='Plot options') + self.declareProperty(name='Verbose',defaultValue=True, doc='Switch Verbose Off/On') + self.declareProperty(name='Save',defaultValue=False, doc='Switch Save result to nxs file Off/On') - def PyExec(self): + def PyExec(self): from IndirectImport import run_f2py_compatibility_test, is_supported_f2py_platform if is_supported_f2py_platform(): import IndirectBayes as Main - run_f2py_compatibility_test() - - self.log().information('ResNorm input') - inType = self.getPropertyValue('InputType') - prefix = self.getPropertyValue('Instrument') - ana = self.getPropertyValue('Analyser') - van = self.getPropertyValue('VanNumber') - rinType = self.getPropertyValue('ResInputType') - res = self.getPropertyValue('ResNumber') - emin = self.getPropertyValue('EnergyMin') - emax = self.getPropertyValue('EnergyMax') - nbin = self.getPropertyValue('VanBinning') + run_f2py_compatibility_test() + + self.log().information('ResNorm input') + inType = self.getPropertyValue('InputType') + prefix = self.getPropertyValue('Instrument') + ana = self.getPropertyValue('Analyser') + van = self.getPropertyValue('VanNumber') + rinType = self.getPropertyValue('ResInputType') + res = self.getPropertyValue('ResNumber') + emin = self.getPropertyValue('EnergyMin') + emax = self.getPropertyValue('EnergyMax') + nbin = self.getPropertyValue('VanBinning') - vname = prefix+van+'_'+ana+ '_red' - rname = prefix+res+'_'+ana+ '_res' - erange = [float(emin), float(emax)] - verbOp = self.getProperty('Verbose').value - plotOp = self.getPropertyValue('Plot') - saveOp = self.getProperty('Save').value + vname = prefix+van+'_'+ana+ '_red' + rname = prefix+res+'_'+ana+ '_res' + erange = [float(emin), float(emax)] + verbOp = self.getProperty('Verbose').value + plotOp = self.getPropertyValue('Plot') + saveOp = self.getProperty('Save').value - workdir = config['defaultsave.directory'] - if inType == 'File': - vpath = os.path.join(workdir, vname+'.nxs') # path name for van nxs file - LoadNexusProcessed(Filename=vpath, OutputWorkspace=vname) - Vmessage = 'Vanadium from File : '+vpath - else: - Vmessage = 'Vanadium from Workspace : '+vname - if rinType == 'File': - rpath = os.path.join(workdir, rname+'.nxs') # path name for res nxs file - LoadNexusProcessed(Filename=rpath, OutputWorkspace=rname) - Rmessage = 'Resolution from File : '+rpath - else: - Rmessage = 'Resolution from Workspace : '+rname - if verbOp: - logger.notice(Vmessage) - logger.notice(Rmessage) - Main.ResNormRun(vname,rname,erange,nbin,verbOp,plotOp,saveOp) + workdir = config['defaultsave.directory'] + if inType == 'File': + vpath = os.path.join(workdir, vname+'.nxs') # path name for van nxs file + LoadNexusProcessed(Filename=vpath, OutputWorkspace=vname) + Vmessage = 'Vanadium from File : '+vpath + else: + Vmessage = 'Vanadium from Workspace : '+vname + if rinType == 'File': + rpath = os.path.join(workdir, rname+'.nxs') # path name for res nxs file + LoadNexusProcessed(Filename=rpath, OutputWorkspace=rname) + Rmessage = 'Resolution from File : '+rpath + else: + Rmessage = 'Resolution from Workspace : '+rname + if verbOp: + logger.notice(Vmessage) + logger.notice(Rmessage) + Main.ResNormRun(vname,rname,erange,nbin,verbOp,plotOp,saveOp) AlgorithmFactory.subscribe(ResNorm) # Register algorithm with Mantid diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSAbsoluteScale.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSAbsoluteScale.py index 0ae25c7eb269..41ea80c89f43 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSAbsoluteScale.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSAbsoluteScale.py @@ -21,9 +21,10 @@ def category(self): def name(self): return "SANSAbsoluteScale" + def summary(self): + return "Calculate and apply absolute scale correction for SANS data" + def PyInit(self): - self.setOptionalMessage("Calculate and apply absolute scale correction for SANS data") - self.setWikiSummary("Calculate and apply absolute scale correction for SANS data") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", direction=Direction.Input)) self.declareProperty(MatrixWorkspaceProperty("OutputWorkspace", "", diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSAzimuthalAverage1D.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSAzimuthalAverage1D.py index 0e0156a9fd09..10ace1c5377e 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSAzimuthalAverage1D.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSAzimuthalAverage1D.py @@ -12,10 +12,11 @@ def category(self): def name(self): return "SANSAzimuthalAverage1D" - + + def summary(self): + return "Compute I(q) for reduced SANS data" + def PyInit(self): - self.setOptionalMessage("Compute I(q) for reduced SANS data") - self.setWikiSummary("Compute I(q) for reduced SANS data") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", direction=Direction.Input)) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSBeamSpreaderTransmission.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSBeamSpreaderTransmission.py index 040b0ac4cf4e..21edcecd4d66 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSBeamSpreaderTransmission.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSBeamSpreaderTransmission.py @@ -15,10 +15,11 @@ def category(self): def name(self): return "SANSBeamSpreaderTransmission" - + + def summary(self): + return "Compute transmission using the beam spreader method" + def PyInit(self): - self.setOptionalMessage("Compute transmission using the beam spreader method") - self.setWikiSummary("Compute transmission using the beam spreader method") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", direction=Direction.Input)) self.declareProperty(FileProperty("SampleSpreaderFilename", "", diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSDirectBeamTransmission.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSDirectBeamTransmission.py index bdff030c266e..3e43f5d5cec8 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSDirectBeamTransmission.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSDirectBeamTransmission.py @@ -13,10 +13,11 @@ def category(self): def name(self): return "SANSDirectBeamTransmission" - + + def summary(self): + return "Compute transmission using the direct beam method" + def PyInit(self): - self.setOptionalMessage("Compute transmission using the direct beam method") - self.setWikiSummary("Compute transmission using the direct beam method") self.declareProperty(MatrixWorkspaceProperty("InputWorkspace", "", direction=Direction.Input)) self.declareProperty(FileProperty("SampleDataFilename", "", diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSMask.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSMask.py index de23e5261691..4c694680e50a 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSMask.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSMask.py @@ -22,6 +22,9 @@ def category(self): def name(self): return "SANSMask" + def summary(self): + return "Apply mask to SANS detector" + def PyInit(self): facilities = [ "SNS", "HFIR"] self.declareProperty("Facility", "SNS", diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSReduction.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSReduction.py index 3583b87a50d2..25d5ca0f3d90 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSReduction.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SANSReduction.py @@ -15,9 +15,10 @@ def category(self): def name(self): return 'SANSReduction' + def summary(self): + return "Basic SANS reduction workflow" + def PyInit(self): - self.setOptionalMessage("Basic SANS reduction workflow") - self.setWikiSummary("Basic SANS reduction workflow") self._py_init() def PyExec(self): diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SavePlot1D.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SavePlot1D.py index b57db7b80104..3d6eca7754c2 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SavePlot1D.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SavePlot1D.py @@ -21,12 +21,14 @@ def name(self): """ Algorithm name """ return "SavePlot1D" - + + def summary(self): + return "Save 1D plots to a file" + def checkGroups(self): return False def PyInit(self): - self.setWikiSummary("Save 1D plots to a file") #declare properties self.declareProperty(mantid.api.WorkspaceProperty("InputWorkspace","",mantid.kernel.Direction.Input),"Workspace to plot") self.declareProperty(mantid.api.FileProperty('OutputFilename', '', action=mantid.api.FileAction.Save, extensions = ["png"]), doc='Name of the image file to savefile.') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SofQWMoments.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SofQWMoments.py index 5f38ee345a27..b37d153944b6 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SofQWMoments.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SofQWMoments.py @@ -17,10 +17,10 @@ class SofQWMoments(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def PyInit(self): - self.setOptionalMessage("Calculates the nth moment of y(q,w)") - self.setWikiSummary("Calculates the nth moment of y(q,w)") + def summary (self): + return "Calculates the nth moment of y(q,w)" + def PyInit(self): self.declareProperty(MatrixWorkspaceProperty("Sample", "", Direction.Input), doc="Sample to use.") self.declareProperty(name='EnergyMin', defaultValue=-0.5, doc='Minimum energy for fit. Default=-0.5') self.declareProperty(name='EnergyMax', defaultValue=0.5, doc='Maximum energy for fit. Default=0.5') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Symmetrise.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Symmetrise.py index 8fc7432fad09..b54a81797b24 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Symmetrise.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Symmetrise.py @@ -14,10 +14,10 @@ class Symmetrise(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def PyInit(self): - self.setOptionalMessage("Takes and asymmetric S(Q,w) and makes it symmetric") - self.setWikiSummary("Takes and asymmetric S(Q,w) and makes it symmetric") + def summary (self): + return "Takes and asymmetric S(Q,w) and makes it symmetric" + def PyInit(self): self.declareProperty(name='InputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of data input - File (_red.nxs) or Workspace') self.declareProperty(name='Instrument',defaultValue='iris',validator=StringListValidator(['irs','iris','osi','osiris']), doc='Instrument') self.declareProperty(name='Analyser',defaultValue='graphite002',validator=StringListValidator(['graphite002','graphite004']), doc='Analyser & reflection') From 6ccacb4ca82c2b5f39a062ce1963b42fc59debb8 Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 17:35:57 +0100 Subject: [PATCH 099/126] Attempt to fix builds. Refs #9523. --- Code/Mantid/Build/wiki_tools.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/Build/wiki_tools.py b/Code/Mantid/Build/wiki_tools.py index 5856da14a31e..a4d57fe11149 100755 --- a/Code/Mantid/Build/wiki_tools.py +++ b/Code/Mantid/Build/wiki_tools.py @@ -121,7 +121,7 @@ def get_custom_wiki_section(algo, version, tag, tryUseDescriptionFromBinaries=Fa from mantid.api import AlgorithmManager alg = AlgorithmManager.createUnmanaged(algo, version) print "Getting algorithm description from binaries." - return alg.getWikiDescription() + return alg.summary() elif source == '' and not tryUseDescriptionFromBinaries: print "Warning: Cannot find source for algorithm" return desc From a960a458dd22823a162a7529fd682d97ccfcfc6b Mon Sep 17 00:00:00 2001 From: Jay Rainey Date: Thu, 29 May 2014 17:47:43 +0100 Subject: [PATCH 100/126] Attempt to fix build servers. Refs #9523. --- Code/Mantid/docs/qtassistant/algorithm_help.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/docs/qtassistant/algorithm_help.py b/Code/Mantid/docs/qtassistant/algorithm_help.py index 2ec16b41fcd0..180456485c03 100644 --- a/Code/Mantid/docs/qtassistant/algorithm_help.py +++ b/Code/Mantid/docs/qtassistant/algorithm_help.py @@ -115,7 +115,7 @@ def process_algorithm(name, versions, qhp, outputdir, fetchimages, **kwargs): # htmlfile.h3("Summary") #htmlfile.p(alg.getWikiSummary()) wiki = MediaWiki(htmlfile, HTML_DIR, latex=kwargs["latex"], dvipng=kwargs["dvipng"]) - wiki.parse(alg.getWikiSummary(), qhp) + wiki.parse(alg.summary(), qhp) htmlfile.h3("Usage") include_signature, custom_usage = wiki_tools.get_wiki_usage(name, version) From 1cf43a5bca70b1be02f81b1d293e81f100dd3d03 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 30 May 2014 09:57:38 +0100 Subject: [PATCH 101/126] Fix mediaiwiki parser for non-lists that have multiple stars in line Refs #9523 --- Code/Mantid/docs/qtassistant/mediawiki.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Code/Mantid/docs/qtassistant/mediawiki.py b/Code/Mantid/docs/qtassistant/mediawiki.py index f624bdc62fb0..9435fa555f54 100644 --- a/Code/Mantid/docs/qtassistant/mediawiki.py +++ b/Code/Mantid/docs/qtassistant/mediawiki.py @@ -150,11 +150,12 @@ def __fixUL(self, text): if text.find('*') < 0: return text # no candidates - # lines that start with '*' + # lines that start with a single '*' starts = [] text = text.split("\n") + for (i, line) in zip(range(len(text)), text): - if line.strip().startswith("*"): + if line.strip().startswith("*") and not line.strip().startswith("**"): starts.append(i) # none of the stars were at the start of a line From 0b5321c5052ac8f71382dd304b8c4c1122119490 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 30 May 2014 10:12:53 +0100 Subject: [PATCH 102/126] Fix indentation problems in PythonAlgorithms. Fixes warning messages about failing to load plugins. Refs #9523 --- .../WorkflowAlgorithms/DensityOfStates.py | 1026 ++++++++--------- .../IndirectTransmission.py | 4 +- .../WorkflowAlgorithms/MuscatData.py | 12 +- .../WorkflowAlgorithms/MuscatFunc.py | 10 +- .../algorithms/WorkflowAlgorithms/QLines.py | 4 +- .../algorithms/WorkflowAlgorithms/Quest.py | 12 +- .../algorithms/WorkflowAlgorithms/ResNorm.py | 6 +- .../WorkflowAlgorithms/SofQWMoments.py | 4 +- .../WorkflowAlgorithms/Symmetrise.py | 4 +- 9 files changed, 541 insertions(+), 541 deletions(-) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/DensityOfStates.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/DensityOfStates.py index a945c0c72b58..fc9887102b15 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/DensityOfStates.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/DensityOfStates.py @@ -16,610 +16,610 @@ class DensityOfStates(PythonAlgorithm): - def summary(self): - return "Calculates phonon densities of states, Raman and IR spectrum." - - def PyInit(self): - #declare properties - self.declareProperty(FileProperty('File', '', action=FileAction.Load, - extensions = ["phonon", "castep"]), - doc='Filename of the file.') - - self.declareProperty(name='Function',defaultValue='Gaussian', - validator=StringListValidator(['Gaussian', 'Lorentzian']), - doc="Type of function to fit to peaks.") - - self.declareProperty(name='PeakWidth', defaultValue=10.0, - doc='Set Gaussian/Lorentzian FWHM for broadening. Default is 10') - - self.declareProperty(name='SpectrumType',defaultValue='DOS', - validator=StringListValidator(['DOS', 'IR_Active', 'Raman_Active']), - doc="Type of intensities to extract and model (fundamentals-only) from .phonon.") - - self.declareProperty(name='Scale', defaultValue=1.0, - doc='Scale the intesity by the given factor. Default is no scaling.') - - self.declareProperty(name='BinWidth', defaultValue=1.0, - doc='Set histogram resolution for binning (eV or cm**-1). Default is 1') - - self.declareProperty(name='Temperature', defaultValue=300, - doc='Temperature to use (in raman spectrum modelling). Default is 300') - - self.declareProperty(name='ZeroThreshold', defaultValue=3.0, - doc='Ignore frequencies below the this threshold. Default is 3.0') - - self.declareProperty(StringArrayProperty('Ions', Direction.Input), - doc="List of Ions to use to calculate partial density of states. If left blank, total density of states will be calculated") - - self.declareProperty(name='SumContributions', defaultValue=False, - doc="Sum the partial density of states into a single workspace.") - - self.declareProperty(WorkspaceProperty('OutputWorkspace', '', Direction.Output), - doc="Name to give the output workspace.") - - #regex pattern for a floating point number - self._float_regex = '\-?(?:\d+\.?\d*|\d*\.?\d+)' + def summary(self): + return "Calculates phonon densities of states, Raman and IR spectrum." + + def PyInit(self): + #declare properties + self.declareProperty(FileProperty('File', '', action=FileAction.Load, + extensions = ["phonon", "castep"]), + doc='Filename of the file.') + + self.declareProperty(name='Function',defaultValue='Gaussian', + validator=StringListValidator(['Gaussian', 'Lorentzian']), + doc="Type of function to fit to peaks.") + + self.declareProperty(name='PeakWidth', defaultValue=10.0, + doc='Set Gaussian/Lorentzian FWHM for broadening. Default is 10') + + self.declareProperty(name='SpectrumType',defaultValue='DOS', + validator=StringListValidator(['DOS', 'IR_Active', 'Raman_Active']), + doc="Type of intensities to extract and model (fundamentals-only) from .phonon.") + + self.declareProperty(name='Scale', defaultValue=1.0, + doc='Scale the intesity by the given factor. Default is no scaling.') + + self.declareProperty(name='BinWidth', defaultValue=1.0, + doc='Set histogram resolution for binning (eV or cm**-1). Default is 1') + + self.declareProperty(name='Temperature', defaultValue=300, + doc='Temperature to use (in raman spectrum modelling). Default is 300') + + self.declareProperty(name='ZeroThreshold', defaultValue=3.0, + doc='Ignore frequencies below the this threshold. Default is 3.0') + + self.declareProperty(StringArrayProperty('Ions', Direction.Input), + doc="List of Ions to use to calculate partial density of states. If left blank, total density of states will be calculated") + + self.declareProperty(name='SumContributions', defaultValue=False, + doc="Sum the partial density of states into a single workspace.") + + self.declareProperty(WorkspaceProperty('OutputWorkspace', '', Direction.Output), + doc="Name to give the output workspace.") + + #regex pattern for a floating point number + self._float_regex = '\-?(?:\d+\.?\d*|\d*\.?\d+)' #---------------------------------------------------------------------------------------- - def PyExec(self): - # Run the algorithm - self._get_properties() - - file_name = self.getPropertyValue('File') - file_data = self._read_data_from_file(file_name) - frequencies, ir_intensities, raman_intensities, weights = file_data[:4] - - prog_reporter = Progress(self,0.0,1.0,1) - if self._calc_partial: - eigenvectors = file_data[4] - prog_reporter.report("Calculating partial density of states") - - if self._sum_contributions: - #sum each of the contributions - self._compute_partial(self._partial_ion_numbers, frequencies, eigenvectors, weights) - mtd[self._ws_name].setYUnit('(D/A)^2/amu') - mtd[self._ws_name].setYUnitLabel('Intensity') - else: - #output each contribution to it's own workspace - partial_workspaces = [] - for ion_name, ions in self._ion_dict.items(): - self._compute_partial(ions, frequencies, eigenvectors, weights) - mtd[self._ws_name].setYUnit('(D/A)^2/amu') - mtd[self._ws_name].setYUnitLabel('Intensity') - - partial_ws_name = self._ws_name + '_' + ion_name - partial_workspaces.append(partial_ws_name) - RenameWorkspace(self._ws_name, OutputWorkspace=partial_ws_name) - - group = ','.join(partial_workspaces) - GroupWorkspaces(group, OutputWorkspace=self._ws_name) - - elif self._spec_type == 'DOS': - prog_reporter.report("Calculating density of states") - self._compute_DOS(frequencies, np.ones_like(frequencies), weights) - mtd[self._ws_name].setYUnit('(D/A)^2/amu') - mtd[self._ws_name].setYUnitLabel('Intensity') - - elif self._spec_type == 'IR_Active': - if ir_intensities.size == 0: - raise ValueError("Could not load any IR intensities from file.") - - prog_reporter.report("Calculating IR intensities") - self._compute_DOS(frequencies, ir_intensities, weights) + def PyExec(self): + # Run the algorithm + self._get_properties() + + file_name = self.getPropertyValue('File') + file_data = self._read_data_from_file(file_name) + frequencies, ir_intensities, raman_intensities, weights = file_data[:4] + + prog_reporter = Progress(self,0.0,1.0,1) + if self._calc_partial: + eigenvectors = file_data[4] + prog_reporter.report("Calculating partial density of states") + + if self._sum_contributions: + #sum each of the contributions + self._compute_partial(self._partial_ion_numbers, frequencies, eigenvectors, weights) mtd[self._ws_name].setYUnit('(D/A)^2/amu') mtd[self._ws_name].setYUnitLabel('Intensity') + else: + #output each contribution to it's own workspace + partial_workspaces = [] + for ion_name, ions in self._ion_dict.items(): + self._compute_partial(ions, frequencies, eigenvectors, weights) + mtd[self._ws_name].setYUnit('(D/A)^2/amu') + mtd[self._ws_name].setYUnitLabel('Intensity') + + partial_ws_name = self._ws_name + '_' + ion_name + partial_workspaces.append(partial_ws_name) + RenameWorkspace(self._ws_name, OutputWorkspace=partial_ws_name) + + group = ','.join(partial_workspaces) + GroupWorkspaces(group, OutputWorkspace=self._ws_name) + + elif self._spec_type == 'DOS': + prog_reporter.report("Calculating density of states") + self._compute_DOS(frequencies, np.ones_like(frequencies), weights) + mtd[self._ws_name].setYUnit('(D/A)^2/amu') + mtd[self._ws_name].setYUnitLabel('Intensity') + + elif self._spec_type == 'IR_Active': + if ir_intensities.size == 0: + raise ValueError("Could not load any IR intensities from file.") + + prog_reporter.report("Calculating IR intensities") + self._compute_DOS(frequencies, ir_intensities, weights) + mtd[self._ws_name].setYUnit('(D/A)^2/amu') + mtd[self._ws_name].setYUnitLabel('Intensity') - elif self._spec_type == 'Raman_Active': - if raman_intensities.size == 0: - raise ValueError("Could not load any Raman intensities from file.") + elif self._spec_type == 'Raman_Active': + if raman_intensities.size == 0: + raise ValueError("Could not load any Raman intensities from file.") - prog_reporter.report("Calculating Raman intensities") - self._compute_raman(frequencies, raman_intensities, weights) - mtd[self._ws_name].setYUnit('A^4') - mtd[self._ws_name].setYUnitLabel('Intensity') + prog_reporter.report("Calculating Raman intensities") + self._compute_raman(frequencies, raman_intensities, weights) + mtd[self._ws_name].setYUnit('A^4') + mtd[self._ws_name].setYUnitLabel('Intensity') - self.setProperty("OutputWorkspace", self._ws_name) + self.setProperty("OutputWorkspace", self._ws_name) #---------------------------------------------------------------------------------------- - def _get_properties(self): - """ - Set the properties passed to the algorithm - """ - self._temperature = self.getProperty('Temperature').value - self._bin_width = self.getProperty('BinWidth').value - self._spec_type = self.getPropertyValue('SpectrumType') - self._peak_func = self.getPropertyValue('Function') - self._ws_name = self.getPropertyValue('OutputWorkspace') - self._peak_width = self.getProperty('PeakWidth').value - self._scale = self.getProperty('Scale').value - self._zero_threshold = self.getProperty('ZeroThreshold').value - self._ions = self.getProperty('Ions').value - self._sum_contributions = self.getProperty('SumContributions').value - self._calc_partial = (len(self._ions) > 0) + def _get_properties(self): + """ + Set the properties passed to the algorithm + """ + self._temperature = self.getProperty('Temperature').value + self._bin_width = self.getProperty('BinWidth').value + self._spec_type = self.getPropertyValue('SpectrumType') + self._peak_func = self.getPropertyValue('Function') + self._ws_name = self.getPropertyValue('OutputWorkspace') + self._peak_width = self.getProperty('PeakWidth').value + self._scale = self.getProperty('Scale').value + self._zero_threshold = self.getProperty('ZeroThreshold').value + self._ions = self.getProperty('Ions').value + self._sum_contributions = self.getProperty('SumContributions').value + self._calc_partial = (len(self._ions) > 0) #---------------------------------------------------------------------------------------- - def _draw_peaks(self, hist, peaks): - """ - Draw Gaussian or Lorentzian peaks to each point in the data + def _draw_peaks(self, hist, peaks): + """ + Draw Gaussian or Lorentzian peaks to each point in the data - @param hist - array of counts for each bin - @param peaks - the indicies of each non-zero point in the data - @return the fitted y data - """ - if self._peak_func == "Gaussian": - n_gauss = int( 3.0* self._peak_width / self._bin_width ) - sigma = self._peak_width / 2.354 + @param hist - array of counts for each bin + @param peaks - the indicies of each non-zero point in the data + @return the fitted y data + """ + if self._peak_func == "Gaussian": + n_gauss = int( 3.0* self._peak_width / self._bin_width ) + sigma = self._peak_width / 2.354 - dos = np.zeros(len(hist)-1 + n_gauss) + dos = np.zeros(len(hist)-1 + n_gauss) - for index in peaks: - for g in range(-n_gauss, n_gauss): - if index + g > 0: - dos[index+g] += hist[index] * math.exp( - (g * self._bin_width)**2 / (2 * sigma **2)) / (math.sqrt(2*math.pi) * sigma) - - elif self._peak_func == "Lorentzian": - - n_lorentz = int( 25.0 * self._peak_width / self._bin_width ) - gamma_by_2 = self._peak_width / 2 + for index in peaks: + for g in range(-n_gauss, n_gauss): + if index + g > 0: + dos[index+g] += hist[index] * math.exp( - (g * self._bin_width)**2 / (2 * sigma **2)) / (math.sqrt(2*math.pi) * sigma) + + elif self._peak_func == "Lorentzian": + + n_lorentz = int( 25.0 * self._peak_width / self._bin_width ) + gamma_by_2 = self._peak_width / 2 - dos = np.zeros(len(hist)-1 + n_lorentz) - - for index in peaks: - for l in range(-n_lorentz, n_lorentz): - if index + l > 0: - dos[index+l] += hist[index] * gamma_by_2 / ( l ** 2 + gamma_by_2 **2 ) / math.pi - - return dos + dos = np.zeros(len(hist)-1 + n_lorentz) + + for index in peaks: + for l in range(-n_lorentz, n_lorentz): + if index + l > 0: + dos[index+l] += hist[index] * gamma_by_2 / ( l ** 2 + gamma_by_2 **2 ) / math.pi + + return dos #---------------------------------------------------------------------------------------- - def _compute_partial(self, ion_numbers, frequencies, eigenvectors, weights): - """ - Compute partial Density Of States. + def _compute_partial(self, ion_numbers, frequencies, eigenvectors, weights): + """ + Compute partial Density Of States. + + This uses the eigenvectors in a .phonon file to calculate + the partial density of states. + + @param frequencies - frequencies read from file + @param eigenvectors - eigenvectors read from file + @param weights - weights for each frequency block + """ + + intensities = [] + for block_vectors in eigenvectors: + block_intensities = [] + for mode in xrange(self._num_branches): + #only select vectors for the ions we're interested in + lower, upper = mode*self._num_ions, (mode+1)*self._num_ions + vectors = block_vectors[lower:upper] + vectors = vectors[ion_numbers] + + #compute intensity + exponent = np.empty(vectors.shape) + exponent.fill(2) + vectors = np.power(vectors, exponent) + total = np.sum(vectors) + + block_intensities.append(total) - This uses the eigenvectors in a .phonon file to calculate - the partial density of states. + intensities += block_intensities + + intensities = np.asarray(intensities) + self._compute_DOS(frequencies, intensities, weights) - @param frequencies - frequencies read from file - @param eigenvectors - eigenvectors read from file - @param weights - weights for each frequency block - """ - intensities = [] - for block_vectors in eigenvectors: - block_intensities = [] - for mode in xrange(self._num_branches): - #only select vectors for the ions we're interested in - lower, upper = mode*self._num_ions, (mode+1)*self._num_ions - vectors = block_vectors[lower:upper] - vectors = vectors[ion_numbers] - - #compute intensity - exponent = np.empty(vectors.shape) - exponent.fill(2) - vectors = np.power(vectors, exponent) - total = np.sum(vectors) - - block_intensities.append(total) +#---------------------------------------------------------------------------------------- - intensities += block_intensities + def _compute_DOS(self, frequencies, intensities, weights): + """ + Compute Density Of States + + @param frequencies - frequencies read from file + @param intensities - intensities read from file + @param weights - weights for each frequency block + """ + if ( frequencies.size > intensities.size ): + #if we have less intensities than frequencies fill the difference with ones. + diff = frequencies.size-intensities.size + intensities = np.concatenate((intensities, np.ones(diff))) + + if ( frequencies.size != weights.size or frequencies.size != intensities.size ): + raise ValueError("Number of data points must match!") + + #ignore values below fzerotol + zero_mask = np.where(np.absolute(frequencies) < self._zero_threshold) + intensities[zero_mask] = 0.0 - intensities = np.asarray(intensities) - self._compute_DOS(frequencies, intensities, weights) + #sort data to follow natural ordering + permutation = frequencies.argsort() + frequencies = frequencies[permutation] + intensities = intensities[permutation] + weights = weights[permutation] + + #weight intensities + intensities = intensities * weights + + #create histogram x data + xmin, xmax = frequencies[0], frequencies[-1]+self._bin_width + bins = np.arange(xmin, xmax, self._bin_width) + + #sum values in each bin + hist = np.zeros(bins.size) + for index, (lower, upper) in enumerate(zip(bins, bins[1:])): + binMask = np.where((frequencies >= lower) & (frequencies < upper)) + hist[index] = intensities[binMask].sum() + + #find and fit peaks + peaks = hist.nonzero()[0] + dos = self._draw_peaks(hist, peaks) + + data_x = np.arange(xmin, xmin+dos.size) + CreateWorkspace(DataX=data_x, DataY=dos, OutputWorkspace=self._ws_name) + unitx = mtd[self._ws_name].getAxis(0).setUnit("Label") + unitx.setLabel("Energy Shift", 'cm^-1') + + if self._scale != 1: + Scale(InputWorkspace=self._ws_name, OutputWorkspace=self._ws_name, Factor=self._scale) + +#---------------------------------------------------------------------------------------- + def _compute_raman(self, frequencies, intensities, weights): + """ + Compute Raman intensities + + @param frequencies - frequencies read from file + @param intensities - raman intensities read from file + @param weights - weights for each frequency block + """ + #we only want to use the first set + frequencies = frequencies[:self._num_branches] + intensities = intensities[:self._num_branches] + weights = weights[:self._num_branches] + + #speed of light in vaccum in m/s + c = scipy.constants.c + #wavelength of the laser + laser_wavelength = 514.5e-9 + #planck's constant + planck = scipy.constants.h + # cm(-1) => K conversion + cm1_to_K = scipy.constants.codata.value('inverse meter-kelvin relationship')*100 + + factor = (math.pow((2*math.pi / laser_wavelength), 4) * planck) / (8 * math.pi**2 * 45) * 1e12 + x_sections = np.zeros(frequencies.size) + + #use only the first set of frequencies and ignore small values + zero_mask = np.where( frequencies > self._zero_threshold ) + frequency_x_sections = frequencies[zero_mask] + intensity_x_sections = intensities[zero_mask] + + bose_occ = 1.0 / ( np.exp(cm1_to_K * frequency_x_sections / self._temperature) -1) + x_sections[zero_mask] = factor / frequency_x_sections * (1 + bose_occ) * intensity_x_sections + + self._compute_DOS(frequencies, x_sections, weights) #---------------------------------------------------------------------------------------- - def _compute_DOS(self, frequencies, intensities, weights): - """ - Compute Density Of States + def _read_data_from_file(self, file_name): + """ + Select the appropriate file parser and check data was successfully + loaded from file. - @param frequencies - frequencies read from file - @param intensities - intensities read from file - @param weights - weights for each frequency block - """ - if ( frequencies.size > intensities.size ): - #if we have less intensities than frequencies fill the difference with ones. - diff = frequencies.size-intensities.size - intensities = np.concatenate((intensities, np.ones(diff))) - - if ( frequencies.size != weights.size or frequencies.size != intensities.size ): - raise ValueError("Number of data points must match!") + @param file_name - path to the file. + @return tuple of the frequencies, ir and raman intensities and weights + """ + ext = os.path.splitext(file_name)[1] - #ignore values below fzerotol - zero_mask = np.where(np.absolute(frequencies) < self._zero_threshold) - intensities[zero_mask] = 0.0 - - #sort data to follow natural ordering - permutation = frequencies.argsort() - frequencies = frequencies[permutation] - intensities = intensities[permutation] - weights = weights[permutation] - - #weight intensities - intensities = intensities * weights - - #create histogram x data - xmin, xmax = frequencies[0], frequencies[-1]+self._bin_width - bins = np.arange(xmin, xmax, self._bin_width) + if ext == '.phonon': + file_data = self._parse_phonon_file(file_name) + elif ext == '.castep': + if len(self._ions) > 0: + raise ValueError("Cannot compute partial density of states from .castep files.") - #sum values in each bin - hist = np.zeros(bins.size) - for index, (lower, upper) in enumerate(zip(bins, bins[1:])): - binMask = np.where((frequencies >= lower) & (frequencies < upper)) - hist[index] = intensities[binMask].sum() + file_data = self._parse_castep_file(file_name) - #find and fit peaks - peaks = hist.nonzero()[0] - dos = self._draw_peaks(hist, peaks) + frequencies = file_data[0] - data_x = np.arange(xmin, xmin+dos.size) - CreateWorkspace(DataX=data_x, DataY=dos, OutputWorkspace=self._ws_name) - unitx = mtd[self._ws_name].getAxis(0).setUnit("Label") - unitx.setLabel("Energy Shift", 'cm^-1') + if ( frequencies.size == 0 ): + raise ValueError("Failed to load any frequencies from file.") - if self._scale != 1: - Scale(InputWorkspace=self._ws_name, OutputWorkspace=self._ws_name, Factor=self._scale) + return file_data #---------------------------------------------------------------------------------------- - def _compute_raman(self, frequencies, intensities, weights): - """ - Compute Raman intensities + def _parse_block_header(self, header_match, block_count): + """ + Parse the header of a block of frequencies and intensities - @param frequencies - frequencies read from file - @param intensities - raman intensities read from file - @param weights - weights for each frequency block - """ - #we only want to use the first set - frequencies = frequencies[:self._num_branches] - intensities = intensities[:self._num_branches] - weights = weights[:self._num_branches] - - #speed of light in vaccum in m/s - c = scipy.constants.c - #wavelength of the laser - laser_wavelength = 514.5e-9 - #planck's constant - planck = scipy.constants.h - # cm(-1) => K conversion - cm1_to_K = scipy.constants.codata.value('inverse meter-kelvin relationship')*100 - - factor = (math.pow((2*math.pi / laser_wavelength), 4) * planck) / (8 * math.pi**2 * 45) * 1e12 - x_sections = np.zeros(frequencies.size) - - #use only the first set of frequencies and ignore small values - zero_mask = np.where( frequencies > self._zero_threshold ) - frequency_x_sections = frequencies[zero_mask] - intensity_x_sections = intensities[zero_mask] - - bose_occ = 1.0 / ( np.exp(cm1_to_K * frequency_x_sections / self._temperature) -1) - x_sections[zero_mask] = factor / frequency_x_sections * (1 + bose_occ) * intensity_x_sections - - self._compute_DOS(frequencies, x_sections, weights) + @param header_match - the regex match to the header + @param block_count - the count of blocks found so far + @return weight for this block of values + """ + #found header block at start of frequencies + q1, q2, q3, weight = map(float, header_match.groups()) + if block_count > 1 and sum([q1,q2,q3]) == 0: + weight = 0.0 + return weight #---------------------------------------------------------------------------------------- - def _read_data_from_file(self, file_name): - """ - Select the appropriate file parser and check data was successfully - loaded from file. - - @param file_name - path to the file. - @return tuple of the frequencies, ir and raman intensities and weights - """ - ext = os.path.splitext(file_name)[1] + def _parse_phonon_file_header(self, f_handle): + """ + Read information from the header of a <>.phonon file + + @param f_handle - handle to the file. + @return tuple of the number of ions and branches in the file + """ + while True: + line = f_handle.readline() + + if not line: + raise IOError("Could not find any header information.") + + if 'Number of ions' in line: + self._num_ions = int(line.strip().split()[-1]) + elif 'Number of branches' in line: + self._num_branches = int(line.strip().split()[-1]) + elif self._calc_partial and 'Fractional Co-ordinates' in line: + #we're calculating partial density of states + self._ion_dict = dict( (ion, []) for ion in self._ions) + + if self._num_ions == None: + raise IOError("Failed to parse file. Invalid file header.") - if ext == '.phonon': - file_data = self._parse_phonon_file(file_name) - elif ext == '.castep': - if len(self._ions) > 0: - raise ValueError("Cannot compute partial density of states from .castep files.") + #extract the mode number for each of the ions we're interested in + for _ in xrange(self._num_ions): + line = f_handle.readline() + line_data = line.strip().split() + ion = line_data[4] + + if ion in self._ions: + mode = int(line_data[0])-1 #-1 to convert to zero based indexing + self._ion_dict[ion].append(mode) - file_data = self._parse_castep_file(file_name) + self._partial_ion_numbers = [] + for ion, ion_nums in self._ion_dict.items(): + if len(ion_nums) == 0: + logger.warning("Could not find any ions of type %s" % ion) + self._partial_ion_numbers += ion_nums - frequencies = file_data[0] + self._partial_ion_numbers = sorted(self._partial_ion_numbers) + self._partial_ion_numbers = np.asarray(self._partial_ion_numbers) - if ( frequencies.size == 0 ): - raise ValueError("Failed to load any frequencies from file.") + if self._partial_ion_numbers.size == 0: + raise ValueError("Could not find any of the specified ions") - return file_data + if 'END header' in line: + if self._num_ions == None or self._num_branches == None: + raise IOError("Failed to parse file. Invalid file header.") + return #---------------------------------------------------------------------------------------- - def _parse_block_header(self, header_match, block_count): - """ - Parse the header of a block of frequencies and intensities - - @param header_match - the regex match to the header - @param block_count - the count of blocks found so far - @return weight for this block of values + def _parse_phonon_freq_block(self, f_handle): """ - #found header block at start of frequencies - q1, q2, q3, weight = map(float, header_match.groups()) - if block_count > 1 and sum([q1,q2,q3]) == 0: - weight = 0.0 - return weight - -#---------------------------------------------------------------------------------------- - - def _parse_phonon_file_header(self, f_handle): - """ - Read information from the header of a <>.phonon file + Iterator to parse a block of frequencies from a .phonon file. @param f_handle - handle to the file. - @return tuple of the number of ions and branches in the file """ - while True: + prog_reporter = Progress(self,0.0,1.0,1) + for _ in xrange( self._num_branches): line = f_handle.readline() + line_data = line.strip().split()[1:] + line_data = map(float, line_data) + yield line_data + + prog_reporter.report("Reading frequencies.") - if not line: - raise IOError("Could not find any header information.") +#---------------------------------------------------------------------------------------- + def _parse_phonon_eigenvectors(self, f_handle): + vectors = [] + prog_reporter = Progress(self,0.0,1.0,self._num_branches*self._num_ions) + for _ in xrange(self._num_ions*self._num_branches): + line = f_handle.readline() + + if not line: + raise IOError("Could not parse file. Invalid file format.") + + line_data = line.strip().split() + vector_componets = line_data[2::2] + vector_componets = map(float, vector_componets) + vectors.append(vector_componets) + prog_reporter.report("Reading eigenvectors.") - if 'Number of ions' in line: - self._num_ions = int(line.strip().split()[-1]) - elif 'Number of branches' in line: - self._num_branches = int(line.strip().split()[-1]) - elif self._calc_partial and 'Fractional Co-ordinates' in line: - #we're calculating partial density of states - self._ion_dict = dict( (ion, []) for ion in self._ions) - - if self._num_ions == None: - raise IOError("Failed to parse file. Invalid file header.") - - #extract the mode number for each of the ions we're interested in - for _ in xrange(self._num_ions): - line = f_handle.readline() - line_data = line.strip().split() - ion = line_data[4] - - if ion in self._ions: - mode = int(line_data[0])-1 #-1 to convert to zero based indexing - self._ion_dict[ion].append(mode) - - self._partial_ion_numbers = [] - for ion, ion_nums in self._ion_dict.items(): - if len(ion_nums) == 0: - logger.warning("Could not find any ions of type %s" % ion) - self._partial_ion_numbers += ion_nums - - self._partial_ion_numbers = sorted(self._partial_ion_numbers) - self._partial_ion_numbers = np.asarray(self._partial_ion_numbers) - - if self._partial_ion_numbers.size == 0: - raise ValueError("Could not find any of the specified ions") - - if 'END header' in line: - if self._num_ions == None or self._num_branches == None: - raise IOError("Failed to parse file. Invalid file header.") - return + return np.asarray(vectors) #---------------------------------------------------------------------------------------- - def _parse_phonon_freq_block(self, f_handle): - """ - Iterator to parse a block of frequencies from a .phonon file. + def _parse_phonon_file(self, file_name): + """ + Read frequencies from a <>.phonon file - @param f_handle - handle to the file. - """ - prog_reporter = Progress(self,0.0,1.0,1) - for _ in xrange( self._num_branches): - line = f_handle.readline() - line_data = line.strip().split()[1:] - line_data = map(float, line_data) - yield line_data - - prog_reporter.report("Reading frequencies.") + @param file_name - file path of the file to read + @return the frequencies, infra red and raman intensities and weights of frequency blocks + """ + #Header regex. Looks for lines in the following format: + # q-pt= 1 0.000000 0.000000 0.000000 1.0000000000 0.000000 0.000000 1.000000 + header_regex_str = r"^ +q-pt=\s+\d+ +(%(s)s) +(%(s)s) +(%(s)s) (?: *(%(s)s)){0,4}" % {'s': self._float_regex} + header_regex = re.compile(header_regex_str) -#---------------------------------------------------------------------------------------- - def _parse_phonon_eigenvectors(self, f_handle): - vectors = [] - prog_reporter = Progress(self,0.0,1.0,self._num_branches*self._num_ions) - for _ in xrange(self._num_ions*self._num_branches): + eigenvectors_regex = re.compile(r"\s*Mode\s+Ion\s+X\s+Y\s+Z\s*") + block_count = 0 + + frequencies, ir_intensities, raman_intensities, weights = [], [], [], [] + eigenvectors = [] + data_lists = (frequencies, ir_intensities, raman_intensities) + with open(file_name, 'rU') as f_handle: + self._parse_phonon_file_header(f_handle) + + while True: line = f_handle.readline() - - if not line: - raise IOError("Could not parse file. Invalid file format.") - - line_data = line.strip().split() - vector_componets = line_data[2::2] - vector_componets = map(float, vector_componets) - vectors.append(vector_componets) - prog_reporter.report("Reading eigenvectors.") + #check we've reached the end of file + if not line: break + + #check if we've found a block of frequencies + header_match = header_regex.match(line) + if header_match: + block_count += 1 - return np.asarray(vectors) + weight = self._parse_block_header(header_match, block_count) + weights.append(weight) + + #parse block of frequencies + for line_data in self._parse_phonon_freq_block(f_handle): + for data_list, item in zip(data_lists, line_data): + data_list.append(item) + + vector_match = eigenvectors_regex.match(line) + if vector_match: + if self._calc_partial: + #parse eigenvectors for partial dos + vectors = self._parse_phonon_eigenvectors(f_handle) + eigenvectors.append(vectors) + else: + #skip over eigenvectors + for _ in xrange(self._num_ions*self._num_branches): + line = f_handle.readline() + if not line: + raise IOError("Bad file format. Uexpectedly reached end of file.") + + frequencies = np.asarray(frequencies) + ir_intensities = np.asarray(ir_intensities) + eigenvectors = np.asarray(eigenvectors) + raman_intensities = np.asarray(raman_intensities) + warray = np.repeat(weights, self._num_branches) + + return frequencies, ir_intensities, raman_intensities, warray, eigenvectors #---------------------------------------------------------------------------------------- - def _parse_phonon_file(self, file_name): - """ - Read frequencies from a <>.phonon file + def _parse_castep_file_header(self, f_handle): + """ + Read information from the header of a <>.castep file - @param file_name - file path of the file to read - @return the frequencies, infra red and raman intensities and weights of frequency blocks - """ - #Header regex. Looks for lines in the following format: - # q-pt= 1 0.000000 0.000000 0.000000 1.0000000000 0.000000 0.000000 1.000000 - header_regex_str = r"^ +q-pt=\s+\d+ +(%(s)s) +(%(s)s) +(%(s)s) (?: *(%(s)s)){0,4}" % {'s': self._float_regex} - header_regex = re.compile(header_regex_str) + @param f_handle - handle to the file. + @return tuple of the number of ions and branches in the file + """ + num_species, self._num_ions = 0,0 + while True: + line = f_handle.readline() - eigenvectors_regex = re.compile(r"\s*Mode\s+Ion\s+X\s+Y\s+Z\s*") - block_count = 0 + if not line: + raise IOError("Could not find any header information.") - frequencies, ir_intensities, raman_intensities, weights = [], [], [], [] - eigenvectors = [] - data_lists = (frequencies, ir_intensities, raman_intensities) - with open(file_name, 'rU') as f_handle: - self._parse_phonon_file_header(f_handle) + if 'Total number of ions in cell =' in line: + self._num_ions = int(line.strip().split()[-1]) + elif 'Total number of species in cell = ' in line: + num_species = int(line.strip().split()[-1]) - while True: - line = f_handle.readline() - #check we've reached the end of file - if not line: break - - #check if we've found a block of frequencies - header_match = header_regex.match(line) - if header_match: - block_count += 1 - - weight = self._parse_block_header(header_match, block_count) - weights.append(weight) - - #parse block of frequencies - for line_data in self._parse_phonon_freq_block(f_handle): - for data_list, item in zip(data_lists, line_data): - data_list.append(item) - - vector_match = eigenvectors_regex.match(line) - if vector_match: - if self._calc_partial: - #parse eigenvectors for partial dos - vectors = self._parse_phonon_eigenvectors(f_handle) - eigenvectors.append(vectors) - else: - #skip over eigenvectors - for _ in xrange(self._num_ions*self._num_branches): - line = f_handle.readline() - if not line: - raise IOError("Bad file format. Uexpectedly reached end of file.") - - frequencies = np.asarray(frequencies) - ir_intensities = np.asarray(ir_intensities) - eigenvectors = np.asarray(eigenvectors) - raman_intensities = np.asarray(raman_intensities) - warray = np.repeat(weights, self._num_branches) - - return frequencies, ir_intensities, raman_intensities, warray, eigenvectors + if num_species > 0 and self._num_ions > 0: + self._num_branches = num_species*self._num_ions + return #---------------------------------------------------------------------------------------- - def _parse_castep_file_header(self, f_handle): - """ - Read information from the header of a <>.castep file + def _parse_castep_freq_block(self, f_handle): + """ + Iterator to parse a block of frequencies from a .castep file. - @param f_handle - handle to the file. - @return tuple of the number of ions and branches in the file - """ - num_species, self._num_ions = 0,0 - while True: - line = f_handle.readline() + @param f_handle - handle to the file. + """ + prog_reporter = Progress(self,0.0,1.0,1) + for _ in xrange(self._num_branches): + line = f_handle.readline() + line_data = line.strip().split()[1:-1] + freq = line_data[1] + intensity_data = line_data[3:] - if not line: - raise IOError("Could not find any header information.") + #remove non-active intensities from data + intensities = [] + for value, active in zip(intensity_data[::2], intensity_data[1::2]): + if self._spec_type == 'IR_Active' or self._spec_type == 'Raman_Active': + if active == 'N' and value != 0: + value = 0.0 + intensities.append(value) - if 'Total number of ions in cell =' in line: - self._num_ions = int(line.strip().split()[-1]) - elif 'Total number of species in cell = ' in line: - num_species = int(line.strip().split()[-1]) + line_data = [freq] + intensities + line_data = map(float, line_data) + yield line_data - if num_species > 0 and self._num_ions > 0: - self._num_branches = num_species*self._num_ions - return + prog_reporter.report("Reading frequencies.") #---------------------------------------------------------------------------------------- - def _parse_castep_freq_block(self, f_handle): - """ - Iterator to parse a block of frequencies from a .castep file. - - @param f_handle - handle to the file. - """ - prog_reporter = Progress(self,0.0,1.0,1) - for _ in xrange(self._num_branches): - line = f_handle.readline() - line_data = line.strip().split()[1:-1] - freq = line_data[1] - intensity_data = line_data[3:] - - #remove non-active intensities from data - intensities = [] - for value, active in zip(intensity_data[::2], intensity_data[1::2]): - if self._spec_type == 'IR_Active' or self._spec_type == 'Raman_Active': - if active == 'N' and value != 0: - value = 0.0 - intensities.append(value) - - line_data = [freq] + intensities - line_data = map(float, line_data) - yield line_data - - prog_reporter.report("Reading frequencies.") + def _find_castep_freq_block(self, f_handle, data_regex): + """ + Find the start of the frequency block in a .castep file. + This will set the file pointer to the line before the start + of the block. + + @param f_handle - handle to the file. + """ + while True: + pos = f_handle.tell() + line = f_handle.readline() + + if not line: + raise IOError("Could not parse frequency block. Invalid file format.") + + if data_regex.match(line): + f_handle.seek(pos) + return #---------------------------------------------------------------------------------------- - def _find_castep_freq_block(self, f_handle, data_regex): - """ - Find the start of the frequency block in a .castep file. - This will set the file pointer to the line before the start - of the block. + def _parse_castep_file(self, file_name): + """ + Read frequencies from a <>.castep file + + @param file_name - file path of the file to read + @return the frequencies, infra red and raman intensities and weights of frequency blocks + """ + #Header regex. Looks for lines in the following format: + # + q-pt= 1 ( 0.000000 0.000000 0.000000) 1.0000000000 + + header_regex_str = r" +\+ +q-pt= +\d+ \( *(?: *(%(s)s)) *(%(s)s) *(%(s)s)\) +(%(s)s) +\+" % {'s' : self._float_regex} + header_regex = re.compile(header_regex_str) + + #Data regex. Looks for lines in the following format: + # + 1 -0.051481 a 0.0000000 N 0.0000000 N + + data_regex_str = r" +\+ +\d+ +(%(s)s)(?: +\w)? *(%(s)s)? *([YN])? *(%(s)s)? *([YN])? *\+"% {'s': self._float_regex} + data_regex = re.compile(data_regex_str) + + block_count = 0 + frequencies, ir_intensities, raman_intensities, weights = [], [], [], [] + data_lists = (frequencies, ir_intensities, raman_intensities) + with open(file_name, 'rU') as f_handle: + self._parse_castep_file_header(f_handle) - @param f_handle - handle to the file. - """ while True: - pos = f_handle.tell() line = f_handle.readline() - - if not line: - raise IOError("Could not parse frequency block. Invalid file format.") - - if data_regex.match(line): - f_handle.seek(pos) - return + #check we've reached the end of file + if not line: break + + #check if we've found a block of frequencies + header_match = header_regex.match(line) + if header_match: + block_count += 1 + weight = self._parse_block_header(header_match, block_count) + weights.append(weight) + + #move file pointer forward to start of intensity data + self._find_castep_freq_block(f_handle, data_regex) -#---------------------------------------------------------------------------------------- + #parse block of frequencies + for line_data in self._parse_castep_freq_block(f_handle): + for data_list, item in zip(data_lists, line_data): + data_list.append(item) - def _parse_castep_file(self, file_name): - """ - Read frequencies from a <>.castep file + frequencies = np.asarray(frequencies) + ir_intensities = np.asarray(ir_intensities) + raman_intensities = np.asarray(raman_intensities) + warray = np.repeat(weights, self._num_branches) - @param file_name - file path of the file to read - @return the frequencies, infra red and raman intensities and weights of frequency blocks - """ - #Header regex. Looks for lines in the following format: - # + q-pt= 1 ( 0.000000 0.000000 0.000000) 1.0000000000 + - header_regex_str = r" +\+ +q-pt= +\d+ \( *(?: *(%(s)s)) *(%(s)s) *(%(s)s)\) +(%(s)s) +\+" % {'s' : self._float_regex} - header_regex = re.compile(header_regex_str) - - #Data regex. Looks for lines in the following format: - # + 1 -0.051481 a 0.0000000 N 0.0000000 N + - data_regex_str = r" +\+ +\d+ +(%(s)s)(?: +\w)? *(%(s)s)? *([YN])? *(%(s)s)? *([YN])? *\+"% {'s': self._float_regex} - data_regex = re.compile(data_regex_str) - - block_count = 0 - frequencies, ir_intensities, raman_intensities, weights = [], [], [], [] - data_lists = (frequencies, ir_intensities, raman_intensities) - with open(file_name, 'rU') as f_handle: - self._parse_castep_file_header(f_handle) - - while True: - line = f_handle.readline() - #check we've reached the end of file - if not line: break - - #check if we've found a block of frequencies - header_match = header_regex.match(line) - if header_match: - block_count += 1 - weight = self._parse_block_header(header_match, block_count) - weights.append(weight) - - #move file pointer forward to start of intensity data - self._find_castep_freq_block(f_handle, data_regex) - - #parse block of frequencies - for line_data in self._parse_castep_freq_block(f_handle): - for data_list, item in zip(data_lists, line_data): - data_list.append(item) - - frequencies = np.asarray(frequencies) - ir_intensities = np.asarray(ir_intensities) - raman_intensities = np.asarray(raman_intensities) - warray = np.repeat(weights, self._num_branches) - - return frequencies, ir_intensities, raman_intensities, warray + return frequencies, ir_intensities, raman_intensities, warray # Register algorithm with Mantid AlgorithmFactory.subscribe(DensityOfStates) diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/IndirectTransmission.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/IndirectTransmission.py index 58220db3dd44..89e257751bf4 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/IndirectTransmission.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/IndirectTransmission.py @@ -16,8 +16,8 @@ class IndirectTransmission(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def summary(self): - return "Calculates the scattering & transmission for Indirect Geometry spectrometers." + def summary(self): + return "Calculates the scattering & transmission for Indirect Geometry spectrometers." def PyInit(self): self.declareProperty(name='Instrument',defaultValue='IRIS',validator=StringListValidator(['IRIS','OSIRIS']), doc='Instrument') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatData.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatData.py index 1bc06aa78553..ef00b8259049 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatData.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatData.py @@ -17,8 +17,8 @@ class MuscatData(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def summary(self): - return "Calculates multiple scattering using a sample S(Q,w)." + def summary(self): + return "Calculates multiple scattering using a sample S(Q,w)." def PyInit(self): self.declareProperty(name='Instrument',defaultValue='iris',validator=StringListValidator(['irs','iris','osi','osiris']), doc='Instrument') @@ -42,10 +42,10 @@ def PyInit(self): self.declareProperty(name='Save',defaultValue=False, doc='Switch Save result to nxs file Off/On') def PyExec(self): - from IndirectImport import run_f2py_compatibility_test, is_supported_f2py_platform - - if is_supported_f2py_platform(): - import IndirectMuscat as Main + from IndirectImport import run_f2py_compatibility_test, is_supported_f2py_platform + + if is_supported_f2py_platform(): + import IndirectMuscat as Main run_f2py_compatibility_test() self.log().information('Muscat input') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatFunc.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatFunc.py index 6842bd226c86..9b70b81a06df 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatFunc.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/MuscatFunc.py @@ -17,8 +17,8 @@ class MuscatFunc(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def summary(self): - return "Calculates multiple scattering using S(Q,w) from specified functions." + def summary(self): + return "Calculates multiple scattering using S(Q,w) from specified functions." def PyInit(self): self.declareProperty(name='Instrument',defaultValue='iris',validator=StringListValidator(['irs','iris','osi','osiris']), doc='Instrument') @@ -51,10 +51,10 @@ def PyInit(self): self.declareProperty(name='Save',defaultValue=False, doc='Switch Save result to nxs file Off/On') def PyExec(self): - from IndirectImport import run_f2py_compatibility_test, is_supported_f2py_platform + from IndirectImport import run_f2py_compatibility_test, is_supported_f2py_platform - if is_supported_f2py_platform(): - import IndirectMuscat as Main + if is_supported_f2py_platform(): + import IndirectMuscat as Main run_f2py_compatibility_test() diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/QLines.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/QLines.py index 0f3331e88f4c..471e3a785f43 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/QLines.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/QLines.py @@ -24,8 +24,8 @@ class QLines(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def summary(self): - return "The program estimates the quasielastic components of each of the groups of spectra and requires the resolution file (.RES file) and optionally the normalisation file created by ResNorm." + def summary(self): + return "The program estimates the quasielastic components of each of the groups of spectra and requires the resolution file (.RES file) and optionally the normalisation file created by ResNorm." def PyInit(self): self.declareProperty(name='InputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of data input - File (*.nxs) or Workspace') diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Quest.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Quest.py index dddccefcd677..2a21f387d7f0 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Quest.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Quest.py @@ -17,8 +17,8 @@ class Quest(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def summary(self): - return "This is a variation of the stretched exponential option of Quasi." + def summary(self): + return "This is a variation of the stretched exponential option of Quasi." def PyInit(self): self.declareProperty(name='InputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of data input - File (*.nxs) or Workspace') @@ -42,10 +42,10 @@ def PyInit(self): self.declareProperty(name='Save',defaultValue=False, doc='Switch Save result to nxs file Off/On') def PyExec(self): - from IndirectImport import run_f2py_compatibility_test, is_supported_f2py_platform - - if is_supported_f2py_platform(): - import IndirectBayes as Main + from IndirectImport import run_f2py_compatibility_test, is_supported_f2py_platform + + if is_supported_f2py_platform(): + import IndirectBayes as Main run_f2py_compatibility_test() diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ResNorm.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ResNorm.py index 86051c9cb1b6..6f1d1eb6eea9 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ResNorm.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/ResNorm.py @@ -36,10 +36,10 @@ def PyInit(self): self.declareProperty(name='Save',defaultValue=False, doc='Switch Save result to nxs file Off/On') def PyExec(self): - from IndirectImport import run_f2py_compatibility_test, is_supported_f2py_platform + from IndirectImport import run_f2py_compatibility_test, is_supported_f2py_platform - if is_supported_f2py_platform(): - import IndirectBayes as Main + if is_supported_f2py_platform(): + import IndirectBayes as Main run_f2py_compatibility_test() diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SofQWMoments.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SofQWMoments.py index b37d153944b6..92661916a943 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SofQWMoments.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/SofQWMoments.py @@ -17,8 +17,8 @@ class SofQWMoments(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def summary (self): - return "Calculates the nth moment of y(q,w)" + def summary (self): + return "Calculates the nth moment of y(q,w)" def PyInit(self): self.declareProperty(MatrixWorkspaceProperty("Sample", "", Direction.Input), doc="Sample to use.") diff --git a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Symmetrise.py b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Symmetrise.py index b54a81797b24..bfef49e385d6 100644 --- a/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Symmetrise.py +++ b/Code/Mantid/Framework/PythonInterface/plugins/algorithms/WorkflowAlgorithms/Symmetrise.py @@ -14,8 +14,8 @@ class Symmetrise(PythonAlgorithm): def category(self): return "Workflow\\MIDAS;PythonAlgorithms" - def summary (self): - return "Takes and asymmetric S(Q,w) and makes it symmetric" + def summary (self): + return "Takes and asymmetric S(Q,w) and makes it symmetric" def PyInit(self): self.declareProperty(name='InputType',defaultValue='File',validator=StringListValidator(['File','Workspace']), doc='Origin of data input - File (_red.nxs) or Workspace') From 84564b4a8e8e027d944f83befde2b65ec1dc9033 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 30 May 2014 10:59:46 +0100 Subject: [PATCH 103/126] Fix doxygen warnings. Refs #9523 --- Code/Mantid/Framework/Algorithms/src/ResetNegatives.cpp | 3 --- Code/Mantid/Framework/DataHandling/src/LoadPreNexus.cpp | 3 --- 2 files changed, 6 deletions(-) diff --git a/Code/Mantid/Framework/Algorithms/src/ResetNegatives.cpp b/Code/Mantid/Framework/Algorithms/src/ResetNegatives.cpp index b8aea8bd5acb..1c3ae281f9f7 100644 --- a/Code/Mantid/Framework/Algorithms/src/ResetNegatives.cpp +++ b/Code/Mantid/Framework/Algorithms/src/ResetNegatives.cpp @@ -55,9 +55,6 @@ namespace Algorithms return "Utility"; } - //---------------------------------------------------------------------------------------------- - /// @copydoc Mantid::API:: - //---------------------------------------------------------------------------------------------- /// @copydoc Mantid::API::Algorithm::init() void ResetNegatives::init() diff --git a/Code/Mantid/Framework/DataHandling/src/LoadPreNexus.cpp b/Code/Mantid/Framework/DataHandling/src/LoadPreNexus.cpp index 83b27e6096f5..666451222973 100644 --- a/Code/Mantid/Framework/DataHandling/src/LoadPreNexus.cpp +++ b/Code/Mantid/Framework/DataHandling/src/LoadPreNexus.cpp @@ -76,9 +76,6 @@ namespace DataHandling return "DataHandling\\PreNexus;Workflow\\DataHandling"; } - //---------------------------------------------------------------------------------------------- - /// @copydoc Mantid::API:: - /** * Return the confidence with with this algorithm can load the file * @param descriptor A descriptor for the file From 206afa4a34e7ff0858ff43050c6fb68e47869635 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 30 May 2014 11:18:17 +0100 Subject: [PATCH 104/126] Remove unrequired algm_categories directive. The standard 'categories' one can now be used in both cases. Refs #9521 --- .../mantiddoc/directives/categories.py | 80 ++++++++----------- 1 file changed, 34 insertions(+), 46 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py index c0ce2864e709..c5b7f51bcb75 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/categories.py @@ -94,15 +94,17 @@ def __init__(self, name, docname): class CategoriesDirective(BaseDirective): """ - Records the page as part of the given categories. Index pages for each + Records the page as part of given categories. Index pages for each category are then automatically created after all pages are collected together. Subcategories can be given using the "\\" separator, e.g. Algorithms\\Transforms + + If the argument list is empty then the the file is assumed to be an algorithm file + and the lists is pulled from the algoritm object """ - # requires at least 1 category - required_arguments = 1 + required_arguments = 0 # it can be in many categories and we put an arbitrary upper limit here optional_arguments = 25 @@ -125,16 +127,40 @@ def _get_categories_list(self): Returns: list: A list of strings containing the required categories """ - # Simply return all of the arguments as strings - return self.arguments + # if the argument list is empty then assume this is in an algorithm file + args = self.arguments + if len(args) > 0: + return args + else: + return self._get_algorithm_categories_list() + + def _get_algorithm_categories_list(self): + """ + Returns a list of the category strings + + Returns: + list: A list of strings containing the required categories + """ + category_list = ["Algorithms"] + alg_cats = self.create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()).categories() + for cat in alg_cats: + # double up the category separators so they are not treated as escape characters + category_list.append(cat.replace("\\", "\\\\")) + + return category_list def _get_display_name(self): """ Returns the name of the item as it should appear in the category """ - env = self.state.document.settings.env - # env.docname returns relative path from doc root. Use name after last "/" separator - return env.docname.split("/")[-1] + # If there are no arguments then take the name directly from the document name, else + # assume it is an algorithm and use its name + if len(self.arguments) > 0: + env = self.state.document.settings.env + # env.docname returns relative path from doc root. Use name after last "/" separator + return env.docname.split("/")[-1] + else: + return self.algorithm_name() def _create_links_and_track(self, page_name, category_list): """ @@ -195,42 +221,6 @@ def _create_links_and_track(self, page_name, category_list): #--------------------------------------------------------------------------------- -class AlgorithmCategoryDirective(CategoriesDirective): - """ - Supports the "algm_categories" directive that takes a single - argument and pulls the categories from an algorithm object. - - In addition to adding the named page to the requested category, it - also appends it to the "Algorithms" category - """ - # requires at least 1 argument - required_arguments = 0 - # no other arguments - optional_arguments = 0 - - def _get_categories_list(self): - """ - Returns a list of the category strings - - Returns: - list: A list of strings containing the required categories - """ - category_list = ["Algorithms"] - alg_cats = self.create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()).categories() - for cat in alg_cats: - # double up the category separators so they are not treated as escape characters - category_list.append(cat.replace("\\", "\\\\")) - - return category_list - - def _get_display_name(self): - """ - Returns the name of the item as it should appear in the category - """ - return self.algorithm_name() - -#--------------------------------------------------------------------------------- - def html_collect_pages(app): """ Callback for the 'html-collect-pages' Sphinx event. Adds category @@ -302,8 +292,6 @@ def purge_categories(app, env, docname): def setup(app): # Add categories directive app.add_directive('categories', CategoriesDirective) - # Add algm_categories directive - app.add_directive('algm_categories', AlgorithmCategoryDirective) # connect event html collection to handler app.connect("html-collect-pages", html_collect_pages) From 49c92bcd3126e629936fd4c8c6a58db7e9a0453a Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 30 May 2014 11:38:26 +0100 Subject: [PATCH 105/126] Add summary messages for MPI algorithms. Refs #9523 --- .../inc/MantidMPIAlgorithms/BroadcastWorkspace.h | 2 ++ .../MPIAlgorithms/inc/MantidMPIAlgorithms/GatherWorkspaces.h | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/Code/Mantid/Framework/MPIAlgorithms/inc/MantidMPIAlgorithms/BroadcastWorkspace.h b/Code/Mantid/Framework/MPIAlgorithms/inc/MantidMPIAlgorithms/BroadcastWorkspace.h index 9d4b66d4dffd..1150869f9857 100644 --- a/Code/Mantid/Framework/MPIAlgorithms/inc/MantidMPIAlgorithms/BroadcastWorkspace.h +++ b/Code/Mantid/Framework/MPIAlgorithms/inc/MantidMPIAlgorithms/BroadcastWorkspace.h @@ -50,6 +50,8 @@ class BroadcastWorkspace : public API::Algorithm virtual const std::string name() const { return "BroadcastWorkspace"; } /// Algorithm's version virtual int version() const { return (1); } + /// @copydoc Algorithm::summary + virtual const std::string summary() const { return "Copy a workspace from one process to all the others."; } /// Algorithm's category for identification virtual const std::string category() const { return "MPI"; } diff --git a/Code/Mantid/Framework/MPIAlgorithms/inc/MantidMPIAlgorithms/GatherWorkspaces.h b/Code/Mantid/Framework/MPIAlgorithms/inc/MantidMPIAlgorithms/GatherWorkspaces.h index 83dc3875ac42..2c7f21c593ce 100644 --- a/Code/Mantid/Framework/MPIAlgorithms/inc/MantidMPIAlgorithms/GatherWorkspaces.h +++ b/Code/Mantid/Framework/MPIAlgorithms/inc/MantidMPIAlgorithms/GatherWorkspaces.h @@ -62,6 +62,11 @@ class GatherWorkspaces : public API::Algorithm virtual const std::string name() const { return "GatherWorkspaces"; } /// Algorithm's version virtual int version() const { return (1); } + /// @copydoc Algorithm::summary + virtual const std::string summary() const + { + return "Stitches together the input workspaces provided by each of the processes into a single workspace."; + } /// Algorithm's category for identification virtual const std::string category() const { return "MPI"; } From 784ee6626718a28b612c43633dade68ac82f018d Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Fri, 9 May 2014 12:31:52 +0100 Subject: [PATCH 106/126] refs #9438 Current state of LET instrument folder. Redundancies are present and some regularization is necessary. --- .../instrument/LET_Definition_3to10.xml | 690 +++++++++++++++++ .../instrument/LET_Definition_dr2to7.xml | 689 +++++++++++++++++ .../instrument/LET_Definition_dr2to9.xml | 8 +- .../instrument/LET_Definition_dr3to9.xml | 691 ++++++++++++++++++ Code/Mantid/instrument/LET_Parameters.xml | 14 +- .../instrument/LET_Parameters_3to10.xml | 390 ++++++++++ .../Mantid/instrument/LET_Parameters_3to9.xml | 384 ++++++++++ .../instrument/LET_Parameters_cycle2013_5.xml | 384 ++++++++++ .../instrument/LET_Parameters_dr2to7.xml | 384 ++++++++++ .../instrument/LET_Parameters_dr2to9.xml | 26 +- .../instrument/LET_Parameters_dr3to10.xml | 384 ++++++++++ 11 files changed, 4015 insertions(+), 29 deletions(-) create mode 100644 Code/Mantid/instrument/LET_Definition_3to10.xml create mode 100644 Code/Mantid/instrument/LET_Definition_dr2to7.xml create mode 100644 Code/Mantid/instrument/LET_Definition_dr3to9.xml create mode 100644 Code/Mantid/instrument/LET_Parameters_3to10.xml create mode 100644 Code/Mantid/instrument/LET_Parameters_3to9.xml create mode 100644 Code/Mantid/instrument/LET_Parameters_cycle2013_5.xml create mode 100644 Code/Mantid/instrument/LET_Parameters_dr2to7.xml create mode 100644 Code/Mantid/instrument/LET_Parameters_dr3to10.xml diff --git a/Code/Mantid/instrument/LET_Definition_3to10.xml b/Code/Mantid/instrument/LET_Definition_3to10.xml new file mode 100644 index 000000000000..d903e6a2b2f2 --- /dev/null +++ b/Code/Mantid/instrument/LET_Definition_3to10.xml @@ -0,0 +1,690 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Code/Mantid/instrument/LET_Definition_dr2to7.xml b/Code/Mantid/instrument/LET_Definition_dr2to7.xml new file mode 100644 index 000000000000..b67cf567f6c6 --- /dev/null +++ b/Code/Mantid/instrument/LET_Definition_dr2to7.xml @@ -0,0 +1,689 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Code/Mantid/instrument/LET_Definition_dr2to9.xml b/Code/Mantid/instrument/LET_Definition_dr2to9.xml index 239faf9f0f72..bb8ec5c0815b 100644 --- a/Code/Mantid/instrument/LET_Definition_dr2to9.xml +++ b/Code/Mantid/instrument/LET_Definition_dr2to9.xml @@ -3,8 +3,8 @@ see http://www.mantidproject.org/IDF --> + valid-to ="2014-05-01 23:59:59" + last-modified="2014-05-06 00:00:00"> @@ -664,7 +664,6 @@ - @@ -686,4 +685,7 @@ + + + diff --git a/Code/Mantid/instrument/LET_Definition_dr3to9.xml b/Code/Mantid/instrument/LET_Definition_dr3to9.xml new file mode 100644 index 000000000000..bb8ec5c0815b --- /dev/null +++ b/Code/Mantid/instrument/LET_Definition_dr3to9.xml @@ -0,0 +1,691 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Code/Mantid/instrument/LET_Parameters.xml b/Code/Mantid/instrument/LET_Parameters.xml index 3e10a41fec09..6673d28c65e5 100644 --- a/Code/Mantid/instrument/LET_Parameters.xml +++ b/Code/Mantid/instrument/LET_Parameters.xml @@ -41,14 +41,6 @@
- - - - - @@ -295,6 +287,12 @@ + + + + diff --git a/Code/Mantid/instrument/LET_Parameters_3to10.xml b/Code/Mantid/instrument/LET_Parameters_3to10.xml new file mode 100644 index 000000000000..2d38928878d8 --- /dev/null +++ b/Code/Mantid/instrument/LET_Parameters_3to10.xml @@ -0,0 +1,390 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Code/Mantid/instrument/LET_Parameters_3to9.xml b/Code/Mantid/instrument/LET_Parameters_3to9.xml new file mode 100644 index 000000000000..454b6c50b5cc --- /dev/null +++ b/Code/Mantid/instrument/LET_Parameters_3to9.xml @@ -0,0 +1,384 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Code/Mantid/instrument/LET_Parameters_cycle2013_5.xml b/Code/Mantid/instrument/LET_Parameters_cycle2013_5.xml new file mode 100644 index 000000000000..bd1c66ada6c4 --- /dev/null +++ b/Code/Mantid/instrument/LET_Parameters_cycle2013_5.xml @@ -0,0 +1,384 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Code/Mantid/instrument/LET_Parameters_dr2to7.xml b/Code/Mantid/instrument/LET_Parameters_dr2to7.xml new file mode 100644 index 000000000000..99c364ea44da --- /dev/null +++ b/Code/Mantid/instrument/LET_Parameters_dr2to7.xml @@ -0,0 +1,384 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Code/Mantid/instrument/LET_Parameters_dr2to9.xml b/Code/Mantid/instrument/LET_Parameters_dr2to9.xml index 33dd4f441648..e85b1cf88762 100644 --- a/Code/Mantid/instrument/LET_Parameters_dr2to9.xml +++ b/Code/Mantid/instrument/LET_Parameters_dr2to9.xml @@ -41,17 +41,9 @@ - - - - - - + @@ -114,15 +106,6 @@ - - - - - + + + + + diff --git a/Code/Mantid/instrument/LET_Parameters_dr3to10.xml b/Code/Mantid/instrument/LET_Parameters_dr3to10.xml new file mode 100644 index 000000000000..454b6c50b5cc --- /dev/null +++ b/Code/Mantid/instrument/LET_Parameters_dr3to10.xml @@ -0,0 +1,384 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 90f54b53a3bcc8c08b119e0724d4b5945e3e9c1f Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Fri, 9 May 2014 12:57:23 +0100 Subject: [PATCH 107/126] refs #9438 Better diagnostics During IDF changes, it was found difficult to understand what is going wrong when monitor number is specified incorrectly. This change should help to address similar problem in a future. --- .../Inelastic/DirectEnergyConversion.py | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/Code/Mantid/scripts/Inelastic/DirectEnergyConversion.py b/Code/Mantid/scripts/Inelastic/DirectEnergyConversion.py index 5e8b691eddc9..3c9e1bbebcb3 100644 --- a/Code/Mantid/scripts/Inelastic/DirectEnergyConversion.py +++ b/Code/Mantid/scripts/Inelastic/DirectEnergyConversion.py @@ -402,7 +402,7 @@ def _do_mono_SNS(self, data_ws, monitor_ws, result_name, ei_guess, ConvertFromDistribution(Workspace=result_name) - # Normalise using the chosen method + # Normalize using the chosen method # This should be done as soon as possible after loading and usually happens at diag. Here just in case if diag was bypassed self.normalise(mtd[result_name], result_name, self.normalise_method, range_offset=bin_offset) @@ -445,7 +445,7 @@ def _do_mono_ISIS(self, data_ws, monitor_ws, result_name, ei_guess, WorkspaceIndexList= '',Mode= 'Mean',SkipMonitors='1') - # Normalise using the chosen method+group + # Normalize using the chosen method+group # : This really should be done as soon as possible after loading self.normalise(mtd[result_name], result_name, self.normalise_method, range_offset=bin_offset) @@ -472,7 +472,7 @@ def _do_mono(self, data_ws, monitor_ws, result_name, ei_guess, white_run=None, map_file=None, spectra_masks=None, Tzero=None): """ Convert units of a given workspace to deltaE, including possible - normalisation to a white-beam vanadium run. + normalization to a white-beam vanadium run. """ if (self.__facility == "SNS"): self._do_mono_SNS(data_ws,monitor_ws,result_name,ei_guess, @@ -610,13 +610,17 @@ def get_ei(self, input_ws, resultws_name, ei_guess): if type(monitor_ws) is str: monitor_ws = mtd[monitor_ws] try: - # check if the spectra with correspondent number is present in the worksace + # check if the spectra with correspondent number is present in the workspace nsp = monitor_ws.getIndexFromSpectrumNumber(int(self.ei_mon_spectra[0])); - except: + except RuntimeError as err: monitors_from_separate_ws = True mon_ws = monitor_ws.getName()+'_monitors' - monitor_ws = mtd[mon_ws]; - #------------------------------------------------------------- + try: + monitor_ws = mtd[mon_ws]; + except: + print "**** ERROR while attempting to get spectra {0} from workspace: {1}, error: {2} ".format(self.ei_mon_spectra[0],monitor_ws.getName(), err) + raise + #------------------------------------------------ # Calculate the incident energy ei,mon1_peak,mon1_index,tzero = \ From b8e16103126e00b3926d44f8a68838891ea0e632 Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Fri, 9 May 2014 15:07:23 +0100 Subject: [PATCH 108/126] refs #9438 Should fix duplicated IDF issue. --- Code/Mantid/instrument/LET_Definition.xml | 689 ----------------- ...n_3to10.xml => LET_Definition_dr3to10.xml} | 0 .../instrument/LET_Definition_dr3to9.xml | 691 ------------------ Code/Mantid/instrument/LET_Parameters.xml | 391 ---------- .../instrument/LET_Parameters_3to10.xml | 390 ---------- .../Mantid/instrument/LET_Parameters_3to9.xml | 384 ---------- .../instrument/LET_Parameters_dr3to10.xml | 26 +- 7 files changed, 16 insertions(+), 2555 deletions(-) delete mode 100644 Code/Mantid/instrument/LET_Definition.xml rename Code/Mantid/instrument/{LET_Definition_3to10.xml => LET_Definition_dr3to10.xml} (100%) delete mode 100644 Code/Mantid/instrument/LET_Definition_dr3to9.xml delete mode 100644 Code/Mantid/instrument/LET_Parameters.xml delete mode 100644 Code/Mantid/instrument/LET_Parameters_3to10.xml delete mode 100644 Code/Mantid/instrument/LET_Parameters_3to9.xml diff --git a/Code/Mantid/instrument/LET_Definition.xml b/Code/Mantid/instrument/LET_Definition.xml deleted file mode 100644 index dcd2d0c0ffca..000000000000 --- a/Code/Mantid/instrument/LET_Definition.xml +++ /dev/null @@ -1,689 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Code/Mantid/instrument/LET_Definition_3to10.xml b/Code/Mantid/instrument/LET_Definition_dr3to10.xml similarity index 100% rename from Code/Mantid/instrument/LET_Definition_3to10.xml rename to Code/Mantid/instrument/LET_Definition_dr3to10.xml diff --git a/Code/Mantid/instrument/LET_Definition_dr3to9.xml b/Code/Mantid/instrument/LET_Definition_dr3to9.xml deleted file mode 100644 index bb8ec5c0815b..000000000000 --- a/Code/Mantid/instrument/LET_Definition_dr3to9.xml +++ /dev/null @@ -1,691 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Code/Mantid/instrument/LET_Parameters.xml b/Code/Mantid/instrument/LET_Parameters.xml deleted file mode 100644 index 6673d28c65e5..000000000000 --- a/Code/Mantid/instrument/LET_Parameters.xml +++ /dev/null @@ -1,391 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Code/Mantid/instrument/LET_Parameters_3to10.xml b/Code/Mantid/instrument/LET_Parameters_3to10.xml deleted file mode 100644 index 2d38928878d8..000000000000 --- a/Code/Mantid/instrument/LET_Parameters_3to10.xml +++ /dev/null @@ -1,390 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Code/Mantid/instrument/LET_Parameters_3to9.xml b/Code/Mantid/instrument/LET_Parameters_3to9.xml deleted file mode 100644 index 454b6c50b5cc..000000000000 --- a/Code/Mantid/instrument/LET_Parameters_3to9.xml +++ /dev/null @@ -1,384 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Code/Mantid/instrument/LET_Parameters_dr3to10.xml b/Code/Mantid/instrument/LET_Parameters_dr3to10.xml index 454b6c50b5cc..2d38928878d8 100644 --- a/Code/Mantid/instrument/LET_Parameters_dr3to10.xml +++ b/Code/Mantid/instrument/LET_Parameters_dr3to10.xml @@ -5,10 +5,6 @@ - - - - @@ -34,11 +30,6 @@ - - - - - @@ -77,12 +68,20 @@ + + + + + + - @@ -328,6 +327,13 @@ + + + + + + + - - - - @@ -34,11 +30,6 @@ - - - - - @@ -77,12 +68,20 @@ + + + + + + - @@ -328,6 +327,13 @@ + + + + + + + @@ -685,7 +686,4 @@ - - - diff --git a/Code/Mantid/instrument/LET_Parameters_cycle2013_5.xml b/Code/Mantid/instrument/LET_Parameters_cycle2013_5.xml deleted file mode 100644 index bd1c66ada6c4..000000000000 --- a/Code/Mantid/instrument/LET_Parameters_cycle2013_5.xml +++ /dev/null @@ -1,384 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Code/Mantid/instrument/LET_Parameters_dr2to7.xml b/Code/Mantid/instrument/LET_Parameters_dr2to7.xml index 391c36088c50..974fe0b7e48d 100644 --- a/Code/Mantid/instrument/LET_Parameters_dr2to7.xml +++ b/Code/Mantid/instrument/LET_Parameters_dr2to7.xml @@ -41,6 +41,14 @@ + + + + + @@ -106,6 +114,15 @@ + + + + + - - - - - diff --git a/Code/Mantid/instrument/LET_Parameters_dr2to9.xml b/Code/Mantid/instrument/LET_Parameters_dr2to9.xml index e85b1cf88762..33dd4f441648 100644 --- a/Code/Mantid/instrument/LET_Parameters_dr2to9.xml +++ b/Code/Mantid/instrument/LET_Parameters_dr2to9.xml @@ -41,9 +41,17 @@ + + + + + - + @@ -106,6 +114,15 @@ + + + + + - - - - - diff --git a/Code/Mantid/instrument/LET_Parameters_dr3to10.xml b/Code/Mantid/instrument/LET_Parameters_dr3to10.xml index 2d38928878d8..de6d0b1bd660 100644 --- a/Code/Mantid/instrument/LET_Parameters_dr3to10.xml +++ b/Code/Mantid/instrument/LET_Parameters_dr3to10.xml @@ -41,6 +41,14 @@ + + + + + @@ -106,6 +114,15 @@ + + + + + - - - - - From a4636d88071edd8450152757ad2397f29be445f0 Mon Sep 17 00:00:00 2001 From: Alex Buts Date: Thu, 15 May 2014 13:42:33 +0100 Subject: [PATCH 111/126] refs #9438 fixing system test: Renamed LET_Definition_dr2to7 to LET_Definition and LET_Parameters accordingly, as LET2014Multirep nexus system tests source files contains old LET_Definition and LET_Parameters, which do not work with recent reduction. The only way to run these files is to reload LET_Definition.xml and LET_Parameters.xml from the IDF. --- .../instrument/{LET_Definition_dr2to7.xml => LET_Definition.xml} | 0 .../instrument/{LET_Parameters_dr2to7.xml => LET_Parameters.xml} | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename Code/Mantid/instrument/{LET_Definition_dr2to7.xml => LET_Definition.xml} (100%) rename Code/Mantid/instrument/{LET_Parameters_dr2to7.xml => LET_Parameters.xml} (100%) diff --git a/Code/Mantid/instrument/LET_Definition_dr2to7.xml b/Code/Mantid/instrument/LET_Definition.xml similarity index 100% rename from Code/Mantid/instrument/LET_Definition_dr2to7.xml rename to Code/Mantid/instrument/LET_Definition.xml diff --git a/Code/Mantid/instrument/LET_Parameters_dr2to7.xml b/Code/Mantid/instrument/LET_Parameters.xml similarity index 100% rename from Code/Mantid/instrument/LET_Parameters_dr2to7.xml rename to Code/Mantid/instrument/LET_Parameters.xml From 84e983f996d5ccd78563dbaaa5af092f431dff3e Mon Sep 17 00:00:00 2001 From: Vickie Lynch Date: Fri, 30 May 2014 10:35:27 -0400 Subject: [PATCH 112/126] Refs #9546 option for AllowPermutations with default of true --- .../Crystal/src/SelectCellOfType.cpp | 6 ++- .../Crystal/src/SelectCellWithForm.cpp | 2 +- .../Crystal/src/ShowPossibleCells.cpp | 2 +- .../inc/MantidQtCustomInterfaces/MantidEV.ui | 48 +++++++++++++++---- .../MantidQtCustomInterfaces/MantidEVWorker.h | 3 +- .../CustomInterfaces/src/MantidEV.cpp | 7 ++- .../CustomInterfaces/src/MantidEVWorker.cpp | 7 ++- .../scripts/SCD_Reduction/ReduceSCD.config | 3 +- .../scripts/SCD_Reduction/ReduceSCD_OneRun.py | 2 + .../SCD_Reduction/ReduceSCD_Parallel.py | 3 +- 10 files changed, 66 insertions(+), 17 deletions(-) diff --git a/Code/Mantid/Framework/Crystal/src/SelectCellOfType.cpp b/Code/Mantid/Framework/Crystal/src/SelectCellOfType.cpp index 3d734c0ea0fe..be760fd25532 100644 --- a/Code/Mantid/Framework/Crystal/src/SelectCellOfType.cpp +++ b/Code/Mantid/Framework/Crystal/src/SelectCellOfType.cpp @@ -114,6 +114,9 @@ namespace Crystal this->declareProperty(new PropertyWithValue( "AverageError", 0.0, Direction::Output), "The average HKL indexing error if apply==true."); + + this->declareProperty( "AllowPermutations", true, + "Allow permutations of conventional cells" ); } //-------------------------------------------------------------------------- @@ -143,9 +146,10 @@ namespace Crystal std::string centering = this->getProperty("Centering"); bool apply = this->getProperty("Apply"); double tolerance = this->getProperty("Tolerance"); + bool allowPermutations = this->getProperty("AllowPermutations"); std::vector list = - ScalarUtils::GetCells( UB, cell_type, centering ); + ScalarUtils::GetCells( UB, cell_type, centering, allowPermutations ); ConventionalCell info = ScalarUtils::GetCellBestError( list, true ); diff --git a/Code/Mantid/Framework/Crystal/src/SelectCellWithForm.cpp b/Code/Mantid/Framework/Crystal/src/SelectCellWithForm.cpp index 8cbfaf38c1eb..6927b8854ae9 100644 --- a/Code/Mantid/Framework/Crystal/src/SelectCellWithForm.cpp +++ b/Code/Mantid/Framework/Crystal/src/SelectCellWithForm.cpp @@ -97,7 +97,7 @@ namespace Crystal this->declareProperty(new PropertyWithValue( "AverageError", 0.0, Direction::Output), "The average HKL indexing error if apply==true."); - this->declareProperty( "AllowPermutations", false, + this->declareProperty( "AllowPermutations", true, "Allow permutations of conventional cells" ); } diff --git a/Code/Mantid/Framework/Crystal/src/ShowPossibleCells.cpp b/Code/Mantid/Framework/Crystal/src/ShowPossibleCells.cpp index 1910f2b4bd74..b8102ebe3261 100644 --- a/Code/Mantid/Framework/Crystal/src/ShowPossibleCells.cpp +++ b/Code/Mantid/Framework/Crystal/src/ShowPossibleCells.cpp @@ -87,7 +87,7 @@ namespace Crystal new PropertyWithValue( "NumberOfCells", 0, Direction::Output), "Gets set with the number of possible cells."); - this->declareProperty( "AllowPermutations", false, + this->declareProperty( "AllowPermutations", true, "Allow permutations of conventional cells" ); } diff --git a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MantidEV.ui b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MantidEV.ui index b522cd7f8cce..6bfc0442db09 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MantidEV.ui +++ b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MantidEV.ui @@ -57,7 +57,7 @@ - 0 + 3 @@ -616,8 +616,8 @@ 0 0 - 372 - 330 + 903 + 708 @@ -1823,8 +1823,8 @@ 0 0 - 345 - 280 + 903 + 708 @@ -1924,6 +1924,36 @@ + + + + + + Qt::Horizontal + + + QSizePolicy::Fixed + + + + 15 + 0 + + + + + + + + Allow permutations of conventional cells. + + + Allow Permutations + + + + + @@ -2378,8 +2408,8 @@ 0 0 - 389 - 188 + 903 + 708 @@ -2632,8 +2662,8 @@ 0 0 - 606 - 635 + 903 + 708 diff --git a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MantidEVWorker.h b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MantidEVWorker.h index 3aab0ab919ce..af3a2a596b9f 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MantidEVWorker.h +++ b/Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MantidEVWorker.h @@ -129,7 +129,8 @@ class DLLExport MantidEVWorker /// Show the possible conventional cells for a Niggli cell bool showCells( const std::string & peaks_ws_name, double max_scalar_error, - bool best_only ); + bool best_only, + bool allow_perm); /// Select conventional cell using the cell type and centering bool selectCellOfType( const std::string & peaks_ws_name, diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/MantidEV.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/MantidEV.cpp index 160385ddb29f..12e730113c93 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/MantidEV.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/MantidEV.cpp @@ -476,6 +476,7 @@ void MantidEV::setDefaultState_slot() m_uiForm.ShowPossibleCells_rbtn->setChecked(true); m_uiForm.MaxScalarError_ledt->setText("0.2"); m_uiForm.BestCellOnly_ckbx->setChecked(true); + m_uiForm.AllowPermutations_ckbx->setChecked(true); m_uiForm.SelectCellOfType_rbtn->setChecked(false); m_uiForm.CellType_cmbx->setCurrentIndex(0); m_uiForm.CellCentering_cmbx->setCurrentIndex(0); @@ -1029,10 +1030,11 @@ void MantidEV::chooseCell_slot() if ( show_cells ) { bool best_only = m_uiForm.BestCellOnly_ckbx->isChecked(); + bool allow_perm = m_uiForm.AllowPermutations_ckbx->isChecked(); double max_scalar_error = 0; if ( !getPositiveDouble( m_uiForm.MaxScalarError_ledt, max_scalar_error ) ) return; - if ( !worker->showCells( peaks_ws_name, max_scalar_error, best_only ) ) + if ( !worker->showCells( peaks_ws_name, max_scalar_error, best_only, allow_perm ) ) { errorMessage("Failed to Show Conventional Cells"); } @@ -1727,6 +1729,7 @@ void MantidEV::setEnabledShowCellsParams_slot( bool on ) m_uiForm.MaxScalarError_lbl->setEnabled( on ); m_uiForm.MaxScalarError_ledt->setEnabled( on ); m_uiForm.BestCellOnly_ckbx->setEnabled( on ); + m_uiForm.AllowPermutations_ckbx->setEnabled( on ); } @@ -2078,6 +2081,7 @@ void MantidEV::saveSettings( const std::string & filename ) state->setValue("ShowPossibleCells_rbtn",m_uiForm.ShowPossibleCells_rbtn->isChecked()); state->setValue("MaxScalarError_ledt",m_uiForm.MaxScalarError_ledt->text()); state->setValue("BestCellOnly_ckbx",m_uiForm.BestCellOnly_ckbx->isChecked()); + state->setValue("BestCellOnly_ckbx",m_uiForm.AllowPermutations_ckbx->isChecked()); state->setValue("SelectCellOfType_rbtn",m_uiForm.SelectCellOfType_rbtn->isChecked()); state->setValue("CellType_cmbx",m_uiForm.CellType_cmbx->currentIndex()); state->setValue("CellCentering_cmbx",m_uiForm.CellCentering_cmbx->currentIndex()); @@ -2190,6 +2194,7 @@ void MantidEV::loadSettings( const std::string & filename ) restore( state, "ShowPossibleCells_rbtn", m_uiForm.ShowPossibleCells_rbtn ); restore( state, "MaxScalarError_ledt", m_uiForm.MaxScalarError_ledt ); restore( state, "BestCellOnly_ckbx", m_uiForm.BestCellOnly_ckbx ); + restore( state, "AllowPermutations_ckbx", m_uiForm.AllowPermutations_ckbx ); restore( state, "SelectCellOfType_rbtn", m_uiForm.SelectCellOfType_rbtn ); restore( state, "CellType_cmbx", m_uiForm.CellType_cmbx ); restore( state, "CellCentering_cmbx", m_uiForm.CellCentering_cmbx ); diff --git a/Code/Mantid/MantidQt/CustomInterfaces/src/MantidEVWorker.cpp b/Code/Mantid/MantidQt/CustomInterfaces/src/MantidEVWorker.cpp index 8119135550aa..0cba832b97f1 100644 --- a/Code/Mantid/MantidQt/CustomInterfaces/src/MantidEVWorker.cpp +++ b/Code/Mantid/MantidQt/CustomInterfaces/src/MantidEVWorker.cpp @@ -614,12 +614,16 @@ bool MantidEVWorker::indexPeaksWithUB( const std::string & peaks_ws_name, * is allowed for a possible cell to be listed. * @param best_only If true, only the best fitting cell of any * particular type will be displayed. + * @param allow_perm If true, permutations are used to find the + * best fitting cell of any + * particular type. * * @return true if the ShowPossibleCells algorithm completes successfully. */ bool MantidEVWorker::showCells( const std::string & peaks_ws_name, double max_scalar_error, - bool best_only ) + bool best_only, + bool allow_perm) { if ( !isPeaksWorkspace( peaks_ws_name ) ) return false; @@ -628,6 +632,7 @@ bool MantidEVWorker::showCells( const std::string & peaks_ws_name, alg->setProperty("PeaksWorkspace",peaks_ws_name); alg->setProperty("MaxScalarError",max_scalar_error); alg->setProperty("BestOnly",best_only); + alg->setProperty("AllowPermutations",allow_perm); if ( alg->execute() ) return true; diff --git a/Code/Mantid/scripts/SCD_Reduction/ReduceSCD.config b/Code/Mantid/scripts/SCD_Reduction/ReduceSCD.config index 7f3d6a0b3437..67b5014828af 100644 --- a/Code/Mantid/scripts/SCD_Reduction/ReduceSCD.config +++ b/Code/Mantid/scripts/SCD_Reduction/ReduceSCD.config @@ -90,11 +90,12 @@ UseFirstLattice True # .integrate file, and will combine, re-index and convert to a conventional # cell, so these can usually be left as None. # -# Cell trnasformation is not applied to cylindrical profiles, +# Cell transformation is not applied to cylindrical profiles, # i.e. use None if cylindrical integration is used! # cell_type None centering None +allow_perm True # # Number of peaks to find, per run, both for getting the UB matrix, diff --git a/Code/Mantid/scripts/SCD_Reduction/ReduceSCD_OneRun.py b/Code/Mantid/scripts/SCD_Reduction/ReduceSCD_OneRun.py index fb1aae072322..dc3686a284a4 100644 --- a/Code/Mantid/scripts/SCD_Reduction/ReduceSCD_OneRun.py +++ b/Code/Mantid/scripts/SCD_Reduction/ReduceSCD_OneRun.py @@ -79,6 +79,7 @@ monitor_index = params_dictionary[ "monitor_index" ] cell_type = params_dictionary[ "cell_type" ] centering = params_dictionary[ "centering" ] +allow_perm = params_dictionary[ "allow_perm" ] num_peaks_to_find = params_dictionary[ "num_peaks_to_find" ] min_d = params_dictionary[ "min_d" ] max_d = params_dictionary[ "max_d" ] @@ -344,6 +345,7 @@ cell_type + "_" + centering + ".integrate" SelectCellOfType( PeaksWorkspace=peaks_ws, CellType=cell_type, Centering=centering, + AllowPermutations=allow_perm, Apply=True, Tolerance=tolerance ) SaveIsawPeaks( InputWorkspace=peaks_ws, AppendFile=False, Filename=run_conventional_integrate_file ) diff --git a/Code/Mantid/scripts/SCD_Reduction/ReduceSCD_Parallel.py b/Code/Mantid/scripts/SCD_Reduction/ReduceSCD_Parallel.py index 44116ccddbf4..68572b5974d8 100644 --- a/Code/Mantid/scripts/SCD_Reduction/ReduceSCD_Parallel.py +++ b/Code/Mantid/scripts/SCD_Reduction/ReduceSCD_Parallel.py @@ -91,6 +91,7 @@ def run ( self ): tolerance = params_dictionary[ "tolerance" ] cell_type = params_dictionary[ "cell_type" ] centering = params_dictionary[ "centering" ] +allow_perm = params_dictionary[ "allow_perm" ] run_nums = params_dictionary[ "run_nums" ] use_cylindrical_integration = params_dictionary[ "use_cylindrical_integration" ] @@ -218,7 +219,7 @@ def run ( self ): conventional_matrix_file = conv_name + ".mat" SelectCellOfType( PeaksWorkspace=peaks_ws, CellType=cell_type, Centering=centering, - Apply=True, Tolerance=tolerance ) + AllowPermutations=allow_perm, Apply=True, Tolerance=tolerance ) SaveIsawPeaks( InputWorkspace=peaks_ws, AppendFile=False, Filename=conventional_integrate_file ) SaveIsawUB( InputWorkspace=peaks_ws, Filename=conventional_matrix_file ) From 0540c103f9caa90a10dc353d578b147a05b0fef8 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 30 May 2014 15:49:08 +0100 Subject: [PATCH 113/126] Remove migration python tool Refs #9523 --- Code/Tools/DocMigration/MigrateOptMessage.py | 127 ------------------- 1 file changed, 127 deletions(-) delete mode 100644 Code/Tools/DocMigration/MigrateOptMessage.py diff --git a/Code/Tools/DocMigration/MigrateOptMessage.py b/Code/Tools/DocMigration/MigrateOptMessage.py deleted file mode 100644 index 9cd9ef764ae4..000000000000 --- a/Code/Tools/DocMigration/MigrateOptMessage.py +++ /dev/null @@ -1,127 +0,0 @@ -import argparse -import fnmatch -import os -import re - - -def main(): - parser = argparse.ArgumentParser() - parser.add_argument("-d","--dry", help="dry run, does not change files",action="store_true") - parser.add_argument("codedir", help="The directory to start searching for algorithms", type=str) - args = parser.parse_args() - - - cppFiles = [] - for root, dirnames, filenames in os.walk(args.codedir): - for filename in fnmatch.filter(filenames, '*.cpp'): - cppFiles.append(os.path.join(root, filename)) - - cppFiles.sort() - for cppFile in cppFiles: - cppdir = os.path.dirname(cppFile) - (cppname,cppext) = os.path.splitext(os.path.basename(cppFile)) - print cppname,"\t", - - #get .h file - subdir = "" - if not cppdir.endswith("src"): - idx = cppdir.find("src") - if idx >= 0: - subdir = cppdir[idx+3:] - cppdir = cppdir[0:idx+3] - - moduledir = os.path.dirname(cppdir) - incdir = os.path.join(moduledir,"inc") - #this should contain only one directory - hdir = "" - for x in os.listdir(incdir): - if os.path.isfile(x): - pass - else: - hdir = os.path.join(incdir,x) - hFile = os.path.join(hdir + subdir,cppname+".h") - if not os.path.isfile(hFile): - print "HEADER NOT FOUND" - #next file - continue - - #read cppFile - cppText= "" - with open (cppFile, "r") as cppfileHandle: - cppText=cppfileHandle.read() - - #read hFile - hText= "" - with open (hFile, "r") as hfileHandle: - hText=hfileHandle.read() - - summary = readOptionalMessage(cppText) - summary = striplinks(summary) - - - if summary != "": - hText=insertSummaryCommand(hText,summary) - hText=removeHeaderInitDocs(hText) - if hText != "": - cppText=removeOptionalMessage(cppText) - if not args.dry: - with open(hFile, "w") as outHFile: - outHFile.write(hText) - with open(cppFile, "w") as outCppFile: - outCppFile.write(cppText) - - print - else: - print "Could not find h instertion position" - else: - print "Could not find summary" - -def striplinks(text): - retVal = text.replace("[[","") - retVal = retVal.replace("]]","") - return retVal - -def readOptionalMessage(cppText): - retVal = "" - match = re.search(r'^.*setOptionalMessage\s*\(\s*"(.+)"\s*\)\s*;\.*$',cppText,re.MULTILINE) - if match: - retVal = match.group(1) - else: - wikiMatch = re.search(r'^.*setWikiSummary\s*\(\s*"(.+)"\s*\)\s*;\.*$',cppText,re.MULTILINE) - if wikiMatch: - retVal = wikiMatch.group(1) - return retVal - -def removeOptionalMessage(cppText): - retVal = regexReplace(r'^.*setOptionalMessage\s*\(\s*"(.+)"\s*\)\s*;\.*$','',cppText,re.MULTILINE) - retVal = regexReplace(r'^.*setWikiSummary\s*\(\s*"(.+)"\s*\)\s*;\.*$','',retVal,re.MULTILINE) - retVal = regexReplace(r'[\w\s/]*::initDocs.*?\}','',retVal,re.DOTALL) - return retVal - -def removeHeaderInitDocs(hText): - retVal = regexReplace(r'[\w\s/]*initDocs.*?$','',hText,re.MULTILINE+re.DOTALL) - return retVal - -def insertSummaryCommand(hText,summary): - retVal = "" - newLine = '\n ///Summary of algorithms purpose\n virtual const std::string summary() const {return "' + summary + '";}\n' - match = re.search(r'^.*const.*string\s+name\(\)\s+const.*$',hText,re.MULTILINE) - if match: - endpos = match.end(0) - #insert new line - retVal = hText[:endpos] + newLine + hText[endpos:] - else: - print "DID NOT MATCH!!!" - return retVal - -def regexReplace(regex,replaceString,inputString,regexOpts): - retVal = inputString - match = re.search(regex,inputString,regexOpts) - if match: - retVal = inputString[:match.start(0)] + replaceString + inputString[match.end(0):] - return retVal - - - - -main() From f3180eff4ca65942e34073d4db3c79b3d15c836f Mon Sep 17 00:00:00 2001 From: Vickie Lynch Date: Fri, 30 May 2014 11:39:12 -0400 Subject: [PATCH 114/126] Refs #9546 only write ls files when PerRun is checked --- .../src/OptimizeLatticeForCellType.cpp | 36 ++++++++++--------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/Code/Mantid/Framework/Crystal/src/OptimizeLatticeForCellType.cpp b/Code/Mantid/Framework/Crystal/src/OptimizeLatticeForCellType.cpp index 84a2f33eaa96..f5432b83209f 100644 --- a/Code/Mantid/Framework/Crystal/src/OptimizeLatticeForCellType.cpp +++ b/Code/Mantid/Framework/Crystal/src/OptimizeLatticeForCellType.cpp @@ -108,9 +108,7 @@ namespace Mantid int edge = this->getProperty("EdgePixels"); std::string cell_type = getProperty("CellType"); DataObjects::PeaksWorkspace_sptr ws = getProperty("PeaksWorkspace"); - std::string outputdir = getProperty("OutputDirectory"); - if (outputdir[outputdir.size()-1] != '/') - outputdir += "/"; + std::vector runWS; for (int i= int(ws->getNumberPeaks())-1; i>=0; --i) @@ -316,19 +314,25 @@ namespace Mantid alg->executeAsChildAlg(); } AnalysisDataService::Instance().remove("_peaks"); - // Save Peaks - Mantid::API::IAlgorithm_sptr savePks_alg = createChildAlgorithm("SaveIsawPeaks"); - savePks_alg->setPropertyValue("InputWorkspace", runWS[i_run]->getName()); - savePks_alg->setProperty("Filename", outputdir + "ls"+runWS[i_run]->getName()+".integrate"); - savePks_alg->executeAsChildAlg(); - g_log.notice() <<"See output file: " << outputdir + "ls"+runWS[i_run]->getName()+".integrate" << "\n"; - // Save UB - Mantid::API::IAlgorithm_sptr saveUB_alg = createChildAlgorithm("SaveIsawUB"); - saveUB_alg->setPropertyValue("InputWorkspace", runWS[i_run]->getName()); - saveUB_alg->setProperty("Filename", outputdir + "ls"+runWS[i_run]->getName()+".mat"); - saveUB_alg->executeAsChildAlg(); - // Show the names of files written - g_log.notice() <<"See output file: " << outputdir + "ls"+runWS[i_run]->getName()+".mat" << "\n"; + if ( perRun) + { + std::string outputdir = getProperty("OutputDirectory"); + if (outputdir[outputdir.size()-1] != '/') + outputdir += "/"; + // Save Peaks + Mantid::API::IAlgorithm_sptr savePks_alg = createChildAlgorithm("SaveIsawPeaks"); + savePks_alg->setPropertyValue("InputWorkspace", runWS[i_run]->getName()); + savePks_alg->setProperty("Filename", outputdir + "ls"+runWS[i_run]->getName()+".integrate"); + savePks_alg->executeAsChildAlg(); + g_log.notice() <<"See output file: " << outputdir + "ls"+runWS[i_run]->getName()+".integrate" << "\n"; + // Save UB + Mantid::API::IAlgorithm_sptr saveUB_alg = createChildAlgorithm("SaveIsawUB"); + saveUB_alg->setPropertyValue("InputWorkspace", runWS[i_run]->getName()); + saveUB_alg->setProperty("Filename", outputdir + "ls"+runWS[i_run]->getName()+".mat"); + saveUB_alg->executeAsChildAlg(); + // Show the names of files written + g_log.notice() <<"See output file: " << outputdir + "ls"+runWS[i_run]->getName()+".mat" << "\n"; + } } } //----------------------------------------------------------------------------------------- From f3d39a1988d3ddd75939725c401e078d2aaca0d3 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Fri, 30 May 2014 17:27:41 +0100 Subject: [PATCH 115/126] Simplify creating the screenshots. They are no created in a directory specified by an environment variable so that they don't have to touch the source directory. Refs #9521 --- Code/Mantid/docs/CMakeLists.txt | 5 +- Code/Mantid/docs/runsphinx.py.in | 6 +- .../mantiddoc/directives/algorithm.py | 77 +++++++------------ 3 files changed, 34 insertions(+), 54 deletions(-) diff --git a/Code/Mantid/docs/CMakeLists.txt b/Code/Mantid/docs/CMakeLists.txt index b6a1bed99409..16da0325eb8d 100644 --- a/Code/Mantid/docs/CMakeLists.txt +++ b/Code/Mantid/docs/CMakeLists.txt @@ -8,6 +8,7 @@ if ( SPHINX_FOUND ) # We generate a target per build type, i.e docs-html set ( SPHINX_BUILD ${CMAKE_BINARY_DIR}/docs ) + set ( SCREENSHOTS_DIR ${SPHINX_BUILD}/screenshots ) set ( BUILDER html ) configure_file ( runsphinx.py.in runsphinx_html.py @ONLY ) @@ -15,9 +16,9 @@ if ( SPHINX_FOUND ) set ( TARGET_PREFIX docs) # HTML target - add_custom_target ( ${TARGET_PREFIX}-html + add_custom_target ( ${TARGET_PREFIX}-html COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MantidPlot -xq runsphinx_html.py - COMMENT "Build Sphinx html documentation" + COMMENT "Building html documentation" ) endif () diff --git a/Code/Mantid/docs/runsphinx.py.in b/Code/Mantid/docs/runsphinx.py.in index d675706b9819..8d1011908dd0 100644 --- a/Code/Mantid/docs/runsphinx.py.in +++ b/Code/Mantid/docs/runsphinx.py.in @@ -11,9 +11,13 @@ from pkg_resources import load_entry_point mantidplot = "@CMAKE_RUNTIME_OUTPUT_DIRECTORY@/MantidPlot" builder = "@BUILDER@" src_dir = "@CMAKE_CURRENT_SOURCE_DIR@/source" +screenshots_dir = "@SCREENSHOTS_DIR@" output_dir = os.path.join("@SPHINX_BUILD@", builder) -argv = [mantidplot,'-b', builder, src_dir, output_dir] +# set environment +os.environ["SCREENSHOTS_DIR"] = screenshots_dir +# fake the sys args +argv = [mantidplot,'-b', builder, src_dir, output_dir] if __name__ == '__main__': sys.exit( load_entry_point(__requires__, 'console_scripts', 'sphinx-build')(argv) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index bb20442d8382..af161d0fa331 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -23,6 +23,10 @@ class AlgorithmDirective(BaseDirective): - Table of contents If the algorithms is deprecated then a warning is inserted. + + It requires a SCREENSHOTS_DIR environment variable to be set to the + directory where a screenshot should be generated. If it is not set then + a RuntimeError occurs """ required_arguments, optional_arguments = 0, 0 @@ -89,8 +93,8 @@ def _insert_toc(self): def _create_screenshot(self): """ - Creates a screenshot for the named algorithm in an "images/screenshots" - subdirectory of the currently processed document + Creates a screenshot for the named algorithm in the "images/screenshots" + subdirectory. The file will be named "algorithmname-vX_dlg.png", e.g. Rebin-v1_dlg.png @@ -115,21 +119,32 @@ def _create_screenshot(self): def _insert_screenshot_link(self, img_path): """ Outputs an image link with a custom :class: style. The filename is - extracted from the path given and then a link to /images/screenshots/filename.png - is created. Sphinx handles copying the files over to the build directory - and reformatting the links + extracted from the path given and then a relative link to the + directory specified by the SCREENSHOTS_DIR environment variable from + the root source directory is formed. Args: img_path (str): The full path as on the filesystem to the image """ + env = self.state.document.settings.env format_str = ".. figure:: %s\n"\ " :class: screenshot\n\n"\ " %s\n\n" + # Sphinx assumes that an absolute path is actually relative to the directory containing the + # conf.py file and a relative path is relative to the directory where the current rst file + # is located. + filename = os.path.split(img_path)[1] - path = "/images/screenshots/" + filename - caption = "A screenshot of the **" + self.algorithm_name() + "** dialog." + cfgdir = env.srcdir + screenshots_dir = self._screenshot_directory() + rel_path = os.path.relpath(screenshots_dir, cfgdir) + # This is a href link so is expected to be in unix style + rel_path = rel_path.replace("\\","/") + # stick a "/" as the first character so Sphinx computes relative location from source directory + path = "/" + rel_path + "/" + filename + caption = "A screenshot of the **" + self.algorithm_name() + "** dialog." self.add_rst(format_str % (path, caption)) def _screenshot_directory(self): @@ -145,7 +160,10 @@ def _screenshot_directory(self): str: A string containing a path to where the screenshots should be created. This will be a filesystem path """ - return screenshot_directory(self.state.document.settings.env.app) + try: + return os.environ["SCREENSHOTS_DIR"] + except: + raise RuntimeError("The '.. algorithm::' directive requires a SCREENSHOTS_DIR environment variable to be set.") def _insert_deprecation_warning(self): """ @@ -169,24 +187,6 @@ def _insert_deprecation_warning(self): #------------------------------------------------------------------------------------------------------------ -def screenshot_directory(app): - """ - Returns a full path where the screenshots should be generated. They are - put in a screenshots subdirectory of the main images directory in the source - tree. Sphinx then handles copying them to the final location - - Arguments: - app (Sphinx.Application): A reference to the application object - - Returns: - str: A string containing a path to where the screenshots should be created. This will - be a filesystem path - """ - cfg_dir = app.srcdir - return os.path.join(cfg_dir, "images", "screenshots") - -#------------------------------------------------------------------------------------------------------------ - def html_collect_pages(app): """ Write out unversioned algorithm pages that redirect to the highest version of the algorithm @@ -206,27 +206,6 @@ def html_collect_pages(app): #------------------------------------------------------------------------------------------------------------ -def purge_screenshots(app, exception): - """ - Remove all screenshots images that were generated in the source directory during the build - - Arguments: - app (Sphinx.Application): A reference to the application object - exception (Exception): If an exception was raised this is a reference to the exception object, else None - """ - import os - - screenshot_dir = screenshot_directory(app) - for filename in os.listdir(screenshot_dir): - filepath = os.path.join(screenshot_dir, filename) - try: - if os.path.isfile(filepath): - os.remove(filepath) - except Exception, e: - app.warn(str(e)) - -#------------------------------------------------------------------------------------------------------------ - def setup(app): """ Setup the directives when the extension is activated @@ -238,7 +217,3 @@ def setup(app): # connect event html collection to handler app.connect("html-collect-pages", html_collect_pages) - - # Remove all generated screenshots from the source directory when finished - # so that they don't become stale - app.connect("build-finished", purge_screenshots) \ No newline at end of file From 6aa58fbd775f3b325b520e9e5988c3c81aa59996 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Sun, 1 Jun 2014 20:16:54 +0100 Subject: [PATCH 116/126] Allow older versions of algorithms to be referenced Refs #9521 --- .../sphinxext/mantiddoc/directives/algorithm.py | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py index af161d0fa331..ec14e58566f4 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/algorithm.py @@ -16,8 +16,9 @@ class AlgorithmDirective(BaseDirective): Inserts details of an algorithm by querying Mantid Adds: - - A referenceable link for use with Sphinx ":ref:`` tags", if this is - the highest version of the algorithm being processed + - A referenceable link for use with Sphinx ":ref:`` tags". If this is + the highest version of the algorithm being processed then a both + a versioned link is created and a non-versioned link - A title - A screenshot of the algorithm - Table of contents @@ -70,13 +71,19 @@ def _track_algorithm(self): def _insert_reference_link(self): """ Outputs a reference to the top of the algorithm's rst - of the form .. _AlgorithmName: if this is the highest version + of the form ".. _algm-AlgorithmName-vVersion:", so that + the page can be referenced using + :ref:`algm-AlgorithmName-version`. If this is the highest + version then it also outputs a reference ".. _algm-AlgorithmName: """ from mantid.api import AlgorithmFactory alg_name = self.algorithm_name() - if AlgorithmFactory.highestVersion(alg_name) == self.algorithm_version(): - self.add_rst(".. _algorithm|%s:\n" % alg_name) + version = self.algorithm_version() + self.add_rst(".. _algm-%s-v%d:\n" % (alg_name, version)) + + if AlgorithmFactory.highestVersion(alg_name) == version: + self.add_rst(".. _algm-%s:\n" % alg_name) def _insert_pagetitle(self): """ From c5db858279a5efa8e7febcaffe02f63a6f027146 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Sun, 1 Jun 2014 20:26:25 +0100 Subject: [PATCH 117/126] Add docs-test target to run sphinx doctests Refs #9521 --- Code/Mantid/docs/CMakeLists.txt | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/Code/Mantid/docs/CMakeLists.txt b/Code/Mantid/docs/CMakeLists.txt index 16da0325eb8d..4f19643c5862 100644 --- a/Code/Mantid/docs/CMakeLists.txt +++ b/Code/Mantid/docs/CMakeLists.txt @@ -9,18 +9,26 @@ if ( SPHINX_FOUND ) # We generate a target per build type, i.e docs-html set ( SPHINX_BUILD ${CMAKE_BINARY_DIR}/docs ) set ( SCREENSHOTS_DIR ${SPHINX_BUILD}/screenshots ) - set ( BUILDER html ) - configure_file ( runsphinx.py.in runsphinx_html.py @ONLY ) # targets set ( TARGET_PREFIX docs) # HTML target + set ( BUILDER html ) + configure_file ( runsphinx.py.in runsphinx_html.py @ONLY ) add_custom_target ( ${TARGET_PREFIX}-html COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MantidPlot -xq runsphinx_html.py COMMENT "Building html documentation" ) + # doctest target + set ( BUILDER doctest ) + configure_file ( runsphinx.py.in runsphinx_doctest.py @ONLY ) + add_custom_target ( ${TARGET_PREFIX}-test + COMMAND ${PYTHON_EXECUTABLE} runsphinx_doctest.py + COMMENT "Running documentation tests" + ) + endif () From f02531e224fb248793c7e1062472292a7624187e Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Mon, 2 Jun 2014 08:13:47 +0100 Subject: [PATCH 118/126] Use cmake variable to set MantidPlot used for docs build This will allow us to use a package rather than a fresh build if necessary. Refs #9521 --- Code/Mantid/docs/CMakeLists.txt | 15 ++++++++------- Code/Mantid/docs/runsphinx.py.in | 2 +- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/Code/Mantid/docs/CMakeLists.txt b/Code/Mantid/docs/CMakeLists.txt index 4f19643c5862..e9dac87df73b 100644 --- a/Code/Mantid/docs/CMakeLists.txt +++ b/Code/Mantid/docs/CMakeLists.txt @@ -4,20 +4,21 @@ find_package ( Sphinx ) if ( SPHINX_FOUND ) - # Fill in the config file and autogen file with build information - - # We generate a target per build type, i.e docs-html - set ( SPHINX_BUILD ${CMAKE_BINARY_DIR}/docs ) - set ( SCREENSHOTS_DIR ${SPHINX_BUILD}/screenshots ) + # We generate a target per build type, i.e docs-html, docs-test + set ( SPHINX_BUILD_DIR ${CMAKE_BINARY_DIR}/docs ) + set ( SCREENSHOTS_DIR ${SPHINX_BUILD_DIR}/screenshots ) # targets set ( TARGET_PREFIX docs) + # runner - default=current build + set ( DOCS_RUNNER_EXE ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/${CMAKE_CFG_INTDIR}/MantidPlot CACHE FILEPATH + "MantidPlot executable to use to build the documentation" ) # HTML target set ( BUILDER html ) configure_file ( runsphinx.py.in runsphinx_html.py @ONLY ) add_custom_target ( ${TARGET_PREFIX}-html - COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MantidPlot -xq runsphinx_html.py + COMMAND ${DOCS_RUNNER_EXE} -xq runsphinx_html.py COMMENT "Building html documentation" ) @@ -25,7 +26,7 @@ if ( SPHINX_FOUND ) set ( BUILDER doctest ) configure_file ( runsphinx.py.in runsphinx_doctest.py @ONLY ) add_custom_target ( ${TARGET_PREFIX}-test - COMMAND ${PYTHON_EXECUTABLE} runsphinx_doctest.py + COMMAND ${DOCS_RUNNER_EXE} -xq runsphinx_doctest.py COMMENT "Running documentation tests" ) diff --git a/Code/Mantid/docs/runsphinx.py.in b/Code/Mantid/docs/runsphinx.py.in index 8d1011908dd0..45724dc86fe3 100644 --- a/Code/Mantid/docs/runsphinx.py.in +++ b/Code/Mantid/docs/runsphinx.py.in @@ -12,7 +12,7 @@ mantidplot = "@CMAKE_RUNTIME_OUTPUT_DIRECTORY@/MantidPlot" builder = "@BUILDER@" src_dir = "@CMAKE_CURRENT_SOURCE_DIR@/source" screenshots_dir = "@SCREENSHOTS_DIR@" -output_dir = os.path.join("@SPHINX_BUILD@", builder) +output_dir = os.path.join("@SPHINX_BUILD_DIR@", builder) # set environment os.environ["SCREENSHOTS_DIR"] = screenshots_dir From 893e11b45c29368910ec476ec713101d153850b7 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Mon, 2 Jun 2014 10:43:49 +0100 Subject: [PATCH 119/126] Add search path for CMake to find Sphinx on Windows. Refs #9559 --- Code/Mantid/Build/CMake/FindSphinx.cmake | 1 + 1 file changed, 1 insertion(+) diff --git a/Code/Mantid/Build/CMake/FindSphinx.cmake b/Code/Mantid/Build/CMake/FindSphinx.cmake index 42b53237fff2..99727469870f 100644 --- a/Code/Mantid/Build/CMake/FindSphinx.cmake +++ b/Code/Mantid/Build/CMake/FindSphinx.cmake @@ -8,6 +8,7 @@ # SPHINX_EXECUTABLE find_program( SPHINX_EXECUTABLE NAME sphinx-build + PATHS ${CMAKE_LIBRARY_PATH}/Python27/Scripts PATH_SUFFIXES bin DOC "Sphinx documentation generator" ) From 8fac852114a841ed1ccff506a7292aacae3b7b6c Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Mon, 2 Jun 2014 10:44:42 +0100 Subject: [PATCH 120/126] Simplify Sphinx runner script. It just calls the sphinx.main() function directly without the need to go through pkg_resources. Refs #9559 --- Code/Mantid/docs/runsphinx.py.in | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/Code/Mantid/docs/runsphinx.py.in b/Code/Mantid/docs/runsphinx.py.in index 45724dc86fe3..02316f03b62b 100644 --- a/Code/Mantid/docs/runsphinx.py.in +++ b/Code/Mantid/docs/runsphinx.py.in @@ -2,24 +2,18 @@ module. This script calls the sphinx entry point with the necessary arguments """ - -__requires__ = 'Sphinx' -import sys import os -from pkg_resources import load_entry_point +import sys + +# set environment +os.environ["SCREENSHOTS_DIR"] = "@SCREENSHOTS_DIR@" -mantidplot = "@CMAKE_RUNTIME_OUTPUT_DIRECTORY@/MantidPlot" builder = "@BUILDER@" src_dir = "@CMAKE_CURRENT_SOURCE_DIR@/source" -screenshots_dir = "@SCREENSHOTS_DIR@" output_dir = os.path.join("@SPHINX_BUILD_DIR@", builder) -# set environment -os.environ["SCREENSHOTS_DIR"] = screenshots_dir -# fake the sys args -argv = [mantidplot,'-b', builder, src_dir, output_dir] -if __name__ == '__main__': - sys.exit( - load_entry_point(__requires__, 'console_scripts', 'sphinx-build')(argv) - ) +if __name__ == "__main__": + from sphinx import main + argv = [sys.executable, "-b", builder, src_dir, output_dir] + sys.exit(main(argv)) From 95be1d53d7b983934194b4cbed996281b1d12509 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Mon, 2 Jun 2014 10:51:46 +0100 Subject: [PATCH 121/126] Group the documentation targets in Visual Studio. Refs #9559 --- Code/Mantid/MantidPlot/docs/python/CMakeLists.txt | 3 +++ Code/Mantid/docs/CMakeLists.txt | 3 +++ Code/Mantid/docs/qtassistant/CMakeLists.txt | 1 + 3 files changed, 7 insertions(+) diff --git a/Code/Mantid/MantidPlot/docs/python/CMakeLists.txt b/Code/Mantid/MantidPlot/docs/python/CMakeLists.txt index b31900a21e74..8f761161f7f2 100644 --- a/Code/Mantid/MantidPlot/docs/python/CMakeLists.txt +++ b/Code/Mantid/MantidPlot/docs/python/CMakeLists.txt @@ -60,6 +60,7 @@ if ( SPHINX_FOUND ) DEPENDS ${SPHINX_CONF_FILES} COMMENT "Generating Python API for sphinx" ) + set_property ( TARGET ${TARGET_NAME}-generateapi PROPERTY FOLDER "Documentation/python" ) # HTML target set ( SPHINX_HTML_BUILD ${SPHINX_BUILD}/html ) @@ -67,6 +68,7 @@ if ( SPHINX_FOUND ) COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MantidPlot -xq runsphinx_html.py COMMENT "Build Sphinx html documentation" ) + set_property ( TARGET ${TARGET_NAME}-html PROPERTY FOLDER "Documentation/python" ) add_dependencies( ${TARGET_NAME}-html ${TARGET_NAME}-generateapi ) # Latex target @@ -75,6 +77,7 @@ if ( SPHINX_FOUND ) COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MantidPlot -xq runsphinx_latex.py COMMENT "Build Python Sphinx latex documentation" ) + set_property ( TARGET ${TARGET_NAME}-latex PROPERTY FOLDER "Documentation/python" ) add_dependencies( ${TARGET_NAME}-latex ${TARGET_NAME}-generateapi ) diff --git a/Code/Mantid/docs/CMakeLists.txt b/Code/Mantid/docs/CMakeLists.txt index e9dac87df73b..0fc353a6d9c1 100644 --- a/Code/Mantid/docs/CMakeLists.txt +++ b/Code/Mantid/docs/CMakeLists.txt @@ -21,6 +21,8 @@ if ( SPHINX_FOUND ) COMMAND ${DOCS_RUNNER_EXE} -xq runsphinx_html.py COMMENT "Building html documentation" ) + # Group within VS + set_property ( TARGET ${TARGET_PREFIX}-html PROPERTY FOLDER "Documentation" ) # doctest target set ( BUILDER doctest ) @@ -29,6 +31,7 @@ if ( SPHINX_FOUND ) COMMAND ${DOCS_RUNNER_EXE} -xq runsphinx_doctest.py COMMENT "Running documentation tests" ) + set_property ( TARGET ${TARGET_PREFIX}-test PROPERTY FOLDER "documentation" ) endif () diff --git a/Code/Mantid/docs/qtassistant/CMakeLists.txt b/Code/Mantid/docs/qtassistant/CMakeLists.txt index 496ebec13402..c9abcef608f7 100644 --- a/Code/Mantid/docs/qtassistant/CMakeLists.txt +++ b/Code/Mantid/docs/qtassistant/CMakeLists.txt @@ -167,6 +167,7 @@ find_program ( DVIPNG_EXE dvipng ) POST_BUILD COMMAND ${CMAKE_COMMAND} ARGS -E copy_directory ${HELP_OUT_DIR} ${HELP_BIN_OUT_DIR} ) + set_property ( TARGET ${TARGET_PREFIX}-test PROPERTY FOLDER "Documentation" ) ########################################################################################### # Installation settings From b9c991e774490d73f4f5af9dad8d2a8c3625e09c Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Mon, 2 Jun 2014 11:07:08 +0100 Subject: [PATCH 122/126] Use .summary() instead of deprecated .getWikiSummary() Refs #9559 --- Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py index 3d92a9071bd8..23fde38832eb 100644 --- a/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py +++ b/Code/Mantid/docs/sphinxext/mantiddoc/directives/summary.py @@ -15,7 +15,7 @@ def run(self): """ self.add_rst(self.make_header("Summary")) alg = self.create_mantid_algorithm(self.algorithm_name(), self.algorithm_version()) - self.add_rst(alg.getWikiSummary()) + self.add_rst(alg.summary()) self.commit_rst() return [] From 334175b9ca254322c5405534a590198f07129b40 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Mon, 2 Jun 2014 12:19:02 +0100 Subject: [PATCH 123/126] Ensure MantidPlot exits with 0 status code on script success. Refs #9559 --- Code/Mantid/MantidPlot/src/ApplicationWindow.cpp | 13 +++++++++++++ Code/Mantid/MantidPlot/src/ApplicationWindow.h | 2 ++ 2 files changed, 15 insertions(+) diff --git a/Code/Mantid/MantidPlot/src/ApplicationWindow.cpp b/Code/Mantid/MantidPlot/src/ApplicationWindow.cpp index 2b4b38256c9c..071663e8c05a 100644 --- a/Code/Mantid/MantidPlot/src/ApplicationWindow.cpp +++ b/Code/Mantid/MantidPlot/src/ApplicationWindow.cpp @@ -16438,6 +16438,7 @@ void ApplicationWindow::executeScriptFile(const QString & filename, const Script code += in.readLine() + "\n"; } Script *runner = scriptingEnv()->newScript(filename, this, Script::NonInteractive); + connect(runner, SIGNAL(finished(const QString &)), this, SLOT(onScriptExecuteSuccess(const QString &))); connect(runner, SIGNAL(error(const QString &, const QString &, int)), this, SLOT(onScriptExecuteError(const QString &, const QString &, int))); runner->redirectStdOut(false); scriptingEnv()->redirectStdOut(false); @@ -16459,6 +16460,18 @@ void ApplicationWindow::executeScriptFile(const QString & filename, const Script delete runner; } +/** + * This is the slot for handing script exits when it returns successfully + * + * @param lineNumber The line number in the script that caused the error. + */ +void ApplicationWindow::onScriptExecuteSuccess(const QString & message) +{ + g_log.notice() << message.toStdString() << "\n"; + this->setExitCode(0); + this->exitWithPresetCode(); +} + /** * This is the slot for handing script execution errors. It is only * attached by ::executeScriptFile which is only done in the '-xq' diff --git a/Code/Mantid/MantidPlot/src/ApplicationWindow.h b/Code/Mantid/MantidPlot/src/ApplicationWindow.h index 4e1a157ec32f..c575f6fb3d60 100644 --- a/Code/Mantid/MantidPlot/src/ApplicationWindow.h +++ b/Code/Mantid/MantidPlot/src/ApplicationWindow.h @@ -230,6 +230,8 @@ public slots: ApplicationWindow * loadScript(const QString& fn); /// Runs a script from a file. Mainly useful for automatically running scripts void executeScriptFile(const QString & filename, const Script::ExecutionMode execMode); + /// Slot to connect the script execution success + void onScriptExecuteSuccess(const QString & message); /// Slot to connect the script execution errors to void onScriptExecuteError(const QString & message, const QString & scriptName, int lineNumber); /// Runs an arbitrary lump of python code, return true/false on success/failure. From 315b453bda2fecab8b9333de2eab15f5bc39de1a Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Mon, 2 Jun 2014 12:31:37 +0100 Subject: [PATCH 124/126] Correction for CMake folder target. Refs #9559 --- Code/Mantid/docs/qtassistant/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/docs/qtassistant/CMakeLists.txt b/Code/Mantid/docs/qtassistant/CMakeLists.txt index c9abcef608f7..c6d6592cb7ca 100644 --- a/Code/Mantid/docs/qtassistant/CMakeLists.txt +++ b/Code/Mantid/docs/qtassistant/CMakeLists.txt @@ -167,7 +167,7 @@ find_program ( DVIPNG_EXE dvipng ) POST_BUILD COMMAND ${CMAKE_COMMAND} ARGS -E copy_directory ${HELP_OUT_DIR} ${HELP_BIN_OUT_DIR} ) - set_property ( TARGET ${TARGET_PREFIX}-test PROPERTY FOLDER "Documentation" ) + set_property ( TARGET qtassistant PROPERTY FOLDER "Documentation" ) ########################################################################################### # Installation settings From 538904dc35dda4022f983fda22b5bc613c838d48 Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Mon, 2 Jun 2014 12:38:16 +0100 Subject: [PATCH 125/126] Fix case of VS folder name Refs #9559 --- Code/Mantid/docs/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Code/Mantid/docs/CMakeLists.txt b/Code/Mantid/docs/CMakeLists.txt index 0fc353a6d9c1..31c6e117b4f4 100644 --- a/Code/Mantid/docs/CMakeLists.txt +++ b/Code/Mantid/docs/CMakeLists.txt @@ -31,7 +31,7 @@ if ( SPHINX_FOUND ) COMMAND ${DOCS_RUNNER_EXE} -xq runsphinx_doctest.py COMMENT "Running documentation tests" ) - set_property ( TARGET ${TARGET_PREFIX}-test PROPERTY FOLDER "documentation" ) + set_property ( TARGET ${TARGET_PREFIX}-test PROPERTY FOLDER "Documentation" ) endif () From c3b0fe09a69528e007f0e6c9601a275ad8ec253c Mon Sep 17 00:00:00 2001 From: Martyn Gigg Date: Mon, 2 Jun 2014 13:26:57 +0100 Subject: [PATCH 126/126] Exclude the sphinx docs by default from VS build Refs #9559 --- .../MantidPlot/docs/python/CMakeLists.txt | 24 +++++++------------ Code/Mantid/docs/CMakeLists.txt | 12 ++++++---- 2 files changed, 17 insertions(+), 19 deletions(-) diff --git a/Code/Mantid/MantidPlot/docs/python/CMakeLists.txt b/Code/Mantid/MantidPlot/docs/python/CMakeLists.txt index 8f761161f7f2..250885f4435f 100644 --- a/Code/Mantid/MantidPlot/docs/python/CMakeLists.txt +++ b/Code/Mantid/MantidPlot/docs/python/CMakeLists.txt @@ -60,26 +60,20 @@ if ( SPHINX_FOUND ) DEPENDS ${SPHINX_CONF_FILES} COMMENT "Generating Python API for sphinx" ) - set_property ( TARGET ${TARGET_NAME}-generateapi PROPERTY FOLDER "Documentation/python" ) + # Group within VS and exclude from whole build + set_target_properties ( ${TARGET_NAME}-generateapi PROPERTIES FOLDER "Documentation/python" + EXCLUDE_FROM_DEFAULT_BUILD 1 + EXCLUDE_FROM_ALL 1) + # HTML target set ( SPHINX_HTML_BUILD ${SPHINX_BUILD}/html ) add_custom_target ( ${TARGET_NAME}-html COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MantidPlot -xq runsphinx_html.py COMMENT "Build Sphinx html documentation" ) - set_property ( TARGET ${TARGET_NAME}-html PROPERTY FOLDER "Documentation/python" ) - add_dependencies( ${TARGET_NAME}-html ${TARGET_NAME}-generateapi ) - - # Latex target - set ( SPHINX_LATEX_BUILD ${SPHINX_BUILD}/latex ) - add_custom_target ( ${TARGET_NAME}-latex - COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MantidPlot -xq runsphinx_latex.py - COMMENT "Build Python Sphinx latex documentation" - ) - set_property ( TARGET ${TARGET_NAME}-latex PROPERTY FOLDER "Documentation/python" ) - add_dependencies( ${TARGET_NAME}-latex ${TARGET_NAME}-generateapi ) - - - + # Group within VS and exclude from whole build + set_target_properties ( ${TARGET_NAME}-html PROPERTIES FOLDER "Documentation/python" + EXCLUDE_FROM_DEFAULT_BUILD 1 + EXCLUDE_FROM_ALL 1) endif () diff --git a/Code/Mantid/docs/CMakeLists.txt b/Code/Mantid/docs/CMakeLists.txt index 31c6e117b4f4..953974978a30 100644 --- a/Code/Mantid/docs/CMakeLists.txt +++ b/Code/Mantid/docs/CMakeLists.txt @@ -21,8 +21,10 @@ if ( SPHINX_FOUND ) COMMAND ${DOCS_RUNNER_EXE} -xq runsphinx_html.py COMMENT "Building html documentation" ) - # Group within VS - set_property ( TARGET ${TARGET_PREFIX}-html PROPERTY FOLDER "Documentation" ) + # Group within VS and exclude from whole build + set_target_properties ( ${TARGET_PREFIX}-html PROPERTIES FOLDER "Documentation" + EXCLUDE_FROM_DEFAULT_BUILD 1 + EXCLUDE_FROM_ALL 1) # doctest target set ( BUILDER doctest ) @@ -31,8 +33,10 @@ if ( SPHINX_FOUND ) COMMAND ${DOCS_RUNNER_EXE} -xq runsphinx_doctest.py COMMENT "Running documentation tests" ) - set_property ( TARGET ${TARGET_PREFIX}-test PROPERTY FOLDER "Documentation" ) - + # Group within VS and exclude from whole build + set_target_properties ( ${TARGET_PREFIX}-test PROPERTIES FOLDER "Documentation" + EXCLUDE_FROM_DEFAULT_BUILD 1 + EXCLUDE_FROM_ALL 1) endif ()