Modify

Opened 8 years ago

Closed 6 years ago

Last modified 6 years ago

#14289 closed defect (fixed)

Some issues with crossing operator ⧉

Reported by: naoliv Owned by: team
Priority: normal Milestone: 19.05
Component: Core validator Version:
Keywords: Cc:

Description (last modified by naoliv)

I don't remember if there is a ticket about this, sorry.

1)
Validate example1.osm and see two warnings inside Overlapping Identical Natural Areas: 2 ways: A, B and another with 2 ways: B, A

A, B is the same as B, A, and only one message should be displayed (instead 2, as we see now)
The order should not matter here.

2)
Validate example2.osm and see:
https://i.imgur.com/ER2LYtz.png

There is no warning about the overlapping ways B, C (we should be seeing 3 warnings here: A, B, A, C, B, C)

JOSM:

URL:http://josm.openstreetmap.de/svn/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2017-01-25 02:17:36 +0100 (Wed, 25 Jan 2017)
Build-Date:2017-01-25 02:33:55
Revision:11490
Relative:URL: ^/trunk

Identification: JOSM/1.5 (11490 en) Linux Debian GNU/Linux 9.0 (stretch)
Memory Usage: 273 MB / 10206 MB (64 MB allocated, but free)
Java version: 1.8.0_111-8u111-b14-3-b14, Oracle Corporation, OpenJDK 64-Bit Server VM
Screen: :0.0 1600x900, :0.1 1280x1024
Maximum Screen Size: 1600x1024
Java package: openjdk-8-jre:amd64-8u111-b14-3
Java ATK Wrapper package: libatk-wrapper-java:all-0.33.3-13
VM arguments: [-Dawt.useSystemAAFontSettings=on]
Program arguments: [--language=en]
Dataset consistency test: No problems found

Attachments (3)

example1.osm (1.3 KB ) - added by naoliv 8 years ago.
example2.osm (1.9 KB ) - added by naoliv 8 years ago.
14289.PNG (6.0 KB ) - added by GerdP 6 years ago.

Download all attachments as: .zip

Change History (13)

by naoliv, 8 years ago

Attachment: example1.osm added

by naoliv, 8 years ago

Attachment: example2.osm added

comment:1 by Don-vip, 8 years ago

First point is #12627

comment:2 by naoliv, 8 years ago

Description: modified (diff)

Oh, really sorry for the duplicate part.

comment:3 by Don-vip, 8 years ago

In 11493/josm:

see #12627, see #14289 - add non regression unit tests

by GerdP, 6 years ago

Attachment: 14289.PNG added

comment:4 by GerdP, 6 years ago

I've created a patch for #14287 which also seems to solve this problem:

comment:5 by GerdP, 6 years ago

Resolution: fixed
Status: newclosed

In 15064/josm:

fix #12627,#14287,#14289,#17695

  • let CrossingFinder and ContainsFinder find all objects instead of stopping at first match
  • if objects are selected, make sure that ContainsFinder is called for enclosing objects which are not in the selection
  • enable corresponding unit tests

Draw back: MapCSSTagChecker is a bit slower.

comment:6 by Klumbumbus, 6 years ago

Milestone: 19.05

in reply to:  5 comment:7 by Don-vip, 6 years ago

Replying to GerdP:

Draw back: MapCSSTagChecker is a bit slower.

How much?

comment:8 by GerdP, 6 years ago

Depends on the data. In most situations it will not matter. With lots of complex ways the additional intersection tests might have an effect. I have some ideas how to improve performance, I guess that will be more important when I add support for multipolygons to the CrossingFinder.

comment:9 by GerdP, 6 years ago

Reg. performance: just to make it clearer:
"let CrossingFinder and ContainsFinder find all objects instead of stopping at first match"
The normal case is that CrossingFinder and ContainsFinder do NOT find a match, so that all tests are performed. The special case is that a match is found and only in that situation the old algo stopped earlier.
So, for the validator the expected effect is very small. A different situation is the search dialog.
If you have a dataset with very complex, complete multipolygons and use a mapcss search with e.g.

*[building]  area[natural]

(finds buildings inside natual area)
the search will take much longer when there are many such buildings. The reason is that the Geometry.isPolygonInsideMultiPolygon() is very slow in this case. (working on it now...)

"if objects are selected, make sure that ContainsFinder is called for enclosing objects which are not in the selection"
This adds additional loops to search for objects and filter duplicates. Hard to say how big the effect is.

comment:10 by GerdP, 6 years ago

Oops, I was wrong. The search

*[building]  area[natural]

finds natural areas with a building inside. So, for this case it would be okay to stop the search on the first match, on the other hand the result seems wrong to me, so probably nobody uses this search.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.