29339 (1) [Avatar] Offline
#1
Hi,

I tested the code in "Listing 8.9 Indexing a feature vector as a point", but failed in step 3.

It shows that the dimension count of a Lucene FloatPoint must be <= 8, but that of the image representation is 1024 in this case. How can I fixed this issue?
al.krinker (16) [Avatar] Offline
#2
Same here... 8 seems to be the max according to Lucene Doc API. Not sure how the author got around this


/**
* Enables points indexing.
*/
public void setDimensions(int dimensionCount, int dimensionNumBytes) {
if (dimensionCount < 0) {
throw new IllegalArgumentException("dimensionCount must be >= 0; got " + dimensionCount);
}
if (dimensionCount > PointValues.MAX_DIMENSIONS) {
throw new IllegalArgumentException("dimensionCount must be <= " + PointValues.MAX_DIMENSIONS + "; got " + dimensionCount);
}