https://www.cnblogs.com/ryukirin/p/14587520.html
感觉不太对
#num_layers
#可以看到,x就还是`(batch_size,seq,input_size=)`的形式,要设置为batch_first=True
import torch.nn as nn
import torch
x = torch.rand(10,24,100)
#torch.nn.lstm(input_size=100,hidden_size=16,num_layers=2)
#输入维度100,h维度16,lstm层数2
#以训练句子为例子,假如每个词是100维的向量,每个句子含有24个单词,一次训练10个句子。
#那么batch_size=10,seq=24,input_size=100。(seq指的是句子的长度,input_size作为一个x_t<