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

[Bug]: search iterator always gives empty results #39827

Open
1 task done
subhamhimself opened this issue Feb 12, 2025 · 3 comments
Open
1 task done

[Bug]: search iterator always gives empty results #39827

subhamhimself opened this issue Feb 12, 2025 · 3 comments
Assignees
Labels
kind/bug Issues or changes related a bug triage/accepted Indicates an issue or PR is ready to be actively worked on.

Comments

@subhamhimself
Copy link

subhamhimself commented Feb 12, 2025

Is there an existing issue for this?

  • I have searched the existing issues

Environment

- Milvus version: 2.5
- Deployment mode(standalone or cluster): cluster
- MQ type(rocksmq, pulsar or kafka):    
- SDK version(e.g. pymilvus v2.0.0rc2): pymilvus 2.4.5
- OS(Ubuntu or CentOS): 
- CPU/Memory: 
- GPU: 
- Others:

Current Behavior

We use 'IP' metric, but our vectors are normalized so we get metric always between -1 to 1.
Index is IVF_FLAT with nlist=128.
For Collection.search_iterator, even after setting {"radius": -1, "range_filter": 1}, we get following error on a million scale partition:

Cannot init search iterator because init page contains no matched rows, please check the radius and range_filter set up by searchParams

Most likely it started happening when we upgraded our milvus to 2.5, but we're not sure about that.

Expected Behavior

No response

Steps To Reproduce

param = {'metric_type': 'IP', 'params': {'nprobe': 128, 'radius': -10000000, 'range_filter': 10000000}}

Milvus Log

No response

Anything else?

Adding that client.search seems to respect these parameters perfectly fine. Only collection.search_iterators has problems

@subhamhimself subhamhimself added kind/bug Issues or changes related a bug needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Feb 12, 2025
@xiaofan-luan
Copy link
Collaborator

The reason of this error is you can not find even one valid data between the range.

I think you will need to check the distance of your query and some vector in your collection

@subhamhimself
Copy link
Author

@xiaofan-luan MilvusClient.search() works perfectly fine for the same parameters and I see over a million vectors.

@yanliang567
Copy link
Contributor

@MrPresent-Han could you please take a look? is it something different with iterator v1 and v2?
/assign @MrPresent-Han
/unassign

@yanliang567 yanliang567 added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Issues or changes related a bug triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
None yet
Development

No branches or pull requests

4 participants