MCPcopy Create free account
hub / github.com/BUPT-GAMMA/MASFactory / edge_from_controller

Method edge_from_controller

masfactory/components/graphs/loop.py:346–354  ·  view source on GitHub ↗

Create an edge from controller to an internal node.

(self,
            receiver: Node,
            keys: dict[str,dict|str]|None=None)

Source from the content-addressed store, hash-verified

344 self._controller.add_in_edge(edge)
345 return edge
346 def edge_from_controller(self,
347 receiver: Node,
348 keys: dict[str,dict|str]|None=None):
349 """Create an edge from controller to an internal node."""
350 edge = Edge(self._controller, receiver, keys)
351 self._edges.append(edge)
352 self._controller.add_out_edge(edge)
353 receiver.add_in_edge(edge)
354 return edge
355 @masf_hook(Node.Hook.FORWARD)
356 def _forward(self,input:dict[str,object]) -> dict[str,object]:
357 """Execute loop iterations until controller or terminate node stops it."""

Callers 15

buildMethod · 0.95
buildMethod · 0.80
buildMethod · 0.80
buildMethod · 0.80
buildMethod · 0.80
buildMethod · 0.80
buildMethod · 0.80
_compile_aml_loopFunction · 0.80
_compile_loopFunction · 0.80
connect_loop_controllerFunction · 0.80
mainFunction · 0.80
_build_graphMethod · 0.80

Calls 3

EdgeClass · 0.90
add_out_edgeMethod · 0.80
add_in_edgeMethod · 0.80

Tested by

no test coverage detected