[mkgmap-dev] patch for omitting nearby POIs with the same name and type
From Mike Baggaley mike at tvage.co.uk on Mon Aug 24 17:42:29 BST 2015
Hi Gerd, both good points - I have fixed them. However, since posting and further evaluating the results, I have come to the conclusion that whilst the first attempt was an improvement, it was somewhat simplistic in its approach. As ever, I started thinking of something simple and then realised there was a better way to handle the problem. What I wanted to be able to do was for some duplicate POIS just delete the duplicates, for others it would be better to keep the POIS but delete the duplicate names (for example a set of communications masts that have all been individually named with the same name) and for yet others it would be better to delete the duplicate POI, but move the remaining one to a midpoint between the two (useful for multi-carriageway bridges to get the name between the carriageways and also for roundabout names). Also, the distance for a POI to be considered a duplicate needed to depend on the type of POI. A bollard 3m away from another I would not consider to be a duplicate, but a roundabout 200m away with the same name should be. I've therefore come up with another option --nearby-poi-rules which specifies a list of rules about how to handle nearby POIs. Please find the updated patch attached. Any suggestions for improvement gratefully received. Regards, Mike From: Gerd Petermann [mailto:gpetermann_muenchen at hotmail.com] Sent: 20 August 2015 06:46 To: mkgmap-dev at lists.mkgmap.org.uk Subject: Re: [mkgmap-dev] patch for omitting nearby POIs with the same name and type Hi Mike, thanks for the patch. I think the docu should mention that --max-same-poi-distance expects a value in metres. Looking at the code I see one small -maybe unwanted - side effect: If --max-same-poi-distance > 0 only duplicated named POI are removed. When I coded the original code I thought that it is ok to remove e.g. pillars when they appear at the same map point. For those that like to test: I've uploaded a binary here: <http://files.mkgmap.org.uk/download/276/mkgmap.jar> http://files.mkgmap.org.uk/download/276/mkgmap.jar Gerd _____ From: <mailto:mike at tvage.co.uk> mike at tvage.co.uk To: <mailto:mkgmap-dev at lists.mkgmap.org.uk> mkgmap-dev at lists.mkgmap.org.uk Date: Wed, 19 Aug 2015 23:14:53 +0100 Subject: [mkgmap-dev] patch for omitting nearby POIs with the same name and type Hi, please find attached a patch that adds two new options: --max-same-poi-distance=distance and --include-nearby-poi-types=type[,type...]. These options are used to determine whether nearby POIS are duplicates and should be omitted from the map, extending the existing check for duplicates at the exact same location. They help to reduce the problems cause by OSM data frequently having an area such as a building tagged with the same information as a point or where multiple areas are given the same name - this is most problematic if the --add-pois-to-areas option is used. It may be valid for some named POI types to be found close together hence the option to omit certain types of POI from the nearby processing. I have the distance set to 50 with bus stops and cave entrances always included and this seems to work well for me (I don't use the default style). If --max-same-poi-distance is omitted or set to 0, the check works as previously. Please try and if OK, commit. Thanks, Mike _______________________________________________ mkgmap-dev mailing list <mailto:mkgmap-dev at lists.mkgmap.org.uk> mkgmap-dev at lists.mkgmap.org.uk <http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev> http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://www.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20150824/04486acb/attachment-0001.html> -------------- next part -------------- A non-text attachment was scrubbed... Name: nearbypoi2.patch Type: application/octet-stream Size: 17420 bytes Desc: not available URL: <http://www.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20150824/04486acb/attachment-0001.obj>
- Previous message: [mkgmap-dev] patch for omitting nearby POIs with the same name and type
- Next message: [mkgmap-dev] [Patch v0] fix sharp angles to optimise bicycle routing
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the mkgmap-dev mailing list