mark_subgraph

Contents

mark_subgraph#

graph_tool.topology.mark_subgraph(g, sub, vmap, vmask=None, emask=None)[source]#

Mark a given subgraph sub on the graph g.

Parameters:
gGraph

Graph in which the subgraph will be marked.

subGraph

Subgraph to be marked.

vmapVertexPropertyMap

Vertex property map belonging to sub, which maps its vertices to the indices of the corresponding vertices in g.

vmaskVertexPropertyMap (optional, default: None)

Boolean vertex property map of g where the result will be stored. If not provided, a new one will be created.

emaskEdgePropertyMap (optional, default: None)

Boolean edge property map of g where the result will be stored. If not provided, a new one will be created.

Returns:
vmaskVertexPropertyMap

Boolean vertex property map indicating whether or not a vertex in g belongs to the subgraph sub.

emaskEdgePropertyMap

Boolean edge property map indicating whether or not an edge in g belongs to the subgraph sub.