File size: 522 Bytes
c3702c9 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
import sys
from pathlib import Path
from synthesizer.inference import Synthesizer
from encoder import inference as encoder
from vocoder import inference as vocoder
project_name = "Real-Time-Voice-Cloning"
sys.path.append(project_name)
# Load the models
encoder.load_model(Path(project_name) / "encoder/saved_models/pretrained.pt")
synthesizer = Synthesizer(Path(project_name) / "synthesizer/saved_models/pretrained/pretrained.pt")
vocoder.load_model(Path(project_name) / "vocoder/saved_models/pretrained/pretrained.pt")
|