Skip to content

Connector

mllabs.Connector

Selects nodes by matching against name, processor, and/or edges.

All provided criteria are combined with AND logic. Omitted criteria always match.

Parameters:

Name Type Description Default
node_query

Node name filter. A str is treated as a regex pattern; a list requires exact membership.

None
edges

Edge filter. {key: dsl_string} — for each key, the node's resolved edges[key] must equal this DSL string exactly.

None
processor

Processor filter as a "module.ClassName" string — not a class. Compared directly (string equality) against the node's stored processor value, which Pipeline also keeps unresolved (whatever form set_grp/set_node was given). Use the same string form there for the match to line up.

None

match(spec)

Return True if the node satisfies all configured criteria.

Parameters:

Name Type Description Default
spec ProcessorSpec

The node's resolved spec — from Pipeline.get_node_spec() or Trial.get_spec().

required

Returns:

Name Type Description
bool

True if all criteria match.