Skip to content

Commit 4fa1f83

Browse files
added changes
1 parent 20a3b94 commit 4fa1f83

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

tok/kmeans/kmeans.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ func (km *Kmeans[T]) AddVector(vec []T) error {
3333
}
3434

3535
func (km *Kmeans[T]) FindIndexForSearch(vec []T) ([]int, error) {
36-
res := make([]int, len(km.centroids.centroids))
36+
res := make([]int, km.NumSeedVectors())
3737
for i := range res {
3838
res[i] = i
3939
}

tok/partitioned_hnsw/partitioned_hnsw.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ func (ph *partitionedHNSW[T]) Search(ctx context.Context, txn index.CacheType, q
169169
}(index)
170170
}
171171
wg.Wait()
172-
fmt.Println("Result:", res)
172+
fmt.Println("Result:", res, indexes)
173173
return ph.clusterMap[0].MergeResults(ctx, txn, res, query, maxResults, filter)
174174
}
175175

0 commit comments

Comments
 (0)