What is the right shape for the quantization accuracy data?
Sorry if this question is basic, but I was not able to find an answer in the documentation. I have a very simple Keras model with one input and one output, for your reference the architecture is:
model = tf.keras.Sequential()
model.add(tf.keras.layers.Dense(16, activation='relu', input_shape=(1,)))
model.add(tf.keras.layers.Dense(16, activation='relu'))
model.add(tf.keras.layers.Dense(1))
I have two vectors x_test and y_test with shape (200,), the same shape of my validation arrays used during the training phase, and I saved a .npz dataset to quantize the network as follows:
np.savez('testdata.npz',x_test=x_test,y_test=y_test)
I am using the STM32.AI developer cloud to quantize the network. Quantization fails, and the log displays the message:
Executing with: {'model': '...
Converting original model to TFLite...
cannot reshape array of size 200 into shape (1,1)
So apparently the problem is the shape of the data in the .npz file. Which shape should have the test vectors in the .npz file?
Best,
Pietro
