Getting Ready...

From Chapter 4, Convolutional Neural Network, you had learned that, as convolutional layers are added, the information passed to the next layer reduces in spatial extent, but in an autoencoder, the reconstructed image should be of the same size and depth as the input image. This implies that the decoder should somehow do both image resizing and convolution to reconstruct the original image. One way of increasing the spatial extent along with convolution is with the help of transposed convolution layers. These are easily implemented in TensorFlow by tf.nn.conv2d_transpose, but it was found that transposed convolution layers result in artefacts in the final image. Augustus Odena et al. [1], in their work, showed that these artefacts can be avoided by resizing the layers using either the nearest neighbour or bilinear interpolation (upsampling) followed by a convolutional layer. They achieved best results with nearest neighbour interpolation, implemented via tf.image.resize_images; we will follow the same approach here.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset