[Lemon-user] Executing one algorithm multiple times

Balazs Dezso deba.mf at gmail.com
Tue Mar 16 17:57:21 CET 2010


Hi All,

I see what is the problem with the solution, the _blossom_data and _node_data 
variables are not resized when the graph is changed. The current version is 
safe, when just the weight map is changed, but it can cause segmentation 
fault, if the graph is also modified.

I will send a patch, which solves the problem. 

Best, Balazs 

On Sunday 14 March 2010 13:38:43 Alpár Jüttner wrote:
> On Sun, 2010-03-14 at 12:32 +0100, Ben Strasser wrote:
> > Hi,
> >
> > Alpár Jüttner wrote:
> > > I think both Version 1 and 2 should be correct, while Version 3 is not.
> > > Version 2 shouldn't crash, it is a probably a bug (could you submit a
> > > bug report at http://lemon.cs.elte.hu/trac/lemon/wiki/IssueTracker ?).
> >
> > Are you sure that version 2 is incorrect?
> 
> If you mean it should work, then yes, it should. Otherwise it `run()`
> wouldn't mean much, for the whole algorithm could be runNev in the
> constructor.
> 
> >  I don't want to create a
> > minimal example that crashes just to find out, that that is the expected
> > behavior.
> 
> Don't bother creating such an example if it isn't trivial. Let's wait
> for Balazs's answer, for he wrote this part of the code, so he may
> immediately see the solution.
> 
> > I "solved" my problem by using version 1.
> >  However that defeats the
> > purpose of having init and start at all so that doesn't seem to be the
> > "right" way.
> 
> Not really. As I wrote you, the primary purpose of the init()/start()
> separation is not to allows more efficient multiple execution but
> instead to provide finer execution control.
> 
> > I'd love to see some guidelines on how algorithms objects
> > should behave in the documentation.
> 
> You are very right. The documentation is clearly weak at this point.
> Thanks for pointing it out. Someone will certainly fix it sooner or
> later. The issue tracker is again a good place to keep record of this
> kind of deficiencies, as well.
> 
> Regards,
> Alpar Juttner
> 
> _______________________________________________
> Lemon-user mailing list
> Lemon-user at lemon.cs.elte.hu
> http://lemon.cs.elte.hu/mailman/listinfo/lemon-user
> 



More information about the Lemon-user mailing list