Structure Description
The parameters used by the APIs provided by KVecturbo involve the VectorArray and PQParams structures. For details, see Table 1 and Table 2.
Field |
Description |
Data Type |
Value Range |
|---|---|---|---|
maxLen |
Maximum number of vectors. |
int |
[1,10000000] |
length |
Number of vectors. |
int |
[1, maxLen], where maxLen is a field in the VectorArray structure, indicating the maximum number of vectors. |
dim |
Vector dimension. |
int |
[1,2000] |
itemSize |
Length of a single vector. |
size_t |
The value cannot be 0. |
items |
Start addresses of length vectors. |
char* |
The value cannot be null. |
Field |
Description |
Data Type |
Value Range |
|---|---|---|---|
dim |
Dimension. |
int |
[1,2000] |
pqM |
Number of subspaces. |
int |
[1,dim], where dim is a field in the PQParams structure, indicating the vector dimension. |
pqKsub |
Number of cluster centroids in the subspace. |
int |
[1,256] |
functype |
Distance type. |
int |
[1,3]
|
subItemSize |
Codeword size. |
size_t |
The value cannot be 0. |
pqTable |
Codebook. |
char* |
The value cannot be null. |