[
https://issues.apache.org/jira/browse/LUCENE-8281?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16456254#comment-16456254
]
Karl Wright commented on LUCENE-8281:
-------------------------------------
It looks like the Edge XYZBounds are working fine. Here's the new output:
{code}
[junit4] 1> Recording edge [[lat=-1.135982425157425E-6,
lon=6.109011074784121E-7([X=0.9999999999991683, Y=6.1090110747798E-7,
Z=-1.1359824251571808E-6])] --> [lat=-2.7797906712270083E-7,
lon=1.8357011217773334E-6([X=0.9999999999982765, Y=1.8357011217762314E-6,
Z=-2.7797906712269723E-7])]]; bounds = XYZBounds: [xmin=0.9999999989982765
xmax=1.0000000009991798 ymin=6.0990110747798E-7 ymax=1.8367011217762314E-6
zmin=-1.136982425157181E-6 zmax=-2.769790671226972E-7]
[junit4] 1> Recording edge [[lat=-2.7797906712270083E-7,
lon=1.8357011217773334E-6([X=0.9999999999982765, Y=1.8357011217762314E-6,
Z=-2.7797906712269723E-7])] --> [lat=4.492749557241206E-7,
lon=1.8019115568534971E-6([X=0.9999999999982758, Y=1.8019115568523405E-6,
Z=4.492749557241056E-7])]]; bounds = XYZBounds: [xmin=0.9999999989982759
xmax=1.0000000009983425 ymin=1.8009115568523404E-6 ymax=1.8367011217762314E-6
zmin=-2.7897906712269725E-7 zmax=4.5027495572410565E-7]
[junit4] 1> Recording edge [[lat=4.492749557241206E-7,
lon=1.8019115568534971E-6([X=0.9999999999982758, Y=1.8019115568523405E-6,
Z=4.492749557241056E-7])] --> [lat=1.255403467900245E-6,
lon=1.3751481926504994E-6([X=0.9999999999982665, Y=1.3751481926489823E-6,
Z=1.2554034678999154E-6])]]; bounds = XYZBounds: [xmin=0.9999999989982665
xmax=1.0000000009983752 ymin=1.3741481926489823E-6 ymax=1.8029115568523406E-6
zmin=4.482749557241056E-7 zmax=1.2564034678999155E-6]
[junit4] 1> Recording edge [[lat=1.255403467900245E-6,
lon=1.3751481926504994E-6([X=0.9999999999982665, Y=1.3751481926489823E-6,
Z=1.2554034678999154E-6])] --> [lat=1.640689686301266E-25, lon=0.0([X=1.0,
Y=0.0, Z=1.640689686301266E-25])]]; bounds = XYZBounds:
[xmin=0.9999999989982665 xmax=1.000000001 ymin=-1.0E-9
ymax=1.3761481926489824E-6 zmin=-1.0E-9 zmax=1.2564034678999155E-6]
[junit4] 1> Recording edge [[lat=1.640689686301266E-25, lon=0.0([X=1.0,
Y=0.0, Z=1.640689686301266E-25])] --> [lat=-1.135982425157425E-6,
lon=6.109011074784121E-7([X=0.9999999999991683, Y=6.1090110747798E-7,
Z=-1.1359824251571808E-6])]]; bounds = XYZBounds: [xmin=0.9999999989991684
xmax=1.000000001 ymin=-1.0E-9 ymax=6.1190110747798E-7
zmin=-1.136982425157181E-6 zmax=1.0000000000000003E-9]
[junit4] 1> Determining in-set-ness of test point2
([X=-0.9999999999993657, Y=-1.124732395751746E-6, Z=-5.8143386268861615E-8]):
[junit4] 1>
[junit4] 1> IsInSet called for
[-0.9999999999993657,-1.124732395751746E-6,-5.8143386268861615E-8],
testPoint=[lat=5.8143386268861655E-8,
lon=1.1247323957519851E-6([X=0.9999999999993657, Y=1.124732395751746E-6,
Z=5.8143386268861615E-8])]; is in set? true
[junit4] 1> Using two planes
[junit4] 1> Looking for intersections between travel and test point
planes...
[junit4] 1> Picking XZ then XY
[junit4] 1> Looking for intersections between travel and test point
planes...
[junit4] 1> Finding whether [X=0.9999999999993657,
Y=-1.124732395751746E-6, Z=5.8143386268861615E-8] is in-set, based on travel
from [lat=5.8143386268861655E-8,
lon=1.1247323957519851E-6([X=0.9999999999993657, Y=1.124732395751746E-6,
Z=5.8143386268861615E-8])] along [A=0.0, B=0.0; C=1.0;
D=-5.8143386268861615E-8] (value=5.8143386268861615E-8)
[junit4] 1> Constructing sector linear crossing edge iterator
[junit4] 1>
[junit4] 1> The following edges intersect the travel plane within the
given bounds:
[junit4] 1> Edge [lat=1.255403467900245E-6,
lon=1.3751481926504994E-6([X=0.9999999999982665, Y=1.3751481926489823E-6,
Z=1.2554034678999154E-6])] --> [lat=1.640689686301266E-25, lon=0.0([X=1.0,
Y=0.0, Z=1.640689686301266E-25])] intersects
[junit4] 1> ...done
[junit4] 1>
[junit4] 1> Edge [[lat=-2.7797906712270083E-7,
lon=1.8357011217773334E-6([X=0.9999999999982765, Y=1.8357011217762314E-6,
Z=-2.7797906712269723E-7])] --> [lat=4.492749557241206E-7,
lon=1.8019115568534971E-6([X=0.9999999999982758, Y=1.8019115568523405E-6,
Z=4.492749557241056E-7])]] potentially crosses travel plane [A=0.0, B=0.0;
C=1.0; D=-5.8143386268861615E-8]
[junit4] 1> Finding intersections between edge plane and travel plane...
[junit4] 1> There are no intersection points within bounds.
[junit4] 1> Crossing point [X=0.999999999998342,
Y=1.820084251873324E-6, Z=5.8143386268861615E-8] rejected by bound1
(6.953518561222897E-7)
[junit4] 1> Crossing point [X=-0.9999999999983322,
Y=-1.8254871500725794E-6, Z=5.8143386268861615E-8] rejected by bound2
(-2.950219545821297E-6)
[junit4] 1> Crossing point [X=-0.9999999999983322,
Y=-1.8254871500725794E-6, Z=5.8143386268861615E-8] rejected by edge.startPlane
(-2.2007283293136158E-7)
[junit4] 1> Crossing point [X=-0.9999999999983322,
Y=-1.8254871500725794E-6, Z=5.8143386268861615E-8] rejected by edge.endPlane
(5.079657295394685E-7)
[junit4] 1> Endpoint(s) of edge are not on travel plane; distances:
-3.3612245339155885E-7 and 3.91131569455244E-7
[junit4] 1> Edge [[lat=1.255403467900245E-6,
lon=1.3751481926504994E-6([X=0.9999999999982665, Y=1.3751481926489823E-6,
Z=1.2554034678999154E-6])] --> [lat=1.640689686301266E-25, lon=0.0([X=1.0,
Y=0.0, Z=1.640689686301266E-25])]] potentially crosses travel plane [A=0.0,
B=0.0; C=1.0; D=-5.8143386268861615E-8]
[junit4] 1> Finding intersections between edge plane and travel plane...
[junit4] 1> There were intersection points!
[junit4] 1> Edge intersects travel plane [A=0.0, B=0.0; C=1.0;
D=-5.8143386268861615E-8]
[junit4] 1> Intersection point in-set? false
[junit4] 1> Finding whether
[-0.9999999999993657,-1.124732395751746E-6,-5.8143386268861615E-8] is in-set,
based on travel from [X=0.9999999999993657, Y=-1.124732395751746E-6,
Z=5.8143386268861615E-8] along [A=0.0, B=1.0; C=0.0; D=1.124732395751746E-6]
(value=-1.124732395751746E-6)
[junit4] 1> Constructing full linear crossing edge iterator
[junit4] 1>
[junit4] 1> The following edges intersect the travel plane within the
given bounds:
[junit4] 1> ...done
[junit4] 1>
[junit4] 1> Check point in set? false
[junit4] 1>
[junit4] 1> ... done. Checking against test point1
([lat=5.8143386268861655E-8, lon=1.1247323957519851E-6([X=0.9999999999993657,
Y=1.124732395751746E-6, Z=5.8143386268861615E-8])]):
[junit4] 1>
[junit4] 1> IsInSet called for
[0.9999999999993657,1.124732395751746E-6,5.8143386268861615E-8],
testPoint=[X=-0.9999999999993657, Y=-1.124732395751746E-6,
Z=-5.8143386268861615E-8]; is in set? false
[junit4] 1> Using two planes
[junit4] 1> Looking for intersections between travel and test point
planes...
[junit4] 1> Picking XZ then XY
[junit4] 1> Looking for intersections between travel and test point
planes...
[junit4] 1> Finding whether [X=0.9999999999993657,
Y=1.124732395751746E-6, Z=-5.8143386268861615E-8] is in-set, based on travel
from [X=-0.9999999999993657, Y=-1.124732395751746E-6, Z=-5.8143386268861615E-8]
along [A=0.0, B=0.0; C=1.0; D=5.8143386268861615E-8]
(value=-5.8143386268861615E-8)
[junit4] 1> Constructing sector linear crossing edge iterator
[junit4] 1>
[junit4] 1> The following edges intersect the travel plane within the
given bounds:
[junit4] 1> ...done
[junit4] 1>
[junit4] 1> Edge [[lat=-2.7797906712270083E-7,
lon=1.8357011217773334E-6([X=0.9999999999982765, Y=1.8357011217762314E-6,
Z=-2.7797906712269723E-7])] --> [lat=4.492749557241206E-7,
lon=1.8019115568534971E-6([X=0.9999999999982758, Y=1.8019115568523405E-6,
Z=4.492749557241056E-7])]] potentially crosses travel plane [A=0.0, B=0.0;
C=1.0; D=5.8143386268861615E-8]
[junit4] 1> Finding intersections between edge plane and travel plane...
[junit4] 1> There are no intersection points within bounds.
[junit4] 1> Crossing point [X=0.9999999999983322,
Y=1.8254871500725794E-6, Z=-5.8143386268861615E-8] rejected by bound2
(7.007547543215527E-7)
[junit4] 1> Crossing point [X=-0.999999999998342,
Y=-1.820084251873324E-6, Z=-5.8143386268861615E-8] rejected by bound1
(6.953518561222897E-7)
[junit4] 1> Crossing point [X=-0.999999999998342,
Y=-1.820084251873324E-6, Z=-5.8143386268861615E-8] rejected by edge.startPlane
(-3.364850521189999E-7)
[junit4] 1> Crossing point [X=-0.999999999998342,
Y=-1.820084251873324E-6, Z=-5.8143386268861615E-8] rejected by edge.endPlane
(3.915535103518376E-7)
[junit4] 1> Endpoint(s) of edge are not on travel plane; distances:
-2.1983568085383562E-7 and 5.074183419929672E-7
[junit4] 1> Edge [[lat=1.640689686301266E-25, lon=0.0([X=1.0, Y=0.0,
Z=1.640689686301266E-25])] --> [lat=-1.135982425157425E-6,
lon=6.109011074784121E-7([X=0.9999999999991683, Y=6.1090110747798E-7,
Z=-1.1359824251571808E-6])]] potentially crosses travel plane [A=0.0, B=0.0;
C=1.0; D=5.8143386268861615E-8]
[junit4] 1> Finding intersections between edge plane and travel plane...
[junit4] 1> There are no intersection points within bounds.
[junit4] 1> Crossing point [X=-0.9999999999999978,
Y=3.126796531139363E-8, Z=-5.8143386268861615E-8] rejected by bound2
(1.1560003610631194E-6)
[junit4] 1> Crossing point [X=-0.9999999999999978,
Y=3.126796531139363E-8, Z=-5.8143386268861615E-8] rejected by edge.endPlane
(1.3558457034489254E-6)
[junit4] 1> Crossing point [X=0.9999999999999978,
Y=3.126796531139363E-8, Z=-5.8143386268861615E-8] rejected by bound1
(1.0934644304403715E-6)
[junit4] 1> Endpoint(s) of edge are not on travel plane; distances:
5.8143386268861615E-8 and -1.0778390388883193E-6
[junit4] 1> Intersection point in-set? false
[junit4] 1> Finding whether
[0.9999999999993657,1.124732395751746E-6,5.8143386268861615E-8] is in-set,
based on travel from [X=0.9999999999993657, Y=1.124732395751746E-6,
Z=-5.8143386268861615E-8] along [A=0.0, B=1.0; C=0.0; D=-1.124732395751746E-6]
(value=1.124732395751746E-6)
[junit4] 1> Constructing sector linear crossing edge iterator
[junit4] 1>
[junit4] 1> The following edges intersect the travel plane within the
given bounds:
[junit4] 1> ...done
[junit4] 1>
[junit4] 1> Edge [[lat=-1.135982425157425E-6,
lon=6.109011074784121E-7([X=0.9999999999991683, Y=6.1090110747798E-7,
Z=-1.1359824251571808E-6])] --> [lat=-2.7797906712270083E-7,
lon=1.8357011217773334E-6([X=0.9999999999982765, Y=1.8357011217762314E-6,
Z=-2.7797906712269723E-7])]] potentially crosses travel plane [A=0.0, B=1.0;
C=0.0; D=-1.124732395751746E-6]
[junit4] 1> Finding intersections between edge plane and travel plane...
[junit4] 1> There are no intersection points within bounds.
[junit4] 1> Crossing point [X=0.9999999999990665,
Y=1.124732395751746E-6, Z=-7.76030624328578E-7] rejected by bound1
(7.178872380597327E-7)
[junit4] 1> Crossing point [X=-0.9999999999966022,
Y=1.124732395751746E-6, Z=2.3518375498275934E-6] rejected by bound2
(-2.4099809360962904E-6)
[junit4] 1> Crossing point [X=-0.9999999999966022,
Y=1.124732395751746E-6, Z=2.3518375498275934E-6] rejected by edge.endPlane
(3.6145616079893093E-6)
[junit4] 1> Endpoint(s) of edge are not on travel plane; distances:
-5.138312882737661E-7 and 7.109687260244853E-7
[junit4] 1> Edge [[lat=1.255403467900245E-6,
lon=1.3751481926504994E-6([X=0.9999999999982665, Y=1.3751481926489823E-6,
Z=1.2554034678999154E-6])] --> [lat=1.640689686301266E-25, lon=0.0([X=1.0,
Y=0.0, Z=1.640689686301266E-25])]] potentially crosses travel plane [A=0.0,
B=1.0; C=0.0; D=-1.124732395751746E-6]
[junit4] 1> Finding intersections between edge plane and travel plane...
[junit4] 1> There are no intersection points within bounds.
[junit4] 1> Crossing point [X=-0.9999999999988402,
Y=1.124732395751746E-6, Z=1.0267932995397135E-6] rejected by bound2
(-1.0849366858085427E-6)
[junit4] 1> Crossing point [X=-0.9999999999988402,
Y=1.124732395751746E-6, Z=1.0267932995397135E-6] rejected by edge.startPlane
(-3.384940921425686E-6)
[junit4] 1> Crossing point [X=0.9999999999988402,
Y=1.124732395751746E-6, Z=1.0267932995397135E-6] rejected by bound2
(-9.68649913270881E-7)
[junit4] 1> Endpoint(s) of edge are not on travel plane; distances:
2.5041579689723626E-7 and -1.124732395751746E-6
[junit4] 1> Check point in set? false
{code}
In other words, we find all the intersections that there are -- no more, no
less -- given the travel plane bounding planes and edge bounding planes. So
we're not missing any because of a wrong XYZBounds computation.
I guess we still could be *almost* missing an intersection with an edge,
because of bounds. That's easy to rule out though. Stay tuned.
> Random polygon test failures
> ----------------------------
>
> Key: LUCENE-8281
> URL: https://issues.apache.org/jira/browse/LUCENE-8281
> Project: Lucene - Core
> Issue Type: Bug
> Components: modules/spatial3d
> Reporter: Karl Wright
> Assignee: Karl Wright
> Priority: Major
> Attachments: LUCENE-8281-debugging.patch, LUCENE-8281.jpg
>
>
> Reproduce here:
> {code}
> ant test -Dtestcase=RandomGeoPolygonTest
> -Dtests.method=testCompareSmallPolygons -Dtests.seed=42573983280EE568
> -Dtests.multiplier=3 -Dtests.slow=true -Dtests.locale=jmc-TZ
> -Dtests.timezone=US/Alaska -Dtests.asserts=true -Dtests.file.encoding=US-ASCII
> {code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]