lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Miller <>
Subject Re: Whither Query Norm?
Date Fri, 20 Nov 2009 16:04:42 GMT
Grant Ingersoll wrote:
> For a long time now, we've been telling people not to compare scores across queries,
yet we maintain the queryNorm() code as an attempt to do this and the javadocs even promote
it.  I'm in the process of researching this some more (references welcomed), but wanted to
hear what people think about it here.  I haven't profiled it just yet, but it seems like a
good chunk of wasted computation to me (loops, divisions and square roots).  At a minimum,
I think we might be able to refactor the callback mechanism for it just as we did for the
collectors, such that we push of the actual calculation of the sum of squares into Similarity,
instead of just doing 1/sqrt(sumSqs).  That way, when people want to override queryNorm()
to return 1, they are saving more than just the 1/sqrt calculation.  I haven't tested it yet,
but wanted to find out what others think.
> Thoughts?
> -Grant
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:
Here is old discussion

Its essentially no cost and has minor benefits - I'm still +1 for
keeping it.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message