本实验我采用的是通过requests爬虫爬取网易云音乐歌单内的歌曲作为数据,预先生成数据库数据。再随机创建用户,用户评分的数据。
摘要:课题是基于用户偏好的娱乐项目推介系统的设计与实现,主要内容是运用Python语言,爬取用户数据并进行分析,并根据用户的偏好进行娱乐项目的推介。主要的技术要求是要获取用户的信息,本次毕业设计选择的爬虫网站是网易云音乐,爬取用户的信息,包括用户的歌曲的歌名,歌名对应的歌手以及歌曲对应的专辑,采用协同过滤的算法分析数据写出算法,做出推荐。为了使得最后做出来的页面的观赏度更高,用户体验更好,爬取了专辑封面图片,使得最后的推荐页面能够做的更加精美,提高用户体验度。最后做出的页面,用户能够通过邮箱注册用户,然后根据设置的用户名以及密码登录上页面,做成的页面上会跳出上百首歌曲,等待用户对其中任何一项或者多项做出评分,打完分之后,可以跳转至歌曲推荐的平台,本次设计的程序是用户评价一个音乐,根据后台算法,推荐二个音乐给用户。
关键词:用户偏好 爬虫 协同过滤 皮尔逊相关度评价
Design and implementation of entertainment project recommendation system based on user preference.
Abstract: The topic is the design and implementation of an entertainment project promotion system based on user preferences. The main content is to use Python language to crawl user data and analyze it, and to recommend entertainment items according to the user's preferences. The main technical requirement is to obtain the user's information. The crawler website selected for this graduation project is Cloud Music, crawling the user's information, including the song name of the user's song, the singer corresponding to the song title, and the album corresponding to the song. The collaborative filtering algorithm analyzes the data write algorithm and makes recommendations. In order to make the final view of the page to be higher, the user experience is better, and the album cover picture is crawled, so that the final recommendation page can be made more exquisite and improve the user experience. The last page to be created, the user can register the user by email, and then login to the page according to the set user name and password. The created page will pop up hundreds of songs and wait for the user to score any one or more of them. After playing the points, you can jump to the platform recommended by the song. The program designed this time is that the user evaluates a piece of music. According to the background algorithm, two songs are recommended to the user.
Keywords: User preferences crawler Collaborative filtering Pearson correlation evaluation
目录
摘要 i
Abstract i
目录 iv
第一章 绪论 1
1.1 课题的背景及研究的意义 1
1.1.1 课题的背景 1
1.1.2 研究的意义 2
1.2 本课题的基本内容(重点,难点) 2
1.2.1 本课题的基本内容 2
1.2.2 本课题的重点 2
1.2.3 本课题的难点 3
1.3 采取的手段 3
1.3.1 步骤 3
第二章 国内外发展 5
2.1发展情况 5
2.1.1 国内外发展趋势 5
2.1.2调研的情况 5
第三章 Python的安装 6
3.1 安装的步骤 6
第四章 分析推荐系统的理论基础 10
4.1推荐系统通用模型 10
4.2工作原理 11
4.3推荐算法 12
4.3.1基于内容的推荐 13
4.3.2 基于协同过滤 13
4.3.3组合推荐 13
4.4皮尔逊相关度评价 14
4.4.1基于物品的协同过滤算法 14
4.4.2基于用户的协同过滤算法: 14
4.4.3计算公式 15
4.5框架 16
4.5.1FLASK 16
4.5.2ORM框架 17
4.5.3bootstrap 17
4.6 HTTP HEADER 请求头参数 18
4.7REQUEST 18
第五章 实验过程的设计及描述 20
5.1爬虫 20
5.2模型 24
5.2.1用户数据库模型 24
5.2.2音乐数据表模型 25