How to handle inputs with variable length
Hi @wiseodd, thanks for your open-source code. I find the forward_encoder_embed function in the model.py module cannot support inputs with variable length. In your code, it seems that you assume that each of the input sentences is of length max_sent_len 15, as you alway use the last hidden state to encode the paded sentence.
Hi @wiseodd, thanks for your open-source code. I find the
forward_encoder_embedfunction in themodel.pymodule cannot support inputs with variable length. In your code, it seems that you assume that each of the input sentences is of lengthmax_sent_len 15, as you alway use the last hidden state to encode the paded sentence.
Hi! Have you figured out how to handle inputs with variable length? I run into the same problem.