logo separator

[mkgmap-dev] Problems with latest splitter versions

From Scott Crosby scott at sacrosby.com on Fri Mar 4 03:16:26 GMT 2011

On Wed, Mar 2, 2011 at 5:36 PM, Michael Prinzing <mipri at gmx.net> wrote:
> Hi,
>
> I am getting the splitter from svn, compiling and running it unter
> Windows XP SP3 using JDK 1.6.0_25. There are 2 problems if I am using a
> splitter version newer than r161 (tryed until r167 so far).
>
>
> 1.) germany.osm.pbf from geofabrik cannot be split
> --------------------------------------------------
>
> Invoking the splitter with
>
> java.exe -Xms256m -Xmx1536m -server -jar splitter.jar --resolution=14 --overlap=4000 --max-nodes=1200000 --max-areas=50 --geonames-file=cities1000.zip germany.osm.pbf
>
> The data is split into 76 areas, so there are 2 passes to go.

BTW, there's no need to do two passes. Unlike prior versions, this
version of the splitter will handle as many areas as you want to throw
at it. I've done 6000 at once on my 4GB ram desktop.

Frantisek Mantlik tracked down and fixed the problem with threads=1.


> 2.) File containing contour data cannot be processed
> ----------------------------------------------------
>
> When generating my maps, I usually add data to draw contour lines. The
> file containing that data is available from
> http://osm.arndnet.de/contourdata.osm.gz (not my site!). It is in OSM
> format 0.5.
>

> When buildig a map, I am  combining this data with the OSM data (please
> note that the contour data file contains node IDs starting at 2^31, so
> they collide with the IDs from "real" OSM data if used unchanged). But
> even when I am trying to split this file without additional OSM data,
> the same as above happens and the splitter stops at the end of the
> first and only pass:

This won't work. The splitter is written in Java, where most standard
Java classes and collections don't support indices that are 64 bits.
This means that ID's more than 2**31 are too big and will be treated
as negative by Java and blow up this code. The current array resize
logic further limits this to node ID's less than somewhere around
1,750,000,000, but I just committed a fix to trunk that I think will
extend this range to 1--1,999,999,999. You could help me find and fix
any other issues if you could supply a small file with node ID's
around 1,950,000,000.

>
> Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: Start index (-30655339) is negative
>        at it.unimi.dsi.fastutil.Arrays.ensureFromTo(Arrays.java:45)
>        at it.unimi.dsi.fastutil.objects.ObjectArrays.ensureFromTo(ObjectArrays.java:351)
>        at it.unimi.dsi.fastutil.objects.ObjectArrays.fill(ObjectArrays.java:313)
>        at it.unimi.dsi.fastutil.objects.ObjectArrayList.size(ObjectArrayList.java:308)

Scott



More information about the mkgmap-dev mailing list