Vince-Lau / automatic-watermark-detection

debug automatic-watermark-detection,and success run
95 stars 42 forks source link

关于此项目说明

原项目地址为rohitrango/automatic-watermark-detection: Project for Digital Image Processing

因为有需求需要使用此项目解决视频去水印的问题,所以把此项目的源码大致看了。感觉写的不怎么好

关于上面那些短板,我针对视频识别水印都做了很大优化,对一个视频的识别,速度在ms级别,可以浏览我的项目:[待添加]()

这个项目很简单,只是调了bug发上来。研究之后的成果,我后续会发上来,带有文档说明。

以下为原版readme

Automatic watermark detection and removal

This was a project that was built as part of project for CS663 (Digital Image Processing). This is a crude Python implementation of the paper "On The Effectiveness Of Visible Watermarks", Tali Dekel, Michael Rubinstein, Ce Liu and William T. Freeman, Conference on Computer Vision and Pattern Recongnition (CVPR), 2017.

Rough sketch of the algorithm

A watermarked image J is obtained by imposing a watermark W over an unwatermarked image I with a blend factor . Specifically, we have the following equation:

Where p = (x, y) is the pixel location. For a set of K images, we have:

Although we have a lot of unknown quantities (), we can make use of the structural properties of the image to determine its location and estimate its structure. The coherency of and W over all the images can be exploited to solve the above problem with good accuracy. The steps followed to determine these values are:

Multi-image matting and reconstruction

Please refer to the paper and supplementary for a more in-depth description and derivation of the algorithm.

Results

Here are some of the results for watermarked and watermark removed images:




However, this is a rough implementation and the removal of watermark leaves some "traces" in form of texture distortion or artifacts. I believe this can be corrected by appropriate parameter tuning.

More information

For more information, refer to the original paper here

Disclaimer

I do not encourage or endorse piracy by making this project public. The code is free for academic/research purpose. Please feel free to send pull requests for bug fixes/optimizations, etc.