spatial
spatial copied to clipboard
non batch OSM parser
Is there a 'non batch' OSM inserter? There were allusions to this but I can't seem to find any and the OSMBatchInserter blows up with an out-of-memory exception with a large number of Nodes/Ways. I'd be happy to use ruby or python but can't seem to get those setup either.
Yes. The OSMImporter class can work in both Batch and Non-Batch mode. See the TestOSMImporter class for how to do this in Java. If you want to do this in Ruby, I can double check the neo4j-spatial.rb RubyGem to see that it can work in both ways, but believe it does already.
I'm not sure how to use the ruby script. I'm new to ruby/jruby and am not quite sure of the steps
On Nov 10, 2011, at 3:01 PM, Craig Taverner wrote:
Yes. The OSMImporter class can work in both Batch and Non-Batch mode. See the TestOSMImporter class for how to do this in Java. If you want to do this in Ruby, I can double check the neo4j-spatial.rb RubyGem to see that it can work in both ways, but believe it does already.
Reply to this email directly or view it on GitHub: https://github.com/neo4j/spatial/issues/26#issuecomment-2702625
I answered in more detail on the mailing list, but if you install the gem with: jruby -S gem install neo4j-spatial
You should then get some commands on the path, like osm_import, osm_layer and export_layer. Run those commands with the -h switch to get some help on how they work.
I have noted that the current published neo4j-spatial.rb gem does not use the non-batch-inserter by default. But I explained in the mailling list the one line change required to the osm.rb file to fix this. I will push the fix soon, but need to find time for more testing before doing that.