COIN-OR::LEMON - Graph Library

Opened 11 years ago

Closed 11 years ago

#197 closed defect (fixed)

MaxWeightedMatching and MaxWeightedPerfectMatcing crash

Reported by: Philip.Waldron Owned by: Balazs Dezso
Priority: major Milestone: LEMON 1.1 release
Component: core Version: hg main
Keywords: Cc: "Waldron, Philip" <Philip.Waldron@…>
Revision id: 30d22b636e57

Description

The following code crashes with the attach .lgf file, using either MaxWeightedMatching or MaxWeightedPerfectMatching

#include <lemon/max_matching.h>
#include <lemon/smart_graph.h>
#include <lemon/lgf_reader.h>

using namespace lemon;

int main() 
{
  typedef SmartGraph Graph;
  Graph g;
  Graph::EdgeMap<int> w(g);
  
  GraphReader<Graph>(g,std::cin).edgeMap("weight",w).run();

  MaxWeightedMatching<Graph> mwm(g,w);
  //MaxWeightedPerfectMatching<Graph> mwm(g,w);

  mwm.run();

Attachments (4)

matching.lgf (3.4 KB) - added by Alpar Juttner 11 years ago.
52c04a2a652c.patch (4.1 KB) - added by Balazs Dezso 11 years ago.
Bug fix
heap_unionfind_fix.bundle (3.8 KB) - added by Balazs Dezso 11 years ago.
Application of patch on proper base
heap_unionfind_bugfix2.bundle (3.5 KB) - added by Balazs Dezso 11 years ago.
Fix of bugfix

Download all attachments as: .zip

Change History (9)

Changed 11 years ago by Alpar Juttner

Attachment: matching.lgf added

Changed 11 years ago by Balazs Dezso

Attachment: 52c04a2a652c.patch added

Bug fix

comment:1 Changed 11 years ago by Balazs Dezso

The patch [52c04a2a652c] solves the problem.

Changed 11 years ago by Balazs Dezso

Attachment: heap_unionfind_fix.bundle added

Application of patch on proper base

comment:2 in reply to:  1 ; Changed 11 years ago by Balazs Dezso

Replying to deba:

The patch [52c04a2a652c] solves the problem.

Please use the heap_unionfind_fix.bundle instead of the previous patch. It is applied on the proper base, and it also contains the merges.

comment:3 in reply to:  2 Changed 11 years ago by Alpar Juttner

Resolution: fixed
Status: newclosed

Replying to deba:

Replying to deba:

The patch [52c04a2a652c] solves the problem.

Please use the heap_unionfind_fix.bundle instead of the previous patch. It is applied on the proper base, and it also contains the merges.

The changesets went to the corresponding changesets, see [561be42c4b99], [bb022b8f9c8f] and [6c1ac149ebf8].

Changed 11 years ago by Balazs Dezso

Fix of bugfix

comment:4 Changed 11 years ago by Balazs Dezso

Resolution: fixed
Status: closedreopened

I made a more complex data structure test for HeapUnionFind?. Unfortunately, it indicated a bug in the previous bugfix. Finally, the problem is fixed in the heap_unionfind_bugfix2.bundle file.

comment:5 in reply to:  4 Changed 11 years ago by Alpar Juttner

Resolution: fixed
Status: reopenedclosed

Replying to deba:

I made a more complex data structure test for HeapUnionFind?. Unfortunately, it indicated a bug in the previous bugfix. Finally, the problem is fixed in the heap_unionfind_bugfix2.bundle file.

They are in the corresponding branches, see [81d40f1c850c], [1cc2818c03c0] and [1229dc2f1d36].

Note: See TracTickets for help on using tickets.