With Keras, I defined,
conv = Convolution2D(num_filters, ws, ws)(x)
,
where I have the shape of x
be (1, ?, 10, 1)
And I met the problem with
TypeError: unsupported operand type(s) for *: 'NoneType' and 'int'
Since the convolutional weight matrices applied on each window of the 2D image share parameters, it is valid at least for me to do it without knowing the true dimension of the image.