-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
move common params check to class IndexCommonParam #109
Conversation
LHT129
commented
Nov 1, 2024
- common params(dim,metric_type,data_type...) should be checked for all index
- add param value's datatype check for hnsw and common params
0e12c80
to
9536ab5
Compare
- common params(dim,metric_type,data_type...) should be checked for all index - add param value's datatype check for hnsw and common params Signed-off-by: LHT129 <tianlan.lht@antgroup.com>
CHECK_ARGUMENT(metric_obj.is_string(), | ||
fmt::format("parameters[{}] must string type", PARAMETER_METRIC_TYPE)); | ||
std::string metric = metric_obj; | ||
if (metric == METRIC_L2) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps we don't need to require strict string equality here; we can ignore case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can discuss the strict equality on another pull request.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM