lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Muir <rcm...@gmail.com>
Subject Re: How to retrieve value of NumericDocValuesField in similarity
Date Mon, 12 Aug 2013 15:27:02 GMT
Hello:

This call just "passes thru" to docvalues:

   FieldCache.DEFAULT.getFloats(context.reader(), boostField, false)

if you want to call context.reader().getNumericDocValues... you could
do that too, but thats all its doing in this case.

On Mon, Aug 12, 2013 at 11:09 AM, Ross Woolf <ross@rosswoolf.com> wrote:
> That example shows using fieldcache, I am not wanting to use the
> fieldcache.  I want to use the newer NumericDocValuesField.  Any direction
> or examples of how to retrieve a value from the created
> NumericDocValuesField in most efficient way would be appreciated.
>
>
> On Mon, Aug 12, 2013 at 8:54 AM, Robert Muir <rcmuir@gmail.com> wrote:
>
>> There is a unit test demonstrating this at a very basic level here:
>>
>>
>> http://svn.apache.org/repos/asf/lucene/dev/branches/branch_4x/lucene/core/src/test/org/apache/lucene/search/TestDocValuesScoring.java
>>
>> On Mon, Aug 12, 2013 at 10:43 AM, Ross Woolf <ross@rosswoolf.com> wrote:
>> > The JavaDocs for NumericDocValuesField indicates that this field value
>> can
>> > be used for scoring.  The example shows how to store the field, but I am
>> > unclear as to how to retrieve the value of the field while in a
>> similarity
>> > to use it when scoring a document?  Can someone point me to an example or
>> > give me one that demonstrates how I can fetch the value associated with
>> the
>> > document being scored while in a similarity class that I have created?
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
>> For additional commands, e-mail: java-user-help@lucene.apache.org
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message