Closed YangHaha11514 closed 4 years ago
def forward( self, h: FloatTensor, labels: LongTensor, mask: BoolTensor ) -> FloatTensor: """ :param h: hidden matrix (seq_len, batch_size, num_labels) :param labels: answer labels of each sequence in mini batch (seq_len, batch_size) :param mask: mask tensor of each sequence in mini batch (seq_len, batch_size) :return: The log-likelihood (batch_size) """
In the annotation of this function, the shape of param h\labels\mask should be (batch_size,seq_len,)
h\labels\mask
(batch_size,seq_len,)
@YangHaha11514 Thank you for discovering annotation misses. If you don't mind, you can fix its and make pull requests ?
In the annotation of this function, the shape of param
h\labels\mask
should be(batch_size,seq_len,)