Run plugin in parallel

This tool is useful in situations when you have to run the same plugin tool many times. For example, you may have numerous images all of which must be processed with a spatial filter. To run the tool, the user must specify the name of the plugin and the name of a text file containing the parameter information. The plugin tool will be run once for each non-empty line within the parameter text file. Parameters should be separated by commas. The correct type and order of parameters for any plugin tool can be found by reading the Scripting section of its help entry. There is no need to enclose parameters within quotation marks in the parameter file. The parameter file can be made using any plain text editor. The user must also specify whether or not to suppress any data that is returned by the plugin tool, e.g. an automatically displayed image. Notice that it is not recommended that the same file be used as input to more than one of the plugin runs as this may cause a concurrency error if the file is read simutaneously by more than one thread.

See Also:

Scripting:

This is an example of a Python script using this tool:

wd = pluginHost.getWorkingDirectory()
pluginName = "FillDepressions"
parameterFile = wd + "parameters.txt"
suppressReturns = "false"
args = [pluginName, parameterFile, suppressReturns]
pluginHost.runPlugin("RunPluginInParallel", args, False)

And the following is a Groovy script also using this tool:

def wd = pluginHost.getWorkingDirectory()
def pluginName = "FilterGaussian"
def parameterFile = wd + "parameters.txt"
def suppressReturns = "true"
String[] args = [pluginName, parameterFile, suppressReturns]
pluginHost.runPlugin("RunPluginInParallel", args, false)

Credits: