Let the s̶t̶a̶r̶s̶ map guide you
Most of us make grand plans to travel, but do not end up ticking off all the destinations on our bucket list. Ever wondered where it all went wrong? Loopholes can often be found in the itinerary planning, as you realize only too late that the two monuments you were planning to see on the same day were on completely opposite sides of the city. So what do you think can be done to avoid such a situation in future? TELEPORTATION! But until that is figured out, I would opt for geocoding.
What is geocoding?
Geocoding is the process of converting the description of a location into geographical coordinates. The input data could be a textual description of the location in relation to a reference location or absolute data.
A very good example is PepsiCo introducing Foodicons in India. They took into account the most popular food items across the country, like Mumbai’s vada pavs, Chennai’s dosas and Delhi’s samosas, and put them on the Pepsi bottle’s packaging. After a customer buys a Pepsi bottle, s/he can then SMS the code to a publicly available phone number and receive a list of the nearest food outlets offering exciting discounts on their order using the company’s first ever geocoded encrypted promotion.
Before the list of outlets is shared with the consumer, it has to be mapped to their coordinates to identify which ones are the nearest. However, that might get extremely tedious if we were to manually convert the address of all food outlets into coordinates. Instead, there are a few modules which can be used to facilitate and speed up the process.
There are certain important modules and libraries that are required in order to execute geocoding in Python. If you are into coding, this might interest you, if not feel free to float right over it.
Let’s understand what each one is used for:
Pandas is a powerful and flexible Python library used for data analysis and manipulation. It supports importing of csv files into DataFrame format which can then be analyzed. To further understand Pandas have a look at this blog.
GeoPandas is a Python module used for working with geospatial data. It is a powerful package for spatial data manipulation. It is built on top of Pandas extending its functionalities. GeoPandas supports geocoding through GeoPy.
GeoPy is a dependency of GeoPandas which makes it easy to locate coordinates across the globe using geocoders. As a basemap we will require Google Maps, Bing Maps, Nominatim etc., which are provided in the class geopy.geocoders. An API key is required to initialize these services. Unlike other services that require you to pay, Nominatim API is a useful tool that allows you to search through OpenStreetMap data for free. To know more about APIs you can have a look at this blog.
Folium is used for creating interactive visualizations of geospatial data. There are various services available for generating a base map of particular height and width, among which OpenStreetMap is free to access. It also allows you to display text while hovering over an object on the map, and has an icon plugin to be used as a marker.
Applications in the humanitarian context
- Emergency Response
Emergency services are now turning to use geocoded address systems to respond to various situations, for instance to find the location of a victim of an accident or natural disaster rather than depending only on the panic stricken individual. Visualizing the spatial distribution of temporary relief shelters for disaster affected people can also help understand where the next shelter should be built to accommodate the vulnerable population.
2. Healthcare Sector
Spatial data analysis has been a boost for the health sector, as has been seen during the COVID-19 pandemic. Geocoding can not only help people locate the nearest vaccination centres, but it can also help authorities to better plan the vaccine distribution to the centres. By knowing the address of the vaccinated people and mapping these out, it becomes easier to identify the remote areas or communities where people are yet to be vaccinated.
3. Water, Sanitation and Hygiene (WASH) Sector
Geocoding is used to map out water access points like wells, pipelines, water tanks, etc. This has helped the people facing water scarcity to locate the nearest water access point, and has ultimately given authorities a clear picture about the areas which are in need of more water access points.
However, geocoding does have a few shortcomings. Coverage remains a major limitation today. There are still areas where geocoded information is sparsely available. Geocoding is a continuous process even within regions that are well geocoded, as every new infrastructure needs to be associated with coordinates. There are people who are continuously working to keep the geocoded information in the databases as updated as possible.
Nevertheless, geocoding has proven itself to be a key asset for a multitude of applications ranging from simple data analysis to understanding disease spread, visualizing the spatial display of existing schools and so much more. After all, what is most important is to understand how to leverage location data to make better and more accurate decisions.
So, next time you plan a trip, let the map guide you!