I was wondering if you already have the method in graph-tool?
Yen's Shortest Path algorithm computes a number of shortest paths between two nodes. The algorithm is often called Yen's k-Shortest Path algorithm, where k is the number of shortest paths to compute. The algorithm supports weighted graphs with positive relationship weights.