基于Python爬虫技术的网络目录更新程序设计
2020-02-22宋钰



摘 要:为解决传统网络目录更新程序速率慢的问题,文章设计了基于Python爬虫技术的网络目录更新程序,运用GET方式自动解析预设网络目录参数,删除重复网络目录,转化最新得到的网络目录为EQ3格式,完成网络目录更新,实现EQ3网络目录格式更新程序的设计。通过PyQt编写程序界面得出结论:该程序更新网络目录平均耗时为1.568 s,对照组为4.896 s,该程序更新网络目录平均耗时低于对照组,更新速率更快,可以解决传统网络目录更新程序速率慢的问题。
关键词:Python爬虫技术;网络目录;更新程序;更新速率
中图分类号:TP311.1;TP393.092 文献标识码:A 文章编号:2096-4706(2020)18-0020-03
Abstract:In order to solve the problem of slow speed of traditional network directory update program,a network directory update program design based on Python crawler technology is carried out. Use the GET method to automatically parse the preset network directory parameters,delete duplicate network directories,convert the latest network directory to EQ3 format,complete the network directory update,and realize the EQ3 network directory format update program design. Through the programming interface of PyQt,it is concluded that the average time required to update the network directory of the design program is 1.568 s,and the control group is 4.896 s. The average time required to update the network directory of the design program is lower than that of the control group,and the update rate is faster,which can solve the traditional network problem of slow catalog update process.
Keywords:Python crawler technology;network directory;update program;update rate
0 引 言
網络目录作为网络的核心组成部分,能够将网络中的信息通过目录的形式集中展示,使用户能够对网络中包含的信息一目了然。由于网络目录对时效性有很高的要求,网络目录必须随着网络信息内容的变更及时更新,避免出现目录与实际内容不符的现象。因此,网络目录更新程序应势而生。以往的网络目录更新程序在应用过程中存在耗时长的缺点,无法快速处理格式多样的网络信息数据。Python爬虫技术作为能够自动捕捉网络信息的程序,在网络信息获取方面具有很大的优势[1]。随着Python爬虫技术的逐步成熟,其已经被应用到多个领域中,因此也可以将Python爬虫技术引进到网络目录更新程序设计中。本人在校期间曾有幸参与过该项目的实验,希望能够通过Python爬虫技术的高效信息获取功能,从根本上提高网络目录更新速率。……
