Subsequent convolution layers
I think I found the reason: the correct description of the 2nd layer is:


for the 2nd layer:


input size: (1, 26, 26, 32)   
weights size: (3, 3, 32, 64)
output size: (1, 24, 24, 64)



So for each one of the 64 features, the (26,26,32) input is convoled with a (3,3,32)-sized kernel, producing a (24,24) output.

Since this is for each one of the 64 features, the output will finally be (1, 24, 24, 64).



Code to display the shape of the weights:

for l in model.layers:
    if len(l.get_weights()) &gt; 0:
        print(l.get_weights()[0].shape)        # ...[1].shape  would be for the biases