aymericdamien / TensorFlow-Examples

TensorFlow Tutorial and Examples for Beginners (support TF v1 & v2)
Other
43.38k stars 14.95k forks source link

delete of matmul for hidden weights #45

Open 987410 opened 8 years ago

987410 commented 8 years ago

HI, I note that in your updated code, you deleted _X = tf.matmul(_X, _weights['hidden']) + _biases['hidden'], and reshpae as n_steps * (batch_size, input_dim) instead of n_steps * (batch_size, n_hidden)

Why did you do this? Thanks

aymericdamien commented 8 years ago

Are you talking about RNN model? It was to make the example more clear, it wasn't necessary.

987410 commented 8 years ago

Yes, I mean bidi_lstm.

'n_hidden' means the number of hidden layers, what is it used to ? what's the difference if i set 'n_hidden' as 128 or 1024? (for example, in CNN, n_hidden mean in each convolutional layer, there are n_hidden filters)

Thanks

aymericdamien commented 8 years ago

It means the number of hidden units, you can set it to any value! The larger the slower your model will be, but the more information you can keep in your layer.