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

Karl Wright edited comment on LUCENE-7357 at 6/27/16 4:07 PM:
--------------------------------------------------------------

Here's a log of the planes being considered during bound computation, and the 
minimum/maximum X.

{code}
   [junit4]   2>     computing X bound for plane [A=1.2246467991473535E-16, 
B=-1.0, C=0.0, D=-0.8967828076912789, side=-1.0]
   [junit4]   2> Point1: [X=-0.44499388270914614, Y=-0.8967828076912789, Z=0.0]
   [junit4]   2> Point2: [X=0.4449938827091463, Y=-0.8967828076912789, Z=0.0]
   [junit4]   2>     computing X bound for plane [A=1.2246467991473535E-16, 
B=-1.0, C=0.0, D=0.8967828076912789, side=1.0]
   [junit4]   2> Point1: [X=-0.4449938827091463, Y=0.8967828076912789, Z=-0.0]
   [junit4]   2> Point2: [X=0.44499388270914614, Y=0.8967828076912789, Z=-0.0]
   [junit4]   2>     computing X bound for plane [A=-2.18531083006635E-12, 
B=-2.676233913182802E-28, C=-1.0, D=0.0, side=1.0]
   [junit4]   2> Point1: [X=-1.0011188539924791, Y=5.894405855879941E-40, 
Z=2.1877558738133775E-12]
   [junit4]   2> Point2: [X=1.0011188539924791, Y=-5.894405855879941E-40, 
Z=-2.1877558738133775E-12]
   [junit4]   2> Point is outside of bound [A=0.0, B=-0.0, C=-1.0, D=0.0, 
side=-1.0]
   [junit4]   2>     computing X bound for plane [A=0.0, B=-0.0, C=-1.0, D=0.0, 
side=-1.0]
   [junit4]   2> Point1: [X=-1.0011188539924791, Y=-0.0, Z=-0.0]
   [junit4]   2> Point2: [X=1.0011188539924791, Y=0.0, Z=0.0]
   [junit4]   2> Point is outside of bound [A=-2.18531083006635E-12, 
B=-2.676233913182802E-28, C=-1.0, D=0.0, side=1.0]
   [junit4]   2>     computing X bound for plane [A=-0.9999999999999999, 
B=-1.2380065887785788E-16, C=2.18531083006635E-12, D=0.44499388270914614, 
side=1.0]
   [junit4]   2> Point1: [X=0.44499387510170474, Y=7.458916684009455E-9, 
Z=-1.3078228192713674E-4]
   [junit4]   2> Point2: [X=0.4449938884797613, Y=-7.458916573828387E-9, 
Z=1.307822799952568E-4]
   [junit4]   2>     computing X bound for plane [A=-0.9999999999999999, 
B=-1.2380065887785788E-16, C=0.0, D=0.44499388270914614, side=1.0]
   [junit4]   2> Point1: [X=0.4449938664875679, Y=7.458916763861519E-9, Z=-0.0]
   [junit4]   2> Point2: [X=0.44499388655465266, Y=-7.458916653680447E-9, Z=0.0]
{code}

The bounding planes (on either side of the path) given min/max X of +/-0.44499. 
 Since the point with an X value of 0.45 manages to be considered in-set, it 
must be because of the end-point half-circles and the fact that these circles 
are truly ellipses, not circles.  Indeed, the question is really why the point 
is considered within the shape in the first place.  I'll have to look into that 
next.


was (Author: kwri...@metacarta.com):
Here's a log of the planes being considered during bound computation, and the 
minimum/maximum X.

{code}
   [junit4]   2>     computing X bound for plane [A=1.2246467991473535E-16, 
B=-1.0, C=0.0, D=-0.8967828076912789, side=-1.0]
   [junit4]   2> Point1: [X=-0.44499388270914614, Y=-0.8967828076912789, Z=0.0]
   [junit4]   2> Point2: [X=0.4449938827091463, Y=-0.8967828076912789, Z=0.0]
   [junit4]   2>     computing X bound for plane [A=1.2246467991473535E-16, 
B=-1.0, C=0.0, D=0.8967828076912789, side=1.0]
   [junit4]   2> Point1: [X=-0.4449938827091463, Y=0.8967828076912789, Z=-0.0]
   [junit4]   2> Point2: [X=0.44499388270914614, Y=0.8967828076912789, Z=-0.0]
   [junit4]   2>     computing X bound for plane [A=-2.18531083006635E-12, 
B=-2.676233913182802E-28, C=-1.0, D=0.0, side=1.0]
   [junit4]   2> Point1: [X=-1.0011188539924791, Y=5.894405855879941E-40, 
Z=2.1877558738133775E-12]
   [junit4]   2> Point2: [X=1.0011188539924791, Y=-5.894405855879941E-40, 
Z=-2.1877558738133775E-12]
   [junit4]   2> Point is outside of bound [A=0.0, B=-0.0, C=-1.0, D=0.0, 
side=-1.0]
   [junit4]   2>     computing X bound for plane [A=0.0, B=-0.0, C=-1.0, D=0.0, 
side=-1.0]
   [junit4]   2> Point1: [X=-1.0011188539924791, Y=-0.0, Z=-0.0]
   [junit4]   2> Point2: [X=1.0011188539924791, Y=0.0, Z=0.0]
   [junit4]   2> Point is outside of bound [A=-2.18531083006635E-12, 
B=-2.676233913182802E-28, C=-1.0, D=0.0, side=1.0]
   [junit4]   2>     computing X bound for plane [A=-0.9999999999999999, 
B=-1.2380065887785788E-16, C=2.18531083006635E-12, D=0.44499388270914614, 
side=1.0]
   [junit4]   2> Point1: [X=0.44499387510170474, Y=7.458916684009455E-9, 
Z=-1.3078228192713674E-4]
   [junit4]   2> Point2: [X=0.4449938884797613, Y=-7.458916573828387E-9, 
Z=1.307822799952568E-4]
   [junit4]   2>     computing X bound for plane [A=-0.9999999999999999, 
B=-1.2380065887785788E-16, C=0.0, D=0.44499388270914614, side=1.0]
   [junit4]   2> Point1: [X=0.4449938664875679, Y=7.458916763861519E-9, Z=-0.0]
   [junit4]   2> Point2: [X=0.44499388655465266, Y=-7.458916653680447E-9, Z=0.0]
{code}

The bounding planes (on either side of the path) given min/max X of +/-0.44499. 
 Since the point with an X value of 0.45 manages to be considered in-set, it 
must be because of the end-point half-circles and the fact that these circles 
are truly ellipses, not circles.  

> TestGeo3DPoint.testGeo3DRelations() failure: invalid bounds for 
> shape=GeoStandardPath
> -------------------------------------------------------------------------------------
>
>                 Key: LUCENE-7357
>                 URL: https://issues.apache.org/jira/browse/LUCENE-7357
>             Project: Lucene - Core
>          Issue Type: Bug
>          Components: modules/spatial3d
>            Reporter: Steve Rowe
>            Assignee: Karl Wright
>
> From [https://builds.apache.org/job/Lucene-Solr-Tests-master/1228/]:
> {noformat}
> Checking out Revision 46c827e31a5534bb032d0803318d01309bf0195c 
> (refs/remotes/origin/master)
> [...]
>   [junit4] Suite: org.apache.lucene.spatial3d.TestGeo3DPoint
>   [junit4]   1>     doc=1544 is contained by shape but is outside the 
> returned XYZBounds
>   [junit4]   1>       unquantized=[lat=-2.848117399637174E-91, 
> lon=-1.1092122135274942([X=0.44586529864043345, Y=-0.8963498732568058, 
> Z=-2.851304027160807E-91])]
>   [junit4]   1>       quantized=[X=0.44586529870253566, 
> Y=-0.8963498734280969, Z=-2.3309121299774915E-10]
>   [junit4]   1>   shape=GeoStandardPath: {planetmodel=PlanetModel.WGS84, 
> width=1.117010721276371(64.0), points={[[lat=2.18531083006635E-12, 
> lon=-3.141592653589793([X=-1.0011188539924791, Y=-1.226017000107956E-16, 
> Z=2.187755873813378E-12])], [lat=0.0, 
> lon=-3.141592653589793([X=-1.0011188539924791, Y=-1.226017000107956E-16, 
> Z=0.0])]]}}
>   [junit4]   1>   bounds=XYZBounds: [xmin=-1.0011188549924792 
> xmax=0.4449938894797613 ymin=-1.0011188549924792 ymax=1.0011188549924792 
> zmin=-0.9977622930221051 zmax=0.9977622930221051]
>   [junit4]   2> NOTE: reproduce with: ant test  -Dtestcase=TestGeo3DPoint 
> -Dtests.method=testGeo3DRelations -Dtests.seed=1F71744AE2101863 
> -Dtests.multiplier=2 -Dtests.slow=true -Dtests.locale=pt-PT 
> -Dtests.timezone=Europe/Berlin -Dtests.asserts=true 
> -Dtests.file.encoding=ISO-8859-1
>   [junit4] FAILURE 1.46s J1 | TestGeo3DPoint.testGeo3DRelations <<<
>   [junit4]    > Throwable #1: java.lang.AssertionError: invalid bounds for 
> shape=GeoStandardPath: {planetmodel=PlanetModel.WGS84, 
> width=1.117010721276371(64.0), points={[[lat=2.18531083006635E-12, 
> lon=-3.141592653589793([X=-1.0011188539924791, Y=-1.226017000107956E-16, 
> Z=2.187755873813378E-12])], [lat=0.0, 
> lon=-3.141592653589793([X=-1.0011188539924791, Y=-1.226017000107956E-16, 
> Z=0.0])]]}}
>   [junit4]    >       at 
> __randomizedtesting.SeedInfo.seed([1F71744AE2101863:AF0E09DE6D5DB6FF]:0)
>   [junit4]    >       at 
> org.apache.lucene.spatial3d.TestGeo3DPoint.testGeo3DRelations(TestGeo3DPoint.java:259)
>   [junit4]    >       at java.lang.Thread.run(Thread.java:745)
>   [junit4] IGNOR/A 0.00s J1 | TestGeo3DPoint.testRandomBig
>   [junit4]    > Assumption #1: 'nightly' test group is disabled (@Nightly())
>   [junit4]   2> NOTE: test params are: codec=Asserting(Lucene62), 
> sim=RandomSimilarity(queryNorm=false,coord=yes): {}, locale=pt-PT, 
> timezone=Europe/Berlin
>   [junit4]   2> NOTE: Linux 3.13.0-85-generic amd64/Oracle Corporation 
> 1.8.0_74 (64-bit)/cpus=4,threads=1,free=256210224,total=354418688
>   [junit4]   2> NOTE: All tests run in this JVM: [TestGeo3DPoint]
>   [junit4] Completed [10/11 (1!)] on J1 in 37.22s, 14 tests, 1 failure, 1 
> skipped <<< FAILURES!
> {noformat}
> Reproduces for me.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

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

Reply via email to