diff --git a/src/ivfbuild.c b/src/ivfbuild.c index 346f03e..f9533f1 100644 --- a/src/ivfbuild.c +++ b/src/ivfbuild.c @@ -320,7 +320,12 @@ InsertTuples(Relation index, IvfflatBuildState * buildstate, ForkNumber forkNum) static int GetMaxDimensions(IvfflatType type) { - return IVFFLAT_MAX_DIM; + int maxDimensions = IVFFLAT_MAX_DIM; + + if (type == IVFFLAT_TYPE_HALFVEC) + maxDimensions *= 2; + + return maxDimensions; } /*