Comments (8)
For the latter you can check out the distanceToPath() ranking feature as documented here:
http://docs.vespa.ai/documentation/geo-search.html
http://docs.vespa.ai/documentation/reference/rank-features.html
from vespa.
Thanks @knownasilya for this detailed feature request!
from vespa.
Are there any real use cases where this is more than a convenience?
You can always do a query with a radius and do a more fine filtering in code.
Applications with some complexity will add their own component in the stateless layer anyway. In general we're not really attempting to create declarative code for solving every use case, only the ones where computation close to data matters for performance.
from vespa.
only the ones where computation close to data matters for performance.
Use cases like find all fire departments in my county. Where the county isn't specified on the fire department data, but the fire department has a location. So you'd need to do a polygon query to see which fire departments intersect the county polygon.
Another example, I'm currently located at lat, long what property am I at? This requires doing an within query on the property polygon data with passed in latlong data.
I have a road, and I need to know which properties are along that road. Do a buffer on the road, and do an intersection of that buffer with all of the properties.
from vespa.
Thanks, forgot that was thee. Unfortunately, that would only work with documents that have points, not polygon data (or other spatial data types), is that correct?
from vespa.
Yes, that is correct, Vespa do not provide any feature where a document can have a polygon, but that is not needed for your "on the road" use case, which is the one we know of where radius+post-filtering wouldn't be efficient.
Regarding
Use cases like find all fire departments in my county.
You could do retrieve all documents within a circle encompassing the county, and filter those that are outside. That is probably more efficient, and certainly more flexible.
By the way, in practice this kind of thing is often solved using place names instead of koordinates.
from vespa.
You could do retrieve all documents within a circle encompassing the county, and filter those that are outside. That is probably more efficient, and certainly more flexible.
But less accurate, and that is important for any federal, state and local government scenarios.
Regarding the "on the road" example, the same thing applies. For example, one property might be bigger then the rest, and if you use a point (centroid), it would be missed because the point is further from the road then other properties. If you increase the road "width" then you run into finding properties that aren't even on the road. This trades accuracy for speed.
from vespa.
But less accurate, and that is important for any federal, state and local government scenarios.
With post filtering - in a component running inside the system - it is precisely as accurate.
The road feature should be implemented with the distance to path feature instead of radius. I agree that in that case radius+post filtering is not efficient, which is why we do provide a separate feature for it.
from vespa.
Related Issues (20)
- Vespa visit not returning deleted documents when selection criteria is added. HOT 3
- [Schema streaming mode] Enhence rank calculation for substring search HOT 5
- Make behaviour between `global` and `second` phase when `ranking.sorting=''` is given consistent HOT 1
- Allow multiple tensor outputs from native Vespa embedders HOT 3
- Pyvespa deployment fails HOT 5
- [Schema streaming mode] bm25 score is always zero HOT 2
- Array length as search criteria HOT 1
- Sorry couldn't find a discussion tab, so asking here. Can vespa be used as a primary database? HOT 3
- Evaluate onnx models with onnxruntime HOT 3
- Export Vespa golang client API as a library HOT 5
- Parse exception for regular expression HOT 2
- Make YQL Query Syntax Parse Exception more meaningful
- Case sensitive search not supported on index fields HOT 2
- special-tokens not applied for document, only query HOT 1
- Add a topk tensor function for mapped tensors
- Indexing language fails on an empty array HOT 2
- Reindexing is getting stalled
- Inconsistent rendering of string versus array of string with regards to unicode escaping HOT 2
- Vespa 9: Consider updating bm25 hyperparameter defaults
- Segmented And behaviour with weakAnd for CJK languages HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vespa.