What's the best way to get a random vector from a Milvus collection #28699
Replies: 4 comments
-
What kind of index? |
Beta Was this translation helpful? Give feedback.
-
Per your description, seems you are trying to "get a random entity by a random vector from a Milvus collection". I wrote a script to test this case. This script creates a collection with 1M entities of 768-dim vectors, and generates 10 random vectors to search.
The results are random:
|
Beta Was this translation helpful? Give feedback.
-
Thank you @yhmo your approach is the same as mine. I realised that I changed my random vector to have negative components the results I got back were better. Like so:
I'm closing this. I think this is probably the best we can do. |
Beta Was this translation helpful? Give feedback.
-
One way to sample random data is to implement a random function in the filter. But unluckily it is not supported in milvus right now. Anyone interested please take it. thanks |
Beta Was this translation helpful? Give feedback.
-
Hi! I'm trying to get a random vector from our Milvus dataset. I'm not sure what the best approach is but I've tried searching with random vectors, but doesn't work so well.
I'm doing this but I keep getting duplicate results which seems unlikely because the collection contains 2 million entries. Can anybody point me in the right direction? Thanks!
Beta Was this translation helpful? Give feedback.
All reactions