titu1994 / Keras-IndRNN

Implementation of IndRNN in Keras
MIT License
67 stars 34 forks source link

ImportError: cannot import name '_generate_dropout_ones' #3

Closed rorycawley closed 5 years ago

rorycawley commented 6 years ago

I'm using Keras 2.1.5 but i am getting this error when I try to run IndRNN:

ImportError Traceback (most recent call last)

in () 11 from keras.legacy import interfaces 12 from keras.layers import RNN ---> 13 from keras.layers.recurrent import _generate_dropout_mask, _generate_dropout_ones 14 15 class IndRNNCell(Layer): ImportError: cannot import name '_generate_dropout_ones'
kepengxu commented 6 years ago

I also find this problem,and can't find solutionfor it

kepengxu commented 6 years ago

I find the reason of this problem is keras2.1.6 remove _gemerate_dropout_ones,and it out of index

ctudoudou commented 6 years ago

I think u can try using keras2.1.5, that can run.

MaximumEndurance commented 5 years ago

generate_dropout_ones has been depreciated and K.ones_like() is used in turn. Refer issue #9892 in keras. Changes have already been made in the code and this issue might now be closed if you deem fit. @titu1994