-
Notifications
You must be signed in to change notification settings - Fork 56
[On Hold] Add bit hamming #284
base: main
Are you sure you want to change the base?
[On Hold] Add bit hamming #284
Conversation
2. Add Bit As String vector write into hnswlib
Codecov Report
@@ Coverage Diff @@
## master #284 +/- ##
============================================
+ Coverage 79.27% 80.89% +1.62%
- Complexity 359 413 +54
============================================
Files 58 62 +4
Lines 1404 1581 +177
Branches 126 147 +21
============================================
+ Hits 1113 1279 +166
- Misses 243 249 +6
- Partials 48 53 +5
Continue to review full report at Codecov.
|
Hi @luyuncheng, Thanks for the PR! I will take a look some time early next week. My concern about the "non-optimized" indices is that we will end up storing two different files for the HNSW structure in the Lucene index. I need to think about the implications of doing this some more. |
#161 in this PR, it Write footer for .dat file. I reuse this as "non-optimized" data storage. As i checked the nmslib's code, When we add "non-optimized" data storage, K-NN plugin can support all nmslib's Space Types |
@luyuncheng Apologies, have not gotten a chance to look at this yet. Will review in January. |
Modified BitHamming, Using int32 to parse the vector
Previously, this PR using string to parse the bit vector, this may occupy too much memory! |
1. Modified code for codecov
This Pr is put on hold. Please refer #283 (comment) |
…us field create. 2. Free memory data in destructor
1. FIXED SpaceType Get From IndexSettings may be EMPTY when a anonymo…
*Issue #283,
Description of changes:
As I see #264 that add Hamming distance in custom scoring it is a great functionality. i see there is bit_hamming space space_bit_hamming in nmslib. i think we can add this into plugin.
i refer to the code space_bit_hamming and space_bit_hamming_test, may be we could add "SpaceBitVector" into plugin and support bit_hamming space which is no optimized index.
i also refer to PR: #161 which add no optimized index for "negdotprod", i see the nmslib's python_binding code python_binding_nmslib, may be we could add a "save_data" into plugin and can store index and dataset for "no optimized index".
so, i submit this PR.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.