December 2018
Beginner to intermediate
684 pages
21h 9m
English
The insights from Chapter 17, Convolutional Neural Networks, suggest we incorporate convolutional layers into the autoencoder to extract information characteristic of the grid-like structure of image data.
We define a three-layer encoder that uses 2D convolutions with 32, 16, and 8 filters, respectively, ReLU activations, and 'same' padding to maintain the input size. The resulting encoding size at the third layer is 4 x 4 x 8 = 128, higher than for the preceding examples:
x = Conv2D(filters=32, kernel_size=(3, 3), activation='relu', padding='same', name='Encoding_Conv_1')(input_)x = MaxPooling2D(pool_size=(2, 2), padding='same', name='Encoding_Max_1')(x)x = Conv2D(filters=16, kernel_size=(3, 3), activation='relu', ...