Re: [jgrapht-users] Set implementation
Brought to you by:
barak_naveh,
perfecthash
From: Ricardo R. <ric...@gm...> - 2011-02-28 21:36:40
|
It seems you're right, I carefully reviewed my code, and I think I found source of the non-deterministic order. Sorry for that... and thanks for the help. Regards, 2011/2/28 John Sichi <js...@gm...> > We already us LinkedHashXXX for the default graph implementations. > Are you sure it's not some other non-deterministic aspect of your > traversal? > > JVS > > On Sun, Feb 27, 2011 at 7:23 PM, Ricardo Redder > <ric...@gm...> wrote: > > Hi, > > I was wondering if there is a "suggested" way of choosing the Set > > implementation used by the Graph implementations (edge's and vertex's > Sets). > > I am facing a few problems with unit tests, because my program output > keeps > > changing since the iteration is not deterministic. So... a few questions: > > > > Would it possible to simply change the Set implementation used by a graph > > implementation? e.g.: Force DefaultDirectedGraph to use LinkedHashSet for > > vertexSet() instead the default implementation? > > Is there a significant impact, like a big performance degradation, or > > maybe operation's correctness? > > If it cannot be done, is there a Graph implementation that provides > > deterministic iteration over these sets? > > > > Thanks in advance for any help. > > Regards, > > -- > > Redder > > > > > ------------------------------------------------------------------------------ > > Free Software Download: Index, Search & Analyze Logs and other IT data in > > Real-Time with Splunk. Collect, index and harness all the fast moving IT > > data > > generated by your applications, servers and devices whether physical, > > virtual > > or in the cloud. Deliver compliance at lower cost and gain new business > > insights. http://p.sf.net/sfu/splunk-dev2dev > > _______________________________________________ > > jgrapht-users mailing list > > jgr...@li... > > https://lists.sourceforge.net/lists/listinfo/jgrapht-users > > > > > -- Redder |