[
https://issues.apache.org/jira/browse/LUCENE-4342?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
David Smiley updated LUCENE-4342:
---------------------------------
Attachment:
LUCENE-4342_errant_+1_in_spatial_prefix_tree_factory_getLevelForDistance().patch
I missed something. There is an errant "+ 1" I removed in QuadPrefixTree and
GeohashPrefixTree Factories getLevelForDistance(). This affects the levels
needed when using the default 1m precision calculated from the factory. The
attached patch removes the "+ 1" that shouldn't be there. I'll commit it soon.
Note that this whole issue (not just this specific patch) affects the max
length of indexed prefixes given a specified target precision (default of 1m).
So to retain compatibility, you should either re-index the data or add
maxLevels="..." (as interpreted by the prefix tree factory) to explicitly say
the number of levels used when the data was indexed. FWIW the Solr adapters,
in a patch, will log this statistic on startup.
> Issues with prefix tree's Distance Error Percentage
> ----------------------------------------------------
>
> Key: LUCENE-4342
> URL: https://issues.apache.org/jira/browse/LUCENE-4342
> Project: Lucene - Core
> Issue Type: Bug
> Components: modules/spatial
> Affects Versions: 4.0-ALPHA, 4.0-BETA
> Reporter: Itamar Syn-Hershko
> Assignee: David Smiley
> Fix For: 4.0
>
> Attachments:
> LUCENE-4342_errant_+1_in_spatial_prefix_tree_factory_getLevelForDistance().patch,
>
> LUCENE-4342_fix_distance_precision_lookup_for_prefix_trees,_and_modify_the_default_algorit.patch,
> unnamed.patch
>
>
> See attached patch for a failing test
> Basically, it's a simple point and radius scenario that works great as long
> as args.setDistPrecision(0.0); is called. Once the default precision is used
> (2.5%), it doesn't work as expected.
> The distance between the 2 points in the patch is 35.75 KM. Taking into
> account the 2.5% error the effective radius without false negatives/positives
> should be around 34.8 KM. This test fails with a radius of 33 KM.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]