摘要: rnn = nn.RNN(input_size=4,hidden_size=3,num_layers=2,batch_first=True, bidirectional = True) input = torch.randn(1,5,4) output , h_n = rnn(input) prin 阅读全文
posted @ 2022-04-25 09:04 华小电 阅读(311) 评论(0) 推荐(0) 编辑
摘要: batch_first – If True, then the input and output tensors are provided as (batch, seq, feature) instead of (seq, batch, feature). Note that this does n 阅读全文
posted @ 2022-04-25 08:49 华小电 阅读(607) 评论(0) 推荐(0) 编辑