[ https://issues.apache.org/jira/browse/LUCENE-8634?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16752482#comment-16752482 ]
Nicholas Knize commented on LUCENE-8634: ---------------------------------------- For clarity I'll separate the issues being discussed here: 1. Sub centimeter polygons: I think we document the spatial resolution of the encoding fairly well. 1e-7 dec deg ~= 1.11cm. Any polygon defined with vertex distances <= 1e-7 dec deg (like the one in the example here) should not be expected to index with the same accuracy as provided. So subcentimeter polygons in the WGS84 lat/lon projection are not supported and may result in an unexpected invalid shape. This is why I opened LUCENE-8632 to lay groundwork for alternative projections. If a user wants to index subcentimeter shapes they should do so using the right spatial reference system for the job. 2. "Should we keep lines and polygons in the encoded space like boxes?" So I made a simple decision (occam's razor) when handling this in the first iteration of development. For point, line, and polygon query, rather than quantize the search shape in the query constructor (like BoundingBox does) I quantized the query shape in the test before invoking the query. Right or wrong I chose this route for two reasons: a. consistency with {{LatLonPointInPolygonQuery}} which we discussed this topic at length across several issues, and b. we have no formal support for the EqualTo relation operation, only INTERSECT, DISJOINT, WITHIN. In hindsight INTERSECT does fill this void so a false negative using INTERSECT query on an indexed shape that is equalTo the query shape could/should probably be considered a bug. Furthermore, {{LatLonPointInPolygonQuery}} doesn't have the complexities to contend with like relating lines and polygons. I think this change probably deserves a bit more thought / consideration. > LatLonShape: Query with the same polygon that is indexed might not match > ------------------------------------------------------------------------ > > Key: LUCENE-8634 > URL: https://issues.apache.org/jira/browse/LUCENE-8634 > Project: Lucene - Core > Issue Type: Bug > Components: modules/sandbox > Affects Versions: 8.0, 7.7, master (9.0) > Reporter: Ignacio Vera > Priority: Major > Attachments: LUCENE-8634.patch, LUCENE-8634.patch > > > If a polygon with a degenerated dimension is indexed and then an intersect > query is performed with the same polygon, it might result in an empty result. > For example this polygon with degenerated longitude: > POLYGON((1.401298464324817E-45 22.0, 1.401298464324817E-45 69.0, > 4.8202184588118395E-40 69.0, 4.8202184588118395E-40 22.0, > 1.401298464324817E-45 22.0)) > -- 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