Description Usage Arguments Value Note Author(s) Examples
Perform a forward pass to evaluate a given target node in a graph.
1 | cg_graph_forward(graph, target)
|
graph |
cg_graph object, graph that is evaluated. |
target |
cg_node object, node in the graph that is evaluated. Alternatively, argument |
None.
All nodes required to compute the target node must have a value or their value must be able to be computed at run-time. Only those nodes needed to compute the target node (including the target itself) are evaluated.
The value of a node can be retrieved via the values
data member of a cg_node
object.
If the name of the target node is supplied to argument target
, a linear search is performed to retrieve the node from the graph. In case multiple nodes share the same name, the last node added to the graph is retrieved. Please note that this linear search can become relatively expensive for large graphs.
Ron Triepels
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.