Skip to content

BlessMark: A Blind Diagnostically-Lossless Watermarking Framework for Medical Applications Based on Deep Neural Networks

License

Notifications You must be signed in to change notification settings

HamidrezaZarrabi/BlessMark

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BlessMark: A Blind Diagnostically-Lossless Watermarking Framework

Python 3.6 TensorFlow 1.13.1

Im1 Block diagram of BlessMark framework, composed of three separate modules for embedding of the watermark, extraction of the watermark, and recovery of the original cover image.

This repository contains the source code for the method described in the paper:

BlessMark: A Blind Diagnostically-Lossless Watermarking Framework for Medical Applications Based on Deep Neural Networks

Multimedia Tools and Applications, Springer, 2020
Hamidreza Zarrabi, Ali Emami, Pejman Khadivi, Nader Karimi, Shadrokh Samavi
[Paper]

Abstract: Nowadays, with the development of public network usage, medical information is transmitted throughout the hospitals. A watermarking system can help for the confidentiality of medical information distributed over the internet. In medical images, regions-of-interest (ROI) contain diagnostic information. The watermark should be embedded only into non-regions-of-interest (NROI) regions to keep diagnostically important details without distortion. Recently, ROI based watermarking has attracted the attention of the medical research community. The ROI map can be used as an embedding key for improving confidentiality protection purposes. However, in most existing works, the ROI map that is used for the embedding process must be sent as side-information along with the watermarked image. This side information is a disadvantage and makes the extraction process non-blind. Also, most existing algorithms do not recover NROI of the original cover image after the extraction of the watermark. In this paper, we propose a framework for blind diagnostically-lossless watermarking, which iteratively embeds only into NROI. The significance of the proposed framework is in satisfying the confidentiality of the patient information through a blind watermarking system, while it preserves diagnostic/medical information of the image throughout the watermarking process. A deep neural network is used to recognize the ROI map in the embedding, extraction, and recovery processes. In the extraction process, the same ROI map of the embedding process is recognized without requiring any additional information. Hence, the watermark is blindly extracted from the NROI. Furthermore, a three-layer fully connected neural network is used for the detection of distorted NROI blocks in the recovery process to recover the distorted NROI blocks to their original form. The proposed framework is compared with one lossless watermarking algorithm. Experimental results demonstrate the superiority of the proposed framework in terms of side information.

Motivation

Why this method exist while there are many watermarking methods? Since BlessMark method is:

  • A framework that can be used as a platform for applying a desired watermarking method.
  • A non-blind method which same ROI map is recognized in embedding and extraction processes.
  • A diagnostically lossless method which the NROI blocks recovered to their original state wherever possible.

Installation

This code was tested with tensorflow 1.13.1, python 3.6 and ubuntu 20.04.

1. Install Anaconda

To install Anaconda just follow the tutorial

2. Install Requirements

Just run it in the terminal

conda create -n BlessMark python=3.6
conda activate BlessMark
conda install -c anaconda tensorflow-gpu=1.13.1
git clone https://github.com/HamidrezaZarrabi/BlessMark.git
cd BlessMark
python -m pip install -r requirements.txt

3. Download Pretrain (optional)

To fair comparison, we recommend utilizing the pre-trained models if they are used for academic purpose. The link to the pretrained segmentation and classification models of Angiography dataset

Block Size6x68x810x10
Network
Segmentation
Classification
Segmentation
Classification
Segmentation
Classification

Inference

Just run it in the terminal. To perform embedding or extraction, use

python main.py

There are several arguments that must be used, which are

-data_path +str #Where to get the images for embedding/extraction
-image_size +nargs #Which size of image as [height, width, channel]
-process_name +str choices=['embedding', 'extraction'] #Embedding or extraction process
-coefficient +nargs #Which used DCT coefficients in our algorithm
-thresh +float #Which used threshold in our algorithm
-block_size +int #Which block size of image
-capacity +float #Capacity of watermarking as bit per pixel
-segmentation_model_path +str #Where to get the segmentation model
-classification_model_path +str #Where to get the classification model

For example, to embed watermark

python main.py -data_path workspace/img_orig -img_size 512 512 1 -process_name embedding -coef 6 7 -thresh 0.01 -blk_size 8 -cap 0.012 -seg_path workspace/segmentation_8x8

the watermarked image is saved in workspace/img_marked/ directory.
For example, to extract watermark and recovery original image

python main.py -data_path workspace/img_marked -img_size 512 512 1 -process_name extraction -coef 6 7 -thresh 0.01 -blk_size 8 -cap 0.012 -seg_path workspace/segmentation_8x8 -class_path workspace/classification_8x8

the recovered image is saved in workspace/img_recovered/ directory.

Results (From Pretrained models)

Some results on 22 images of Angiography dataset.

Block size6x68x8
Capacity (BPP) 0.022 0.012
PSNR of Watermarked Image (dB) 55.65 58.20
PSNR of Recovered Image (dB) 62.81 65.32
Improvement of PSNR(dB)7.16 7.12
PSNR of Watermarked Image NROI (dB) 55.48 57.99
PSNR of Recovered Image NROI (dB) 62.66 65.11
Improvement of NROI PSNR (dB)7.18 7.12
PSNR of Watermarked Image ROI (dB) 59.63 63.73
PSNR of Recovered Image ROI (dB)65.96 70.88
Improvement of ROI PSNR (dB)6.33 7.15

Citation

Please cite our paper if you find this repo useful in your research.

@article{Zarrabi_2020,
	doi = {10.1007/s11042-020-08698-9},
	url = {https://doi.org/10.1007%2Fs11042-020-08698-9},
	year = 2020,
	month = {may},
	publisher = {Springer Science and Business Media {LLC}},
	volume = {79},
	number = {31-32},
	pages = {22473--22495},
	author = {Hamidreza Zarrabi and Ali Emami and Pejman Khadivi and Nader Karimi and Shadrokh Samavi},
	title = {{BlessMark}: a blind diagnostically-lossless watermarking framework for medical applications based on deep neural networks},
	journal = {Multimedia Tools and Applications}
}

About

BlessMark: A Blind Diagnostically-Lossless Watermarking Framework for Medical Applications Based on Deep Neural Networks

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages