“Kai Zhang, Wangmeng Zuo, Yunjin Chen, Deyu Meng, Lei Zhang, Beyond a Gaussian Denoiser: Residual Learning of Deep CNN for Image Denoising, IEEE Trans. on Image Processing, 2017”
DnCNNs: feed-forward denoising convolutional neural networks
Code
def dncnn(input, is_training=True, output_channels=1):
with tf.variable_scope('block1'):
output = tf.layers.conv2d(input, 64, 3, padding='same', activation=tf.nn.relu)
## (i) Conv+ReLU: for the first layer
# 64 filters of size 3*3*c are used to generate 64 feature maps
# zero padding to avoid boundary artifacts
# utilize rectified linearunits (ReLU, max(0; ·)) to introduce nonlinearity
for layers in xrange(2, 16 + 1):
with tf.variable_scope('block%d' % layers):
output = tf.layers.conv2d(output, 64, 3, padding='same', name='conv%d' % layers, use_bias=False)
output = tf.nn.relu(tf.layers.batch_normalization(output, training=is_training))
## (ii) Conv+BN+ReLU: for layers 2 ~ (D - 1)
# 64 filters of size 3*3*64
# batch normalization is added between convolution and ReLU
with tf.variable_scope('block17'):
output = tf.layers.conv2d(output, output_channels, 3, padding='same')
## (iii) Conv: for the last layer
# c filters of size 3*3*64 are used to reconstruct the output
## output is residual image; return is (input-output) = predicted clean image
return input - output
网络结构说明: