logo separator

[mkgmap-dev] Another splitter bug

From Chris Miller chris.miller at kbcfp.com on Sat Aug 15 10:51:49 BST 2009

Hi Paul,

This is because the .osm file you are splitting has a node with no 'lat' 
attribute. As far as I'm aware this shouldn't happen; something is probably 
wrong with your .osm file? I downloaded the europe.osm file a few hours after 
you posted your message and it processes without a problem. My europe.osm 
file is 28,626,280,448 bytes in size.

Anyway I've put in a check for this since in this case the change is simple 
and it doesn't have much affect on performance. The splitter will now output 
details of the problem, ignore the node and carry on with the split. Generally 
speaking though it's not such a good idea to put too much validation of the 
XML into the splitter because it will just complicate the code and slow things 
down. I guess if we any further problems like this we'll have to decide what's 
best on a case-by-case basis.

Chris


PO> Hi,
PO> 
PO> there is next splitter bugreport:
PO> 
PO> Splitter r73
PO> europe.osm from today
PO> java -Xmx3800m -verbose:gc -jar ../splitter.jar --max-areas=255
PO> --max-nodes=600000 ../../europe.osm
PO> [GC 98554K->51194K(99008K), 0.0009550 secs]
PO> 12,500,000 nodes processed...
PO> [GC 96378K->51194K(96896K), 0.0009430 secs]
PO> [GC 94330K->51194K(95040K), 0.0009170 secs]
PO> [GC 92410K->51194K(93120K), 0.0009060 secs]
PO> [GC 90554K->51194K(91392K), 0.0008910 secs]
PO> [GC 88826K->51194K(89728K), 0.0008880 secs]
PO> [GC 87162K->51194K(88128K), 0.0008940 secs]
PO> [GC 85562K->51194K(86656K), 0.0009170 secs]
PO> [GC 84090K->51194K(85248K), 0.0009010 secs]
PO> [GC 82682K->51194K(83904K), 0.0008870 secs]
PO> Exception in thread "main" java.lang.NullPointerException
PO> at
PO> sun.misc.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:9
PO> 91)
PO> at java.lang.Double.parseDouble(Double.java:510)
PO> at
PO> uk.me.parabola.splitter.DivisionParser.startElement(DivisionParser.j
PO> ava:64)
PO> at
PO> uk.me.parabola.splitter.AbstractXppParser.parse(AbstractXppParser.ja
PO> va:38)
PO> at uk.me.parabola.splitter.Main.calculateAreas(Main.java:183)
PO> at uk.me.parabola.splitter.Main.split(Main.java:108)
PO> at uk.me.parabola.splitter.Main.main(Main.java:87)
PO> Paul
PO> 






More information about the mkgmap-dev mailing list