I have a huge shapefile (over 400MB) of an entire city that contains many polygons of the residential area of this city. I can check it on QGIS as the following:
This shapefile contains a huge number of polygons, and I'd like cut a small shapefile from it in a circular or squared area around a point. So, let's say I give a point to a system, I want to return all the polygons around this area inside an offset (just so I can send only this segmentation of the data to the frontend of my application).
I know I could convert this shapefile to GeoJSON and find what are the polygons that exist inside the area that I have created (using turf.js for example), but that would be a brute force solution and it wouldn't be efficient.
On the other hand, I know I could install PostgreSQL and PostGIS and implement solutions like this one.
My doubt is that if I can achieve the goal of finding all polygons inside a polygon efficiently using only the command line, Python or JavaScript without implementing a spatial index for that, working directly with the shapefile. Is it possible?

timecommand... I've realized that the time it takes for doing this operation is the same with the index file.qixgenerated or not (6 seconds in my case). So, creating the spatial index is necessary in this case? Is it used automatically? – raylight Apr 29 '21 at 16:07debugmode I see that the index is being created as you said. I think the problem is that it's creating the index on the run instead of using the.qixthat we've created. – raylight Apr 29 '21 at 22:31.qixindex file with the commandogrinfo... – raylight Apr 30 '21 at 00:28