官方GitHub代码:“Fixed Neural Network Steganography: Train the images, not the network” (ICLR 2022)

需要使用steganogan的环境跑代码,要求pytorch是1.0.0版本

  1. 下载源代码和提供的权重文件
  2. 打开demo.ipynb,导包
  3. 注意 num_bitsmodel_path中的steg要对应
    在这里插入图片描述
  4. 报错AttributeError: 'Adam' object has no attribute 'defaults' 是因为pytorch版本不对应导致的,pytorch1.0.0版本就没问题
  5. FNNS Optimization那节代码中,还有一个报错提示optim的view要改成reshape,在torch源码中改了就好了

依赖环境可参考SteganoGAN:https://blog.csdn.net/qq_40859587/article/details/121795461#comments_23716355

Logo

一站式 AI 云服务平台

更多推荐