7.2.1.4. get_unused_node_id

get_unused_node_id(graph, initial_guess='unknown', _format='{}<%d>')[source]

Finds an unused node id in graph.

Parameters
  • graph (schedula.utils.graph.DiGraph) – A directed graph.

  • initial_guess (str, optional) – Initial node id guess.

  • _format (str, optional) – Format to generate the new node id if the given is already used.

Returns

An unused node id.

Return type

str