何も分からなかった頃のメモ:rvc

links
youtube投稿
- ダダパンver: https://www.youtube.com/watch?v=OkcDu2l3PpY&t=74s
- 上の人のchのメモ: https://child-programmer.com/ai-voice-change-tutorial-v2/#RVC_v2RVC_WebUI_8211_AI_RVC_v2_model_Edition_RVC_WebUI_8211_AI_Voice_Changer_Tutorial
- 実際に配信利用されてる方のch: https://www.youtube.com/@yumeno_momonose/streams
rvcのvstプラグインがあると便利。現状はなさそう。できればその作成に貢献したい
配信用tips
- ピッチ調整vst GRAILLON 2: https://vst-joho.com/auburn_sounds_graillon_2/

windows10 環境構築(webui-user.bat)はまりどころ
- visual stadio installerでcpp 14以上を入れておく
- python3.10である必要(3.11じゃだめ)
1
Installing requirements
Traceback (most recent call last):
File "C:\Users\darai0512\Downloads\rvc-webui\launch.py", line 138, in <module>
prepare_environment()
File "C:\Users\darai0512\Downloads\rvc-webui\launch.py", line 119, in prepare_environment
run(
File "C:\Users\darai0512\Downloads\rvc-webui\launch.py", line 36, in run
raise RuntimeError(message)
...
(omission)
...
error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for fairseq
error: subprocess-exited-with-error
Building wheel for pyworld (pyproject.toml) did not run successfully.
exit code: 1
[29 lines of output]
C:\Users\darai0512\AppData\Local\Temp\pip-build-env-j852msb5\overlay\Lib\site-packages\setuptools\dist.py:498: SetuptoolsDeprecationWarning: Invalid dash-separated options
!!
...(omission)...
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pyworld
ERROR: Could not build wheels for fairseq, pyworld, which is required to install pyproject.toml-based projects
2
...
ValueError: mutable default <class ‘fairseq.dataclass.configs.CommonConfig’> for field common is not allowed: use default_factory

zenn、投稿可能な長さがあまりに短すぎ、、、

以下終わらず
sampling rate = 48k
v2
cpu threads = 12
学習用データ ずんだもんコーパス 1.5Mb * 4600ファイル
rmvpe_gpu
save per epoch = 15
total epoch = 100
GPU batch size = 15
no
cache = yes <- これがあやしい
no

配信Tips
cubase
input=自分のmic
output=Vertual Audio Cable
とすべきだが、テスト目的で
output=ヘッドフォン
としてから上に切り替えるとinputのモニタリングができなくなる。

配信Tips
VACは有料版ならLineはVirtual Audio Cable Control Panelから複数本作れる。
VB-Cableも寄付で増やせる。
なので例えば、OBSでマイクをモニターのみ出力させ、マイクのフィルタでStudioRack+rx 10などでノイズキャンセリングし、モニター出力をLine1に流し、Line1をinputでAIボイチェンクライアントに流し、outputをLine2、OBSの音声入力キャプチャでLine2を流す、とか可能。
(AIボイチェンクライアントをvstプラグイン化したい。BeatriceがOSS化されないなら開発モチベあり。)
無料でやるならVAC+VB-Cable

by いたりん
RVCモデル間の類似度を計算する簡易スクリプト。単なるコサイン類似度。
同一話者による違うデータセットから作ったモデルでは類似度はそこまで高くない。
しかし2つのモデルをマージしたものと元のモデルとの類似度は明確に高くなる。
モデルマージチェックには使える可能性がある。

ddsp-svc 4.0構築 main branch
$pip install torch==2.1.0+cu118 torchaudio --index-url https://download.pytorch.org/whl/cu118
$pip install -r requirements.txt

ddsp実行
>cd DDSP-SVC
>venv\Scripts\activate.bat
$python 4.0/z_init_project.py
$python preprocess.py -c configs/model/diffusion-new.yaml
$python train_diff.py -c configs/model/diffusion-new.yaml
$python 4.0/z_main_diff.py -k 12
# => $python main_diff.py -diff <ckpt.pt> -k +12 -kstep 100 -i .wav -o .wav
# -method ddim

データ整形
$python audio_to_copas.py --input ../b.wav --outdir ./copas --time 10 --rate 50
$python separate_in_speach.py --input_dir ./copas --min 5000 --max 10000 --out_dir ./out --padding true

RVC学習ノウハウ
GPU占有メモリが上限に張り付くと処理が止まる。設定値の見極めが大事。
rtx4070の場合のメモ
止まる
input=750files, 60min超
cache=false <= 10minが目安
CPU threads=12
GPU batch size=12 => 10Gb/12Gb