All Projects → marcbelmont → Cnn Watermark Removal

marcbelmont / Cnn Watermark Removal

Fully convolutional deep neural network to remove transparent overlays from images

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Cnn Watermark Removal

Rubberstamp
📫 RubberStamp is an Android library that makes it easy for you to add a watermark to your images.
Stars: ✭ 411 (-54.54%)
Mutual labels:  watermark
Cifar Zoo
PyTorch implementation of CNNs for CIFAR benchmark
Stars: ✭ 584 (-35.4%)
Mutual labels:  densenet
Wavideobox
秒级! 三行代码实现iOS视频压缩、变速、混音、合并、GIF水印、旋转、换音、裁剪 ! 支持不同分辩率,支持你能想到的各种混合操作! 扩展性强...更多功能不断增加中... iOS 8.0 + 有需要的功能或错误欢迎issue,笔者会及时更新
Stars: ✭ 707 (-21.79%)
Mutual labels:  watermark
Awesome Very Deep Learning
♾A curated list of papers and code about very deep neural networks
Stars: ✭ 435 (-51.88%)
Mutual labels:  densenet
Medicalzoopytorch
A pytorch-based deep learning framework for multi-modal 2D/3D medical image segmentation
Stars: ✭ 546 (-39.6%)
Mutual labels:  densenet
Senet Tensorflow
Simple Tensorflow implementation of "Squeeze and Excitation Networks" using Cifar10 (ResNeXt, Inception-v4, Inception-resnet-v2)
Stars: ✭ 682 (-24.56%)
Mutual labels:  densenet
Nowatermark
remove watermark. 去除图片中的水印
Stars: ✭ 373 (-58.74%)
Mutual labels:  watermark
Automatic Watermark Detection
Project for Digital Image Processing
Stars: ✭ 754 (-16.59%)
Mutual labels:  watermark
Densenet Tensorflow
DenseNet Implementation in Tensorflow
Stars: ✭ 580 (-35.84%)
Mutual labels:  densenet
Watermark Dom
watermark.js是基于DOM对象实现的BS系统的水印,确保系统保密性,安全性,降低数据泄密风险,简单轻量,支持多属性配置,动态计算水印,水印防被删(监听水印组件元素删除并重新添加,监听改变水印的属性并重新添加)。1、支持2种方式导入使用,2、水印插件-testTool(测试工具),3、内置3种全局API方法,等等。欢迎访问:
Stars: ✭ 695 (-23.12%)
Mutual labels:  watermark
Blind watermark
Blind Watermark (图片盲水印,提取水印无须原图!)
Stars: ✭ 441 (-51.22%)
Mutual labels:  watermark
Easywatermark
🔒 🖼 Securely, easily add a watermark to your sensitive photos. 安全、简单地为你的敏感照片添加水印,防止被小人泄露、利用
Stars: ✭ 519 (-42.59%)
Mutual labels:  watermark
Densenet.pytorch
A PyTorch implementation of DenseNet.
Stars: ✭ 684 (-24.34%)
Mutual labels:  densenet
Ocr densenet
第一届西安交通大学人工智能实践大赛(2018AI实践大赛--图片文字识别)第一名;仅采用densenet识别图中文字
Stars: ✭ 425 (-52.99%)
Mutual labels:  densenet
Keras Idiomatic Programmer
Books, Presentations, Workshops, Notebook Labs, and Model Zoo for Software Engineers and Data Scientists wanting to learn the TF.Keras Machine Learning framework
Stars: ✭ 720 (-20.35%)
Mutual labels:  densenet
Pytorch classification
利用pytorch实现图像分类的一个完整的代码,训练,预测,TTA,模型融合,模型部署,cnn提取特征,svm或者随机森林等进行分类,模型蒸馏,一个完整的代码
Stars: ✭ 395 (-56.31%)
Mutual labels:  densenet
Pytorch2keras
PyTorch to Keras model convertor
Stars: ✭ 676 (-25.22%)
Mutual labels:  densenet
Cifar 10 Cnn
Play deep learning with CIFAR datasets
Stars: ✭ 756 (-16.37%)
Mutual labels:  densenet
Imageai
A python library built to empower developers to build applications and systems with self-contained Computer Vision capabilities
Stars: ✭ 6,734 (+644.91%)
Mutual labels:  densenet
Densenet
DenseNet implementation in Keras
Stars: ✭ 693 (-23.34%)
Mutual labels:  densenet

Warning! The architecture used in this project does not generalize well. You may want to check https://dmitryulyanov.github.io/deep_image_prior. This inpainting technique will likely give you better results.

Fully convolutional watermark removal attack

Deep learning architecture to remove transparent overlays from images.

example

Top: left is with watermark, middle is reconstruction and right is the mask the algo predicts (the neural net was never trained using text or this image)

Bottom: Pascal dataset image reconstructions. When the watermarked area is saturated, the reconstruction tends to produce a gray color.

Design choices

At train time, I generate a mask. It is a rectangle with randomly generated parameters (height, width, opacity, black/white, rotation). The mask is applied to a picture and the network is trained to find what was added. The loss is abs(prediction, image_perturbations)**1/2. It is not on the entire picture. An area around the mask is used to make the problem more tractable.

The network architecture does not down-sample the image. The prediction with a down-sampling network were not accurate enough. To have a large enough receptive field and not blow up the compute, I use dilated convolution. So concretely, I have a densenet style block, a bunch of dilated convolutions and final convolution to output a picture (3 channels). I did not spend much time doing hyper-parameters optimization. There's room to get better results using the current architecture.

Limitations: this architectures does not generalize to watermarks that are too different from the one generated with create_mask and it produces decent results only when the overlay is applied in an additive fashion.

Usage

This project uses Tensorflow. Install packages withpip install -r requirements.txt

You will need the jpeg library to compile Pillow from source: sudo apt-get install libjpeg-dev zlib1g-dev

You will also need to download the pascal dataset (used by default) from http://host.robots.ox.ac.uk/pascal/VOC/voc2012/ or CIFAR10 python version from https://www.cs.toronto.edu/~kriz/cifar.html (use flag --dataset=dataset_cifar). Make sure the extract the pascal dataset under a directory called data. The project directory should then have the directory cifar-10-batches-py and/or data/VOCdevkit/VOC2012/JPEGImages. If you want to use your own images, place them in data/VOCdevkit/VOC2012/JPEGImages/.

To train the network python3 watermarks.py --logdir=save/. It starts to produce some interesting results after 12000 steps.

To use the network for inference, you can run python watermarks.py --image assets/cat.png --selection assets/cat-selection.png this will create a new image output.png.

Pretrained weights

Here you can find the weights: https://github.com/marcbelmont/cnn-watermark-removal/files/1594328/data.zip put them in /tmp/

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].