lucy-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Karman <pe...@peknet.com>
Subject Re: get_score == nan
Date Tue, 06 Apr 2010 18:39:33 GMT
Marvin Humphrey wrote on 04/06/2010 01:20 PM:
> On Tue, Apr 06, 2010 at 11:56:56AM -0500, Peter Karman wrote:
>> Is there any legitimate way that $hitdoc->get_score would return a value
>> that Perl stringifies to 'nan'? 
> 
> When using a SortSpec that doesn't include scoring, yes.  In that case,
> SortCollector assigns 'nan' to the MatchDoc score member and it never gets
> overwritten with a real value.   We optimize the "score not needed" case and
> avoid the cost of calculating scores.

ah ok. That's likely what's happening (SortSpec with no scoring).

Thanks.

-- 
Peter Karman  .  http://peknet.com/  .  peter@peknet.com

Mime
View raw message