Skip to content
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

Add support for ScaNN index #2771

Open
SaiKiranBurle opened this issue Jul 7, 2020 · 21 comments
Open

Add support for ScaNN index #2771

SaiKiranBurle opened this issue Jul 7, 2020 · 21 comments
Assignees
Labels
kind/feature Issues related to feature request from users severity/major Major, major function doesn't work under some condition.
Milestone

Comments

@SaiKiranBurle
Copy link

Is your feature request related to a problem? Please describe.
Google recently released a new algorithm to find Approximate Nearest Neighbors called ScaNN (https://github.com/google-research/google-research/tree/master/scann).
They show through benchmarks that it can perform significantly better than the existing solutions like Annoy, FAISS, hnsw.

Describe the solution you'd like
Add ScaNN as a new index type for milvus.

Describe alternatives you've considered
None

Additional context
The paper which describes ScaNN how it is different from existing approaches is at https://arxiv.org/pdf/1908.10396.pdf

@JinHai-CN JinHai-CN added the kind/support Issues that users need help label Jul 8, 2020
@JinHai-CN
Copy link
Contributor

@SaiKiranBurle Good, we are investigating this algorithm and considering to integrate it into Milvus.

@wxyucs wxyucs added the kind/feature Issues related to feature request from users label Oct 19, 2020
@shengjun1985 shengjun1985 removed the kind/support Issues that users need help label Dec 8, 2020
@sa-
Copy link

sa- commented Feb 19, 2021

Google has a managed service that implements ScaNN in an alpha state btw.

@SaiKiranBurle
Copy link
Author

@sa- Can you point me to that said managed service?

@sa-
Copy link

sa- commented Feb 23, 2021

Added you on LinkedIn as Samay Kapadia, I'll send a link through there

@rostandkenne
Copy link

@JinHai-CN @SaiKiranBurle @sa- I was working on a standalone Scann service but just realized that Faiss has released a version that outperform Scann. facebookresearch/faiss#1399

@wxyucs wxyucs added the priority/backlog Higher priority than priority/awaiting-more-evidence. label May 10, 2021
@wxyucs wxyucs assigned cqy123456 and unassigned JinHai-CN May 11, 2021
@wxyucs wxyucs added priority/important-longterm and removed priority/backlog Higher priority than priority/awaiting-more-evidence. labels May 11, 2021
@wxyucs wxyucs added this to the 2.0 milestone May 11, 2021
@yanliang567 yanliang567 added severity/major Major, major function doesn't work under some condition. and removed priority/important-longterm labels Nov 15, 2021
@stale
Copy link

stale bot commented Dec 15, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Rotten issues close after 30d of inactivity. Reopen the issue with /reopen.

@stale stale bot added the stale indicates no udpates for 30 days label Dec 15, 2021
@stale stale bot closed this as completed Dec 22, 2021
@raynor08
Copy link

raynor08 commented May 5, 2022

Hi, any update or progress on this?

@xiaofan-luan xiaofan-luan removed the stale indicates no udpates for 30 days label May 6, 2022
@xiaofan-luan
Copy link
Collaborator

xiaofan-luan commented May 6, 2022

let's keep it open~
We are waiting for volunteers

@xiaofan-luan xiaofan-luan reopened this May 6, 2022
@stale
Copy link

stale bot commented Jun 5, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Rotten issues close after 30d of inactivity. Reopen the issue with /reopen.

@stale stale bot added the stale indicates no udpates for 30 days label Jun 5, 2022
@xiaofan-luan
Copy link
Collaborator

keep it open.
Any progress on it?

@stale stale bot removed the stale indicates no udpates for 30 days label Jun 5, 2022
@xiaofan-luan xiaofan-luan added stale indicates no udpates for 30 days and removed stale indicates no udpates for 30 days labels Jun 5, 2022
@filip-halt
Copy link
Contributor

Any status updates?

@xiaofan-luan
Copy link
Collaborator

Faiss ScaNN will be supported in 2.3

@xiaofan-luan
Copy link
Collaborator

/assign @liliu-z

@vamossagar12
Copy link

vamossagar12 commented Jan 21, 2023

hello @xiaofan-luan , I was actually working on this some time ago. Here's a branch which has the changes: https://github.com/vamossagar12/knowhere/tree/MEP-15. I had to stop this because I have an M1 laptop and SCANN libraries were not building. It seems to be an open issue as mentioned here: google-research/google-research#1082.
Looks like we have changed to using FAISS SCANN which hopefully has better APIs to work against. I was using the ones provided by google research and it had only python APIs and I had to reverse engineer a lot to integrate those into the codebase. @liliu-z , if you need any help/assistance, let me know would be happy to contribute still. I would need to refresh my memory but should be a good exercise :D

@xiaofan-luan
Copy link
Collaborator

hello @xiaofan-luan , I was actually working on this some time ago. Here's a branch which has the changes: https://github.com/vamossagar12/knowhere/tree/MEP-15. I had to stop this because I have an M1 laptop and SCANN libraries were not building. It seems to be an open issue as mentioned here: google-research/google-research#1082. Looks like we have changed to using FAISS SCANN which hopefully has better APIs to work against. I was using the ones provided by google research and it had only python APIs and I had to reverse engineer a lot to integrate those into the codebase. @liliu-z , if you need any help/assistance, let me know would be happy to contribute still. I would need to refresh my memory but should be a good exercise :D

Thanks for the contribution @vamossagar12 . Faiss ScaNN seems to be faster and as you mentioned it could work on M1 CPUs. we will release the Faiss ScaNN support soon! chears

@vamossagar12
Copy link

Thanks @xiaofan-luan for the update. I am not sure if FAISS SCANN was available when I was working on this (or maybe it was I didn't check). Nonetheless, I would leave this to the experts then :)

@sualehasif
Copy link

@xiaofan-luan do you know when 2.3 would be out? Is there a beta that we can test? Also are there guides on how to performance tune Milvus to get sub-10ms query times?

@xiaofan-luan
Copy link
Collaborator

@xiaofan-luan do you know when 2.3 would be out? Is there a beta that we can test? Also are there guides on how to performance tune Milvus to get sub-10ms query times?

Hi @sualehasif
From our test search under sub-10ms is possible, and the trick is to maintain lower cpu usage and use HNSW index(< 50%).
2.3 will be released some time this March, we will be working actively on ScaNN and GPU support and let's see if we can catch the train
If you can share more details, like the dimension of the vector data, how much machines you have and the data size, that will be super helpful

@BobLiu20
Copy link

BobLiu20 commented Jul 6, 2023

@xiaofan-luan Any update for ScaNN ?

@liliu-z
Copy link
Member

liliu-z commented Jul 6, 2023

Hi @BobLiu20 , Sorry about the delay, and we target supporting this in Q3 2023 for now.
/assign @chasingegg

@liliu-z
Copy link
Member

liliu-z commented Apr 2, 2024

SCANN is supported from Milvus 2.3.

@liliu-z liliu-z removed their assignment Apr 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Issues related to feature request from users severity/major Major, major function doesn't work under some condition.
Projects
None yet
Development

No branches or pull requests