-
Notifications
You must be signed in to change notification settings - Fork 207
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
モーフィング関係で、スタイルIDなのにspeakerになっているところをstyle_idに変更 (#826)
* モーフィング関係で、スタイルIDなのにspeakerになっているところをstyle_idに変更 * NOTE化 * run.pyのとこStyleIdに * API引数をStyleId化 * 間違えて追加してしまっていた * get_style_id_from_deprecated周りの変更 * audio_queryのe2eテスト * stash * 漏れ * さらなる漏れの修正 * StyleIdの場所移動 * StyleIdの場所変更 * pysen * 自動import箇所が意図とあってなさそうだった * なぜか再代入しても大丈夫なようになっていた。。。 * to depreceated_speaker * タイポ。。
- Loading branch information
Showing
6 changed files
with
95 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -76,6 +76,7 @@ curl -s \ | |
### 読み方を AquesTalk 風記法で取得・修正 | ||
|
||
#### AquesTalk 風記法 | ||
|
||
<!-- NOTE: この節は静的リンクとして運用中なので変更しない方が良い(voicevox_engine#816) --> | ||
|
||
「**AquesTalk 風記法**」はカタカナと記号だけで読み方を指定する記法です。[AquesTalk 本家の記法](https://www.a-quest.com/archive/manual/siyo_onseikigou.pdf)とは一部が異なります。 | ||
|
@@ -90,7 +91,7 @@ AquesTalk 風記法は次のルールに従います: | |
#### AquesTalk 風記法のサンプルコード | ||
|
||
`/audio_query`のレスポンスにはエンジンが判断した読み方が[AquesTalk 風記法](#aquestalk-風記法)で記述されます。 | ||
これを修正することで音声の読み仮名やアクセントを制御できます。 | ||
これを修正することで音声の読み仮名やアクセントを制御できます。 | ||
|
||
```bash | ||
# 読ませたい文章をutf-8でtext.txtに書き出す | ||
|
@@ -245,20 +246,20 @@ curl -s \ | |
- `id`は重複してはいけません | ||
- エンジン起動後にファイルを書き換えるとエンジンに反映されます | ||
|
||
### 2 人の話者でモーフィングするサンプルコード | ||
### 2 種類のスタイルでモーフィングするサンプルコード | ||
|
||
`/synthesis_morphing`では、2 人の話者でそれぞれ合成された音声を元に、モーフィングした音声を生成します。 | ||
`/synthesis_morphing`では、2 種類のスタイルでそれぞれ合成された音声を元に、モーフィングした音声を生成します。 | ||
|
||
```bash | ||
echo -n "モーフィングを利用することで、2つの声を混ぜることができます。" > text.txt | ||
echo -n "モーフィングを利用することで、2種類の声を混ぜることができます。" > text.txt | ||
|
||
curl -s \ | ||
-X POST \ | ||
"127.0.0.1:50021/audio_query?style_id=0"\ | ||
--get --data-urlencode [email protected] \ | ||
> query.json | ||
|
||
# 元の話者での合成結果 | ||
# 元のスタイルでの合成結果 | ||
curl -s \ | ||
-H "Content-Type: application/json" \ | ||
-X POST \ | ||
|
@@ -268,22 +269,22 @@ curl -s \ | |
|
||
export MORPH_RATE=0.5 | ||
|
||
# 話者2人分の音声合成+WORLDによる音声分析が入るため時間が掛かるので注意 | ||
# スタイル2種類分の音声合成+WORLDによる音声分析が入るため時間が掛かるので注意 | ||
curl -s \ | ||
-H "Content-Type: application/json" \ | ||
-X POST \ | ||
-d @query.json \ | ||
"127.0.0.1:50021/synthesis_morphing?base_speaker=0&target_speaker=1&morph_rate=$MORPH_RATE" \ | ||
"127.0.0.1:50021/synthesis_morphing?base_style_id=0&target_style_id=1&morph_rate=$MORPH_RATE" \ | ||
> audio.wav | ||
|
||
export MORPH_RATE=0.9 | ||
|
||
# query、base_speaker、target_speakerが同じ場合はキャッシュが使用されるため比較的高速に生成される | ||
# query、base_style_id、target_style_idが同じ場合はキャッシュが使用されるため比較的高速に生成される | ||
curl -s \ | ||
-H "Content-Type: application/json" \ | ||
-X POST \ | ||
-d @query.json \ | ||
"127.0.0.1:50021/synthesis_morphing?base_speaker=0&target_speaker=1&morph_rate=$MORPH_RATE" \ | ||
"127.0.0.1:50021/synthesis_morphing?base_style_id=0&target_style_id=1&morph_rate=$MORPH_RATE" \ | ||
> audio.wav | ||
``` | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.