[OSM-talk] Re: [OSM-dev] MassGIS dataset

Christopher Schmidt crschmidt at crschmidt.net
Fri Jun 9 15:21:24 BST 2006


On Fri, Jun 09, 2006 at 03:03:11PM +0100, Nick Whitelegg wrote:
> >Well, I don't really know where to go from here, cause no one's offered
> >any hints as to what actually calls this code in the planet.osm dump, so
> >I'm blocking on that. Given that, you'll probably finish first. :)
> 
> dao.rb contains the code which obtains nodes, segments and ways from the 
> database. It's a case of modifying that to write out the XML rather than 
> store the information in a DOM. 

Okay, I ran into about the same thing you did with multis, so I'll go
with what I've got so far, and someone else can finish it up if they
choose.

http://crschmidt.net/projects/openstreetmap/planet.py

depends on 
http://crschmidt.net/projects/openstreetmap/osm.py

Method:
 * Iterate over lat/lon, from bottom left to right to top.
 * In each case, select nodes
 * Select segments
 * Select nodes for those segments not included in the first query
 * Commented out is a section that may do ways
    * But doesn't select tags, so it got commented out.

I have to do paying work now :) But someone might be able to take this
and run with it. One of the problems is that segments which cross
boundaries will probably be included twice.

-- 
Christopher Schmidt
Web Developer




More information about the dev mailing list