IvfFlatIndex constructor
IvfFlatIndex(})
Implementation
IvfFlatIndex(
this.dim, {
required this.nlist,
this.nprobe = 1,
this.defaultMetric = VectorMetric.l2sq,
int seed = 1234,
int niter = 25,
}) : _quantizer = _KMeans(dim: dim, k: nlist, niter: niter, seed: seed),
_cellVecs = List<Float32List>.generate(nlist, (_) => Float32List(0)),
_cellIds = List<List<Object?>>.generate(nlist, (_) => <Object?>[]),
_cellCounts = List<int>.filled(nlist, 0);