Automatically erase objects in the video, such as logo, text, etc.

Overview

Video-Auto-Wipe

Read English Introduction:Here

  本人不定期的基于生成技术制作一些好玩有趣的算法模型,这次带来的作品是“视频擦除”方向的应用模型,它实现的功能是自动感知到视频中我们不想看见的部分(譬如广告、水印、字幕、图标等等)然后进行擦除。由于图标擦除模型存在潜在的被利用于侵权行为的隐患,因此我暂时只分享了字幕擦除模型,希望能帮助到大家。
  我后续会持续不断的探索和制作新的生成方向的技术内容。基于生成模型可玩的点还有很多,此项目仅展示了其中一个做落地应用的例子。本项目的模型版权所属为:www.seeprettyface.com ,未获得授权请不要直接用作商业用途。关于算法的细节介绍可以参阅我的研究笔记



效果预览

1. 图标擦除

  图标擦除模型的功能是模型自动感知到视频中图标的位置然后进行擦除,感知图标的方法为在时域上静止不动的小块像素块被视作图标。

1.1 测试1-电视剧的台标、剧名和角标擦除

Image text

查看视频



1.2 测试2-足球赛的台标、状态栏擦除

Image text

查看视频



1.3 测试3-综艺节目的台标、状态栏擦除

Image text

查看视频



1.4 测试4-短视频MV的遮挡图标擦除

Image text

查看视频



1.5 测试5-短视频MV的遮挡水印擦除

Image text

查看视频



1.6 测试6-新闻媒体的台标擦除

Image text

查看视频





2. 动态图标擦除

  动态图标擦除模型的功能是模型自动感知到视频中动态图标的位置然后进行擦除,感知动态图标的方法为在时域上闪烁出现或动态移动的固定像素块被视作动态图标,这个在制作上有一定难度所以还没有对外开放。

2.1 测试1-闪烁出现的特效文字擦除

Image text

Image text

查看视频





3. 字幕擦除

  字幕擦除模型的功能是模型自动感知到视频中字幕的位置然后进行擦除,感知字幕的方法为具有统一样式的文字区域被视作字幕。

3.1 测试1-电影字幕擦除

Image text

查看视频



3.2 测试2-电视剧字幕擦除

Image text

查看视频



3.3 测试3-综艺节目字幕擦除

Image text

查看视频



3.4 测试4-综艺节目特殊字幕擦除

Image text

查看视频



3.5 测试5-网络视频字幕擦除

Image text

查看视频



3.6 测试6-小语种字幕擦除

Image text

查看视频





使用方法

1.环境配置

  torch>1.0
  其他的缺什么依赖就pip install xxx,需要的东西不多

2.运行方法

  1. 下载预训练模型放在pretrained-weight文件夹里;
    预训练模型下载地址:链接:https://pan.baidu.com/s/1ubZHkgkcskS7Bpg8ZbtoRQ 提取码:ricn

  2. 将视频文件和mask文件放在input文件夹里,编辑demo.py(或通过命令行参数)选中对应文件位置;
    输入样例下载地址:https://pan.baidu.com/s/1rfdAwxomCVjTJ1zwl7hu3g 提取码:qk64

  3. 图标擦除任务运行:python demo.py delogo
   字幕擦除任务运行:python demo.py detext



训练方法

训练数据

  1.YoutubeVOS2018数据集;

  2.基于搜集的300余部高清电影制作了2,709部电影片段数据集;
    下载地址:https://pan.baidu.com/s/1CIgJmFmx5iR2JfgAyjVaeg 提取码:xb7o

  3.基于搜集的40余部综艺节目制作了864部综艺片段数据集;
    下载地址:https://pan.baidu.com/s/1lJk6IIWlwxknAie0LlGYOg 提取码:9rd4

训练过程

  第1步. 针对特定任务的时域感知训练;
  第2步. 融合擦除模型的微调训练。

训练配置

最近寻觅到了一种非常简易的制作和训练方法:
  '图标擦除'模型在单卡3090上训练3天;
  '字幕擦除'模型在单卡3090上训练2天;





更多玩法

  这个项目目前还只是做了很短期的尝试,实际上视频擦除可玩的点还有很多,譬如敏感内容(涉黄涉暴等)擦除、广告擦除、指定人/物擦除、背景人擦除等等。只要是能寻找到有像素预测的场景+有像素预测的需求都是“视频擦除”可以玩出花样的情景~

Sample





了解更多

  本人的研究方向是生成模型的应用技术研究。生成技术解决的问题是像素的预测,也就是在一个有缺失/完全缺失的图像棋盘上进行像素的填补/预测,使填补/预测完的图像符合真实图像的规律。基于这种模式可展开的玩法有很多,除了我之前做的数字人生成、视频内容生成等,我们还可以拓展出更多并行的思路出来。
  尽管目前大部分的CV落地项目都集中在感知和识别任务上,而对于重构和生成任务的研发相对较少,但这不应影响我们对于生成技术价值的判断,毕竟生成技术是相对较新、参与人较少,但是应用前景较广的研究方向。我后续将持续致力于探索生成方向的落地型算法研发,欢迎访问我的网站了解这方面最新的研究进展:www.seeprettyface.com

Sample

Owner
seeprettyface.com
seeprettyface.com
The official implementation of paper Siamese Transformer Pyramid Networks for Real-Time UAV Tracking, accepted by WACV22

SiamTPN Introduction This is the official implementation of the SiamTPN (WACV2022). The tracker intergrates pyramid feature network and transformer in

Robotics and Intelligent Systems Control @ NYUAD 29 Jan 08, 2023
Pytorch implementation of Integrating Tree Path in Transformer for Code Representation

This is an official Pytorch implementation of the approaches proposed in: Han Peng, Ge Li, Wenhan Wang, Yunfei Zhao, Zhi Jin “Integrating Tree Path in

Han Peng 16 Dec 23, 2022
A Traffic Sign Recognition Project which can help the driver recognise the signs via text as well as audio. Can be used at Night also.

Traffic-Sign-Recognition In this report, we propose a Convolutional Neural Network(CNN) for traffic sign classification that achieves outstanding perf

Mini Project 64 Nov 19, 2022
Code repository of the paper Neural circuit policies enabling auditable autonomy published in Nature Machine Intelligence

Neural Circuit Policies Enabling Auditable Autonomy Online access via SharedIt Neural Circuit Policies (NCPs) are designed sparse recurrent neural net

8 Jan 07, 2023
Users can free try their models on SIDD dataset based on this code

SIDD benchmark 1 Train python train.py If you want to train your network, just modify the yaml in the options folder. 2 Validation python validation.p

Yuzhi ZHAO 2 May 20, 2022
SAS output to EXCEL converter for Cornell/MIT Language and acquisition lab

CORNELLSASLAB SAS output to EXCEL converter for Cornell/MIT Language and acquisition lab Instructions: This python code can be used to convert SAS out

2 Jan 26, 2022
Source code for our paper "Do Not Trust Prediction Scores for Membership Inference Attacks"

Do Not Trust Prediction Scores for Membership Inference Attacks Abstract: Membership inference attacks (MIAs) aim to determine whether a specific samp

<a href=[email protected]"> 3 Oct 25, 2022
Source code for CVPR 2020 paper "Learning to Forget for Meta-Learning"

L2F - Learning to Forget for Meta-Learning Sungyong Baik, Seokil Hong, Kyoung Mu Lee Source code for CVPR 2020 paper "Learning to Forget for Meta-Lear

Sungyong Baik 29 May 22, 2022
A Python toolbox to create adversarial examples that fool neural networks in PyTorch, TensorFlow, and JAX

Foolbox Native: Fast adversarial attacks to benchmark the robustness of machine learning models in PyTorch, TensorFlow, and JAX Foolbox is a Python li

Bethge Lab 2.4k Dec 25, 2022
Codes for paper "KNAS: Green Neural Architecture Search"

KNAS Codes for paper "KNAS: Green Neural Architecture Search" KNAS is a green (energy-efficient) Neural Architecture Search (NAS) approach. It contain

90 Dec 22, 2022
Angle data is a simple data type.

angledat Angle data is a simple data type. Installing + using Put angledat.py in the main dir of your project. Import it and use. Comments Comments st

1 Jan 05, 2022
SpiroMask: Measuring Lung Function Using Consumer-Grade Masks

SpiroMask: Measuring Lung Function Using Consumer-Grade Masks Anonymised repository for paper submitted for peer review at ACM HEALTH (October 2021).

0 May 10, 2022
A simple baseline for the 2022 IEEE GRSS Data Fusion Contest (DFC2022)

DFC2022 Baseline A simple baseline for the 2022 IEEE GRSS Data Fusion Contest (DFC2022) This repository uses TorchGeo, PyTorch Lightning, and Segmenta

isaac 24 Nov 28, 2022
This is an official implementation of the paper "Distance-aware Quantization", accepted to ICCV2021.

PyTorch implementation of DAQ This is an official implementation of the paper "Distance-aware Quantization", accepted to ICCV2021. For more informatio

CV Lab @ Yonsei University 36 Nov 04, 2022
This repository contains the code for TABS, a 3D CNN-Transformer hybrid automated brain tissue segmentation algorithm using T1w structural MRI scans

This repository contains the code for TABS, a 3D CNN-Transformer hybrid automated brain tissue segmentation algorithm using T1w structural MRI scans. TABS relies on a Res-Unet backbone, with a Vision

6 Nov 07, 2022
a delightful machine learning tool that allows you to train, test and use models without writing code

igel A delightful machine learning tool that allows you to train/fit, test and use models without writing code Note I'm also working on a GUI desktop

Nidhal Baccouri 3k Jan 05, 2023
Automated image registration. Registrationimation was too much of a mouthful.

alignimation Automated image registration. Registrationimation was too much of a mouthful. This repo contains the code used for my blog post Alignimat

Ethan Rosenthal 9 Oct 13, 2022
SEAN: Image Synthesis with Semantic Region-Adaptive Normalization (CVPR 2020, Oral)

SEAN: Image Synthesis with Semantic Region-Adaptive Normalization (CVPR 2020 Oral) Figure: Face image editing controlled via style images and segmenta

Peihao Zhu 579 Dec 30, 2022
LAMDA: Label Matching Deep Domain Adaptation

LAMDA: Label Matching Deep Domain Adaptation This is the implementation of the paper LAMDA: Label Matching Deep Domain Adaptation which has been accep

Tuan Nguyen 9 Sep 06, 2022
Meta Learning for Semi-Supervised Few-Shot Classification

few-shot-ssl-public Code for paper Meta-Learning for Semi-Supervised Few-Shot Classification. [arxiv] Dependencies cv2 numpy pandas python 2.7 / 3.5+

Mengye Ren 501 Jan 08, 2023