python inference.py --checkpoint_path checkpoints/disc_checkpoint_step000000001.pth --face sample_data/foto.png --audio sample_data/audio.wav
Traceback (most recent call last):
File "/kaggle/working/wav2lip/inference.py", line 280, in
main()
File "/kaggle/working/wav2lip/inference.py", line 252, in main
model = load_model(args.checkpoint_path)
File "/kaggle/working/wav2lip/inference.py", line 176, in load_model
model.load_state_dict(new_s, strict=False)
File "/opt/conda/lib/python3.10/site-packages/torch/nn/modules/module.py", line 2152, in load_state_dict
raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format(
RuntimeError: Error(s) in loading state_dict for Wav2Lip:
size mismatch for face_encoder_blocks.0.0.conv_block.0.weight: copying a param with shape torch.Size([32, 3, 7, 7]) from checkpoint, the shape in current model is torch.Size([16, 6, 7, 7]).
size mismatch for face_encoder_blocks.0.0.conv_block.0.bias: copying a param with shape torch.Size([32]) from checkpoint, the shape in current model is torch.Size([16]).
size mismatch for face_encoder_blocks.1.0.conv_block.0.weight: copying a param with shape torch.Size([64, 32, 5, 5]) from checkpoint, the shape in current model is torch.Size([32, 16, 3, 3]).
size mismatch for face_encoder_blocks.1.0.conv_block.0.bias: copying a param with shape torch.Size([64]) from checkpoint, the shape in current model is torch.Size([32]).
size mismatch for face_encoder_blocks.1.1.conv_block.0.weight: copying a param with shape torch.Size([64, 64, 5, 5]) from checkpoint, the shape in current model is torch.Size([32, 32, 3, 3]).
size mismatch for face_encoder_blocks.1.1.conv_block.0.bias: copying a param with shape torch.Size([64]) from checkpoint, the shape in current model is torch.Size([32]).
size mismatch for face_encoder_blocks.2.0.conv_block.0.weight: copying a param with shape torch.Size([128, 64, 5, 5]) from checkpoint, the shape in current model is torch.Size([64, 32, 3, 3]).
size mismatch for face_encoder_blocks.2.0.conv_block.0.bias: copying a param with shape torch.Size([128]) from checkpoint, the shape in current model is torch.Size([64]).
size mismatch for face_encoder_blocks.2.1.conv_block.0.weight: copying a param with shape torch.Size([128, 128, 5, 5]) from checkpoint, the shape in current model is torch.Size([64, 64, 3, 3]).
size mismatch for face_encoder_blocks.2.1.conv_block.0.bias: copying a param with shape torch.Size([128]) from checkpoint, the shape in current model is torch.Size([64]).
size mismatch for face_encoder_blocks.3.0.conv_block.0.weight: copying a param with shape torch.Size([256, 128, 5, 5]) from checkpoint, the shape in current model is torch.Size([128, 64, 3, 3]).
size mismatch for face_encoder_blocks.3.0.conv_block.0.bias: copying a param with shape torch.Size([256]) from checkpoint, the shape in current model is torch.Size([128]).
size mismatch for face_encoder_blocks.3.1.conv_block.0.weight: copying a param with shape torch.Size([256, 256, 5, 5]) from checkpoint, the shape in current model is torch.Size([128, 128, 3, 3]).
size mismatch for face_encoder_blocks.3.1.conv_block.0.bias: copying a param with shape torch.Size([256]) from checkpoint, the shape in current model is torch.Size([128]).
size mismatch for face_encoder_blocks.4.0.conv_block.0.weight: copying a param with shape torch.Size([512, 256, 3, 3]) from checkpoint, the shape in current model is torch.Size([256, 128, 3, 3]).
size mismatch for face_encoder_blocks.4.0.conv_block.0.bias: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([256]).
size mismatch for face_encoder_blocks.4.1.conv_block.0.weight: copying a param with shape torch.Size([512, 512, 3, 3]) from checkpoint, the shape in current model is torch.Size([256, 256, 3, 3]).
size mismatch for face_encoder_blocks.4.1.conv_block.0.bias: copying a param with shape torch.Size([512]) from checkpoint, the shape in current model is torch.Size([256]).
size mismatch for face_encoder_blocks.5.0.conv_block.0.weight: copying a param with shape torch.Size([512, 512, 3, 3]) from checkpoint, the shape in current model is torch.Size([512, 256, 3, 3]).