Trying to convert a simple CNN using tfjs. The model gets converted, however it does not get loaded in properly. Error: 'An InputLayer should be passed either a batchInputShape or an inputShape.'
tf.saved_model.save(model, 'my_model')
import tensorflowjs as tfjs
tfjs.converters.save_keras_model(model, 'tfjs')
I have tried converting the model from both .h5 and .keras formats. Sometimes I get a different error on the model configuration. A few months ago I converted some similar models and never had any problems. Anyone got an idea?
TensorFlow/Kerasmodel andtensorflowjs. To fix this, make sure model has a defined input shape and ensure you are using compatible versions.