OPAL (Object Oriented Parallel Accelerator Library)
2.2.0
OPAL
|
#include <PythonExpr.h>
Public Member Functions | |
Expressions::Result_t | operator() (client::function::arguments_t args) |
Execute a python script using all given arguments (except for the first being the script name) and return the value of the "result" variable in the python script. Expression arguments can be accessed in the Python script using the vector variable "arguments", like i.e. in file "test.py":
result = 2.0 * arguments[0]
to double the value passed as second argument to the Python expression. For example the expression
EXPR="python("test.py", 15.0)";
evaluates to a value of 30.0 (test.py contains the line shown above).
Definition at line 34 of file PythonExpr.h.
|
inline |
Definition at line 36 of file PythonExpr.h.