总结指定区域内地点的Google地图属性

places-summarized的Python项目详细描述


汇总的地点

Build StatusLicense: MIT

Places summared是googlemaps的placesapi的包装器,它总结了 指定坐标附近位置的属性。在

安装

使用pip汇总的安装位置

$ pip install places-summarized

要求

  • 谷歌地图API密钥。在
  • Python3

使用

本例使用googlemapsapi键。在

importpprintfromplaces_summarized.clientimportClientpp=pprint.PrettyPrinter(indent=4)client=Client(key='your-key')# Google Sydney officessummary=client.places_summary(location=(-33.8670522,151.1957362),radius=1000)pp.pprint(summary.result())# Print the ratings of the locations of type "point_of_interest."# You can find the full list of types# at: https://developers.google.com/places/web-service/supported_typesprint(summary.ratings_by_type('point_of_interest'))# Print the average price level of all the placesprint(summary.average_price_level())

或者,您可以不使用密钥,使用TestClient来测试它。在

^{pr2}$

文件

去做。。。:/也许你想帮忙?在

致谢

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java变量始终存储0值。为什么?   如何使用Java/REST将Azure blob从一个存储容器移动到另一个存储容器?   java将commons DBCP从1.2升级到1.4,我应该害怕吗?   java如何使用分隔符拆分字符串?   java使用数组读取json对象   java在groovy中切片字符串   交换数组java的两个邻域元素   java移动用于确定字符串是否为回文的逻辑   java Android应用程序在一个活动中崩溃   java Sparkjava将webapp文件夹设置为静态资源/模板的文件夹   java复杂条件表达式,用户易用。   java如何仅在表存在时从表中选择值   java I无法将数据从Recyclerview传递到其他活动   java数据结构最佳设计(大数据)   java Android从DatePickerDialogFragment中删除日历视图   java将数据从Firebase获取到片段   数组。sort()在java中运行不正常