-
Notifications
You must be signed in to change notification settings - Fork 41
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
custom_filter get_pois not working with value True #224
Comments
I believe it is because in the line below, the tag values of |
I see that |
I'm getting odd results with using the Filtering with an osm id, yields more results than the same request without a custom filter. my_filter = {'id':['639343']}
admin_boundaries = osm_data_obj.get_boundaries(custom_filter = my_filter) yields 378 results that do not have the id '639343'. Without a custom filter there are only 245 results. Similar things are true with filters: using a custom filter for the |
@Chwiggy could you share the bounding box or area you're using? |
This is the geometry i was using: { "type": "Feature",
"properties": { "name": "2023_rnv_gtfs.zip", "path": "filepath" },
"geometry": {
"type": "Polygon",
"coordinates": [ [ [ 8.1704019, 49.3432631 ], [ 8.811395, 49.3432631 ], [ 8.811395, 49.5811911 ], [ 8.1704019, 49.5811911 ], [ 8.1704019, 49.3432631 ] ] ]
}
} the osm.pbf file was cropped to this bounding box from a larger file with osmosis with |
Describe the bug
The custom_filter does not work as one would expect when using the catch-all 'True' as a value in combination with another tag key. If I understand the documentation correctly, then this should return all osm records with that tag key and this return more entities compared to when one specifies a tag key and value.
To Reproduce
Expected behavior
Using True should always lead to a geq number of records than specifying some tag value.
Environment:
pyrosm, 0.6.2, py311hb755f60_1, conda-forge
Additional context
I realise there is a function called
get_buildings()
which would be more suited if you are only interested in buildings. I am interested in POIs but some buildings I would also like to include. In general, I am using a somewhat involvedcustom_filter
withTrue
and this example shows that I either don't understand the implementation or there is a bug.Great work on the package though, very useful!!
The text was updated successfully, but these errors were encountered: