williamSYSU / TextGAN-PyTorch

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

How to add new Datasets and generate valid output #36

Open achowdhary89 opened 4 years ago

achowdhary89 commented 4 years ago

Dear Dev Team,

I am using seq_gan model for generating text sequence. I am trying to use list of valid "subdomains" as input and generate new "text" as output. I am making changes in run/run_seqgan.py, and adding dataset that I want as input - datasets/subdomains.txt.

I am getting generated output is numeric data. I used text as input, but output seems in numeric form. Am I missing something here, in terms of configuration or code changes ??

ubuntu@ip-XXXXX:~/TextGAN-PyTorch/save/20200625/subdomains/seqgan_vanilla_lt-rsgan_sl20_temp1_T0625_1930_08/samples$ vim samples_ADV_00001.txt 3197 2049 2875 3903 2649 2338 116 4714 4111 638 3665 3782 4722 2049 2467 4123 2560 2823 224 3468 1961 4136 2923 595

mnavaidd commented 3 years ago

The reason why the generated samples of program are some numbers is because you ran the program with synthetic data. You need to change the parameters (in config.py) as if_real_data=True and dataset='image_coco' (or others real datasets).