OpenStreetMap logo OpenStreetMap

100 villages in 100 days

Posted by IrdiIs on 1 June 2024 in English. Last updated on 22 July 2024.

Albania’s mapping, especially in rural areas, is lacking. Villages, in particular, are often not mapped at all. To address this, I’ve set myself a challenge: to map 100 villages in 100 days. I’ve used tools like Overpass Turbo and a Python script to select these villages randomly. Below, I’ve listed the villages, although I haven’t checked if they are already mapped. In the event that a village on the list has already been mapped, I will replace it with another. I’ll update regularly on my progress.

  1. Shushicë (41.1008191, 20.1388668) ✅
  2. Vukël (42.4861958, 19.64735) ✅
  3. Fitore (40.6320149, 19.4559282) ✅
  4. Lapardha e Sipërme (40.7808255, 19.9537119) ✅
  5. Përcëllesh (41.2874122, 19.9449583) ✅
  6. Gjerë (40.9055141, 20.2940623) ✅
  7. Faqekuq (40.5656368, 20.4054953) ✅
  8. Qerret (41.3923154, 19.4917403) ✅
  9. Stropckë (40.8534357, 20.6842592) ✅
  10. Kullaj (42.1386724, 19.5262028) - Already mapped. Will add another village when i get to the bottom of this list.
  11. Kastriot (41.737124, 20.3791595) ✅
  12. Mokricë-Zleushë (40.2992792, 20.3276938) ✅
  13. Tenë (41.7855984, 19.9595356) ✅
  14. Lavdar i Korçës (40.6027805, 20.6556642) ✅
  15. Arrëz (40.5005086, 20.8421665) ✅
  16. Lapulec (40.6288454, 19.7373071) ✅
  17. Kuzhnen (41.8980834, 19.9670947) ✅
  18. Kotorr (40.9265281, 20.1673374) ✅
  19. Kafaraj (40.6364502, 19.5117088) ✅
  20. Shtëpëz (40.2158767, 20.069172) ✅
  21. Frashër (40.3661283, 20.4281963) ✅
  22. Jaran (42.26793, 19.4481678) ✅
  23. Leminot (40.7941842, 20.6957944) ✅
  24. Perkola (41.4464692, 19.9303746) ✅
  25. Hajdaraj (40.9589557, 19.7221109) ✅
  26. Kaftall (41.9452335, 19.7686687) ✅
  27. Vesqi (41.1750169, 19.8248392) ✅
  28. Zdojan (41.6879927, 20.3797589) ✅
  29. Kosovë (40.8998168, 19.8141917) ✅
  30. Mushnik (41.1514842, 19.6657204) ✅
  31. Alarup (40.864066, 20.7950294) ✅
  32. Gllavë (40.4893239, 19.9653888) ✅
  33. Shënepremte (41.0272906, 19.5457236) ✅
  34. Xhan (42.2506701, 19.6490827) ✅
  35. Floq (40.5081269, 20.7154456) ✅
  36. Vlashaj (41.5316376, 20.4055941) ✅
  37. Llëngë (40.8864156, 20.5007392) ✅
  38. Renz (41.7545162, 20.3830977) ✅
  39. Demiraj (42.1811321, 19.4751039) Already mapped
  40. Slatinjë (40.481813, 20.1713576) ✅
  41. Radesh (40.5389203, 20.2550814) ✅
  42. Gradec (42.2547977, 19.4617091) ✅
  43. Fushëz (40.7865358, 20.264107) ✅
  44. Rashtan (40.8801918, 20.3259025) ✅
  45. Duhanas (40.7233908, 19.9954468) ✅
  46. Saraqinisht (40.1055965, 20.2304735) ✅
  47. Tomin (41.6906338, 20.4210429) ✅
  48. Kryemadh (42.0895508, 20.2911894) ✅
  49. Grykë-Manati (41.7791296, 19.6790894) ✅
  50. Mushan (41.9773281, 19.4351608) ✅ Already mapped
  51. Rushkull (41.980251, 19.3969448) ✅ Already mapped
  52. Mjedë (42.0017697, 19.6148898) ✅ Already mapped
  53. Qazim Pali (40.0478302, 19.855221) ✅
  54. Bezhan (40.4215687, 20.7353506) ✅ Ruins
  55. Mesul (41.9489498, 20.0499793) ✅
  56. Cerjan (41.7134663, 20.4824473) ✅
  57. Bishqem (41.0699913, 19.8672447) ✅
  58. Papër (41.0538876, 19.9569239) ✅
  59. Pac (42.2900815, 20.2034059)
  60. Gjergjan (41.0387886, 20.0139255)
  61. Kaçinar (41.8012625, 19.6949146)
  62. Romës (40.5595996, 19.6816829)
  63. Selckë (40.1088656, 20.2968363)
  64. Bukmirë (41.8389148, 19.868848)
  65. Bubq (41.4713963, 19.6545539)
  66. Mengël (41.1202355, 20.1188463)
  67. Gjokaj (41.3587642, 19.6738825)
  68. Nangë (42.0105618, 20.4164814)
  69. Ngraçan (40.646106, 19.7962679)
  70. Bishqethem (40.8695061, 19.6591411)
  71. Baz (41.6286658, 19.9304945)
  72. Memaliaj Fshat (40.3452031, 19.9764133)
  73. Plan (42.2894757, 19.693757)
  74. Kujtim (41.5591781, 20.0601065)
  75. Poçestë (40.6842812, 20.7179655)
  76. Velahovë (39.9054826, 20.1531553)
  77. Tharri (41.7343178, 19.9859391)
  78. Matranxhë (41.8637241, 20.4212978)
  79. Vorrozen (41.1431628, 19.5634312)
  80. Levan (40.6206191, 19.8556674)
  81. Pilur (40.6638888, 20.9162806)
  82. Kodër (40.2747186, 20.065531)
  83. Bllatë e Poshtme (41.5623971, 20.477637)
  84. Toç (40.417205, 19.8675563)
  85. Skrevan (40.7505737, 19.8250009)
  86. Arn i Epërm (41.6405756, 20.3047777)
  87. Lofkend (40.6448336, 19.7453692)
  88. Ogren-Kostrec (40.3163612, 20.4498636)
  89. Lenmushë (40.721556, 20.2431292)
  90. Rrashtan (41.0485117, 20.512638)
  91. Raban (40.3410655, 20.3132609)
  92. Skënderbej (41.1340621, 20.5638372)
  93. Kuç (40.1742689, 19.8389532)
  94. Jezull (41.7445468, 19.817449)
  95. Ujëmirë (40.3873621, 20.1341224)
  96. Shpatanj (40.6591601, 20.2200733)
  97. Unnamed village (41.6811445, 20.3302903)
  98. Rusinjë (40.6784764, 19.6717383)
  99. Tremul (39.8654747, 20.0849958) ✅ Mapped by perenniallylate
  100. Arrëz (40.2520032, 20.6924267)

Discussion

Comment from Mr Morale on 1 June 2024 at 14:29

kudos! all the best.

Comment from watmildon on 2 June 2024 at 02:29

Delightful! Would love to know more about the overpass query and python you’re using.

Comment from IrdiIs on 2 June 2024 at 09:06

I have just started exploring overpass turbo so there might be better solutions for this but im enjoying exploring. I am sharing below the overpass query and the python script:

Overpass query

[out:json];
area["ISO3166-1"="AL"]->.searchArea;
(
  node["place"="village"](area.searchArea);
);
out body;

In the query, “AL” represents Albania. You can replace “AL” with the ISO 3166-1 code for any other country to get results specific to that country.

After i ran the query, i exported the data in .geojson format and then used the python script. It might not be the best, but it did the job.

Python script (select_random_villages.py) to randomly select 100 villages from a .geojson file.

Python script

import json
import random

#Load the GeoJSON data
with open('export.geojson', 'r', encoding='utf-8') as f:
    data = json.load(f)

#Extract the village features
villages = [feature for feature in data['features'] if feature['properties'].get('place') == 'village']

#Select 100 random villages
random_villages = random.sample(villages, 100)

#Create a list of village names and coordinates
village_info = [
    {
        'name': village['properties'].get('name', 'Unnamed village'),
        'latitude': village['geometry']['coordinates'][1],
        'longitude': village['geometry']['coordinates'][0]
    }
    for village in random_villages
]

#Save the selected random village names and coordinates to a text file
with open('random_villages.txt', 'w', encoding='utf-8') as f:
    for info in village_info:
        f.write(f"Name: {info['name']}, Latitude: {info['latitude']}, Longitude: {info['longitude']}\n")

#Print the selected random village names and coordinates (optional)
for info in village_info:
    print(f"Name: {info['name']}, Latitude: {info['latitude']}, Longitude: {info['longitude']}")

On the line “#Load Json data” you have to give the filename of the extracted .geojson data. In my case is ‘export.geojson’. If the file is located in a different directory from the script, include the path to the .geojson file.

Comment from watmildon on 3 June 2024 at 03:58

Very clean. For the US, I have a mastodon bot that posts a town a day in similar fashion. We have okay enough population data on place nodes that I use that as my “village” proxy (population < 1000). It also runs a few Overpass queries before posting so it will only show things with 10 or fewer buildings nearby.

I am excited to hear more about your challenge and how it goes! Keep it up!

Comment from IrdiIs on 3 June 2024 at 10:07

That bot is very cool! Do you think I could adapt it for Albania, even though our population statistics are not that good on OSM?

Comment from watmildon on 3 June 2024 at 18:26

It could definitely be adjusted for other areas. If the place= categorization is a decent proxy, that may be enough. You could also decide that “any place node without X feature” is worth posting about.

I would need to do a bit of work to get the bot to run with multiple accounts but that’s not a huge hurdle. I am busy this week with State of the Map US planning but should have more time in the rest of June to investigate ideas.

Comment from silversurfer83 on 19 June 2024 at 05:12

Hi Read about this in weekly osm and I just wanted to drop by and say that I applaud your effort 💪🏻 Great idea. I hope you can make it happen :)

Comment from IrdiIs on 19 June 2024 at 08:23

It is going good so far and has also inspired me to map in the surrounding countries. Thank you very much!

Log in to leave a comment