Skip to content

Commit

Permalink
remove useless vector index param checker
Browse files Browse the repository at this point in the history
Signed-off-by: xianliang.li <[email protected]>
  • Loading branch information
foxspy committed Oct 31, 2024
1 parent 12fb9d6 commit 29196cc
Show file tree
Hide file tree
Showing 22 changed files with 14 additions and 691 deletions.
14 changes: 0 additions & 14 deletions internal/util/indexparamcheck/base_checker.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,28 +17,14 @@
package indexparamcheck

import (
"fmt"
"math"

"github.com/cockroachdb/errors"

"github.com/milvus-io/milvus-proto/go-api/v2/schemapb"
"github.com/milvus-io/milvus/pkg/util/typeutil"
)

type baseChecker struct{}

func (c baseChecker) CheckTrain(dataType schemapb.DataType, params map[string]string) error {
if typeutil.IsSparseFloatVectorType(dataType) {
if !CheckStrByValues(params, Metric, SparseMetrics) {
return fmt.Errorf("metric type not found or not supported for sparse float vectors, supported: %v", SparseMetrics)
}
} else {
// we do not check dim for sparse
if !CheckIntByRange(params, DIM, 1, math.MaxInt) {
return fmt.Errorf("failed to check vector dimension, should be larger than 0 and smaller than math.MaxInt")
}
}
return nil
}

Expand Down
19 changes: 0 additions & 19 deletions internal/util/indexparamcheck/bin_flat_checker.go

This file was deleted.

35 changes: 0 additions & 35 deletions internal/util/indexparamcheck/bin_ivf_flat_checker.go

This file was deleted.

43 changes: 0 additions & 43 deletions internal/util/indexparamcheck/binary_vector_base_checker.go

This file was deleted.

65 changes: 0 additions & 65 deletions internal/util/indexparamcheck/cagra_checker.go

This file was deleted.

16 changes: 0 additions & 16 deletions internal/util/indexparamcheck/diskann_checker.go

This file was deleted.

15 changes: 0 additions & 15 deletions internal/util/indexparamcheck/flat_checker.go

This file was deleted.

44 changes: 0 additions & 44 deletions internal/util/indexparamcheck/float_vector_base_checker.go

This file was deleted.

54 changes: 0 additions & 54 deletions internal/util/indexparamcheck/hnsw_checker.go

This file was deleted.

28 changes: 0 additions & 28 deletions internal/util/indexparamcheck/ivf_base_checker.go

This file was deleted.

Loading

0 comments on commit 29196cc

Please sign in to comment.