sequence_input = Input(shape=(max_len,), dtype="int32")
embedded_sequences = Embedding(vocab_size, 128, input_length=max_len,
mask_zero=True)(sequence_input)
lstm = Bidirectional(LSTM(64, dropout=0.5, return_sequences=True))(embedded_sequences)
The third line of code gives the following error:
Cannot convert a symbolic Tensor (bidirectional/forward_lstm/strided_slice:0) to a numpy array.
This error may indicate that you're trying to pass a Tensor to a NumPy call, which is not supported
When I was looking for a solution to the same error as me, I saw a lot of answers on stackoverflow telling me to lower the numpy version to less than 1.20.
But since I use featuretools, I need to set the numpy version to 1.2 or higher.
So, my question is, is there currently no way to fix this error without downgrading the numpy version?
(my tensorflow version is 2.3.0, numpy version is 1.23)