LSTMCell

class dragon.vm.torch.nn.LSTMCell(
  input_size,
  hidden_size,
  bias=True
)[source]

Apply a long short-term memory (LSTM) cell. [Hochreiter & Schmidhuber, 1997].

Examples:

m = torch.nn.LSTMCell(32, 64)
x = torch.ones(32, 256)
h1, c1 = m(x)

__init__

LSTMCell.__init__(
  input_size,
  hidden_size,
  bias=True
)[source]

Create a LSTMCell module.

Parameters:
  • input_size (int) The dimension of input.
  • hidden_size (int) The dimension of hidden state.
  • bias (bool, optional, default=True) True to use bias.