• Home
  • Raw
  • Download

Lines Matching full:lstm

72   // Expect the LSTM to have 64 outputs and 3 layers, with an input of batch  in check_lstm_sizes()
103 // Expect the LSTM to have 32 outputs and 3 layers, with an input of batch in check_lstm_sizes_proj()
134 LSTM model(LSTMOptions(128, 64).num_layers(3).dropout(0.2)); in TEST_F()
161 LSTM model(LSTMOptions(128, 64).num_layers(3).dropout(0.2).proj_size(32)); in TEST_F()
190 LSTM model(2, 2); in TEST_F()
260 ASSERT_TRUE(test_RNN_xor<LSTM>( in TEST_F()
261 [](int s) { return LSTM(LSTMOptions(s, s).num_layers(2)); })); in TEST_F()
265 ASSERT_TRUE(test_RNN_xor<LSTM>([](int s) { in TEST_F()
266 return LSTM(LSTMOptions(s, s).num_layers(2).proj_size(s / 2)); in TEST_F()
289 LSTM model(LSTMOptions(128, 64).num_layers(3).dropout(0.2)); in TEST_F()
318 LSTM model(LSTMOptions(128, 64).num_layers(3).dropout(0.2).proj_size(32)); in TEST_F()
346 ASSERT_TRUE(test_RNN_xor<LSTM>( in TEST_F()
347 [](int s) { return LSTM(LSTMOptions(s, s).num_layers(2)); }, true)); in TEST_F()
351 ASSERT_TRUE(test_RNN_xor<LSTM>( in TEST_F()
353 return LSTM(LSTMOptions(s, s).num_layers(2).proj_size(s / 2)); in TEST_F()
380 c10::str(LSTM(LSTMOptions(128, 64).num_layers(3).dropout(0.2))), in TEST_F()
381 …"torch::nn::LSTM(input_size=128, hidden_size=64, num_layers=3, bias=true, batch_first=false, dropo… in TEST_F()
384 LSTM(LSTMOptions(128, 64).num_layers(3).dropout(0.2).proj_size(32))), in TEST_F()
385 …"torch::nn::LSTM(input_size=128, hidden_size=64, num_layers=3, bias=true, batch_first=false, dropo… in TEST_F()
496 // Reverse forward of bidirectional LSTM should act
497 // as regular forward of unidirectional LSTM
508 LSTM bi_lstm{lstm_opt.bidirectional(true)}; in BidirectionalLSTMReverseForwardTest()
509 LSTM reverse_lstm{lstm_opt.bidirectional(false)}; in BidirectionalLSTMReverseForwardTest()
516 // Now make sure the weights of the reverse lstm layer match in BidirectionalLSTMReverseForwardTest()
536 // The hidden states of the reversed LSTM sits in BidirectionalLSTMReverseForwardTest()
613 LSTM lstm_cpu{opt}; in TEST_F()
614 LSTM lstm_cuda{opt}; in TEST_F()
616 // Copy weights and biases from CPU LSTM to CUDA LSTM in TEST_F()
628 // Move LSTM to CUDA in TEST_F()
670 LSTM lstm_cpu{opt}; in TEST_F()
671 LSTM lstm_cuda{opt}; in TEST_F()
673 // Copy weights and biases from CPU LSTM to CUDA LSTM in TEST_F()
685 // Move LSTM to CUDA in TEST_F()
741 auto m = LSTM(2, 3); in TEST_F()
752 // Test passing optional argument to `LSTM::forward_with_packed_input` in TEST_F()
787 ASSERT_THROWS_WITH(LSTM(options), "hidden_size must be greater than zero"); in TEST_F()
790 ASSERT_THROWS_WITH(LSTM(options), "num_layers must be greater than zero"); in TEST_F()