avinsit123 / keyphrase-gan

Code for the AAAI 2020 paper "Keyphrase Generation for Scientific Articles using GANs"

Home Page:https://aaai.org/ojs/index.php/AAAI/article/view/7238

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Which specific model to use as generator?

peppe69 opened this issue · comments

I'm trying to reproduce your work, I trained the CatSeq model using the code of the original project by Hou Pong Chan and Wang Chen and Lu Wang and Irwin King (here: https://github.com/kenchan0226/keyphrase-generation-rl ), but when I run your project to train Discriminator it raises this error:

RuntimeError: Error(s) in loading state_dict for Seq2SeqModel:
	Missing key(s) in state_dict: "decoder.p_gen_linear.weight", "decoder.p_gen_linear.bias". 

Maybe I used the wrong model?

Have you used the -copy_attention flag in both the training the Generator and the Discriminator. It seems that you haven't used the -copy_attention flag while training the generator.

Oh yes, now it works. Thank you so much!