diff --git a/internal/core/src/common/Types.h b/internal/core/src/common/Types.h index 90f06d8e8a..e2f04b6434 100644 --- a/internal/core/src/common/Types.h +++ b/internal/core/src/common/Types.h @@ -31,6 +31,7 @@ #include "knowhere/common/MetricType.h" #include "pb/schema.pb.h" #include "pb/segcore.pb.h" +#include "pb/plan.pb.h" namespace milvus { @@ -61,6 +62,8 @@ using Timestamp = uint64_t; // TODO: use TiKV-like timestamp constexpr auto MAX_TIMESTAMP = std::numeric_limits::max(); constexpr auto MAX_ROW_COUNT = std::numeric_limits::max(); +using OpType = proto::plan::OpType; +using ArithOpType = proto::plan::ArithOpType; using ScalarArray = proto::schema::ScalarField; using DataArray = proto::schema::FieldData; using VectorArray = proto::schema::VectorField; diff --git a/internal/core/src/index/Index.h b/internal/core/src/index/Index.h index 8a213e88d5..66ff943df5 100644 --- a/internal/core/src/index/Index.h +++ b/internal/core/src/index/Index.h @@ -14,7 +14,6 @@ #include #include #include -#include "index/OperatorType.h" #include namespace milvus::scalar { diff --git a/internal/core/src/index/OperatorType.h b/internal/core/src/index/OperatorType.h deleted file mode 100644 index 7c3decd601..0000000000 --- a/internal/core/src/index/OperatorType.h +++ /dev/null @@ -1,26 +0,0 @@ -// Copyright (C) 2019-2020 Zilliz. All rights reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software distributed under the License -// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express -// or implied. See the License for the specific language governing permissions and limitations under the License - -#pragma once - -namespace milvus::scalar { -enum OperatorType { - LT = 0, - LE = 1, - GT = 3, - GE = 4, - RangeOp = 5, - InOp = 6, - NotInOp = 7, - PrefixMatchOp = 8, - PostfixMatchOp = 9, -}; -} // namespace milvus::scalar diff --git a/internal/core/src/index/ScalarIndex-inl.h b/internal/core/src/index/ScalarIndex-inl.h index bc99665b3c..f4f304c0b4 100644 --- a/internal/core/src/index/ScalarIndex-inl.h +++ b/internal/core/src/index/ScalarIndex-inl.h @@ -17,17 +17,17 @@ namespace milvus::scalar { template const TargetBitmapPtr ScalarIndex::Query(const DatasetPtr& dataset) { - auto op = dataset->Get(OPERATOR_TYPE); + auto op = dataset->Get(OPERATOR_TYPE); switch (op) { - case LT: - case LE: - case GT: - case GE: { + case OpType::LessThan: + case OpType::LessEqual: + case OpType::GreaterThan: + case OpType::GreaterEqual: { auto value = dataset->Get(RANGE_VALUE); return Range(value, op); } - case RangeOp: { + case OpType::Range: { auto lower_bound_value = dataset->Get(LOWER_BOUND_VALUE); auto upper_bound_value = dataset->Get(UPPER_BOUND_VALUE); auto lower_bound_inclusive = dataset->Get(LOWER_BOUND_INCLUSIVE); @@ -35,20 +35,20 @@ ScalarIndex::Query(const DatasetPtr& dataset) { return Range(lower_bound_value, lower_bound_inclusive, upper_bound_value, upper_bound_inclusive); } - case InOp: { + case OpType::In: { auto n = dataset->Get(knowhere::meta::ROWS); auto values = dataset->Get(knowhere::meta::TENSOR); return In(n, reinterpret_cast(values)); } - case NotInOp: { + case OpType::NotIn: { auto n = dataset->Get(knowhere::meta::ROWS); auto values = dataset->Get(knowhere::meta::TENSOR); return NotIn(n, reinterpret_cast(values)); } - case PrefixMatchOp: - case PostfixMatchOp: + case OpType::PrefixMatch: + case OpType::PostfixMatch: default: throw std::invalid_argument(std::string("unsupported operator type: " + std::to_string(op))); } diff --git a/internal/core/src/index/ScalarIndex.h b/internal/core/src/index/ScalarIndex.h index 3c81e3f7b8..3147e5b594 100644 --- a/internal/core/src/index/ScalarIndex.h +++ b/internal/core/src/index/ScalarIndex.h @@ -16,6 +16,7 @@ #include #include #include "index/Index.h" +#include "common/Types.h" namespace milvus::scalar { @@ -32,7 +33,7 @@ class ScalarIndex : public IndexBase { NotIn(size_t n, const T* values) = 0; virtual const TargetBitmapPtr - Range(T value, OperatorType op) = 0; + Range(T value, OpType op) = 0; virtual const TargetBitmapPtr Range(T lower_bound_value, bool lb_inclusive, T upper_bound_value, bool ub_inclusive) = 0; diff --git a/internal/core/src/index/ScalarIndexSort-inl.h b/internal/core/src/index/ScalarIndexSort-inl.h index 85f788d2db..4a5ffcbc45 100644 --- a/internal/core/src/index/ScalarIndexSort-inl.h +++ b/internal/core/src/index/ScalarIndexSort-inl.h @@ -17,6 +17,7 @@ #include #include "knowhere/common/Log.h" #include "Meta.h" +#include "common/Utils.h" namespace milvus::scalar { @@ -140,7 +141,7 @@ ScalarIndexSort::NotIn(const size_t n, const T* values) { template inline const TargetBitmapPtr -ScalarIndexSort::Range(const T value, const OperatorType op) { +ScalarIndexSort::Range(const T value, const OpType op) { if (!is_built_) { build(); } @@ -148,16 +149,16 @@ ScalarIndexSort::Range(const T value, const OperatorType op) { auto lb = data_.begin(); auto ub = data_.end(); switch (op) { - case OperatorType::LT: + case OpType::LessThan: ub = std::lower_bound(data_.begin(), data_.end(), IndexStructure(value)); break; - case OperatorType::LE: + case OpType::LessEqual: ub = std::upper_bound(data_.begin(), data_.end(), IndexStructure(value)); break; - case OperatorType::GT: + case OpType::GreaterThan: lb = std::upper_bound(data_.begin(), data_.end(), IndexStructure(value)); break; - case OperatorType::GE: + case OpType::GreaterEqual: lb = std::lower_bound(data_.begin(), data_.end(), IndexStructure(value)); break; default: diff --git a/internal/core/src/index/ScalarIndexSort.h b/internal/core/src/index/ScalarIndexSort.h index 94e4984a1b..eea44c84cb 100644 --- a/internal/core/src/index/ScalarIndexSort.h +++ b/internal/core/src/index/ScalarIndexSort.h @@ -55,7 +55,7 @@ class ScalarIndexSort : public ScalarIndex { NotIn(size_t n, const T* values) override; const TargetBitmapPtr - Range(T value, OperatorType op) override; + Range(T value, OpType op) override; const TargetBitmapPtr Range(T lower_bound_value, bool lb_inclusive, T upper_bound_value, bool ub_inclusive) override; diff --git a/internal/core/src/index/StringIndex.h b/internal/core/src/index/StringIndex.h index 6086fc79c6..f37fd6fffd 100644 --- a/internal/core/src/index/StringIndex.h +++ b/internal/core/src/index/StringIndex.h @@ -44,8 +44,8 @@ class StringIndex : public ScalarIndex { const TargetBitmapPtr Query(const DatasetPtr& dataset) override { - auto op = dataset->Get(OPERATOR_TYPE); - if (op == PrefixMatchOp) { + auto op = dataset->Get(OPERATOR_TYPE); + if (op == OpType::PrefixMatch) { auto prefix = dataset->Get(PREFIX_VALUE); return PrefixMatch(prefix); } diff --git a/internal/core/src/index/StringIndexMarisa.cpp b/internal/core/src/index/StringIndexMarisa.cpp index 6d3eedb758..85e4ca1555 100644 --- a/internal/core/src/index/StringIndexMarisa.cpp +++ b/internal/core/src/index/StringIndexMarisa.cpp @@ -20,7 +20,7 @@ #include #include #include -#include +#include "exceptions/EasyAssert.h" namespace milvus::scalar { @@ -149,7 +149,7 @@ StringIndexMarisa::NotIn(size_t n, const std::string* values) { } const TargetBitmapPtr -StringIndexMarisa::Range(std::string value, OperatorType op) { +StringIndexMarisa::Range(std::string value, OpType op) { throw std::runtime_error("todo: unsupported now"); } diff --git a/internal/core/src/index/StringIndexMarisa.h b/internal/core/src/index/StringIndexMarisa.h index 6f7f53382f..662c3aa192 100644 --- a/internal/core/src/index/StringIndexMarisa.h +++ b/internal/core/src/index/StringIndexMarisa.h @@ -50,7 +50,7 @@ class StringIndexMarisa : public StringIndex { NotIn(size_t n, const std::string* values) override; const TargetBitmapPtr - Range(std::string value, OperatorType op) override; + Range(std::string value, OpType op) override; const TargetBitmapPtr Range(std::string lower_bound_value, bool lb_inclusive, std::string upper_bound_value, bool ub_inclusive) override; diff --git a/internal/core/src/index/StringIndexSort.h b/internal/core/src/index/StringIndexSort.h index 1a7187d30c..5641cc804c 100644 --- a/internal/core/src/index/StringIndexSort.h +++ b/internal/core/src/index/StringIndexSort.h @@ -43,8 +43,8 @@ class StringIndexSort : public ScalarIndexSort { const TargetBitmapPtr Query(const DatasetPtr& dataset) override { - auto op = dataset->Get(OPERATOR_TYPE); - if (op == PrefixMatchOp) { + auto op = dataset->Get(OPERATOR_TYPE); + if (op == OpType::PrefixMatch) { auto prefix = dataset->Get(PREFIX_VALUE); return PrefixMatch(prefix); } diff --git a/internal/core/src/pb/plan.pb.cc b/internal/core/src/pb/plan.pb.cc index b27b5d8af9..b443f382e4 100644 --- a/internal/core/src/pb/plan.pb.cc +++ b/internal/core/src/pb/plan.pb.cc @@ -626,15 +626,15 @@ const char descriptor_table_protodef_plan_2eproto[] PROTOBUF_SECTION_VARIABLE(pr "\030\005 \001(\t\"\221\001\n\010PlanNode\0224\n\013vector_anns\030\001 \001(\013" "2\035.milvus.proto.plan.VectorANNSH\000\022-\n\npre" "dicates\030\002 \001(\0132\027.milvus.proto.plan.ExprH\000" - "\022\030\n\020output_field_ids\030\003 \003(\003B\006\n\004node*\234\001\n\006O" + "\022\030\n\020output_field_ids\030\003 \003(\003B\006\n\004node*\272\001\n\006O" "pType\022\013\n\007Invalid\020\000\022\017\n\013GreaterThan\020\001\022\020\n\014G" "reaterEqual\020\002\022\014\n\010LessThan\020\003\022\r\n\tLessEqual" "\020\004\022\t\n\005Equal\020\005\022\014\n\010NotEqual\020\006\022\017\n\013PrefixMat" - "ch\020\007\022\020\n\014PostfixMatch\020\010\022\t\n\005Match\020\t*G\n\013Ari" - "thOpType\022\013\n\007Unknown\020\000\022\007\n\003Add\020\001\022\007\n\003Sub\020\002\022" - "\007\n\003Mul\020\003\022\007\n\003Div\020\004\022\007\n\003Mod\020\005B3Z1github.com" - "/milvus-io/milvus/internal/proto/planpbb" - "\006proto3" + "ch\020\007\022\020\n\014PostfixMatch\020\010\022\t\n\005Match\020\t\022\t\n\005Ran" + "ge\020\n\022\006\n\002In\020\013\022\t\n\005NotIn\020\014*G\n\013ArithOpType\022\013" + "\n\007Unknown\020\000\022\007\n\003Add\020\001\022\007\n\003Sub\020\002\022\007\n\003Mul\020\003\022\007" + "\n\003Div\020\004\022\007\n\003Mod\020\005B3Z1github.com/milvus-io" + "/milvus/internal/proto/planpbb\006proto3" ; static const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable*const descriptor_table_plan_2eproto_deps[1] = { &::descriptor_table_schema_2eproto, @@ -658,7 +658,7 @@ static ::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase*const descriptor_table_pla static ::PROTOBUF_NAMESPACE_ID::internal::once_flag descriptor_table_plan_2eproto_once; static bool descriptor_table_plan_2eproto_initialized = false; const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_plan_2eproto = { - &descriptor_table_plan_2eproto_initialized, descriptor_table_protodef_plan_2eproto, "plan.proto", 3327, + &descriptor_table_plan_2eproto_initialized, descriptor_table_protodef_plan_2eproto, "plan.proto", 3357, &descriptor_table_plan_2eproto_once, descriptor_table_plan_2eproto_sccs, descriptor_table_plan_2eproto_deps, 14, 1, schemas, file_default_instances, TableStruct_plan_2eproto::offsets, file_level_metadata_plan_2eproto, 17, file_level_enum_descriptors_plan_2eproto, file_level_service_descriptors_plan_2eproto, @@ -729,6 +729,9 @@ bool OpType_IsValid(int value) { case 7: case 8: case 9: + case 10: + case 11: + case 12: return true; default: return false; diff --git a/internal/core/src/pb/plan.pb.h b/internal/core/src/pb/plan.pb.h index ddd99a3adb..6b60fba6c5 100644 --- a/internal/core/src/pb/plan.pb.h +++ b/internal/core/src/pb/plan.pb.h @@ -198,12 +198,15 @@ enum OpType : int { PrefixMatch = 7, PostfixMatch = 8, Match = 9, + Range = 10, + In = 11, + NotIn = 12, OpType_INT_MIN_SENTINEL_DO_NOT_USE_ = std::numeric_limits<::PROTOBUF_NAMESPACE_ID::int32>::min(), OpType_INT_MAX_SENTINEL_DO_NOT_USE_ = std::numeric_limits<::PROTOBUF_NAMESPACE_ID::int32>::max() }; bool OpType_IsValid(int value); constexpr OpType OpType_MIN = Invalid; -constexpr OpType OpType_MAX = Match; +constexpr OpType OpType_MAX = NotIn; constexpr int OpType_ARRAYSIZE = OpType_MAX + 1; const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* OpType_descriptor(); diff --git a/internal/core/src/query/Expr.h b/internal/core/src/query/Expr.h index 6f9636f380..fdbb620b4f 100644 --- a/internal/core/src/query/Expr.h +++ b/internal/core/src/query/Expr.h @@ -25,6 +25,7 @@ #include #include "common/Schema.h" +#include "pb/plan.pb.h" namespace milvus::query { @@ -101,27 +102,6 @@ struct TermExpr : Expr { accept(ExprVisitor&) override; }; -enum class OpType { - Invalid = 0, - GreaterThan = 1, - GreaterEqual = 2, - LessThan = 3, - LessEqual = 4, - Equal = 5, - NotEqual = 6, - PrefixMatch = 7, - PostfixMatch = 8, -}; - -enum class ArithOpType { - Unknown = 0, - Add = 1, - Sub = 2, - Mul = 3, - Div = 4, - Mod = 5, -}; - static const std::map arith_op_mapping_ = { // arith_op_name -> arith_op {"add", ArithOpType::Add}, {"sub", ArithOpType::Sub}, {"mul", ArithOpType::Mul}, diff --git a/internal/core/src/query/visitors/ExecExprVisitor.cpp b/internal/core/src/query/visitors/ExecExprVisitor.cpp index dc817e2021..d485d87eb2 100644 --- a/internal/core/src/query/visitors/ExecExprVisitor.cpp +++ b/internal/core/src/query/visitors/ExecExprVisitor.cpp @@ -211,7 +211,6 @@ auto ExecExprVisitor::ExecUnaryRangeVisitorDispatcher(UnaryRangeExpr& expr_raw) -> BitsetType { auto& expr = static_cast&>(expr_raw); using Index = scalar::ScalarIndex; - using Operator = scalar::OperatorType; auto op = expr.op_type_; auto val = expr.value_; switch (op) { @@ -226,29 +225,29 @@ ExecExprVisitor::ExecUnaryRangeVisitorDispatcher(UnaryRangeExpr& expr_raw) -> Bi return ExecRangeVisitorImpl(expr.field_id_, index_func, elem_func); } case OpType::GreaterEqual: { - auto index_func = [val](Index* index) { return index->Range(val, Operator::GE); }; + auto index_func = [val](Index* index) { return index->Range(val, OpType::GreaterEqual); }; auto elem_func = [val](T x) { return (x >= val); }; return ExecRangeVisitorImpl(expr.field_id_, index_func, elem_func); } case OpType::GreaterThan: { - auto index_func = [val](Index* index) { return index->Range(val, Operator::GT); }; + auto index_func = [val](Index* index) { return index->Range(val, OpType::GreaterThan); }; auto elem_func = [val](T x) { return (x > val); }; return ExecRangeVisitorImpl(expr.field_id_, index_func, elem_func); } case OpType::LessEqual: { - auto index_func = [val](Index* index) { return index->Range(val, Operator::LE); }; + auto index_func = [val](Index* index) { return index->Range(val, OpType::LessEqual); }; auto elem_func = [val](T x) { return (x <= val); }; return ExecRangeVisitorImpl(expr.field_id_, index_func, elem_func); } case OpType::LessThan: { - auto index_func = [val](Index* index) { return index->Range(val, Operator::LT); }; + auto index_func = [val](Index* index) { return index->Range(val, OpType::LessThan); }; auto elem_func = [val](T x) { return (x < val); }; return ExecRangeVisitorImpl(expr.field_id_, index_func, elem_func); } case OpType::PrefixMatch: { auto index_func = [val](Index* index) { auto dataset = std::make_unique(); - dataset->Set(scalar::OPERATOR_TYPE, Operator::PrefixMatchOp); + dataset->Set(scalar::OPERATOR_TYPE, OpType::PrefixMatch); dataset->Set(scalar::PREFIX_VALUE, val); return index->Query(std::move(dataset)); }; @@ -706,7 +705,6 @@ ExecExprVisitor::ExecTermVisitorImpl(TermExpr& expr_raw) -> BitsetT using T = std::string; auto& expr = static_cast&>(expr_raw); using Index = scalar::ScalarIndex; - using Operator = scalar::OperatorType; const auto& terms = expr.terms_; auto n = terms.size(); std::unordered_set term_set(expr.terms_.begin(), expr.terms_.end()); diff --git a/internal/core/unittest/test_bitmap.cpp b/internal/core/unittest/test_bitmap.cpp index 18d512ace6..99531c76f6 100644 --- a/internal/core/unittest/test_bitmap.cpp +++ b/internal/core/unittest/test_bitmap.cpp @@ -25,7 +25,7 @@ TEST(Bitmap, Naive) { auto sort_index = std::make_shared>(); sort_index->Build(N, vec.data()); { - auto res = sort_index->Range(0, scalar::OperatorType::LT); + auto res = sort_index->Range(0, OpType::LessThan); double count = res->count(); ASSERT_NEAR(count / N, 0.5, 0.01); } diff --git a/internal/core/unittest/test_c_api.cpp b/internal/core/unittest/test_c_api.cpp index 1a12c5cf8b..d3790278cf 100644 --- a/internal/core/unittest/test_c_api.cpp +++ b/internal/core/unittest/test_c_api.cpp @@ -1008,9 +1008,9 @@ testReduceSearchWithExpr(int N, int topK, int num_queries) { std::vector results; CSearchResult res1; CSearchResult res2; - auto res = Search(segment, plan, placeholderGroup, dataset.timestamps_[0], &res1, -1); + auto res = Search(segment, plan, placeholderGroup, dataset.timestamps_[N - 1], &res1, -1); assert(res.error_code == Success); - res = Search(segment, plan, placeholderGroup, dataset.timestamps_[0], &res2, -1); + res = Search(segment, plan, placeholderGroup, dataset.timestamps_[N - 1], &res2, -1); assert(res.error_code == Success); results.push_back(res1); results.push_back(res2); diff --git a/internal/core/unittest/test_relational.cpp b/internal/core/unittest/test_relational.cpp index 96451563f5..c3d46e6a41 100644 --- a/internal/core/unittest/test_relational.cpp +++ b/internal/core/unittest/test_relational.cpp @@ -36,8 +36,9 @@ TEST(Relational, Basic) { ASSERT_EQ(Relational{})>()(s, another_s), s > another_s); ASSERT_EQ(Relational{})>()(s, another_s), s <= another_s); ASSERT_EQ(Relational{})>()(s, another_s), s < another_s); - ASSERT_EQ(Relational{})>()(s, another_s), milvus::PrefixMatch(s, another_s)); - ASSERT_EQ(Relational{})>()(s, another_s), + ASSERT_EQ(Relational{})>()(s, another_s), + milvus::PrefixMatch(s, another_s)); + ASSERT_EQ(Relational{})>()(s, another_s), milvus::PostfixMatch(s, another_s)); } @@ -67,8 +68,8 @@ TEST(Relational, DifferentInCompatibleType) { ASSERT_ANY_THROW(Relational{})>()(s, i64)); ASSERT_ANY_THROW(Relational{})>()(s, i64)); ASSERT_ANY_THROW(Relational{})>()(s, i64)); - ASSERT_ANY_THROW(Relational{})>()(s, i64)); - ASSERT_ANY_THROW(Relational{})>()(s, i64)); + ASSERT_ANY_THROW(Relational{})>()(s, i64)); + ASSERT_ANY_THROW(Relational{})>()(s, i64)); ASSERT_ANY_THROW(Relational{})>()(i64, s)); ASSERT_ANY_THROW(Relational{})>()(i64, s)); @@ -76,6 +77,6 @@ TEST(Relational, DifferentInCompatibleType) { ASSERT_ANY_THROW(Relational{})>()(i64, s)); ASSERT_ANY_THROW(Relational{})>()(i64, s)); ASSERT_ANY_THROW(Relational{})>()(i64, s)); - ASSERT_ANY_THROW(Relational{})>()(i64, s)); - ASSERT_ANY_THROW(Relational{})>()(i64, s)); + ASSERT_ANY_THROW(Relational{})>()(i64, s)); + ASSERT_ANY_THROW(Relational{})>()(i64, s)); } diff --git a/internal/core/unittest/test_scalar_index_creator.cpp b/internal/core/unittest/test_scalar_index_creator.cpp index 338dbcc720..f3b4e8cab3 100644 --- a/internal/core/unittest/test_scalar_index_creator.cpp +++ b/internal/core/unittest/test_scalar_index_creator.cpp @@ -32,7 +32,6 @@ namespace indexcgo = milvus::proto::indexcgo; namespace schemapb = milvus::proto::schema; using milvus::indexbuilder::MapParams; using milvus::indexbuilder::ScalarIndexCreatorPtr; -using milvus::scalar::OperatorType; using ScalarTestParams = std::pair; namespace { diff --git a/internal/core/unittest/test_string_index.cpp b/internal/core/unittest/test_string_index.cpp index d2ec76df7b..f24483fd88 100644 --- a/internal/core/unittest/test_string_index.cpp +++ b/internal/core/unittest/test_string_index.cpp @@ -20,7 +20,9 @@ #include "index/ScalarIndex.h" #include "index/StringIndex.h" #include "index/StringIndexMarisa.h" +#include "index/IndexFactory.h" #include "test_utils/indexbuilder_test_utils.h" +#include "test_utils/AssertUtils.h" constexpr int64_t nb = 100; namespace schemapb = milvus::proto::schema; @@ -87,7 +89,7 @@ TEST_F(StringIndexMarisaTest, Range) { auto index = milvus::scalar::CreateStringIndexMarisa(); index->BuildWithDataset(str_ds); - ASSERT_ANY_THROW(index->Range("not important", milvus::scalar::OperatorType::LE)); + ASSERT_ANY_THROW(index->Range("not important", milvus::OpType::LessEqual)); ASSERT_ANY_THROW(index->Range("not important", true, "not important", true)); } @@ -109,28 +111,28 @@ TEST_F(StringIndexMarisaTest, Query) { { auto ds = knowhere::GenDataset(strs.size(), 8, strs.data()); - ds->Set(milvus::scalar::OPERATOR_TYPE, milvus::scalar::OperatorType::InOp); + ds->Set(milvus::scalar::OPERATOR_TYPE, milvus::OpType::In); auto bitset = index->Query(ds); ASSERT_TRUE(bitset->any()); } { auto ds = knowhere::GenDataset(strs.size(), 8, strs.data()); - ds->Set(milvus::scalar::OPERATOR_TYPE, milvus::scalar::OperatorType::NotInOp); + ds->Set(milvus::scalar::OPERATOR_TYPE, milvus::OpType::NotIn); auto bitset = index->Query(ds); ASSERT_TRUE(bitset->none()); } { auto ds = std::make_shared(); - ds->Set(milvus::scalar::OPERATOR_TYPE, milvus::scalar::OperatorType::GE); + ds->Set(milvus::scalar::OPERATOR_TYPE, milvus::OpType::GreaterEqual); ds->Set(milvus::scalar::RANGE_VALUE, "range"); ASSERT_ANY_THROW(index->Query(ds)); } { auto ds = std::make_shared(); - ds->Set(milvus::scalar::OPERATOR_TYPE, milvus::scalar::OperatorType::RangeOp); + ds->Set(milvus::scalar::OPERATOR_TYPE, milvus::OpType::Range); ds->Set(milvus::scalar::LOWER_BOUND_VALUE, "range"); ds->Set(milvus::scalar::UPPER_BOUND_VALUE, "range"); ds->Set(milvus::scalar::LOWER_BOUND_INCLUSIVE, true); @@ -141,8 +143,7 @@ TEST_F(StringIndexMarisaTest, Query) { { for (size_t i = 0; i < strs.size(); i++) { auto ds = std::make_shared(); - ds->Set(milvus::scalar::OPERATOR_TYPE, - milvus::scalar::OperatorType::PrefixMatchOp); + ds->Set(milvus::scalar::OPERATOR_TYPE, milvus::OpType::PrefixMatch); ds->Set(milvus::scalar::PREFIX_VALUE, std::move(strs[i])); auto bitset = index->Query(ds); ASSERT_EQ(bitset->size(), strs.size()); @@ -175,7 +176,7 @@ TEST_F(StringIndexMarisaTest, Codec) { } { - ASSERT_ANY_THROW(copy_index->Range("not important", milvus::scalar::OperatorType::LE)); + ASSERT_ANY_THROW(copy_index->Range("not important", milvus::OpType::LessEqual)); ASSERT_ANY_THROW(copy_index->Range("not important", true, "not important", true)); } diff --git a/internal/core/unittest/test_utils/AssertUtils.h b/internal/core/unittest/test_utils/AssertUtils.h index 84a57e99de..603595b82a 100644 --- a/internal/core/unittest/test_utils/AssertUtils.h +++ b/internal/core/unittest/test_utils/AssertUtils.h @@ -53,19 +53,19 @@ assert_range(const ScalarIndexPtr& index, const std::vector& arr) { auto test_min = arr[0]; auto test_max = arr[arr.size() - 1]; - auto bitset1 = index->Range(test_min - 1, milvus::scalar::OperatorType::GT); + auto bitset1 = index->Range(test_min - 1, milvus::OpType::GreaterThan); ASSERT_EQ(arr.size(), bitset1->size()); ASSERT_TRUE(bitset1->any()); - auto bitset2 = index->Range(test_min, milvus::scalar::OperatorType::GE); + auto bitset2 = index->Range(test_min, milvus::OpType::GreaterEqual); ASSERT_EQ(arr.size(), bitset2->size()); ASSERT_TRUE(bitset2->any()); - auto bitset3 = index->Range(test_max + 1, milvus::scalar::OperatorType::LT); + auto bitset3 = index->Range(test_max + 1, milvus::OpType::LessThan); ASSERT_EQ(arr.size(), bitset3->size()); ASSERT_TRUE(bitset3->any()); - auto bitset4 = index->Range(test_max, milvus::scalar::OperatorType::LE); + auto bitset4 = index->Range(test_max, milvus::OpType::LessEqual); ASSERT_EQ(arr.size(), bitset4->size()); ASSERT_TRUE(bitset4->any()); @@ -96,11 +96,11 @@ assert_range(const ScalarIndexPtr& index, const std::vectorRange(test_min, milvus::scalar::OperatorType::GE); + auto bitset2 = index->Range(test_min, milvus::OpType::GreaterEqual); ASSERT_EQ(arr.size(), bitset2->size()); ASSERT_TRUE(bitset2->any()); - auto bitset4 = index->Range(test_max, milvus::scalar::OperatorType::LE); + auto bitset4 = index->Range(test_max, milvus::OpType::LessEqual); ASSERT_EQ(arr.size(), bitset4->size()); ASSERT_TRUE(bitset4->any()); diff --git a/internal/core/unittest/test_utils/indexbuilder_test_utils.h b/internal/core/unittest/test_utils/indexbuilder_test_utils.h index bbc98ca316..8c724284a9 100644 --- a/internal/core/unittest/test_utils/indexbuilder_test_utils.h +++ b/internal/core/unittest/test_utils/indexbuilder_test_utils.h @@ -43,7 +43,6 @@ namespace indexcgo = milvus::proto::indexcgo; namespace schemapb = milvus::proto::schema; using milvus::indexbuilder::MapParams; using milvus::indexbuilder::ScalarIndexCreator; -using milvus::scalar::OperatorType; using ScalarTestParams = std::pair; using milvus::scalar::ScalarIndexPtr; using milvus::scalar::StringIndexPtr; diff --git a/internal/datanode/segment_replica.go b/internal/datanode/segment_replica.go index be373f1a07..42b63f2748 100644 --- a/internal/datanode/segment_replica.go +++ b/internal/datanode/segment_replica.go @@ -318,7 +318,7 @@ func (replica *SegmentReplica) filterSegments(channelName string, partitionID Un results := make([]*Segment, 0) isMatched := func(segment *Segment, chanName string, partID UniqueID) bool { - return segment.channelName == chanName && (partID == common.InvalidFieldID || segment.partitionID == partID) + return segment.channelName == chanName && (partID == common.InvalidPartitionID || segment.partitionID == partID) } for _, seg := range replica.newSegments { if isMatched(seg, channelName, partitionID) { diff --git a/internal/proto/plan.proto b/internal/proto/plan.proto index 9262e795e7..1e748eaa3f 100644 --- a/internal/proto/plan.proto +++ b/internal/proto/plan.proto @@ -15,6 +15,9 @@ enum OpType { PrefixMatch = 7; // startsWith PostfixMatch = 8; // endsWith Match = 9; // like + Range = 10; // for case 1 < a < b + In = 11; // TODO:: used for term expr + NotIn = 12; }; enum ArithOpType { diff --git a/internal/proto/planpb/plan.pb.go b/internal/proto/planpb/plan.pb.go index 2e4d217157..08e5c9909c 100644 --- a/internal/proto/planpb/plan.pb.go +++ b/internal/proto/planpb/plan.pb.go @@ -34,19 +34,25 @@ const ( OpType_PrefixMatch OpType = 7 OpType_PostfixMatch OpType = 8 OpType_Match OpType = 9 + OpType_Range OpType = 10 + OpType_In OpType = 11 + OpType_NotIn OpType = 12 ) var OpType_name = map[int32]string{ - 0: "Invalid", - 1: "GreaterThan", - 2: "GreaterEqual", - 3: "LessThan", - 4: "LessEqual", - 5: "Equal", - 6: "NotEqual", - 7: "PrefixMatch", - 8: "PostfixMatch", - 9: "Match", + 0: "Invalid", + 1: "GreaterThan", + 2: "GreaterEqual", + 3: "LessThan", + 4: "LessEqual", + 5: "Equal", + 6: "NotEqual", + 7: "PrefixMatch", + 8: "PostfixMatch", + 9: "Match", + 10: "Range", + 11: "In", + 12: "NotIn", } var OpType_value = map[string]int32{ @@ -60,6 +66,9 @@ var OpType_value = map[string]int32{ "PrefixMatch": 7, "PostfixMatch": 8, "Match": 9, + "Range": 10, + "In": 11, + "NotIn": 12, } func (x OpType) String() string { @@ -1371,92 +1380,93 @@ func init() { func init() { proto.RegisterFile("plan.proto", fileDescriptor_2d655ab2f7683c23) } var fileDescriptor_2d655ab2f7683c23 = []byte{ - // 1387 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x57, 0xcd, 0x73, 0xdb, 0x44, - 0x14, 0xb7, 0x2c, 0x3b, 0x96, 0x9e, 0x1d, 0x47, 0xd5, 0x85, 0x7e, 0xd0, 0x26, 0x88, 0x0e, 0x0d, - 0x65, 0x9a, 0x4c, 0x69, 0x69, 0xa7, 0x65, 0x0a, 0xf9, 0x2a, 0x49, 0x86, 0x36, 0x09, 0x6a, 0x9a, - 0x03, 0x17, 0xcd, 0x5a, 0xda, 0xd8, 0x3b, 0x95, 0xb5, 0xea, 0x6a, 0xe5, 0xd6, 0x67, 0x6e, 0xdc, - 0xb8, 0xc3, 0x15, 0xee, 0xdc, 0x38, 0xf1, 0x0f, 0x70, 0xe0, 0xc8, 0x9d, 0xff, 0x82, 0x13, 0xb3, - 0x6f, 0xe5, 0xaf, 0x8e, 0xdd, 0x38, 0x43, 0x67, 0xb8, 0xed, 0xbe, 0x7d, 0xef, 0xb7, 0xef, 0xfd, - 0xf6, 0xed, 0xdb, 0xb7, 0x00, 0x69, 0x4c, 0x92, 0xb5, 0x54, 0x70, 0xc9, 0xdd, 0x0b, 0x5d, 0x16, - 0xf7, 0xf2, 0x4c, 0xcf, 0xd6, 0xd4, 0xc2, 0xe5, 0x46, 0x16, 0x76, 0x68, 0x97, 0x68, 0x91, 0xf7, - 0x83, 0x01, 0x8d, 0x5d, 0x9a, 0x50, 0xc1, 0xc2, 0x13, 0x12, 0xe7, 0xd4, 0xbd, 0x02, 0x56, 0x8b, - 0xf3, 0x38, 0xe8, 0x91, 0xf8, 0xa2, 0xb1, 0x62, 0xac, 0x5a, 0x7b, 0x25, 0xbf, 0xa6, 0x24, 0x27, - 0x24, 0x76, 0xaf, 0x82, 0xcd, 0x12, 0x79, 0xef, 0x2e, 0xae, 0x96, 0x57, 0x8c, 0x55, 0x73, 0xaf, - 0xe4, 0x5b, 0x28, 0x2a, 0x96, 0x4f, 0x63, 0x4e, 0x24, 0x2e, 0x9b, 0x2b, 0xc6, 0xaa, 0xa1, 0x96, - 0x51, 0xa4, 0x96, 0x97, 0x01, 0x32, 0x29, 0x58, 0xd2, 0xc6, 0xf5, 0xca, 0x8a, 0xb1, 0x6a, 0xef, - 0x95, 0x7c, 0x5b, 0xcb, 0x4e, 0x48, 0xbc, 0x55, 0x05, 0xb3, 0x47, 0x62, 0xef, 0x7b, 0x03, 0xec, - 0x6f, 0x72, 0x2a, 0xfa, 0xfb, 0xc9, 0x29, 0x77, 0x5d, 0xa8, 0x48, 0x9e, 0xbe, 0x40, 0x67, 0x4c, - 0x1f, 0xc7, 0xee, 0x32, 0xd4, 0xbb, 0x54, 0x0a, 0x16, 0x06, 0xb2, 0x9f, 0x52, 0xdc, 0xca, 0xf6, - 0x41, 0x8b, 0x8e, 0xfb, 0x29, 0x75, 0x3f, 0x84, 0xc5, 0x8c, 0x12, 0x11, 0x76, 0x82, 0x94, 0x08, - 0xd2, 0xcd, 0xf4, 0x6e, 0x7e, 0x43, 0x0b, 0x8f, 0x50, 0xa6, 0x94, 0x04, 0xcf, 0x93, 0x28, 0x88, - 0x68, 0xc8, 0xba, 0x24, 0xbe, 0x58, 0xc5, 0x2d, 0x1a, 0x28, 0xdc, 0xd1, 0x32, 0xef, 0x67, 0x03, - 0x60, 0x9b, 0xc7, 0x79, 0x37, 0x41, 0x6f, 0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x12, 0xd4, 0x77, 0x05, 0x25, 0x92, 0x8a, 0xe3, 0x0e, 0x49, 0x1c, - 0xc3, 0x75, 0xa0, 0x51, 0x08, 0x1e, 0xbf, 0xcc, 0x49, 0xec, 0x94, 0xdd, 0x06, 0x58, 0x4f, 0x68, - 0x96, 0xe1, 0xba, 0x89, 0x6f, 0x35, 0xcd, 0x32, 0xbd, 0x58, 0x71, 0x6d, 0xa8, 0xea, 0x61, 0x55, - 0xe9, 0x1d, 0x70, 0xa9, 0x67, 0x0b, 0x0a, 0xf8, 0x48, 0xd0, 0x53, 0xf6, 0xfa, 0x29, 0x91, 0x61, - 0xc7, 0xa9, 0x29, 0xe0, 0x23, 0x9e, 0xc9, 0xa1, 0xc4, 0x52, 0xb6, 0x7a, 0x68, 0xdf, 0xdc, 0x85, - 0xfa, 0x58, 0xf5, 0x57, 0x2e, 0x3e, 0x4f, 0x5e, 0x24, 0xfc, 0x55, 0xa2, 0x5b, 0x9e, 0xcd, 0x48, - 0xb5, 0x09, 0x35, 0x30, 0x9f, 0xe5, 0x2d, 0xa7, 0xac, 0x06, 0x4f, 0xf3, 0xd8, 0x31, 0xd5, 0x60, - 0x87, 0xf5, 0x9c, 0x0a, 0x4a, 0x78, 0xe4, 0x54, 0xb7, 0xee, 0x7c, 0x7b, 0xbb, 0xcd, 0x64, 0x27, - 0x6f, 0xad, 0x85, 0xbc, 0xbb, 0xae, 0xc9, 0xbc, 0xc5, 0x78, 0x31, 0x5a, 0x67, 0x89, 0xa4, 0x22, - 0x21, 0xf1, 0x3a, 0xf2, 0xbb, 0xae, 0xf8, 0x4d, 0x5b, 0xad, 0x05, 0x9c, 0xdd, 0xf9, 0x37, 0x00, - 0x00, 0xff, 0xff, 0xc8, 0xcd, 0x73, 0x91, 0x98, 0x0f, 0x00, 0x00, + // 1407 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x57, 0xcd, 0x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