nxt package

execute_graph(filepath, start=None, parameters=None, context=None)[source]

Shortest code path to executing a graph from the nxt package. Creates a 1 off session and executes the graph within that session. Arguments are a direct copy of Session.execute_graph, see there for full details.

Parameters:
  • filepath (str) – Path to the graph file.
  • start (str) – Path to the node to begin execution from.
  • parameters (dict) – Dict where key is attr path and value is new attr value.
  • context (str) – Optional name of remote context to execute graph in, if none is passed the graph is executed in this interpreter.
create_context(custom_name, interpreter_exe='c:\\users\\lucas\\miniconda2\\envs\\nxtdocs\\python.exe', context_graph=None)[source]

Generate a remote context given the path to an interpreter executable, if none is provided the current sys.executable is used. You must provide a custom name for your context.

Parameters:
  • interpreter_exe – String path to python executable
  • custom_name – String of context name. The name users will refer to the context by
  • context_graph – Optional path to an existing context startup graph
Raises:

IOError, NameError

Returns:

string of the new context name