Git Product home page Git Product logo

bilibili-danmu's Introduction

b站视频内容辅助定位

方便up主或用户能够快速定位到想要的内容在番剧或电视剧全部剧集中出现的时刻。

例如,想要获取《孤独的美食家》中,全部有关“五郎的奇妙比喻”的视频片段,仅需要按照如下设置,即可自动化的定位到全部剧集中出现该内容的时刻。

需要安装的包:

requests
BeautifulSoup

根据不同任务,需要修改的两处变量均在main()函数中:

1.变量target_text为关键词,字符型。将你需要定位的弹幕关键词赋值给该变量,若有多个关键词,请用空格分开。

例如:target_text = '比喻'

2.变量season_id为番剧或电视剧的season_id号,数值型。

例如《孤独的美食家》第八季,网页url为:https://www.bilibili.com/bangumi/play/ss28572/,则season_id号为ss后面的那串数字,即28572。


实现思路:

本质上是一个弹幕爬虫+关键词匹配的程序,但是由于在视频中出现“名场面”时往往会伴有大量含有相同关键词的弹幕,因此,可以利用弹幕在视频中出现的时刻来辅助定位“名场面”出现的时刻。

bilibili-danmu's People

Contributors

johnskyreal avatar

Stargazers

Rabi avatar lvzi avatar

Watchers

 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.