Algorithm
This is a Python binding to the C++ class Mantid::API::Algorithm.
bases: mantid.api.IAlgorithm
-
class mantid.api.Algorithm((object)arg1)
Base class for all algorithms
-
__init__((object)arg1) → None
-
alias((IAlgorithm)self) → str :
Return the aliases for the algorithm
-
cancel((IAlgorithm)self) → None :
Request that the algorithm stop running
-
categories((IAlgorithm)self) → numpy.ndarray :
Returns the list of categories this algorithm belongs to
-
category((IAlgorithm)self) → str :
Returns the category containing the algorithm
-
createChildAlgorithm((Algorithm)self, (str)name[, (float)startProgress=-1.0[, (float)endProgress=-1.0[, (bool)enableLogging=True[, (int)version=-1]]]]) → Algorithm :
Creates and intializes a named child algorithm. Output workspaces are given a dummy name.
-
declareProperty((object)self, (Property)prop[, (str)doc='']) → None
- declareProperty( (object)self, (str)name, (object)defaultValue [, (object)validator=None [, (str)doc=’’ [, (int)direction=_kernel.Direction.Input]]]) -> None :
- Declares a named property where the type is taken from the type of the defaultValue and mapped to an appropriate C++ type
- declareProperty( (object)self, (str)name, (object)defaultValue [, (str)doc=’’ [, (int)direction=_kernel.Direction.Input]]) -> None :
- Declares a named property where the type is taken from the type of the defaultValue and mapped to an appropriate C++ type
- declareProperty( (object)self, (str)name, (object)defaultValue [, (int)direction=_kernel.Direction.Input]) -> None :
- Declares a named property where the type is taken from the type of the defaultValue and mapped to an appropriate C++ type
-
docString((IAlgorithm)self) → str :
Returns a doc string for the algorithm
-
enableHistoryRecordingForChild((Algorithm)self, (bool)on) → None :
Turns history recording on or off for an algorithm.
-
execute((object)self) → bool :
Runs the algorithm and returns whether it has been successful
-
executeAsync((object)self) → None :
Starts the algorithm in a separate thread and returns immediately
-
existsProperty((IPropertyManager)self, (str)name) → bool :
Returns whether a property exists
-
fromString((str)arg1) → IAlgorithm :
Initialize the algorithm from a string representation
-
get((IPropertyManager)self, (str)name, (object)value) → Property :
Returns the property of the given name. Use .value to give the value. If property with given name does not exist, returns given default value.
-
getAlgStartupLogging((IAlgorithm)self) → bool :
Returns true if logging of start and end messages
-
getAlgorithmID((IAlgorithm)self) → object :
Returns a unique identifier for this algorithm object
-
getLogger((Algorithm)self) → Logger :
Returns a reference to this algorithm’s logger
-
getOptionalMessage((IAlgorithm)self) → str :
Returns the optional user message attached to the algorithm
-
getProperties((IPropertyManager)self) → std_vector_property :
Returns the list of properties managed by this object
-
getProperty((IPropertyManager)self, (str)name) → Property :
Returns the property of the given name. Use .value to give the value
-
getPropertyValue((IPropertyManager)self, (str)name) → str :
Returns a string representation of the named property’s value
-
getWikiSummary((IAlgorithm)self) → str :
Returns the summary found on the wiki page
-
has_key((IPropertyManager)self, (str)name) → bool :
Returns whether a property exists
-
helpURL((IAlgorithm)self) → str :
Returns optional URL for algorithm documentation
-
initialize((IAlgorithm)self) → None :
Initializes the algorithm
-
inoutProperties((IAlgorithm)self) → list :
Returns a list of the inout properties on the algorithm
-
isChild((IAlgorithm)self) → bool :
Returns True if the algorithm has been marked to run as a child. If True then Output workspaces are NOT stored in the Analysis Data Service but must be retrieved from the property.
-
isExecuted((IAlgorithm)self) → bool :
Returns True if the algorithm has been executed successfully, False otherwise
-
isInitialized((IAlgorithm)self) → bool :
Returns True if the algorithm is initialized, False otherwise
-
isLogging((IAlgorithm)self) → bool :
Returns True if the algorithm’s logger is turned on, False otherwise
-
isRunning((IAlgorithm)self) → bool :
Returns True if the algorithm is considered to be running, False otherwise
-
keys((IPropertyManager)self) → list
-
log((Algorithm)self) → Logger :
Returns a reference to this algorithm’s logger
-
mandatoryProperties((IAlgorithm)self) → list :
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.
-
name((IAlgorithm)self) → str :
Returns the name of the algorithm
-
orderedProperties((IAlgorithm)self) → list :
Return a list of input, in/out and output properties such that the mandatory properties are first followed by the optional ones.
-
outputProperties((IAlgorithm)self) → list :
Returns a list of the output properties on the algorithm
-
propertyCount((IPropertyManager)self) → int :
Returns the number of properties being managed
-
seeAlso((IAlgorithm)self) → numpy.ndarray :
Returns the list of similar algorithms
-
setAlgStartupLogging((IAlgorithm)self, (bool)enabled) → None :
If true then allow logging of start and end messages
-
setAlwaysStoreInADS((IAlgorithm)self, (bool)do_store) → None :
If true then even child algorithms will have their workspaces stored in the ADS.
-
setChild((IAlgorithm)self, (bool)is_child) → None :
If true this algorithm is run as a child algorithm. There will be no logging and nothing is stored in the Analysis Data Service
-
setLogging((IAlgorithm)self, (bool)value) → None :
Toggle logging on/off.
-
setProperties((IPropertyManager)self, (dict)kwargs) → None :
Set a collection of properties from a dict
-
setProperty((IPropertyManager)self, (str)name, (object)value) → None :
Set the value of the named property
-
setPropertyGroup((IPropertyManager)self, (str)name, (str)group) → None :
Set the group for a given property
-
setPropertySettings((IPropertyManager)self, (str)name, (IPropertySettings)settingsManager) → None :
Assign the given IPropertySettings object to the named property
-
setPropertyValue((IPropertyManager)self, (str)name, (str)value) → None :
Set the value of the named property via a string
-
setRethrows((IAlgorithm)self, (bool)rethrow) → None :
To query whether an algorithm should rethrow exceptions when executing.
-
setWikiSummary((Algorithm)self, (str)summary) → None :
(Deprecated.) Set summary for the help.
-
summary((IAlgorithm)self) → str :
Returns a summary message describing the algorithm
-
validateInputs((IAlgorithm)self) → dict :
Cross-check all inputs and return any errors as a dictionary
-
values((IPropertyManager)self) → std_vector_property :
Returns the list of properties managed by this object
-
version((IAlgorithm)self) → int :
Returns the version number of the algorithm
-
workspaceMethodInputProperty((IAlgorithm)self) → str :
Returns the name of the input workspace property used by the calling object
-
workspaceMethodName((IAlgorithm)self) → str :
Returns a name that will be used when attached as a workspace method. Empty string indicates do not attach
-
workspaceMethodOn((IAlgorithm)self) → numpy.ndarray :
Returns a set of class names that will have the method attached. Empty list indicates all types