基于网络爬虫的实时交通数据自动采集
Automatic Acquisition of Real-Time Traffic Date Based on Web Crawlers
DOI: 10.12677/AG.2016.63020, PDF, HTML, XML, 下载: 4,471  浏览: 11,141  国家自然科学基金支持
作者: 闫文豪, 舒娱琴*, 黄植钦:华南师范大学地理科学学院,广东 广州
关键词: 网络爬虫自动采集实时交通数据Python语言Tornado网络框架Web Crawler Automatic Acquisition Real-Time Traffic Data Python Programming Language Tornado Net Framework
摘要: 实时交通数据是低碳出行、智能交通、道路网络优化等研究领域必不可少的数据源。为了解决目前存在的实时交通数据不免费、不公开等问题,本文应用Python语言和Tornado网络框架,设计了一个稳定、高效、及时的爬虫程序。以广州市为例,从四维交通指数网页抓取到了1723条道路的基本信息及其每5分钟更新一次的实时交通数据,并将获取结果保存到MySQL数据库。结果表明网络爬虫技术在实时交通数据采集方面具有可行性和有效性。
Abstract: Real-time traffic data is an essential data source to research fields such as intelligent city, low- carbon city, optimum of road net and so on. But the real-time traffic data is not available for free and public. In this paper, the Python programming language and the Tornado Net Framework are used to design a stable, efficient and timely web crawler program which could grab 1723 roads’ traffic data of Guangzhou city, including its basic attributes and real-time traffic data every 5 minutes for each road, from four-dimensional traffic index page and save the data in the local MySQL database at the same time. The result shows that the web crawl technology is feasible and efficient in acquiring real-time traffic data.
文章引用:闫文豪, 舒娱琴, 黄植钦. 基于网络爬虫的实时交通数据自动采集[J]. 地球科学前沿, 2016, 6(3): 169-179. http://dx.doi.org/10.12677/AG.2016.63020

参考文献

[1] 于娟, 刘强. 主题网络爬虫研究综述[J]. 计算机工程与科学, 2015, 37(2): 231-237.
[2] Kausar, M.A., Dhaka, V.S. and Singh, S.K. (2013) Web Crawler: A Review. International Journal of Computer Applications, 63, 31-36.
http://dx.doi.org/10.5120/10440-5125
[3] 曹磊. 网络空间的数据权研究[J]. 国际观察, 2013(1): 53-58.
[4] 刘兵, 等. Web数据挖掘[M]. 北京: 清华大学出版社, 2013.
[5] 陈美. 大数据在公共交通中的应用[J]. 图书与情报, 2012, 148(6): 22-28.
[6] 周春梅. 大数据在智能交通中的应用与发展[J]. 中国安防, 2014(6): 33-36.
[7] 李欢. 基于API天气数据抓取的特定网络爬虫的研究与实现[D]: [硕士学位论文]. 秦皇岛: 燕山大学, 2014.
[8] 张春菊, 等. 基于网络爬虫的地名数据库维护方法[J]. 地球信息科学学报, 2011, 13(4): 492-499.
[9] Li, W.W., Yang, C.W. and Yang, C.J. (2010) An Active Crawler for Discovering Geospatial Web Services and Their Distribution Pattern—A Case Study of OGC Web Map Service. International Journal of Geo-graphical Information Science, 24, 1127-1147.
http://dx.doi.org/10.1080/13658810903514172
[10] 陈晓慧, 陈荣国, 卫文学. 基于网络爬虫的Web服务抓取解析器的设计与实现[J]. 地理信息世界, 2010, 8(3): 64- 68.
[11] Palkowsky, B. and MetaCarta, I. (2005) A New Approach to Information Discovery—Geography Really Does Matter. Proceedings of the SPE Annual Technical Conference and Exhibition, Dallas, Texas, 9-12 October 2005.
[12] 张红云. 基于页面分析的主题网络爬虫的研究[D]: [硕士学位论文]. 武汉: 武汉理工大学, 2010.
[13] 郝以珍. 基于页面分析的网络爬虫系统的设计与实现[D]: [硕士学位论文]. 武汉: 华中科技大学, 2012.
[14] 宋海洋, 刘晓然, 钱海俊. 一种新的主题网络爬虫爬行策略[J]. 计算机应用与软件, 2011, 28(11): 264-267.
[15] 关积珍. 城市交通综合指数、交通出行指数及其数学建模[J]. 交通运输系统工程与信息, 2004, 4(1): 49-53.
[16] 屈展, 李婵. JSON在Ajax数据交换中应用研究[J]. 西安石油大学学报: 自然科学版, 2011, 26(1): 95-98.
[17] 郑岚. Python访问MySQL数据库[J]. 电脑编程技巧与维护, 2010(6): 59-61.
[18] Faheem, M. and Senellart, P. (2013) Intelligent and Adaptive Crawling of Web Applications for Web Archiving. Web Engineering. Springer Berlin Heidelberg, 306-322.
http://dx.doi.org/10.1007/978-3-642-39200-9_26
[19] 杨波. 链接分析中的数据采集技术研究[J]. 图书馆理论与实践, 2010(10): 44-48.
[20] Yu, J. and Liu, Q. (2015) Survey on Topic-Focused Crawlers. Computer Engineering and Science, 37, 231-237.