def critic(self, real_pred, input):
        "Create some `fake_pred` with the generator from `input` and compare them to `real_pred` in `self.loss_funcD`."
        fake = self.gan_model.generator(input.requires_grad_(False)).requires_grad_(True)
        fake_pred = self.gan_model.critic(fake)
        return self.loss_funcC(real_pred, fake_pred)
def critic ( self , real_pred , input ) : fake = self . gan_model . generator ( input . requires_grad_ ( False ) ) . requires_grad_ ( True ) fake_pred = self . gan_model . critic ( fake ) return self . loss_funcC ( real_pred , fake_pred )
Create some `fake_pred` with the generator from `input` and compare them to `real_pred` in `self.loss_funcD`.