Skip to content
This repository has been archived by the owner on Sep 8, 2023. It is now read-only.

lstm中,定义input=Input((None,embedding))时,和定义input=Input((seq_len,embedding))区别 #89

Open
yhx0105 opened this issue May 17, 2020 · 0 comments

Comments

@yhx0105
Copy link

yhx0105 commented May 17, 2020

输入:x_train=np.random.random((32,30,300)) y_train=np.random.randint(2,size=(32,30,1))
模型A:inputs=Input(shape=(None,300)) lstm=LSTM(40,return_sequences=True)(inputs) outer=TimeDistributed(Dense(1,activation='sigmoid'))(lstm)
模型B:‘inputs=Input(shape=(30,300))
lstm=LSTM(40,return_sequences=True)(inputs)
outer=TimeDistributed(Dense(1,activation='sigmoid'))(lstm)’
二者都不会报错,请问准确率各方面有什么区别吗?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant