[Talk-ca] Question about NIDs

Steve Singer ssinger_pg at sympatico.ca
Wed Jan 21 14:23:40 GMT 2009

On Tue, 20 Jan 2009, James Ewen wrote:

> On Tue, Jan 20, 2009 at 6:01 PM,  <michcasa at gmail.com> wrote:
> What I would like to do, is be able to delete all of my OSM ways, and
> replace them with the GeoBase data. From there I would then use the
> GPX tracks that I have collected as a basis to modify the GeoBase
> data, so that it represents the real world data more accurately.

Scripting a bulk deleting all the nodes in an area that meet various 
criteria is quite doable.  The harder question is what criteria do you use? 
>From a technical standpoint this would be a lot easier to implement if you 
didn't need to look at the object edit history when deciding which nodes 
should be deleted (ie not restrict things to just nodes only edited by 

I'd also prefer doing this step before the bulk import vs after because 
it saves a second import step.  Also the current scripts won't connect 
intersections across two import cycles (scripts to do this could be 
written, but they haven't yet).

> Here's another example where I can see being able to manually remove
> old OSM data, and replacing it with GeoBase data. Most of the primary
> highway grid that exists in Alberta was traced from Landsat data, if
> I'm not mistaken. Whatever the source, the existing road data is of
> very poor accuracy.  Steve's road matcher is going to have a horrid
> time trying to match the GeoBase roads against the existing OSM roads
> which can be upwards of 1/2 a mile out of place. I doubt that I would
> find anyone that object to removing the crude existing OSM data in
> favour of the GeoBase data.
> An easy solution would be to delete all the crude highway data, and
> then run Steve's script against a blank slate. However, this means
> that someone will have to go through the OSM map before running the
> script to remove the crude data.

If you had some why of identifying the data (ie any high tagged a 
'Hwy 16' you could do a bulk delete.  You can play around with 
http://wiki.openstreetmap.org/wiki/Osmxapi to see how well this works 
(finding these highways by query).

Another option is for people to manually collect the list of OSM way id's 
that we would want to bulk delete as part of the import.  We'd have to come 
to some decision on how we decide which highways are 'crude' and need bulk 

> I have tracked a number of major highways across Alberta, into BC, and
> also Saskatchewan and used that to replace the crude older highway
> data. Steve's roadmatcher script will probably have an easier time
> matching to those ways, but that still leaves thousands of miles of
> highway that will need to be manually stitched to the GeoBase data.
> Again, I think it would be much faster to modify the GeoBase data to
> match the GPX tracks if need be, rather than manually match the OSM
> ways against the GeoBase data.
> Anyone else have any observations or opinions?
> James
> _______________________________________________
> Talk-ca mailing list
> Talk-ca at openstreetmap.org
> http://lists.openstreetmap.org/listinfo/talk-ca

More information about the Talk-ca mailing list