You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Adrien Grand (JIRA)" <ji...@apache.org> on 2016/06/01 12:22:59 UTC
[jira] [Issue Comment Deleted] (LUCENE-7309) Speed up Polygon2D
construction
[ https://issues.apache.org/jira/browse/LUCENE-7309?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrien Grand updated LUCENE-7309:
---------------------------------
Comment: was deleted
(was: I am getting the following numbers:
|| || QPS || Construction time ||
| Arrays.sort (master) | 2.63 | 272 |
| ArrayUtil.timSort | 2.54 | 287 |
| ArrayUtil.introSort | 3.01 | 225 |
| ArrayUtil.select (patch) | 3.75 | 160 |
For the record, ArrayUtil.select is similar to ArrayUtil.introSort except that it only recurses on one of the two partitions (the one that contains the median).)
> Speed up Polygon2D construction
> -------------------------------
>
> Key: LUCENE-7309
> URL: https://issues.apache.org/jira/browse/LUCENE-7309
> Project: Lucene - Core
> Issue Type: Improvement
> Reporter: Adrien Grand
> Assignee: Adrien Grand
> Priority: Minor
> Attachments: LUCENE-7309.patch
>
>
> Polygon2D.create recursively sorts on each dimension to build a tree. However, it does not really need to sort the data, it just needs to compute the median and partition other values around it, which can be performed in O(n). If I am not mistaken, this would make Polygon2D.create run in O(n log(n)) rather than O(n log^2(n)) today.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org