Re: [OSM-dev] How to find the way with the most relation memberships
I have taken the liberty to remove these ways and all relations that became empty because of deleting them. Maarten On 2018-08-27 12:57, Jo wrote: I found that quite intriguing... so I went to download. It turns out that this way (with just a name tag, nothing else, located in a small town 18 km south of Ankara) is member in 430 route relations that only have 2 members. The total amount of ways in those 430 route relations combined is 3. The way is a member of 439 route relations in total, 441 relations including 1 street and a 'network'. Something doesn't seem quite right. Polyglot Op ma 27 aug. 2018 om 12:36 schreef Frederik Ramm : Hi, On 27.08.2018 11:41, Simon Poole wrote: Come on, you're leaving us out on a limb. Now we want to know the world leader in relation membership :-). https://www.openstreetmap.org/way/496296681 Bye Frederik -- Frederik Ramm ## eMail frede...@remote.org ## N49°00'09" E008°23'33" ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev
Re: [OSM-dev] How to find the way with the most relation memberships
Hi, https://overpass-turbo.eu/s/BpE shows that this has happended already 2015 and in changeset 33711981. It is notable that - the user made otherwise many useful contributions - there are two version fo that relation within the changeset, only 6 minutes apart This makes it most probable that the editor (an old Potlatch version) had a bug, and that the bug most likely had been fixed long ago. The other affected relation 5328067 (replace twice in the query) is from the same changeset and has the same number of duplicate members, which also is well in line with an editor bug. Best regards, Roland ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev
Re: [OSM-dev] How to find the way with the most relation memberships
Hi, On 27.08.2018 13:23, Maarten Deen wrote: > I have seen duplicates of (bus) relations also in Germany, No way, the Germans would never allow that kind of relation breakage... https://www.openstreetmap.org/way/368506221 ... err, ehm ;) Bye Frederik PS: top 100 planet-wide are in http://www.remote.org/frederik/tmp/relationmembers.txt, done with exactly the script from the beginning of this thread. -- Frederik Ramm ## eMail frede...@remote.org ## N49°00'09" E008°23'33" ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev
Re: [OSM-dev] How to find the way with the most relation memberships
And the ways that are in the bad relations are bogus too. A lot of relations only have way 482554372 and 496296681 in them, both ways with no tags but the name. My guess for the existance of these ways is they were split of from a way "Ankara Otobüs Hatları Çalışması", where left somewhere out of error or for some purpose and forgotten. Does not explain the multitude in bus relations with only those two ways, but I have seen duplicates of (bus) relations also in Germany, where bus xyz had 10 relations of which 9 had only one or two members. I put that down to user error or a bug in the editor (never got a response from the user). I think it is safe to delete these ways and the relations if they become empty. Maybe a note on the turkish part of the forum is in place. Regards, Maarten On 2018-08-27 12:57, Jo wrote: I found that quite intriguing... so I went to download. It turns out that this way (with just a name tag, nothing else, located in a small town 18 km south of Ankara) is member in 430 route relations that only have 2 members. The total amount of ways in those 430 route relations combined is 3. The way is a member of 439 route relations in total, 441 relations including 1 street and a 'network'. Something doesn't seem quite right. Polyglot Op ma 27 aug. 2018 om 12:36 schreef Frederik Ramm : Hi, On 27.08.2018 11:41, Simon Poole wrote: Come on, you're leaving us out on a limb. Now we want to know the world leader in relation membership :-). https://www.openstreetmap.org/way/496296681 Bye Frederik -- Frederik Ramm ## eMail frede...@remote.org ## N49°00'09" E008°23'33" ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev
Re: [OSM-dev] How to find the way with the most relation memberships
I found that quite intriguing... so I went to download. It turns out that this way (with just a name tag, nothing else, located in a small town 18 km south of Ankara) is member in 430 route relations that only have 2 members. The total amount of ways in those 430 route relations combined is 3. The way is a member of 439 route relations in total, 441 relations including 1 street and a 'network'. Something doesn't seem quite right. Polyglot Op ma 27 aug. 2018 om 12:36 schreef Frederik Ramm : > Hi, > > > On 27.08.2018 11:41, Simon Poole wrote: > > Come on, you're leaving us out on a limb. Now we want to know the world > > leader in relation membership :-). > > https://www.openstreetmap.org/way/496296681 > > Bye > Frederik > > -- > Frederik Ramm ## eMail frede...@remote.org ## N49°00'09" E008°23'33" > > ___ > dev mailing list > dev@openstreetmap.org > https://lists.openstreetmap.org/listinfo/dev > ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev
Re: [OSM-dev] How to find the way with the most relation memberships
Hi, On 27.08.2018 11:41, Simon Poole wrote: > Come on, you're leaving us out on a limb. Now we want to know the world > leader in relation membership :-). https://www.openstreetmap.org/way/496296681 Bye Frederik -- Frederik Ramm ## eMail frede...@remote.org ## N49°00'09" E008°23'33" ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev
Re: [OSM-dev] How to find the way with the most relation memberships
Come on, you're leaving us out on a limb. Now we want to know the world leader in relation membership :-). Am 27.08.2018 um 01:00 schrieb Frederik Ramm: > Hi, > > in the course of a discussion over on talk-gb, I wanted to find out > which ways have the highest number of relation memberships. In case > someone is interested, here's how to do it with Osmium and Perl. > > 1. create this Perl script which reads "opl" ascii format > > #!/usr/bin/perl > > while(<>) > { > next unless /boundary/; > s/.* M//g; > foreach (split(/,/)) > { > my ($a,$b)=split(/@/); > $mem{$a}++; > } > } > > $i=0; > foreach (sort { $mem{$b}<=>$mem{$a} } keys(%mem)) > { > printf "%d %s\n", $mem{$_}, $_; > last if ($i++>100); > } > > 2. feed an .osm.pbf file into it: > > osmium cat some-file.osm.pbf -trelation -fopl | perl myscript.pl > > I ran this for England and found a small number of ways that were > actually in over 100 different (bus route) relations ;) > > If you like Python, you could of course do the whole thing in one go > using the PyOsmium library > > Bye > Frederik > signature.asc Description: OpenPGP digital signature ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev
[OSM-dev] How to find the way with the most relation memberships
Hi, in the course of a discussion over on talk-gb, I wanted to find out which ways have the highest number of relation memberships. In case someone is interested, here's how to do it with Osmium and Perl. 1. create this Perl script which reads "opl" ascii format #!/usr/bin/perl while(<>) { next unless /boundary/; s/.* M//g; foreach (split(/,/)) { my ($a,$b)=split(/@/); $mem{$a}++; } } $i=0; foreach (sort { $mem{$b}<=>$mem{$a} } keys(%mem)) { printf "%d %s\n", $mem{$_}, $_; last if ($i++>100); } 2. feed an .osm.pbf file into it: osmium cat some-file.osm.pbf -trelation -fopl | perl myscript.pl I ran this for England and found a small number of ways that were actually in over 100 different (bus route) relations ;) If you like Python, you could of course do the whole thing in one go using the PyOsmium library Bye Frederik -- Frederik Ramm ## eMail frede...@remote.org ## N49°00'09" E008°23'33" ___ dev mailing list dev@openstreetmap.org https://lists.openstreetmap.org/listinfo/dev