基于Pytorch的开源电影分析工具箱

2020 年 7 月 25 日 专知

【导读】在全国电影院复工的第一个周末~ 本文将带来一个基于Pytorch的开源电影分析工具箱,才开基本视频处理、语义特征提取、电影信息爬虫等。


项目网站:

http://movienet.site/


Movienet 包含1.1k 电影,60k预告与375k的meta信息,拥有丰富的对演员、场景的标注,并提供了检测识别、场景分割、电影类型预测等不同类型的任务。


安装

  1. 安装需要用到的库

    pip install -r requirements.txt
  2. 安装pytorch

    conda install pytorch torchvision cudatoolkit=10.2 -c pytorch
  3. build movienet-tools

    python setup.py develop
  4. 下载预训练的模型权重

    python scripts/download_models.py
  5. 运行demo来确认是否成功安装

    python demos/face_demo.py


使用

工具包包括电影爬虫、shot检测器、人脸识别与特征提取、人物识别与特征提取、地点特征提取、动作特征提取、语音特征提取等。

下面以shot检测器为例说明工具包的用法。


shot检测器

为了初始化shot检测器,需要输入源视频输入与输出路径。下面是使用的例子。

from movienet.tools import ShotDetector# build shot detectors# if desire to specify detected duration,# set being/edn_frame/time, otherwise just leave it blanksdt = ShotDetector(    print_list=True,  # print results on command line    save_keyf_txt=True,  # save key frame text list    save_keyf=False,  # save key frame image    split_video=False,  # save split video    begin_frame=0,    end_frame=2000)# specify source video path and output pathvideo_path = osp.join('tests', 'data/test1.mp4')out_dir = osp.join('tests', 'data')# detect shot and save resultssdt.shotdetect(video_path, out_dir)
专 · 知
专知,专业可信的人工智能知识分发,让认知协作更快更好!欢迎注册登录专知www.zhuanzhi.ai,获取5000+AI主题干货知识资料!
欢迎微信扫一扫加入专知人工智能知识星球群,获取最新AI专业干货知识教程视频资料和与专家交流咨询
点击“阅读原文”,了解使用专知,查看5000+AI主题知识资料
登录查看更多
2

相关内容

迁移学习简明教程,11页ppt
专知会员服务
108+阅读 · 2020年8月4日
Python图像处理,366页pdf,Image Operators Image Processing in Python
【实用书】学习用Python编写代码进行数据分析,103页pdf
专知会员服务
198+阅读 · 2020年6月29日
Yann Lecun 纽约大学《深度学习(PyTorch)》课程(2020)PPT
专知会员服务
183+阅读 · 2020年3月16日
专知会员服务
110+阅读 · 2020年3月12日
【GitHub实战】Pytorch实现的小样本逼真的视频到视频转换
专知会员服务
36+阅读 · 2019年12月15日
【深度学习视频分析/多模态学习资源大列表】
专知会员服务
92+阅读 · 2019年10月16日
ExBert — 可视化分析Transformer学到的表示
专知会员服务
32+阅读 · 2019年10月16日
Pytorch多模态框架MMF
专知
49+阅读 · 2020年6月20日
【资源】NLP多标签文本分类代码实现工具包
专知
40+阅读 · 2019年11月20日
开源OCR文本检测器,基于TextBoxes++和RetinaNet
专知
11+阅读 · 2019年11月15日
自然语言处理NLP之旅(NLP文章/代码集锦)
Pytorch视频分类教程
专知
6+阅读 · 2019年5月25日
机器学习可解释性工具箱XAI
专知
11+阅读 · 2019年2月8日
开源 | 基于Python的人脸识别:识别准确率高达99.38%!
全球人工智能
4+阅读 · 2017年7月29日
Arxiv
4+阅读 · 2019年8月7日
Arxiv
6+阅读 · 2019年4月4日
Attend More Times for Image Captioning
Arxiv
6+阅读 · 2018年12月8日
Arxiv
3+阅读 · 2018年8月27日
Arxiv
11+阅读 · 2018年5月13日
Arxiv
7+阅读 · 2018年4月21日
Arxiv
5+阅读 · 2018年3月30日
VIP会员
相关VIP内容
迁移学习简明教程,11页ppt
专知会员服务
108+阅读 · 2020年8月4日
Python图像处理,366页pdf,Image Operators Image Processing in Python
【实用书】学习用Python编写代码进行数据分析,103页pdf
专知会员服务
198+阅读 · 2020年6月29日
Yann Lecun 纽约大学《深度学习(PyTorch)》课程(2020)PPT
专知会员服务
183+阅读 · 2020年3月16日
专知会员服务
110+阅读 · 2020年3月12日
【GitHub实战】Pytorch实现的小样本逼真的视频到视频转换
专知会员服务
36+阅读 · 2019年12月15日
【深度学习视频分析/多模态学习资源大列表】
专知会员服务
92+阅读 · 2019年10月16日
ExBert — 可视化分析Transformer学到的表示
专知会员服务
32+阅读 · 2019年10月16日
相关资讯
Pytorch多模态框架MMF
专知
49+阅读 · 2020年6月20日
【资源】NLP多标签文本分类代码实现工具包
专知
40+阅读 · 2019年11月20日
开源OCR文本检测器,基于TextBoxes++和RetinaNet
专知
11+阅读 · 2019年11月15日
自然语言处理NLP之旅(NLP文章/代码集锦)
Pytorch视频分类教程
专知
6+阅读 · 2019年5月25日
机器学习可解释性工具箱XAI
专知
11+阅读 · 2019年2月8日
开源 | 基于Python的人脸识别:识别准确率高达99.38%!
全球人工智能
4+阅读 · 2017年7月29日
相关论文
Arxiv
4+阅读 · 2019年8月7日
Arxiv
6+阅读 · 2019年4月4日
Attend More Times for Image Captioning
Arxiv
6+阅读 · 2018年12月8日
Arxiv
3+阅读 · 2018年8月27日
Arxiv
11+阅读 · 2018年5月13日
Arxiv
7+阅读 · 2018年4月21日
Arxiv
5+阅读 · 2018年3月30日
Top
微信扫码咨询专知VIP会员