TypeError: lstm() received an invalid combination of arguments - got (Tensor, tuple, list, bool, int, float, bool, int, bool), but expected one of:
* (Tensor data, Tensor batch_sizes, tuple of Tensors hx, tuple of Tensors params, bool has_biases, int num_layers, float dropout, bool train, bool bidirectional)
didn't match because some of the arguments have invalid types: (Tensor, !tuple!, !list!, !bool!, !int!, !float!, !bool!, !int!, bool)
* (Tensor input, tuple of Tensors hx, tuple of Tensors params, bool has_biases, int num_layers, float dropout, bool train, bool bidirectional, bool batch_first)
didn't match because some of the arguments have invalid types: (Tensor, !tuple!, !list!, bool, int, float, bool, !int!, bool)
lstm更新到高版本之后,bidirectional参数不能使用int类型(0或1),要使用bool类型(False或True),要不会报上述错误。