# Keras + Tensorflow CNN with multiple image inputs

I have a CNN that needs to take in 68 images that are all 59x59 pixels. The CNN should output 136 values on the output layer

My training data has shape (-1, 68, 59, 59, 1).

My current approach is to use concatenate to join multiple networks like so:

input_layer = [None] * 68
x = [None] * 68
for i in range(68):
input_layer[i] = tf.keras.layers.Input(shape=training_data.shape[1:][1:])
x[i] = Conv2D(64, (5,5))(input_layer[i])
x[i] = LeakyReLU(alpha=0.3)(x[i])
x[i] = MaxPooling2D(pool_size=(2,2))(x[i])
x[i] = Model(inputs=input_layer[i], outputs=x[i])

combined = concatenate(x)

However, this always gives the error:

ValueError: A Concatenate layer should be called on a list of at least 2 inputs

Is this approach a suitable approach or am I doing this completely wrong?

• Isn't this: shape=training_data.shape[1:][1:] the same for each loop? – Stephen Rauch Apr 7 '19 at 23:53