rustworkx.PyGraph.update_edge_by_index#

PyGraph.update_edge_by_index(edge_index, edge, /)#

根据边索引原地更新边的权重/数据负载

Parameters:
  • edge_index (int) – 边的索引

  • edge (T) – 附加到边的 Python 对象

Raises:

IndexError – when there is no edge present with the provided index