facebookresearch / audioseal

Localized watermarking for AI-generated speech audios, with SOTA on robustness and very fast detector
MIT License
407 stars 47 forks source link

loading fine-tuned weight #45

Open DanMerry opened 1 month ago

DanMerry commented 1 month ago

Hello, I have a problem. After fine-tuning the generator and saving the model, I obtained a .pth file. When importing the model using generator = AudioSeal.load_generator('./checkpoints/generator_model_best_val_loss_20240727141622.pth').to(device), I encountered the following issues. How can I correctly load the weights? image

antoine-tran commented 1 month ago

@DanMerry Sorry for the delayed response. Could you tell me how you saved the model ?

Did you save it with the scripts checkpoints.py as shown in this PR ?