-
Notifications
You must be signed in to change notification settings - Fork 80
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
fix: fail to load ivf_flat(metric = cosine) with DeserializeFromFile #841
Conversation
@cqy123456 🔍 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!. |
aa8e6db
to
96f7a06
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #841 +/- ##
=========================================
+ Coverage 0 75.40% +75.40%
=========================================
Files 0 86 +86
Lines 0 6318 +6318
=========================================
+ Hits 0 4764 +4764
- Misses 0 1554 +1554 |
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
/kind bugfix |
@foxspy: The label(s) In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/hold |
} | ||
} | ||
|
||
void OnDiskInvertedLists::release_code_norms(size_t list_no, const float* codes) |
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.
why is it needed to override this method in the provided way?
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.
Just to clarify the question. It seems that the base class has the same implementation as the added one
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.
@alexanderguzhva I thought the behavior in release_code_norms is based on the storage method of InvertedList(e.g. ArrayInvertedLists, ConcurrentArrayInvertedLists), so this function is overrided, and this function do nothing like the basic class.
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.
Then I would eliminate it, because it does nothing.
Or I can lgtm the PR, just let me know. :)
@cqy123456 Please remove redundant |
/unhold |
96f7a06
to
b35d053
Compare
Signed-off-by: cqy123456 <[email protected]>
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
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: cqy123456, foxspy, liliu-z The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
issue:milvus-io/milvus#36052
When we set IO_FLAG_WITH_NORM = true to read a faiss index, ArrayInvertedLists will read into a read-only OnDiskInvertedLists.
OnDiskInvertedLists will mmap all ids and vectors with the index file, and record the ids and vectors offset in memory. If we use cosine, l1-norms will save in index file and all offsets are wrong.