williamSYSU / TextGAN-PyTorch

TextGAN is a PyTorch framework for Generative Adversarial Networks (GANs) based text generation models.
MIT License
870 stars 205 forks source link

Sentigan generates repetitive samples #49

Open BJavid opened 3 years ago

BJavid commented 3 years ago

Hi I run sentigan with my dataset. It has 48000 recoeds. After 150 epochs for MLE training and 1000 epochs for ADV training, sentigan generate repetitive samples. Why?

vendrick17 commented 3 years ago

Hi, I had the same issue, maybe you are overtraining the discriminator during the pretraining, it usually leads to mode collapse, try to reduce the number of epochs while pretraining the discriminator, if it doesn't fix the problem I suggest to use the original repository https://github.com/Nrgeup/SentiGAN, it worked perfectly for me.

BJavid commented 3 years ago

@vendrick17 Hi, Thank you for answering. I think try run it with fewer epochs but it doesn't fix the problem. The original repository is for 1 class datasets. I have a dataset with positive and negative classes.

congpx commented 4 weeks ago

Hi I run sentigan with my dataset. It has 48000 recoeds. After 150 epochs for MLE training and 1000 epochs for ADV training, sentigan generate repetitive samples. Why?

I have the same problems too. Begin at epoch 5, the ADV sample shows the same sentence as below:

the film is a lot of . the film is a movie . the film is a lot of . the film is a lot of . the film is a lot of . the film is a movie ." ...

Mr @BJavid, have you fix it yet?

Beside, I have tried to run the original code [https://github.com/Nrgeup/SentiGAN], but it is build on TensorFlow v1, but at this moment, I have only TensorFlow v2 installed with Python 3.9, so there are lots of errors issued. What can I do?

BJavid commented 4 weeks ago

Hi No i can't. I run the original code and install TensorFlow and other packages on a new environment (pycharm). The orginal code works with one class (k=1). Good Luck

congpx commented 3 weeks ago

Hi No i can't. I run the original code and install TensorFlow and other packages on a new environment (pycharm). The orginal code works with one class (k=1). Good Luck

@BJavid Hi, I guess it's because the amount of training data is too little that leads to this situation. I would like to include more practical data. Have you tried bringing in other real data? Can you guide me? Thank you.