On 10.03.2017 15:17, Hobé Alex wrote:
Hi Tiago and everyone else on the list
Thank you for your swift reply. The attached png is one example of a max flow calculation result. The flow is limited in four places in this graph.
I'll have to trust you. It is not possible to tell from the image that there are only four possible paths.
I would like to extract the order of the edges in the four paths I drew.
The shortest path solution you described corresponds to path 3 in the drawing. all_shortest_paths gives my path 3 and another completely different path before crashing with a memoryError.
I'm not sure why you get a memory error. I can only guess, since you are not giving me a concrete example of what you are trying to do (i.e. code).
If you are not filtering the graph, or if there are more than 4 possible paths, you may run out of memory if you try to store them all. Note that even if there are 4 paths in the filtered graph, there is definitely a huge number of them in the unmodified graph.
If you want to consider all paths instead of the shortest paths, you should use the function all_paths().
If you need more detailed assistance, please provide a _minimal_ and _self-contained_ example that shows the problem.