Closed jankuss closed 7 years ago
Hey,
the URL where we get the data from and its JSON response has no current popular times data available. Looking at the network traffic, there is a www.google.de/maps/preview/entity request, which contains the current popularity. However, it seems to require a protocol buffer parameter.
It could be possible to retrieve the current popular times this way. We will look into that.
I am really interested in this feature too. It would be great if you give some advice to get the data and implement it.
Any updates?
Check out https://github.com/m-wrzr/populartimes/tree/current_popularity. It should work so far, but I would like to test it more before it get's merged into master.
How could I use this with a placeID? I already have a location and I want the info on the specific location?
i get the error "AttributeError: module 'populartimes' has no attribute 'get_current'"
strange.
I even saved the correct files in my home folder....
To find a specific place/google id you can use the scraper or this: https://developers.google.com/maps/documentation/javascript/examples/places-placeid-finder.
Did you switch to the correct branch and removed the previously installed package? It works find for me.
Is there any way to use python to scrape the location ID given the address?
On Oct 7, 2017 4:59 AM, "m-wrzr" notifications@github.com wrote:
To find a specific place/google id you can use the scraper or this: https://developers.google.com/maps/documentation/javascript/ examples/places-placeid-finder.
Did you switch to the correct branch and removed the previously installed package? It works find for me.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/m-wrzr/populartimes/issues/2#issuecomment-334921153, or mute the thread https://github.com/notifications/unsubscribe-auth/AF_9nOLqWY8-JQx1C8fLvX2VeFAx5tFwks5spz1xgaJpZM4O4J2K .
You should be able to use https://developers.google.com/places/web-service/search?hl=en#TextSearchRequests if you want to use a specific address
would it be possible to:
1) make get_current() have geofence parameters just like get(), to output current popularity for all places inside the fence?
2) add the logic for get_current() to the innards of get(), so that get() will return all data it already does plus "current_popularity: xx"?
Those would make certain processes much faster!
And can you please share how to export this data into a readable format? I just get it all as one giant string. CSV and/or excel export would be ideal, but even a better format in python IDLE is good for now.
Hey @deeznuts03 The current popularity is now available via the normal populartimes.get(). #6
I don't think it is necessary to add geofence parameters to get_current(), as there are now already two ways how to retrieve the data for an area. Either with get() or if you wan't faster requests just save the place-ids in this location and call get_current().
The library is supposed to be a lightweight and easy option for people to retrieve the data and then work with it. By keeping to the python types and returning the data as a dict, this is guaranteed most IMO.
Current popularity is now available #6
Hey @m-wrzr thanks a ton! Looks like there are some awesome updates! I'm pretty new to python, so I'm a bit slow on understanding how all of this works and how to leverage your updates. I think you have helped me greatly though, and I am very thankful for the efforts.
What is the unit/range of current_popularity? Is the number comparable between building of different sizes (stadium with 50 people vs restaurant with 50 people, the restaurant is likely to be far more crowded)?
I'm using your library for getting the average popular times, but is it possible to get the current popular time of the place?
I tried to reverse engineer the response of google but didn't find a way to retrieve the current popular time.