apps-android-commons icon indicating copy to clipboard operation
apps-android-commons copied to clipboard

Map of recently uploaded pictures

Open nicolas-raoul opened this issue 8 years ago • 9 comments

Snapchat has recently released a very entertaining feature that shows public videos uploaded around the globe. You can zoom to a country/city and immediately see what is going on there, for instance a concert or a demonstration, I am having quite a lot of fun with it: snapchat

It would be cool to be able to see the same for Commons uploads. I might not be as entertaining but still interesting. If not entertaining enough, it could also be implemented as just a filter for #28

If there is already some Commons tool offering this feature, please post the URL below, thanks! :-)

nicolas-raoul avatar Jul 16 '17 12:07 nicolas-raoul

Is this still in the plans? If so, I would like to pick it up. I am guessing there should be an API which gets the list of recently uploaded images along with the details about where they were taken and we would simply populate them on the map. I don't use Snapchat but the image @nicolas-raoul attached would be a good place to start.

Bluesir9 avatar Mar 15 '18 15:03 Bluesir9

I still think it would be a cool feature to add :-) It would show the whole world map, so it would be different from Nearby (a map of nearby recent uploads most be desperately empty most of the time).

I don't know any API that gives this, if you could find it that would be wonderful :-) Good places to ask would be https://commons.wikimedia.org/wiki/Commons:Village_pump and Stack Overflow. Please link to the questions you ask, thanks!

nicolas-raoul avatar Mar 16 '18 02:03 nicolas-raoul

Cool, will get started on that and post my findings.

Bluesir9 avatar Mar 16 '18 04:03 Bluesir9

The API we are looking for is this. For whatever reason, I am not able to run it on the wikimedia commons base url in the API sandbox but an example query would be something like this

I think this is good enough to get started, @nicolas-raoul sound good? Anything you think I am missing or should take into consideration?

Bluesir9 avatar Mar 19 '18 16:03 Bluesir9

@Bluesir9 Your example query seems to work, thanks! Is there a way to tweak that query so that it also gives the latitude/longitude? Without the latitude/longitude we would need to request the metadata page for each picture, which would take more time. We also need the URL to a thumbnail of the picture, to show it as a pin on the map :-)

nicolas-raoul avatar Mar 20 '18 12:03 nicolas-raoul

I found the latitude and longitude as part of the "metadata" field for one one of the entries in the response. So I think that is where we will find the GPS data. I guess the takeaway from this is that a lot of pictures will not contain the latitude/longitude data which might make things tricky for us.

The URL is already their as part of the response, its the "url" field.

Bluesir9 avatar Mar 20 '18 12:03 Bluesir9

Just ignore pictures that do not have latitude/longitude.

I wonder if you can make coordinates appear (for those that have some) by modifying the aiprop property's value in your query.

nicolas-raoul avatar Mar 21 '18 05:03 nicolas-raoul

You can find the possible values for aiprop here. There is no explicit field we can use to fetch the coordinates.

That said, I will start working on this now.

Bluesir9 avatar Mar 21 '18 06:03 Bluesir9

This sounds like a brilliant idea, and a great way to potentially gain more interest for the app.

chrisdebian avatar Dec 21 '24 14:12 chrisdebian