logo separator

[mkgmap-dev] Remove short arcs

From Gerd Petermann gpetermann_muenchen at hotmail.com on Thu Jan 17 15:01:30 GMT 2013

Hi Steve,

I did not test the first version of the patch very deeply, but I think that we must remove code that 
nobody understands as fast as possible, esp. as correct routing is one of the most
important features.
I never understood why the original code iterates multiple times.
So, it would be great if that is not needed and we can use the
first version of my patch.
If you don't mind to change the unit test for a while,
let's do this:
1) you change the unit test so that r2448 and later are tested ok
2) I try to find out if the iteration is strictly needed or not. If it turns
out to be needed we (you) can start re-writing the code.

reg. test data: I did not yet try to understand why a short arc brakes
routing. I assume it is because you can't calculate the bearing with
an appropriate precision?
I just know that I see error messages like "road ... contains zero length arc at ... "
or "road ... contains consecutive identical nodes at ... "
when I omit the removeShortArcs call.
So, I'll try to run the first version of the patch against many tiles
and see what happens. If I don't find a problem in Europe, 
it is likely that we don't need iteration.

OK?

Gerd

> Date: Thu, 17 Jan 2013 14:28:02 +0000
> From: steve at parabola.me.uk
> To: mkgmap-dev at lists.mkgmap.org.uk
> Subject: [mkgmap-dev] Remove short arcs
> 
> 
> Hi Gerd
> 
> > Yes, today I tried to put it into RoadNetWork, but then I found out that
> > this
> > routine sees the roads after they were split into smaller parts by
> > StyledConverter. So, a lot more program logic has to be changed, and I think
> 
> Yes, most of that code should be moved too.
> And anyway, shouldn't the short arc code be run after cutting the
> roads up anyway? It might also be possible to combine the two
> functions.
> 
> > that I don't
> > understand enough for that :-(
> > I hope you can solve this, because I am not that happy with the
> > removeShortArcs_v3.patch as well.
> 
> I don't understand it either.
> I suspect that it might be possible to solve the actual problem
> that removeShortArcs is attempting to solve, at the level of building
> the NOD file. But the only way to find out would be to find or
> construct cases that don't route properly as tests and experiment.
> 
> In the short term we need to decide on something to do. We
> could disable the failing tests for the moment, go back to the
> version that didn't iterate multiple times over the roads, or
> go back to running it over all lines.
> 
> Running over all lines is a step backwards in my opinion.  The second
> option seems fine to me, as long as there are no error messages about
> short arcs. Even though the results are different they could well be for
> the better. The comments about contour lines in that routine make me
> think that it could be simplified now that we are not running it
> on contours.  Lastly we could disable the failing tests for now,
> since they are false failures.
> 
> So it depends on what you think about the original patch that didn't
> run multiple times over the ways. If you think it is definitely broken
> then we should @Ignore the failing test, and I will try out ways of
> re-structuring all that code. I've wanted to do it for a long time
> since I think that it is a barrier to any routing improvements.
> 
> ..Steve
> _______________________________________________
> mkgmap-dev mailing list
> mkgmap-dev at lists.mkgmap.org.uk
> http://lists.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20130117/2d28e940/attachment.html 


More information about the mkgmap-dev mailing list