Modify

Opened 4 months ago

Last modified 4 months ago

#18854 new enhancement

Validation for stream and river direction

Reported by: Geimas5 Owned by: team
Priority: normal Milestone:
Component: Core validator Version: tested
Keywords: mapcss waterway stream river direction Cc:

Description

Because of an ongoing import of N50 data, we have in Norway a huge amount of lakes and ponds with the elevation specified. Because of this, it would be very useful to have a validation in JOSM for the direction of streams and rivers based on this elevation information.

This can, of course be made very complicated to cover every case, but even a simple validation of the cases:

  • (ele:200)<----(ele:100)
  • (ele:200)<----(node)<---(ele:100)
  • <----(node)---->(node)<----

Would help a lot.

From experience, it would avoid a lot of false positives if 1-2 meters of "wrong direction" was allowed.

This means that while:

  • (ele:200)<----(ele:100)

would result in an error:

  • (ele:101)<----(ele:100)

would not.

It would also be natural to assume natural=coastline was at ele:0.

Attachments (2)

exampleTwoWaysConnected.osm (482.3 KB) - added by Geimas5 4 months ago.
Example of case with two streams
exampleTwoWaysConnected_withError.osm (482.3 KB) - added by Geimas5 4 months ago.
Two connected ways, with error

Download all attachments as: .zip

Change History (9)

comment:1 Changed 4 months ago by simon04

Component: CoreCore validator
Keywords: mapcss added

It might already be possible to do using Help/Validator/MapCSSTagChecker. Maybe we'd need a sibling selector `~`?

comment:2 Changed 4 months ago by Klumbumbus

The nodes do have the ele tagged? Please link an example from the osm database or attach a sample osm file.

Changed 4 months ago by Geimas5

Attachment: exampleTwoWaysConnected.osm added

Example of case with two streams

comment:3 in reply to:  2 Changed 4 months ago by Geimas5

Replying to Klumbumbus:

The nodes do have the ele tagged? Please link an example from the osm database or attach a sample osm file.

No, the nodes do not have an ele tag. Its just very common for the streams to be split into multiple connected ways.

comment:4 Changed 4 months ago by Klumbumbus

I can't find an error in that example file.

Changed 4 months ago by Geimas5

Two connected ways, with error

comment:5 in reply to:  4 Changed 4 months ago by Geimas5

Replying to Klumbumbus:

I can't find an error in that example file.

Sorry, I created it as an example of a stream with two parts. I have attached one where the streams are in the wrong direction.

comment:6 in reply to:  description Changed 4 months ago by Klumbumbus

Replying to Geimas5:

  • (ele:200)<----(ele:100)
  • (ele:200)<----(node)<---(ele:100)

JOSM has no internal elevation database, so it can't know if the direction is right.

  • <----(node)---->(node)<----

For this case a warning should appear after #17533 is fixed.

comment:7 Changed 4 months ago by Don-vip

Keywords: waterway stream river direction added

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain team.
as The resolution will be set.
to The owner will be changed from team to the specified user.
The owner will change to Geimas5
as duplicate The resolution will be set to duplicate.The specified ticket will be cross-referenced with this ticket
The owner will be changed from team to anonymous.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.