【问题标题】:LSTM layer output size vs. hidden state size in KERASLSTM 层输出大小与 KERAS 中的隐藏状态大小
【发布时间】:2019-10-04 09:27:07
【问题描述】:

我无法理解 LSTM 的概念并在 Keras 上使用它。在考虑 LSTM 层时,输出大小和隐藏状态大小应该有两个值。

1. hidden state size : how many features are passed across the time steps of a samples when training the model
2. output size       : how many outputs should be returned by particular LSTM layer

但是在keras.layers.LSTM中,只有一个参数,用来控制层的输出大小。

问题:

Therefore how hidden state size of the LSTM layer can be changed?

如果我被误解了,非常感谢更正。

【问题讨论】:

标签: tensorflow keras lstm recurrent-neural-network


【解决方案1】:

您对 LSTM 中隐藏单元和输出单元的区别感到困惑。请参阅以下链接以获得更清晰的信息:

https://jasdeep06.github.io/posts/Understanding-LSTM-in-Tensorflow-MNIST/

基本上,您在 num_units 中提供的只是 LSTM 隐藏单元的大小。这一点从这篇文章就很清楚了。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2017-07-27
    • 2020-11-13
    • 2019-03-15
    • 2018-01-20
    • 2018-07-07
    • 2018-10-16
    • 2018-01-25
    • 1970-01-01
    相关资源
    最近更新 更多