lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Yonik Seeley <ysee...@gmail.com>
Subject Re: Bad explanations
Date Wed, 26 Oct 2005 16:32:19 GMT
Typo... try explain(query,doc) instead of (query,i)
:-)


-Yonik
Now hiring -- http://forms.cnet.com/slink?231706


On 10/26/05, Olivier Jaquemet <olivier.jaquemet@jalios.com> wrote:
>
> Hi everyone,
>
> I am encoutering a really weird problem, I'm doing a query which gives
> me perfectly good results, with scores which are looking pretty right
> too. I wanted to display an explanation of some of my results just to
> check for something, and ALL hits output this explanation
> 0.0 = product of:
> 0.0 = sum of:
> 0.0 = coord(0/3)
>
> It's been two hours I have been digging through my code for a possible
> reason to this.
> I even tried to simplify my code:
> - I was using a MultiFieldQueryParser, I removed it in favor a simpler
> QueryParser, no change. still good results but same bad explanation
> - I was using a MultiIndexSearcher wrapper to reuse the searcher as long
> as no indexing occured, I remove it and created a new one which only
> search one index, no change. still good results but same bad explanation
> I tried the same query a MultiFieldQueryParser creates, with luke and
> explanation (of simple query) are good!
>
>
> Here is how i call the explain method:
> for (int i = 0; i < hits.length(); i++) {
> Document doc = hits.doc(i);
> [...]
> logger.debug(searcher.explain(query, i));
> }
>
> I could not find anything and I have no idea where to look.
> So if you can see my mistake or know how this problem can occurs please
> help !
>
> Olivier
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message