Giter VIP home page Giter VIP logo

lyricswordcloud's Introduction

歌手歌词词云

test

运行效果

运行截图

用法

# 下载歌词
$ python download.py 许嵩

# 分析歌词并绘制词云
$ python analyse.py 许嵩

# 或者,下载歌词并绘制词云
$ python download.py 许嵩 && python analyse.py 许嵩

依赖

python(>=3.6)

pip install -r requirements.txt

获取歌词接口:

https://c.y.qq.com/soso/fcgi-bin/client_search_cp?t=7&p=1&n=10&w=%E6%B2%B3%E5%9B%BE&format=json

接口分析:

  • p: 当前页面
  • n: 每面显示的数量
  • w: 歌手姓名
  • format: 返回格式

注意

经试验,该接口仅能返回至多20页数据,其中大约有110条来自搜索的歌手

关于词云的形状

如果在对应歌手的目录有图片 bg.jpg ,则以此图片为依据绘制词云,如果在歌手目录未来发现,则用根目录下的 bg.jpg 为依据绘制词云。

lyricswordcloud's People

Contributors

qwertyyb avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.