|
From: Ali T. <ali...@gm...> - 2015-12-29 22:32:14
|
Hi Andrea, Thanks for reporting this! I believe you are correct in both the description of the bug and the required fix. I no longer use sourceforge to keep my repositories. I have moved to github. Please switch to using the following git repository instead: https://github.com/atofigh/edmonds-alg I have already committed a patch with your suggested fix on the master branch. Could you do me a favor and run all the tests for me (This code was written a long time ago and I currently do not have boost installed)? You just need to compile the test.cpp file and run the test.py script in the test/ directory. If all tests pass, I will then create a new release tag. Thanks again and happy new year to you too! /ali On Tue, Dec 29, 2015 at 7:55 AM, Andrea Marino <ma...@di...> wrote: > Dear All, > > Thanks for this nice implementation of the Edmond Algorithm. We have been > lucky to have found it and we are really happy to use it. > > I think there is a small problem sometimes giving segmentation fault. The > problem is when the number of nodes is computed, namely in the function > void operator()() in the file src/edmonds_optimum_branching_impl.hpp > The number of nodes is computed as the 1+the maximum index among all the > target of all the edges. This is not correct if the maximum has indegree 0. > I think it is sufficient to add after the line > > max_vertex_idx = std::max(max_vertex_idx, index[target(e, g)]); > > also > > max_vertex_idx = std::max(max_vertex_idx, index[source(e, g)]); > > It is certainly a very small problem, but since our input had this bad > shape, we spent a while to find out this. > > Thanks again for the nice job. > With my very best regards, > Happy new year > Andrea Marino > > > > > > ------------------------------------------------------------------------------ > > _______________________________________________ > Edmonds-alg-users mailing list > Edm...@li... > https://lists.sourceforge.net/lists/listinfo/edmonds-alg-users > > |