[graph-tool] Efficient way to have unique edges (with given vertices and type)