Hi,
ich habe das wayproblem processing in meine normale pipeline mit
eingebaut - d.h. alle ~30 Minuten gibt es jetzt neu:

https://osm.zz.de/dbview/?db=wayproblems-owl&layer=wayproblems
https://osm.zz.de/dbview/?db=wayproblems-nrw&layer=wayproblems
https://osm.zz.de/dbview/?db=wayproblems-nds&layer=wayproblems
https://osm.zz.de/dbview/?db=wayproblems-rlp&layer=wayproblems

Das dingen wird sich bestimmt die nächsten tage immer mal wieder
wandeln. Da sind Tonnen an dingen drin mit denen ich auch nicht so
glücklich bin. D.h. verschiedene "Fehler" werde ich bestimmt in 
separate layer verschieben.

Aber das lebt eben vom Feedback - Wenn ihr false positives/negatives
habt dann her damit. Das mit dem footway ohne bicycle=yes/no muss
in einen separaten layer. Das ist per se kein Fehler. Aber ein fehlendes
bicycle=yes ist halt ärgerlich im routing.

Hier der aktuelle code.

        if (!taglist.has_key("highway")) {
                return;
        }

        if (taglist.highway_should_have_ref()) {
                if (!taglist.has_key_value("junction", "roundabout")) {
                        if (!taglist.has_key("ref")) {
                                writer.writeWay(way, "ref", "highway should 
have ref");
                        }
                }
        }

        if (!taglist.highway_may_have_ref()) {
                if (taglist.has_key("ref")) {
                        writer.writeWay(way, "ref", "highway should not have 
ref");
                }
        }

        {
                std::vector<const char *>       accesstags={
                        "access", "vehicle", "motor_vehicle", "motorcycle",
                        "motorcar", "hgv", "psv", "bicycle", "foot",
                        "goods", "mofa", "moped", "horse"};

                if (taglist.is_public()) {
                        for(auto key : accesstags) {
                                const char *value=taglist.get_value_by_key(key);
                                if (!value)
                                        continue;
                                if (!strcmp(value, "permissive")) {
                                        writer.writeWay(way, "default", "public 
highway cant have permissive access tags");
                                } else if (!strcmp(value, "private")) {
                                        writer.writeWay(way, "default", "public 
highway cant have private access tags");
                                } else if (!strcmp(value, "customers")) {
                                        writer.writeWay(way, "default", "public 
highway cant have customers access tags");
                                }
                        }
                }

        }

        if (taglist.has_key("goods")) {
                writer.writeWay(way, "default", "goods=* is not in use in 
Germany - no distinction between goods and hgv");
        }

        if (taglist.has_key("access")) {
                if (taglist.key_value_is_false("access")) {
                        writer.writeWay(way, "default", "access=no - Nicht StVO 
konform. Vermutlich motor_vehicle=no oder vehicle=no");
                } else if (taglist.key_value_is_true("access")) {
                        writer.writeWay(way, "redundant", "access=yes - 
vermutlich redundant");
                } else if (taglist.has_key_value("access", "destination")) {
                        writer.writeWay(way, "default", "access=destination 
nicht StVO konform. Vermutlich vehicle=destination oder 
motor_vehicle=destination");
                }
        }

        if (taglist.has_key_value("highway", "service")) {
                if (taglist.has_key("name")) {
                        writer.writeWay(way, "default", "highway=service with 
name=* is suspicious - Either public e.g. not service or name tag abuse");
                }
        }


        if (taglist.has_key_value("highway", "track")) {
                if (taglist.has_key("name")) {
                        writer.writeWay(way, "default", "highway=track with 
name is suspicious - probably not track");
                }
                if (taglist.has_key("maxspeed")) {
                        writer.writeWay(way, "default", "highway=track with 
maxspeed is suspicious - probably not track");
                }
        } else {
                if (taglist.has_key("tracktype"))
                        writer.writeWay(way, "default", "tracktype=* on non 
track");
        }

        if (taglist.has_key_value("highway", "footway")) {
                if (!taglist.has_key("bicycle")) {
                        writer.writeWay(way, "footway", "highway=footway 
without bicycle=yes/no tag - suspicious combination");
                }
                if (taglist.key_value_is_true("foot")) {
                        writer.writeWay(way, "redundant", "highway=footway with 
foot=yes is redundant");
                }
                if (taglist.key_value_is_false("foot")) {
                        writer.writeWay(way, "default", "highway=footway with 
foot=no is broken");
                }
        }

        if (taglist.has_key_value("highway", "living_street")) {
                if (taglist.has_key("maxspeed")) {
                        writer.writeWay(way, "default", "maxspeed on 
living_street is broken - neither numeric nor walk is correct");
                }

                if (taglist.key_value_is_false("bicycle")) {
                        writer.writeWay(way, "default", "living_street with 
bicycle=no is broken");
                }
                if (taglist.key_value_is_true("bicycle")) {
                        writer.writeWay(way, "redundant", "living_street with 
bicycle=yes is redundant");
                }

                if (taglist.key_value_is_false("foot")) {
                        writer.writeWay(way, "default", "foot=no on 
living_street is broken");
                }
                if (taglist.key_value_is_true("foot")) {
                        writer.writeWay(way, "redundant", "foot=yes on 
living_street is redundant");
                }

                if (taglist.key_value_is_false("vehicle")) {
                        writer.writeWay(way, "default", "vehicle=no on 
living_street is broken");
                }
                if (taglist.key_value_is_true("vehicle")) {
                        writer.writeWay(way, "redundant", "vehicle=yes on 
living_street is redundant");
                }

        }

        if (taglist.has_key_value("highway", "cycleway")) {
                if (taglist.key_value_is_true("bicycle")) {
                        writer.writeWay(way, "redundant", "bicycle=yes on 
cycleway is redundant");
                }
                if (taglist.key_value_is_false("bicycle")) {
                        writer.writeWay(way, "default", "bicycle=no on cycleway 
is broken");
                }
                if (taglist.has_key_value("vehicle", "yes")) {
                        writer.writeWay(way, "default", "vehicle=yes on 
cycleway is broken as its not a cycleway");
                }
                if (taglist.has_key_value("vehicle", "no")) {
                        writer.writeWay(way, "default", "vehicle=no on cycleway 
is broken as bicycle is a vehicle");
                }
        }

        if (taglist.key_value_is_true("vehicle")) {
                if (taglist.key_value_is_false("motor_vehicle")) {
                        writer.writeWay(way, "default", "vehicle=yes and 
motor_vehicle=no should be bicyle");
                } else if (taglist.key_value_is_true("motor_vehicle")) {
                        writer.writeWay(way, "redundant", "vehicle=yes and 
motor_vehicle=yes is redundant");
                }
        }

        if (taglist.key_value_is_true("motor_vehicle")) {
                if (taglist.key_value_is_false("motorcycle")) {
                        writer.writeWay(way, "default", "motor_vehicle=yes and 
motorcycle=no should be motorcar + hgv");
                } else if (taglist.key_value_is_true("motorcycle")) {
                        writer.writeWay(way, "redundant", "motor_vehicle=yes 
and motorcycle=yes is redundant");
                }

                if (taglist.key_value_is_false("motorcar")) {
                        writer.writeWay(way, "default", "motor_vehicle=yes and 
motorcar=no should be motorcycle");
                } else if (taglist.key_value_is_true("motorcar")) {
                        writer.writeWay(way, "redundant", "motor_vehicle=yes 
and motorcar=yes is redundant");
                }

                if (taglist.key_value_is_false("hgv")) {
                        writer.writeWay(way, "default", "motor_vehicle=yes and 
hgv=no should be motorcar");
                } else if (taglist.key_value_is_true("hgv")) {
                        writer.writeWay(way, "redundant", "motor_vehicle=yes 
and hgv=yes is redundant");
                }
        }

        if (taglist.key_value_is_false("tunnel")) {
                writer.writeWay(way, "redundant", "tunnel=no ist redundant");
        }
        if (taglist.key_value_is_false("construction")) {
                writer.writeWay(way, "redundant", "construction=no ist 
redundant");
        }
        if (taglist.key_value_is_false("oneway")) {
                writer.writeWay(way, "redundant", "oneway=no ist redundant");
        }

        if (taglist.has_key_value("junction", "roundabout")) {
                if (taglist.has_key("name")) {
                        writer.writeWay(way, "default", "name on roundabout is 
most like an error");
                }
                if (taglist.has_key("ref")) {
                        writer.writeWay(way, "default", "ref on roundabout is 
most like an error");
                }
                if (taglist.has_key("oneway")) {
                        writer.writeWay(way, "redundant", "oneway on roundabout 
is redundant");
                }
        }


Flo
-- 
Florian Lohoff                                                 [email protected]
             UTF-8 Test: The 🐈 ran after a 🐁, but the 🐁 ran away
_______________________________________________
OSM mailing list
[email protected]
http://gt.owl.de/cgi-bin/mailman/listinfo/osm

Antwort per Email an