sgan icon indicating copy to clipboard operation
sgan copied to clipboard

'NoneType' object is not subscriptable

Open fengxianghu opened this issue 3 years ago • 7 comments

I have met the problem, when I run my the train.py.

Traceback (most recent call last): File "train.py", line 595, in main(args) File "train.py", line 160, in main batch_norm=args.batch_norm) File "/content/gdrive/MyDrive/SGAN/sgan/models.py", line 492, in init if self.noise_dim[0] == 0: TypeError: 'NoneType' object is not subscriptable

Has any friend met this problem and solved it?

fengxianghu avatar Mar 15 '21 08:03 fengxianghu

Friend, I have the same problem. Have you solved it now?

rjycty avatar Mar 22 '21 13:03 rjycty

Friend, I have the same problem. Have you solved it now?

I remember I have solved this problem with a answer under a previous issue. You can try it.

fengxianghu avatar Mar 22 '21 15:03 fengxianghu

Thanks!

rjycty avatar Mar 23 '21 10:03 rjycty

how did you solve it? I got same problem= = I think it is about the size of noise, but I do not totally understand how noise works.

cghaon avatar Mar 29 '21 00:03 cghaon

how did you solve it? I got same problem= = I think it is about the size of noise, but I do not totally understand how noise works.

train.py line53 (It may not be line 53, but it must contain '--noise_dim' ) change None to (0,)

rjycty avatar Apr 01 '21 06:04 rjycty

Try to change the codes image to image It will work and you can use '--noise_dim' option. If I'm wrong, just tell me. I'm a junior.

Mogalipen avatar May 07 '22 19:05 Mogalipen

how did you solve it? I got same problem= = I think it is about the size of noise, but I do not totally understand how noise works.

train.py line53 (It may not be line 53, but it must contain '--noise_dim' ) change None to (0,)

It is line 52 actually.

neugzy avatar Feb 29 '24 12:02 neugzy