Version keras = = 2.3.1

In keras==2.3.1, the LSTM algorithm you gave gave an error if _symbolic_scope. value: AttributeError: ‘_thread._local’ object has no attribute ‘value’

Solution:

Keras <2.3 is required hereConda install keras = = 2.2.4Copy the code
The corresponding tensorFlow version needs to be reduced to TensorFlow 1.xConda install tensorflow = = 1.15.0Copy the code
# If numpy>1.18.0, the version needs to be reduced to 1.16.xConda install numpy = = 1.16.0Copy the code