Node
Type
ComputableDAGs.ComputeTaskNode — Type
ComputeTaskNode <: NodeAny node that computes a result from inputs using an AbstractComputeTask.
Fields
.task: The node's compute task type. A concrete subtype of AbstractComputeTask..parents: A vector of the node's parents (i.e. nodes that depend on this one)..children: A vector of tuples with the node's children (i.e. nodes that this one depends on) and their index, used to order the arguments for the AbstractComputeTask..id: The node's id. Improves the speed of comparisons and is used as a unique identifier.
ComputableDAGs.DataTaskNode — Type
DataTaskNode <: NodeAny node that transfers data and does no computation.
Fields
.task: The node's data task type. Usually DataTask..parents: A vector of the node's parents (i.e. nodes that depend on this one)..children: A vector of tuples of the node's children (i.e. nodes that this one depends on) and their indices, indicating their order in the resulting function call passed to the task..id: The node's id. Improves the speed of comparisons and is used as a unique identifier..name: The name of this node for entry nodes into the graph (is_entry_node) to reliably assign the inputs to the correct nodes when executing.
ComputableDAGs.Edge — Type
EdgeType of an edge in the graph. Edges can only exist between a DataTaskNode and a ComputeTaskNode or vice versa, not between two of the same type of node.
An edge always points from child to parent: child = e.edge[1] and parent = e.edge[2]. Additionally, the Edgecontains theindex` which is used as the child's index in the parent node.
The child is the prerequisite node of the parent.
sourceComputableDAGs.Node — Type
Create
ComputableDAGs.make_edge — Function
ComputableDAGs.make_edge — Function
make_edge(n1::Node, n2::Node, index::Int)Fallback implementation of make_edge throwing an error. If you got this error it likely means you tried to construct an edge between two nodes of the same type.
ComputableDAGs.make_edge — Function
ComputableDAGs.make_node — Function
ComputableDAGs.make_node — Method
make_node(t::AbstractComputeTask)Construct and return a new ComputeTaskNode with the given task.
ComputableDAGs.make_node — Method
make_node(t::AbstractTask)Fallback implementation of make_node for an AbstractTask, throwing an error.
Compare
Base.:== — Method
Base.:== — Method
Properties
ComputableDAGs.children — Method
children(dag::DAG, node::Node)Return node's children.
A node's children are its prerequisite nodes, nodes that need to execute before the task of this node.
A node's children are the nodes that must run before it.
sourceComputableDAGs.is_child — Method
is_child(dag::DAG, potential_child::Node, node::Node)Return whether the potential_child is a child of node.
ComputableDAGs.is_entry_node — Method
is_entry_node(node::Node)Return whether this node is an entry node in its graph, i.e., it has no children.
sourceComputableDAGs.is_exit_node — Method
is_exit_node(node::Node)Return whether this node is an exit node of its graph, i.e., it has no parents.
sourceComputableDAGs.is_parent — Method
is_parent(dag::DAG, potential_parent::Node, node::Node)Return whether the potential_parent is a parent of node.
ComputableDAGs.parents — Method
parents(dag::DAG, node::Node)Return the node's parents.
A node's parents are its subsequent nodes, nodes that need this node to execute.
sourceComputableDAGs.partners — Method
partners(dag::DAG, node::Node, set::Set{Node})Alternative version to partners(node::Node), avoiding allocation of a new set. Works on the given set and returns nothing.
ComputableDAGs.partners — Method
partners(dag::DAG, node::Node)Return a vector of all partners of this node.
A node's partners are all parents of any of its children. The result contains no duplicates and includes the node itself.
This is very slow when there are multiple children with many parents. This is less of a problem in siblings(node::Node) because (depending on the model) there are no nodes with a large number of children, or only a single one.
ComputableDAGs.siblings — Method
siblings(dag::DAG, node::Node)Return a vector of all siblings of this node.
A node's siblings are all children of any of its parents. The result contains no duplicates and includes the node itself.
sourceComputableDAGs.task — Method
ComputableDAGs.to_var_name — Method
to_var_name(id::UUID)Return the uuid as a string usable as a variable name in code generation.
source