WeilunWang / semantic-diffusion-model

Official Implementation of Semantic Image Synthesis via Diffusion Models
214 stars 23 forks source link

How can I train for image-to-image translation? #13

Open minuenergy opened 1 year ago

minuenergy commented 1 year ago

I want to train photo to photo2 translation(without segmentation mask), How can I train?

I use this train script below

python image_train.py --data_dir data --dataset_mode ade20k --lr 1e-4 --batch_size 1 --attention_resolutions 32,16,8 --diffusion_steps 1000 --image_size 256 --learn_sigma True \ --noise_schedule linear --num_channels 256 --num_head_channels 64 --num_res_blocks 2 --resblock_updown True --use_fp16 False --use_scale_shift_norm True --use_checkpoint True --num_classes 1 \ --class_cond True--no_instance True

and encounter this errors

image

yug125lk commented 8 months ago

Hi, did you try it? How did you set the number of classes and this condition? --class_cond True