Optimize tile fetching query

- compute centroid once
- filter input geometries by tile extent