在运行文章 ‘High-Resolution Image Synthesis with Latent Diffusion Models’的代码时,出现了以下报错:
RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation
解决思路:
在模块CrossAttention中 有一个参数is_inplace,将其改为False即可正常运行