努力したWiki

推敲の足りないメモ書き多数

ユーザ用ツール

サイト用ツール


Action disabled: source
documents:freebsd:openjtalk:openjtalk-002

FreeBSDでOpen JTalkを使う その2 

音声合成ソフトウエアの Open JTalk を FreeBSD のPortsにしたので公開。

2017年12月06日
FreeBSDのPorts にOpen Jtalk 実行で必要なHTSエンジン hts_engine-api だけ登録されてました。残りはいつ登録されるやら。

2017年03月17日
FreeBSDのPorts Skelton 作ったけど登録されるかわかんないので公開しちゃう。もしPortsに取り込まれたらそっちからのインストールをお願いしますね。

2017年05月05日
全然登録される気配が無いのう。

Ports Skeltons

インストール

依存関係があるので、 hts_engine-api、open_jtalk、の順にインストールし、htsvoice-* は好みのものを。

例えば hts_engine-api をインストールする場合。*.tar.gz を展開したら出来上がったディレクトリに入り、make; make install でインストール。以下はhts_engine-APIインストールの例。

  root@amanda:/home/k896951 # tar xvfz hts_engine-API.tar.gz
  x hts_engine-API/
  x hts_engine-API/Makefile
  x hts_engine-API/distinfo
  x hts_engine-API/pkg-descr
  x hts_engine-API/pkg-plist
  x hts_engine-API/files/
  x hts_engine-API/files/patch-HTSmisc
  root@amanda:/home/k896951 # cd hts_engine-API
  root@amanda:/home/k896951/hts_engine-API # make
  ===>  License BSD3CLAUSE accepted by the user
  ===>   hts_engine-API-1.10 depends on file: /usr/local/sbin/pkg - found
  ===> Fetching all distfiles required by hts_engine-API-1.10 for building
  ===>  Extracting for hts_engine-API-1.10
  => SHA256 Checksum OK for hts_engine_API-1.10.tar.gz.
  ===>  Patching for hts_engine-API-1.10
  ===>  Applying FreeBSD patches for hts_engine-API-1.10
  ===>  Configuring for hts_engine-API-1.10
  checking for a BSD-compatible install... /usr/bin/install -c
  checking whether build environment is sane... yes
  checking for a thread-safe mkdir -p... config/install-sh -c -d
  checking for gawk... no
  :
  :
  :
  /bin/mkdir -p /home/k896951/hts_engine-API/work/stage/usr/local/share/doc/hts_engine-API
  install  -m 444 /home/k896951/hts_engine-API/work/hts_engine_API-1.10/AUTHORS   /home/k896951/hts_engine-API/work/stage/usr/local/share/doc/hts_engine-API
  install  -m 444 /home/k896951/hts_engine-API/work/hts_engine_API-1.10/COPYING   /home/k896951/hts_engine-API/work/stage/usr/local/share/doc/hts_engine-API
  install  -m 444 /home/k896951/hts_engine-API/work/hts_engine_API-1.10/ChangeLog /home/k896951/hts_engine-API/work/stage/usr/local/share/doc/hts_engine-API
  install  -m 444 /home/k896951/hts_engine-API/work/hts_engine_API-1.10/INSTALL   /home/k896951/hts_engine-API/work/stage/usr/local/share/doc/hts_engine-API
  install  -m 444 /home/k896951/hts_engine-API/work/hts_engine_API-1.10/NEWS      /home/k896951/hts_engine-API/work/stage/usr/local/share/doc/hts_engine-API
  install  -m 444 /home/k896951/hts_engine-API/work/hts_engine_API-1.10/README    /home/k896951/hts_engine-API/work/stage/usr/local/share/doc/hts_engine-API
  ====> Compressing man pages (compress-man)
  root@amanda:/home/k896951/hts_engine-API # make install
  ===>  Installing for hts_engine-API-1.10
  ===>  Checking if hts_engine-API already installed
  ===>   Registering installation for hts_engine-API-1.10
  Installing hts_engine-API-1.10...
  root@amanda:/home/k896951/hts_engine-API #

htsvoiceは htsvoice-*.tar.gz を展開してインストール。

open_jtalkで使う辞書は /usr/local/dic/open_jtalk に、htsvoice は /usr/local/share/htsvoice に格納されている。

Ports htsvoice-mmdagent-example.tar.gz をインストールしたのであれば以下のように使用する。

$ open_jtalk -x /usr/local/dic/open_jtalk -m /usr/local/share/htsvoice/mei_normal.htsvoice -ow speech.wav speech.txt
$ ls -l speech*
-rw-r--r--  1 k896951  custom      43  3月 17 00:40 speech.txt
-rw-r--r--  1 k896951  custom  312044  3月 17 00:40 speech.wav
$ cat speech.txt | nkf
さて、発声できましたでしょうか
$

指定するテキストファイルはutf-8で記述しておく。

documents/freebsd/openjtalk/openjtalk-002.txt · 最終更新: 2023/04/14 02:32 by 127.0.0.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki