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

Michael McCandless commented on LUCENE-5429:
--------------------------------------------

bq. I don't think this approach is thread-safe?  If the same indexsearcher is 
used by multiple threads concurrently, 'scorerIndex' will be changing back and 
forth.

Right, scorerIndex changes for each request.  The javadocs explain this (you 
must make a new IndexSearcher per-request).

{quote}
Maybe an alternative approach would be, score a higher top-N with a single sim 
(like BM25) and re-rank with multiple ones (ideally with support for some of 
the more common schemes of doing this, some of which are heavy)? if we were to 
provide some APIs to do this kind of thing, i think it would be very useful for 
many applications.
{quote}

Yeah, I guess that's the more traditional way to achieve this?  Rather than 
running multiple first-pass searches, just run a single one with a big topN and 
then rescore after.

In one of the many patches on LUCENE-5288 I had created a small and simple 
static rescore method: it just took the docs from the first pass search and 
turned them into a filter and then ran a second search.  Maybe that's a 
start....

> Run one search across multiple scorers/collectors
> -------------------------------------------------
>
>                 Key: LUCENE-5429
>                 URL: https://issues.apache.org/jira/browse/LUCENE-5429
>             Project: Lucene - Core
>          Issue Type: Improvement
>            Reporter: Michael McCandless
>            Assignee: Michael McCandless
>         Attachments: LUCENE-5429.patch
>
>
> I'm looking into the possibility of running the same search across many 
> scorers, so that decoding postings lists / doing union and intersect are done 
> once, but scoring via Similarity can be done multiple times for each it (and 
> the results collected into separate collectors).



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to