相对论的甘
它是什么?
此仓库具有相对论GAN的简单实现。 相对论修改了GAN目标,从而大大提高了训练的稳定性。
这两个目标是:
对于发电机培训步骤: err_d = (
torch.mean((y_real - torch.mean(y_gene) - 1) ** 2) +
torch.mean((y_gene - torch.mean(y_real) + 1) ** 2)
)
凡y_real是鉴别得分的真实数据和y_gene是鉴别得分假数据
对于鉴别器: err_g = (
torch.mean((y_real - torch.mean(y_gene) + 1) ** 2) +
torch.mean((y_gene - torch.mean(y_real) - 1) ** 2)
1