Module: run.launch

Main program to run pySPACE

For further instructions take a look at the pySPACE documentation and the tutorials in there!


Due to errors in configuration files, data or the software, the software may crash. Because of internal parallelization and threading, it is currently not possible to use ‘’ctrl + c’‘. So you should kill the processes manually e.g.:

ctrl + z
kill -9 %1


For profiling the software you should use the option --profile, when running pySPACE. Furthermore you should use the SerialBackend. Otherwise the started subprocesses can not be examined. The result is called profile.pstat and saved in your result folder. For getting a print out of this profiling, you can use in the library folder. (partial) Copy from the documentation:

General usage:

python -f pstats profiling_file -r pySPACE | dot -Tpng -o output.png

or simple usage in result folder, when pyspace is on same level as general storage folder:

python ../../../pyspace/pySPACE/tools/ -f pstats profile.pstat | dot -Tpng -o output.png

where profiling_file is the file that is generated by the cProfile module and output.png is the filename of the resulting picture. The option ‘-r’, ‘–restrict’ is there to eliminate functions in the profiling, that do not contain this string in their path name [default: None].


For creating the graphic, which is done with the ‘dot’ command, the GraphViz package needs to be installed.

Inheritance diagram for

Inheritance diagram of

Class Summary

LaunchParser([usage, option_list, ...]) Overwrite epilog printout

Function Summary

run_operation(default_backend, operation[, ...]) Runs the given operation on the backend
run_operation_chain(default_backend, ...) Runs the given operation chain on the backend



class, option_list=None, option_class=<class optparse.Option>, version=None, conflict_handler='error', description=None, formatter=None, add_help_option=True, prog=None, epilog=None)[source]

Bases: optparse.OptionParser

Overwrite epilog printout

Code taken from:

Class Components Summary

format_epilog(formatter) Simply do not change the format of the string

Simply do not change the format of the string


run_operation(), operation, ex_timeout=1000000.0, re_timeout=1000000.0)[source]

Runs the given operation on the backend

Runs the given operation operation either on the backend specified in the operation’ spec file or (if none is specified) on the backend passed as default_backend.

Different timeouts are required, because for the execute function get is called which does not accept to high timeouts without proper error handling on a Mac OS X whereas Linux systems are fine with larger timeouts.

run_operation_chain(), operation_chain)[source]

Runs the given operation chain on the backend

Runs the given operation chain operation_chain on the backend passed as default_backend.