GAN-tutorial
GAN-tutorial copied to clipboard
Train Backward 과정에서 오류
D_loss.backward() 에서 'one of the variables needed for gradient computation has been modified by an inplace operation' 라는 runtime error가 발생합니다. 어떻게 해결하면 될까요?
Generator와 Discriminator class에서 LeakyReLU와 Dropout의 parameter인 inplace = True를 모두 지우면 됩니다.
만약 data[1] 부분에서 다시 오류가 발생하면, data[1]->data로 바꿔주시면 됩니다