摘要: 转自:https://blog.csdn.net/qq_34218078/article/details/109591000 1.先D后G 1.1 不detach,但需要retain_graph=True 1.2 detach 2.先G后D 有些奇怪的方法,但可用。 因为 generator 的更新 阅读全文
posted @ 2021-12-19 17:25 lypbendlf 阅读(1328) 评论(0) 推荐(0) 编辑
摘要: 转自:https://blog.csdn.net/waitingwinter/article/details/105774720 1.对输入变量求导 要用到输出值对输入变量(不是Weights和Biases)求导,可以用pytorch 中的autograd.grad() 函数实现。 autograd 阅读全文
posted @ 2021-12-19 16:51 lypbendlf 阅读(227) 评论(0) 推荐(0) 编辑
摘要: 1.安装cuda https://developer.nvidia.cn/cuda-downloads,可查看安装版本: 下载 安装: wget https://developer.download.nvidia.com/compute/cuda/11.5.1/local_installers/cu 阅读全文
posted @ 2021-12-19 00:07 lypbendlf 阅读(405) 评论(0) 推荐(0) 编辑