添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement . We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Older diffusion models won't work anymore, for example using models/ldm/text2img256/config.yaml and its corresponding checkpoint.
Using the text2img256 model checkpoint, the command line was: python3 scripts/txt2img.py --ckpt="model.ckpt" --config="models/ldm/text2img256/config.yaml"

Leading to a tensor mismatch:

  File "/home/simon/anaconda3/envs/ldm/lib/python3.8/site-packages/torch/nn/modules/conv.py", line 443, in _conv_forward
    return F.conv2d(input, weight, bias, self.stride,
RuntimeError: Given groups=1, weight of size [192, 3, 3, 3], expected input[6, 4, 64, 64] to have 3 channels, but got 4 channels instead

Probably a batch size extra dimension?

happens same to me with the recent v.1.4 model and command:

python scripts/txt2img.py --prompt "a photograph of an astronaut riding a horse" --plms
        size mismatch for first_stage_model.post_quant_conv.bias: copying a param with shape torch.Size([3]) from checkpoint, the shape in current model is torch.Size([4]).