用另一種語言克隆語音和輸出語音。
建議使用Python 3.7。由於該項目中使用了TensorFlow的版本,因此需要Python 3.7。
python3 -m venv pyvenv
激活虛擬環境:Windows: ./pyvenv/Scripts/activate scripts/activate macos/linux: source pyvenv/bin/activate
停用虛擬環境: deactivate
注意:運行UI時,您的Python虛擬環境可能會引起問題。
安裝後,提取文件夾,然後將<ffmpeg folder path>/bin添加到路徑。
pip3 install -r requirements.txt
下載後,將模型(*.pt)添加到CogNative/CogNative/models/RTVC/saved_models/default
需要下載taco_pretrented文件夾(包括文件夾本身),並添加到CogNative/CogNative/models/RTVCSwedish/synthesizer/saved_models/swedish
credentials.json 。當前有一個名為credentials.json.template的文件,您的credentials.json應該匹配那裡顯示的鍵/值對。 從認知根目錄開始。
要啟動GUI,請運行python -m CogNative.testUI.UI
未指定的任何必要標誌將導致生成提示,這些提示必須在繼續之前回答。如下。
python -m CogNative.main -help CogNative CLI FLags:
-sampleAudio <PATH>: audio file of voice to clone
-synType <text, audio>: synthesis mode either given input text or by transcribing audio file
[-dialogueAudio] <PATH>: for audio synType, audio file of dialogue to speak
[-dialogueText] <PATH>: for text synType, text string of dialogue to speak
-out <PATH>: output audio file path
-useExistingEmbed <y/yes/n/no>: Uses saved embedding of previously used voice samples if enabled and present.
python -m CogNative.main -sampleAudio CogNative/examples/MatthewM66.wav -synType text -dialogueText "The turbo-encabulator has now reached a high level of development, and it's being successfully used in the operation of novertrunnions." -out cmdExampleText.wav -useExistingEmbed y Loaded encoder "english_encoder.pt" trained to step 1564501
Synthesizer using device: cuda
Building Wave-RNN
Trainable Parameters: 4.481M
Loading model weights at CogNativemodelsRTVCsaved_modelsdefaultvocoder.pt
Synthesizing...
Clone output to cmdExampleText.wav
python -m CogNative.main -sampleAudio CogNativeexamplesMatthewM66.wav -synType audio -dialogueAudio CogNativeexamplesBillMaher22.wav -out cmdExampleAudio.wav -useExistingEmbed n Loaded encoder "english_encoder.pt" trained to step 1564501
Synthesizer using device: cuda
Building Wave-RNN
Trainable Parameters: 4.481M
Loading model weights at CogNativemodelsRTVCsaved_modelsdefaultvocoder.pt
Loading requested file...
Synthesizing...
Clone output to cmdExampleAudio.wav
該腳本將將音頻從受支持的語言轉換為英語。要使用Windows上的自動轉換腳本,請將音頻文件拖放到腳本上,或將快捷方式放在%AppData%MicrosoftWindowsSendTo中,並使用“發送到“發送到”上下文菜單函數在音頻文件上。在這兩種情況下,一個帶有原始文件名的新的.WAV文件,然後將“ _ +目標語言”放置在同一文件夾中。對於其他平台,應使用相同的CLI標誌,但上下文菜單集成上的詳細信息將因安裝哪些軟件包而有所不同。
git branch yourname-feature-name此樣式指南對於確保整個項目中的所有樣式匹配非常重要。要設計您的代碼,請使用黑色Python Styler。
單文件: black <python-file-name>所有文件: black .
這個GitHub存儲庫是我們語音克隆模塊的基礎。
實時派遣
請參閱此處的許可證。
這個GitHub存儲庫訓練了瑞典合成器。
實時混合瑞典語