you can use theano or tensorflow as your backend deep learning framework for keras to work on am using tensorflow in this scenario let' build basic two-layer cnn now with max pooling layer between them in [ ]model sequential(model add(conv ( ( )input_shape=( )activation='relu'kernel_initializer='glorot_uniform')model add(maxpooling (pool_size=( ))model add(conv ( ( )activation='relu'kernel_initializer='glorot_uniform')we can actually visualize this network architecture using the following code snippet to understand the layers that have been used in this networkin better way in [ ]from ipython display import svg from keras utils vis_utils import model_to_dot svg(model_to_dot(modelshow_shapes=trueshow_layer_names=truerankdir='tb'create(prog='dot'format='svg')figure - visualizing our two-layer convolutional neural network architecture you can now understand from the depiction in figure - that we are using two two-dimensional convolutional layers containing four ( filters we also have max pool layer between them of size ( for some downsampling let' now build some functions to extract features from these intermediate network layers