Skip to content

Instantly share code, notes, and snippets.

@amit-spatial
amit-spatial / pan_india_facilities_pipeline.md
Last active May 20, 2026 12:20
Pan India Facilities Pipeline Process

Data Processing for Facilities' layer:

For this layer, we downloaded data from multiple resources -- primarily from https://grammanchitra.gov.in/, which used publicly available GIS layers of facilities prepared for PMGSY implementation plan.

We then cleaned and compiled it into 25 csv files, one for each facility type. Each file necessarily contain an uid column {facility}_uid for the facility, along with its coordinates ({facility}_lat, {facility}_long). Wherever the names and any other properties, classifications of the facility were available, they were also retained. You can find the script here.

Using the location in these pan-india point-files and shapes of villages in corestack data/admin-boundary/input/, we calculated the distance of closest facility to each village across India, using k-d tree algorithm. We ran [this process](https://github.com/core-stack-org/core-stack-backend/blob/