nipype.pipeline.plugins.base module

Common graph operations for execution.

class nipype.pipeline.plugins.base.DistributedPluginBase(plugin_args=None)

Bases: nipype.pipeline.plugins.base.PluginBase

Execute workflow with a distribution engine

Combinations of proc_done and proc_pending:

proc_done proc_pending outcome
True False Process is finished
True True Process is currently being run
False False Process is queued
False True INVALID COMBINATION
procs

list (N) of underlying interface elements to be processed

Type:list
proc_done

a boolean numpy array (N,) signifying whether a process has been submitted for execution

Type:numpy.ndarray
proc_pending

a boolean numpy array (N,) signifying whether a process is currently running.

Type:numpy.ndarray
depidx

a boolean matrix (NxN) storing the dependency structure accross processes. Process dependencies are derived from each column.

Type:numpy.matrix
run(graph, config, updatehash=False)

Executes a pre-defined pipeline using distributed approaches

class nipype.pipeline.plugins.base.GraphPluginBase(plugin_args=None)

Bases: nipype.pipeline.plugins.base.PluginBase

Base class for plugins that distribute graphs to workflows

run(graph, config, updatehash=False)

Instruct the plugin to execute the workflow graph.

The core plugin member that should be implemented by all plugins.

Parameters:
  • graph – a networkx, flattened DAG to be executed
  • config (config) – a nipype.config object
  • updatehash (bool) – whether cached nodes with stale hash should be just updated.
class nipype.pipeline.plugins.base.PluginBase(plugin_args=None)

Bases: object

Base class for plugins.

run(graph, config, updatehash=False)

Instruct the plugin to execute the workflow graph.

The core plugin member that should be implemented by all plugins.

Parameters:
  • graph – a networkx, flattened DAG to be executed
  • config (config) – a nipype.config object
  • updatehash (bool) – whether cached nodes with stale hash should be just updated.
class nipype.pipeline.plugins.base.SGELikeBatchManagerBase(template, plugin_args=None)

Bases: nipype.pipeline.plugins.base.DistributedPluginBase

Execute workflow with SGE/OGE/PBS like batch system