support brute-force range search for binary sub/superstructure#1568
support brute-force range search for binary sub/superstructure#1568862103595 wants to merge 1 commit into
Conversation
Enable brute-force binary range search for substructure and superstructure metrics, and cover the path in brute force tests. Signed-off-by: xiejh <862103595@qq.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: 862103595 The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Welcome @862103595! It looks like this is your first PR to zilliztech/knowhere 🎉 |
|
@862103595 🔍 Important: PR Classification Needed! For efficient project management and a seamless review process, it's essential to classify your PR correctly. Here's how:
For any PR outside the kind/improvement category, ensure you link to the associated issue using the format: “issue: #”. Thanks for your efforts and contribution to the community!. |
|
/kind improvement |
|
/kind enhancement |
| for (size_t j = 0; j < nb; j++) { | ||
| if (!sel || sel->is_member(j)) { | ||
| if (mc.compute(b + j * code_size)) { | ||
| T dis = static_cast<T>(0); |
There was a problem hiding this comment.
Why compare dis=0 to the radius here instead of the actual computed distance?
issue: #1574
Summary
SUBSTRUCTUREandSUPERSTRUCTUREContext
This PR closes a capability gap in binary brute-force range search by extending support to
SUBSTRUCTUREandSUPERSTRUCTURE.It adds coverage for missing cases rather than fixing a regression.
Test
LD_LIBRARY_PATH=/home/zilliz/.conan/data/gflags/2.2.2/_/_/package/ef45d1cd7d44c3c89fa6456b370ced89171f282b/lib:/home/zilliz/.conan/data/glog/0.7.1/_/_/package/926e0eaeed666f528abdc8d0c87a9035fe0b0adf/lib:$LD_LIBRARY_PATH ./tests/ut/knowhere_tests "Test Brute Force"pre-commit run --files src/common/comp/brute_force.cc thirdparty/faiss/faiss/cppcontrib/knowhere/utils/binary_distances.cpp tests/ut/test_bruteforce.cc