I have a sequence to sequence model for text summarization like this:
model = Model([encoder_inputs, decoder_inputs], decoder_dense)
I fit it accordingly:
history = model.fit([x_tr, y_tr],y_tr.reshape(y_tr.shape, y_tr.shape, 1), epochs= ..)
The model fits successfully, but how do I use
model.predict() ? If I only pass
model.predict(x_test), it says 2 inputs expected. However, if I do
model.predict([x_test, y_test]), I get the predictions.
It feels wrong to have
model.predict(). What is happening here? How do I use model.predict() in such a seq2seq model ?
From this keras tutorials, I see that you should not directly invoke
model.predict() but create a inference model but I want to understand what is going on in the case I mentioned above and why does
model.predict() only works if I provide