bitvijays / AirPollutionDataPlatform

Platform for air pollution
0 stars 2 forks source link

Location missing in Luftdaten and Smart Citizen Kit #56

Open bitvijays opened 3 years ago

bitvijays commented 3 years ago

Hello @anshulgaikwad01 and Aman,

I had a look at the how the location data can be inserted in the Map for Luftdaten and Smart Citizen Kit.

main.py calls each plugin i.e [Luftdaten]() and SmartCitizen python files as shown in Main.py L69

If we see transform_luftdaten function, it creates a field geo_json, which takes latitude, longitude co-ordinates.

We can write our code here, so create a function get_coord_to_location(latitude, longitude) which takes co-ordinates as inputs and return location as output.

Inside the function, would suggest the logic such that

The same needs to be done for Smart Citizen Kit

I think we can use https://positionstack.com/ or some other Free API to get the details.

Also, we need to change the schema of the Luftdaten resource and SCK resource to add one more column location into that.

Let me know if you have any further queries.