Edge
One read of a value: the value src() produces on output port src_port(), read by dst() on input port dst_port(); Mul(x, x) reads x over two edges. Edges join nodes only: a constant or a state operand is a Value (Node.inputs, Node.input(port)), not an edge, and returning a value from the graph adds none. Two views of the same edge compare equal. Holding an Edge keeps the graph alive. After an edit the view finds its edge again by its two nodes and ports; once no edge has them, or a merge, a split or an extract consumes the graph, check() and every accessor raise InvalidArgumentError naming them, while ==, hash and repr keep working.
__init__
__init__(self, /, *args, **kwargs)
Initialize self. See help(type(self)) for accurate signature.
check
checkcheck(self) -> None
check(self) -> None
check() -> None
None while the graph holds this edge; raises InvalidArgumentError naming its two nodes and ports once it does not (an end was removed or renamed, the read moved to another port, or a merge, a split or an extract consumed the graph).
dst
dstdst(self) -> object
dst(self) -> object
dst() -> Node
The node the edge enters: the operator that reads the value.
dst_port
dst_portdst_port(self) -> int
dst_port(self) -> int
dst_port() -> int
The input port of dst() that reads the value.
src
srcsrc(self) -> object
src(self) -> object
src() -> Node
The node the edge leaves: the producer of the value it carries.
src_port
src_portsrc_port(self) -> int
src_port(self) -> int
src_port() -> int
The output port of src() the value leaves on.