[josm-dev] Handling large files?

Michael Speth conzar at gmail.com
Mon Nov 24 18:29:18 GMT 2008


Greetings,
  I am trying to read OSM data from a large file but am unable to (the
process keeps getting killed).  I have downloaded an OSM file from here
http://downloads.cloudmade.com/.  Uncompressed its about 3.2GBs.

Here is the simple code that I wrote to try and parse the OSM file.
            Main.proj = new Epsg4326();
            DataSet dataSet = OsmReader.parseDataSet(new
FileInputStream(file), null, null);

This works for small files.

So should I be using a different parser for large files?  Does OSM handle
large files?  My end goal is to be able to search through OSM data to find a
road based on the GPS coordinates.  Is there a better way of doing that?  I
was thinking about putting this information in an embedded database like
DB4O.

Thanks for your help.

-- 
Michael Speth  石雨濛
Computer Engineer
OPNET
http://www.opnet.com



More information about the josm-dev mailing list