Steem Map: Development Road

in #steemdev7 years ago (edited)

steem_map

Intro

Hello Steemians,

Creating a Web Map App with all Steemians locations might not seem like a super complex project, however, due to my lack of experience in Python and backend web design, I am forced to keep good track of my steps and take every single decision carefully.

The motivation behind is promoting meetups and user-to-user interaction . Hopefully, with this app users will easily find other Steemians in their neighborhood/area whether using a distance or province/country filtering.

With this roadmap I would like to describe the steps and challenges I have found so far in the current project that I am involved with.

Concept

Finding a map service
Retrieving locations from SteemData Server
Feeding Map with locations
Enabling Map filter feature

Map Service Choice


There are many possibilities out there, many are free but are usually limited by the amount of geolocations uses per day.

I was deciding between one of the following:

pubnubinfosniperbatchgeo
yahoogoogle

Since most services are limited, I decided to going for google maps because of the extensive and good quality of its documentation.

User Location Data Retrieval

The first step was finding a way to get all locations within the blockchain. My solution was using MongoDB and SteemData by Furion (https://steemit.com/steemdata/@furion/getting-started-with-steemdata).

Feeding Map with locations

This is the tricky part. Since I do not want to pay the subscription for unlimited geolocations calls, I have two possibilities:

  • Get geolocations locally from a dictionary and create a database embedding all user location coordinates
  • Get a separated geolocation service that feeds my webmap

Since I decided beforehand running the backend in Python, I chose the great tool "Geopy" as a remote geolocation service (running in Python). For the rest of the processes, I will be running Python3 and additionally the Pymongo module for the Database management.

Testing code so far:

from geopy.geocoders import Nominatim

import datetime

from steemdata import SteemData
geolocator = Nominatim()
from pymongo import MongoClient
client = MongoClient('localhost', 27017)
db = client.test_database
collection = db.test_collection
data2 = []

s = SteemData()

data = s.Accounts.aggregate(

[

{
   "$match": {
            "profile.location": { "$exists": "true", "$ne": "null" }
        }
    },
    { 
    "$project":
    {
        "account":"$account",
        "location":"$profile.location",
        "_id":0
    }},
    {"$limit":5},
])

for element in data:

    print(element["location"])
    location = geolocator.geocode(element["location"])
    data["location"] = location
    print((location.latitude, location.longitude))

Please feel free to comment and suggest. I will post the final web url as soon as the app is ready. Thanks for reading.

-lightproject

Sort:  

Good idea!!!

Thanks mate I appreciate.

I mean, lady :D

Good Idea and great post. I follow you now for more news about the apis.

Look at my posts too @thunderland maybe follow me, if you like them.

Hello @thunderland I will check your work ,thanks for reading.

You've got my 3 cents!

pum intended? xD

Definitely ;)

Appreciate the support @kodaxx !

I love the idea. Can't wait to download the app :D

hello @beingnaveed! the app will be Web based, so no need to download! Thanks for support

Is it violation of privacy?

No, it feeds from locations that are explicitly set by users.

Do you like the project? Any suggestion or feedback?

There is a steemit worldmap project. People can sign their travel posts on that map. Maybe your project and that steemit worldmap project could be combined. For example: 1 map with 2 layers. People could be filter the layers. So, they could see both layers or one of them. One map is better instead of lots of steemit maps.

Yes i made some research already on current similar projects. I know that one. I like the simple concept, but I do not think is a realistic approach as you expect users to manually insert the data.

Seems like an interesting idea for sure =)

Thanks mate, appreciate it. I hope final development will run smooth :)

I am not that much technical but I respect your initiative that you came up with such service by which we can connect locally with other steemians...

Are you aware that SteemSpot project exists?

I am building SteemProjects to make a comparison of similar projects more easy :)

No, I wasnt, but now I am! Cool project @noisy, ill check your work, cool to see creative people around!

What an interesting project. It will be interesting to see the results!

Thanks! I'll try to use it by putting in the co-ordinates when I can!

For the moment results are only visible in my videoblog (the test map is only running in my local machine). However, soon I will have a testing map available on the internet where you can also test.

Coin Marketplace

STEEM 0.27
TRX 0.12
JST 0.031
BTC 57254.26
ETH 2887.51
USDT 1.00
SBD 3.60