[ 
https://issues.apache.org/jira/browse/LUCENE-8173?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16363109#comment-16363109
 ] 

Karl Wright commented on LUCENE-8173:
-------------------------------------

No, upon analysis the problem is that the plane that is produced is pretty much 
EXACTLY capable of containing the three computed points; it's converged that 
far.  But the x,y,z values for the two points it's using are computed 
themselves as differences and therefore they too have a bit of numerical error, 
and it's enough to put the result *just* outside of the boundary.

The two possible ways of fixing this are:

(1) Shoot for a convergence value that's better than we need, or
(2) Algebraically recast the problem in this case to compute the deltas 
differently, so it's a one-step process not a two-step process

Using (2) is better but will probably require duplicating a fair bit of code.


> Three-point plane construction test failure
> -------------------------------------------
>
>                 Key: LUCENE-8173
>                 URL: https://issues.apache.org/jira/browse/LUCENE-8173
>             Project: Lucene - Core
>          Issue Type: Bug
>          Components: modules/spatial3d
>    Affects Versions: master (8.0)
>            Reporter: Karl Wright
>            Assignee: Karl Wright
>            Priority: Major
>
> {noformat}
> Checking out Revision dd08400a3db1c4119a704610ccc4db0d055d8d7f 
> (refs/remotes/origin/master)
> [...]
>   [smoker]    [junit4] Suite: org.apache.lucene.spatial3d.geom.RandomPlaneTest
>   [smoker]    [junit4]   2> NOTE: reproduce with: ant test  
> -Dtestcase=RandomPlaneTest -Dtests.method=testPlaneThreePointsAccuracy 
> -Dtests.seed=AF530D5BB3E29D37 -Dtests.multiplier=2 -Dtests.locale=hy-AM 
> -Dtests.timezone=CAT -Dtests.asserts=true -Dtests.file.encoding=UTF-8
>   [smoker]    [junit4] FAILURE 0.35s J2 | 
> RandomPlaneTest.testPlaneThreePointsAccuracy 
> {seed=[AF530D5BB3E29D37:67333841FC91DFF4]} <<<
>   [smoker]    [junit4]    > Throwable #1: java.lang.AssertionError: 
> -9.99866855977416E-13 PlanetModel.SPHERE point 1: [lat=-0.014383560214672818, 
> lon=0.41800053100596907([X=0.9138078833986019, Y=0.4058919556989371, 
> Z=-0.014383064258334952])], point 2: [lat=0.6932931355139935, 
> lon=-0.18388926426439056([X=0.7561778076398898, Y=-0.14064184629683377, 
> Z=0.6390735437358892])], point 3: [lat=-0.014383560214674136, 
> lon=0.41800053101150425([X=0.9138078833963552, Y=0.4058919557039952, 
> Z=-0.014383064258336268])] , check: [lat=-0.08323537864940594, 
> lon=0.4347906232623258([X=0.9038183078528319, Y=0.4197622219929782, 
> Z=-0.08313930104085177])]
>   [smoker]    [junit4]    >     at 
> __randomizedtesting.SeedInfo.seed([AF530D5BB3E29D37:67333841FC91DFF4]:0)
>   [smoker]    [junit4]    >     at 
> org.apache.lucene.spatial3d.geom.RandomPlaneTest.testPlaneThreePointsAccuracy(RandomPlaneTest.java:74)
>   [smoker]    [junit4]    >     at 
> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   [smoker]    [junit4]    >     at 
> java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>   [smoker]    [junit4]    >     at 
> java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   [smoker]    [junit4]    >     at 
> java.base/java.lang.reflect.Method.invoke(Method.java:564)
>   [smoker]    [junit4]    >     at 
> java.base/java.lang.Thread.run(Thread.java:844)
>   [smoker]    [junit4]   2> NOTE: test params are: codec=Asserting(Lucene70): 
> {}, docValues:{}, maxPointsInLeafNode=537, maxMBSortInHeap=7.561334272193783, 
> sim=Asserting(org.apache.lucene.search.similarities.AssertingSimilarity@7b5f56e9),
>  locale=hy-AM, timezone=CAT
>   [smoker]    [junit4]   2> NOTE: Linux 4.4.0-112-generic amd64/Oracle 
> Corporation 9.0.1 (64-bit)/cpus=4,threads=1,free=225585560,total=264241152
> {noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to