Spaces:
Runtime error
Runtime error
Delete orig_model
Browse filesThis view is limited to 50 files because it contains too many changes.
See raw diff
- orig_model/.mdl +0 -0
- orig_model/.msc +0 -0
- orig_model/README.md +0 -581
- orig_model/basemodel_16k/audio_config_se_16k.yaml +0 -28
- orig_model/basemodel_16k/hifigan/ckpt/checkpoint_2400000.pth +0 -3
- orig_model/basemodel_16k/hifigan/config.yaml +0 -133
- orig_model/basemodel_16k/sambert/ckpt/checkpoint_2400000.pth +0 -3
- orig_model/basemodel_16k/sambert/config.yaml +0 -84
- orig_model/basemodel_16k/speaker_embedding/se.model +0 -3
- orig_model/basemodel_16k/speaker_embedding/se.onnx +0 -3
- orig_model/configuration.json +0 -155
- orig_model/description/aishell3.png +0 -0
- orig_model/description/hifigan.jpg +0 -0
- orig_model/description/notebook_steps/autolabel_done.jpg +0 -3
- orig_model/description/notebook_steps/autolabel_setting.jpg +0 -0
- orig_model/description/notebook_steps/build_trainer.jpg +0 -3
- orig_model/description/notebook_steps/fetch_nltk_data.jpg +0 -3
- orig_model/description/notebook_steps/inference.jpg +0 -3
- orig_model/description/notebook_steps/inference_play.jpg +0 -3
- orig_model/description/notebook_steps/training.jpg +0 -3
- orig_model/description/notebook_steps/upload_wavs.jpg +0 -3
- orig_model/description/ptts_normal.png +0 -0
- orig_model/description/ptts_structure.png +0 -0
- orig_model/description/ptts_vs_normal.png +0 -0
- orig_model/description/sambert.jpg +0 -0
- orig_model/description/speaker_embedding.png +0 -0
- orig_model/description/tts-system.jpg +0 -0
- orig_model/description/wav/ptts/6.wav +0 -0
- orig_model/description/wav/ptts/7.wav +0 -0
- orig_model/description/wav/ptts/8.wav +0 -0
- orig_model/description/wav/record/SSB00180288.wav +0 -0
- orig_model/description/wav/record/SSB00180500.wav +0 -0
- orig_model/description/wav/record/SSB00180503.wav +0 -0
- orig_model/resource.zip +0 -3
- orig_model/resource/festival/Sable.v0_2.dtd +0 -137
- orig_model/resource/festival/Singing.v0_1.dtd +0 -34
- orig_model/resource/festival/VCLocalRules +0 -8
- orig_model/resource/festival/apml.scm +0 -551
- orig_model/resource/festival/apml_f2bf0lr.scm +0 -530
- orig_model/resource/festival/apml_kaldurtreeZ.scm +0 -996
- orig_model/resource/festival/cart_aux.scm +0 -200
- orig_model/resource/festival/clunits.scm +0 -287
- orig_model/resource/festival/clunits_build.scm +0 -479
- orig_model/resource/festival/cmusphinx2_phones.scm +0 -119
- orig_model/resource/festival/cslush.scm +0 -79
- orig_model/resource/festival/cstr.scm +0 -121
- orig_model/resource/festival/darpa_phones.scm +0 -115
- orig_model/resource/festival/dicts/cmu/COPYING +0 -35
- orig_model/resource/festival/dicts/cmu/allowables.scm +0 -102
- orig_model/resource/festival/dicts/cmu/cmu2ft +0 -21
orig_model/.mdl
DELETED
Binary file (86 Bytes)
|
|
orig_model/.msc
DELETED
Binary file (2.85 kB)
|
|
orig_model/README.md
DELETED
@@ -1,581 +0,0 @@
|
|
1 |
-
---
|
2 |
-
tasks:
|
3 |
-
- text-to-speech
|
4 |
-
studios:
|
5 |
-
- damo/personal_tts
|
6 |
-
domain:
|
7 |
-
- audio
|
8 |
-
frameworks:
|
9 |
-
- pytorch
|
10 |
-
backbone:
|
11 |
-
- transformer
|
12 |
-
metrics:
|
13 |
-
- MOS
|
14 |
-
license: Apache License 2.0
|
15 |
-
tags:
|
16 |
-
- Alibaba
|
17 |
-
- tts
|
18 |
-
- personal
|
19 |
-
- hifigan
|
20 |
-
- nsf
|
21 |
-
- sambert
|
22 |
-
- text-to-speech
|
23 |
-
- pretrain
|
24 |
-
- zhcn
|
25 |
-
- 16k
|
26 |
-
widgets:
|
27 |
-
- task: text-to-speech
|
28 |
-
inputs:
|
29 |
-
- type: text
|
30 |
-
name: input
|
31 |
-
title: 文本
|
32 |
-
validator:
|
33 |
-
max_words: 300
|
34 |
-
examples:
|
35 |
-
- name: 1
|
36 |
-
title: 示例1
|
37 |
-
inputs:
|
38 |
-
- name: input
|
39 |
-
data: 北京今天天气怎么样
|
40 |
-
inferencespec:
|
41 |
-
cpu: 4 #CPU数量
|
42 |
-
memory: 8192
|
43 |
-
gpu: 1 #GPU数量
|
44 |
-
gpu_memory: 8192
|
45 |
-
---
|
46 |
-
|
47 |
-
|
48 |
-
## SAMBERT个性化语音合成模型介绍
|
49 |
-
本文将介绍SAMBERT个性化语音合成模型, 包括其模型结构, 如何在ModelScope上体验模型效果, 以及如何使用开源代码训练SAMBERT个性化语音合成模型.
|
50 |
-
|
51 |
-
## 个性化语音合成
|
52 |
-
语音合成(Text-to-Speech, TTS) 是指将输入文字合成为对应语音信号的功能,即赋予计算机“说”的能力,是人机交互中重要的一环。现代语音合成最早可以追溯到1939年贝尔实验室制造的第一个电子语音合成器,后来历经共振峰合成、PSOLA合成、Unit Selection波形拼接、统计参数合成几代的发展,在2016年随着WaveNet的出现步入了深度学习合成时代,此时语音合成的效果已经表现出了比拟真人的水准。
|
53 |
-
|
54 |
-
提到个性化定制语音,大家并不陌生,许多平台会选择一些大家耳熟能详的明星,进行声音定制,并普遍应用在语音导航,文字播报,小说阅读等场景中。这项技术来自文本到语音的服务,一般来说,语音合成数据需要专业播音员在录音棚录制,且数据量都是以500-1000句话起步,这种标准定制的流程,无论是对播音员、录制条件、录制数量和成本都提出了较高的要求。
|
55 |
-
|
56 |
-
Personal TTS,即个性化语音合成,是通过身边的一些常见录音设备(手机、电脑、录音笔等),录取目标说话人的少量语音片段后,构建出这个人的语音合成系统。相比于标准定制,个性化定制的技术难点在于,数据量有限(20句话)、数据质量不佳和流程全自动化。而它的意义在于进一步降低语音合成的定制门槛,能够将语音合成定制推广到普通用户。
|
57 |
-
|
58 |
-
学术界有很多关于声音克隆的工作,论文陈述效果很好。考虑到落地应用场景的效果,达摩院以自研语音合成系统KAN-TTS的迁移学习能力为基础,设计了一套较为完善的个性化语音合成方案。用户只需要录制20句话,经过几分钟的训练,就能够获得一个较好的个性化声音。
|
59 |
-
|
60 |
-
<div align=center>
|
61 |
-
<figure>
|
62 |
-
<img src="description/ptts_normal.png">
|
63 |
-
<figcaption>定制方案比较</figcaption>
|
64 |
-
</figure>
|
65 |
-
</div>
|
66 |
-
|
67 |
-
|
68 |
-
## 模型框架
|
69 |
-
|
70 |
-
模型框架主要由三个部分组成:
|
71 |
-
1. 数据自动化处理和标注
|
72 |
-
2. 韵律建模SAMBERT声学模型
|
73 |
-
3. 基于说话人特征信息的个性化语音合成
|
74 |
-
|
75 |
-
<div align=center>
|
76 |
-
<figure>
|
77 |
-
<img src="description/ptts_structure.png">
|
78 |
-
<figcaption>个性化定制流程</figcaption>
|
79 |
-
</figure>
|
80 |
-
</div>
|
81 |
-
|
82 |
-
### 数据自动化处理和标注
|
83 |
-
在用户录制完音频之后,我们只有<文本,音频>,而语音合成是需要一些额外的标注信息:韵律标注、音素时长标注。为了获得较好的标注信息,我们采用了一种融合了多种原子能力的全自动化处理和标注流程,包括,韵律预测、ASR、VAD和语音增强等。通过测试集测试,该自动化流程产生的标注信息,在准确度能够满足个性化的需求。
|
84 |
-
|
85 |
-
此外,我们也在modelscope上发布了**TTS-Autolabel自动化数据标注工具**,旨在降低TTS数据标注门槛,使开发者更便捷的定制个性化语音合成模型,具体使用方式及相关教程请进入[TTS-AutoLabel工具主页](https://modelscope.cn/models/damo/speech_ptts_autolabel_16k/summary)获取。
|
86 |
-
|
87 |
-
### 韵律建模SAMBERT声学模型
|
88 |
-
在整个链路中,和效果最相关的模块就是声学模型。在语音合成领域,类似FastSpeech的Parallel模型是目前的主流,它针对基频(pitch)、能量(energy)和时长(duration)三种韵律表征分别建模。但是,该类模型普遍存在一些效果和性能上的问题,例如,独立建模时长、基频、能量,忽视了其内在联系;完全非自回归的网络结构,无法满足工业级实时合成需求;帧级别基频和能量预测不稳定。 因此达摩院语音实验室设计了SAMBERT,一种基于Parallel结构的改良版TTS模型,它具有以下优点:
|
89 |
-
|
90 |
-
```
|
91 |
-
1. Backbone采用Self-Attention-Mechanism(SAM),提升模型建模能力。
|
92 |
-
2. Encoder部分采用BERT进行初始化,引入更多文本信息,提升合成韵律。
|
93 |
-
3. Variance Adaptor对音素级别的韵律(基频、能量、时长)��廓进行粗粒度的预测,再通过decoder进行帧级别细粒度的建模;并在时长预测时考虑到其与基频、能量的关联信息,结合自回归结构,进一步提升韵律自然度.
|
94 |
-
4. Decoder部分采用PNCA AR-Decoder[@li2020robutrans],自然支持流式合成。
|
95 |
-
```
|
96 |
-
|
97 |
-
<div align=center>
|
98 |
-
<figure>
|
99 |
-
<img src="description/sambert.jpg">
|
100 |
-
<figcaption>SAMBERT模型结构</figcaption>
|
101 |
-
</figure>
|
102 |
-
</div>
|
103 |
-
|
104 |
-
### 基于说话人特征信息的个性化语音合成
|
105 |
-
如果需要进行迁移学习,那么需要先构建多说话人的声学模型,不同说话人是通过可训练的说话人编码(speaker embedding)进行区分的。给定新的一个说话人,一般通过随机初始化一个speaker embedding,然后再基于这个说话人的数据进行更新(见下图说话人空间1)。对于个性化语音合成来说,发音人的数据量比较少,学习难度很大,最终合成声音的相似度就无法保证。因此,我们采用说话人特征信息来表示每个说话人,此时,以少量说话人数据初始化的 speaker embedding 距离实际的目标说话人更近得多(见下图说话人空间2),学习难度小,此时合成声音的相似度就比较高。采用基于说话人特征信息的个性化语音合成,使得在20句条件下,依旧能够有较好的相似度。
|
106 |
-
|
107 |
-
<div align=center>
|
108 |
-
<figure>
|
109 |
-
<img src="description/speaker_embedding.png">
|
110 |
-
<figcaption>说话人特征空间</figcaption>
|
111 |
-
</figure>
|
112 |
-
</div>
|
113 |
-
|
114 |
-
## Notebook最佳实践
|
115 |
-
|
116 |
-
首先我们从[sample_test_female](https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/test_female.zip)或者[sample_test_male](https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/test_male.zip)获得示例音频文件, 这里以`sample_test_male`为例。
|
117 |
-
|
118 |
-
解压完成后得到如下文件结构:
|
119 |
-
```
|
120 |
-
test_male
|
121 |
-
├── 01_000001.wav
|
122 |
-
├── 01_000002.wav
|
123 |
-
├── 01_000003.wav
|
124 |
-
├── 01_000004.wav
|
125 |
-
├── 01_000005.wav
|
126 |
-
├── 01_000006.wav
|
127 |
-
├── 01_000007.wav
|
128 |
-
├── 01_000008.wav
|
129 |
-
├── 01_000009.wav
|
130 |
-
├── 01_000010.wav
|
131 |
-
├── 01_000011.wav
|
132 |
-
├── 01_000012.wav
|
133 |
-
├── 01_000013.wav
|
134 |
-
├── 01_000014.wav
|
135 |
-
├── 01_000015.wav
|
136 |
-
├── 01_000016.wav
|
137 |
-
├── 01_000017.wav
|
138 |
-
├── 01_000018.wav
|
139 |
-
├── 01_000019.wav
|
140 |
-
└── 01_000020.wav
|
141 |
-
```
|
142 |
-
|
143 |
-
<div align=center>
|
144 |
-
<figure>
|
145 |
-
<img src="description/notebook_steps/upload_wavs.jpg">
|
146 |
-
<figcaption>上传音频至Notebook</figcaption>
|
147 |
-
</figure>
|
148 |
-
</div>
|
149 |
-
|
150 |
-
接着选择这些wav文件上传至Notebook
|
151 |
-
|
152 |
-
### 前置工作
|
153 |
-
使用AutoLabeling需要用到`nltk`, 由于国内访问nltk资源较慢,所以我们建议先按下面的步骤手动下载nltk资源。
|
154 |
-
|
155 |
-
在Terminal界面下使用`wget`获取`nltk_data`并解压至`home`目录
|
156 |
-
```
|
157 |
-
# 切换至home目录
|
158 |
-
cd ~
|
159 |
-
# 安装zip
|
160 |
-
apt install zip
|
161 |
-
# 下载并解压nltk_data
|
162 |
-
wget https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/nltk_data.zip
|
163 |
-
unzip nltk_data.zip
|
164 |
-
```
|
165 |
-
<div align=center>
|
166 |
-
<figure>
|
167 |
-
<img src="description/notebook_steps/fetch_nltk_data.jpg">
|
168 |
-
<figcaption>手动下载nltk资源</figcaption>
|
169 |
-
</figure>
|
170 |
-
</div>
|
171 |
-
|
172 |
-
### 运行TTS-AutoLabel自动标注
|
173 |
-
首先在Notebook左侧新建TTS-AutoLabel工作文件夹`output_training_data`, 然后在Notebook code block中输入如下代码并运行, 由于Notebook运行环境已经安装了`modelscope`和`tts-autolabel`此处可以直接导入。
|
174 |
-
```python
|
175 |
-
from modelscope.tools import run_auto_label
|
176 |
-
|
177 |
-
input_wav = "./test_wavs/"
|
178 |
-
output_data = "./output_training_data/"
|
179 |
-
|
180 |
-
ret, report = run_auto_label(input_wav=input_wav, work_dir=output_data, resource_revision="v1.0.4")
|
181 |
-
```
|
182 |
-
<div align=center>
|
183 |
-
<figure>
|
184 |
-
<img src="description/notebook_steps/autolabel_done.jpg">
|
185 |
-
<figcaption>Notebook运行TTS—AutoLabel自动标注数据</figcaption>
|
186 |
-
</figure>
|
187 |
-
</div>
|
188 |
-
二十条音频标注时间在2~4分钟。标注完成后在`output_training_data`中可以获取音频对应的TTS训练数据。
|
189 |
-
|
190 |
-
### 基于PTTS-basemodel微调
|
191 |
-
获得标注好的训练数据后,我们进行模型微调,新建一个Notebook代码块,并输入如下代码运行
|
192 |
-
```python
|
193 |
-
from modelscope.metainfo import Trainers
|
194 |
-
from modelscope.trainers import build_trainer
|
195 |
-
from modelscope.utils.audio.audio_utils import TtsTrainType
|
196 |
-
|
197 |
-
pretrained_model_id = 'damo/speech_personal_sambert-hifigan_nsf_tts_zh-cn_pretrain_16k'
|
198 |
-
|
199 |
-
dataset_id = "./output_training_data/"
|
200 |
-
pretrain_work_dir = "./pretrain_work_dir/"
|
201 |
-
|
202 |
-
# 训练信息,用于指定需要训练哪个或哪些模型,这里展示AM和Vocoder模型皆进行训练
|
203 |
-
# 目前支持训练:TtsTrainType.TRAIN_TYPE_SAMBERT, TtsTrainType.TRAIN_TYPE_VOC
|
204 |
-
# 训练SAMBERT会以模型最新step作为基础进行finetune
|
205 |
-
train_info = {
|
206 |
-
TtsTrainType.TRAIN_TYPE_SAMBERT: { # 配置训练AM(sambert)模型
|
207 |
-
'train_steps': 202, # 训练多少个step
|
208 |
-
'save_interval_steps': 200, # 每训练多少个step保存一次checkpoint
|
209 |
-
'log_interval': 10 # 每训练多少个step打印一次训练日志
|
210 |
-
}
|
211 |
-
}
|
212 |
-
|
213 |
-
# 配置训练参数,指定数据集,临时工作目录和train_info
|
214 |
-
kwargs = dict(
|
215 |
-
model=pretrained_model_id, # 指定要finetune的模型
|
216 |
-
model_revision = "v1.0.5",
|
217 |
-
work_dir=pretrain_work_dir, # 指定临时工作目录
|
218 |
-
train_dataset=dataset_id, # 指定数据集id
|
219 |
-
train_type=train_info # 指定要训练类型及参数
|
220 |
-
)
|
221 |
-
|
222 |
-
trainer = build_trainer(Trainers.speech_kantts_trainer,
|
223 |
-
default_args=kwargs)
|
224 |
-
|
225 |
-
trainer.train()
|
226 |
-
```
|
227 |
-
|
228 |
-
<div align=center>
|
229 |
-
<figure>
|
230 |
-
<img src="description/notebook_steps/training.jpg">
|
231 |
-
<figcaption>在Notebook中使用trainer微调模型</figcaption>
|
232 |
-
</figure>
|
233 |
-
</div>
|
234 |
-
|
235 |
-
微调过程大概需要5分钟的时间,请耐心等待。
|
236 |
-
|
237 |
-
|
238 |
-
### 体验模型合成效果
|
239 |
-
使用上一步微调得到的模型合成音频,新建一个Notebook代码块, 输入以下代码
|
240 |
-
```python
|
241 |
-
import os
|
242 |
-
from modelscope.models.audio.tts import SambertHifigan
|
243 |
-
from modelscope.pipelines import pipeline
|
244 |
-
from modelscope.utils.constant import Tasks
|
245 |
-
|
246 |
-
model_dir = os.path.abspath("./pretrain_work_dir")
|
247 |
-
|
248 |
-
custom_infer_abs = {
|
249 |
-
'voice_name':
|
250 |
-
'F7',
|
251 |
-
'am_ckpt':
|
252 |
-
os.path.join(model_dir, 'tmp_am', 'ckpt'),
|
253 |
-
'am_config':
|
254 |
-
os.path.join(model_dir, 'tmp_am', 'config.yaml'),
|
255 |
-
'voc_ckpt':
|
256 |
-
os.path.join(model_dir, 'orig_model', 'basemodel_16k', 'hifigan', 'ckpt'),
|
257 |
-
'voc_config':
|
258 |
-
os.path.join(model_dir, 'orig_model', 'basemodel_16k', 'hifigan',
|
259 |
-
'config.yaml'),
|
260 |
-
'audio_config':
|
261 |
-
os.path.join(model_dir, 'data', 'audio_config.yaml'),
|
262 |
-
'se_file':
|
263 |
-
os.path.join(model_dir, 'data', 'se', 'se.npy')
|
264 |
-
}
|
265 |
-
kwargs = {'custom_ckpt': custom_infer_abs}
|
266 |
-
|
267 |
-
model_id = SambertHifigan(os.path.join(model_dir, "orig_model"), **kwargs)
|
268 |
-
|
269 |
-
inference = pipeline(task=Tasks.text_to_speech, model=model_id)
|
270 |
-
output = inference(input="今天的天气真不错")
|
271 |
-
|
272 |
-
import IPython.display as ipd
|
273 |
-
ipd.Audio(output["output_wav"], rate=16000)
|
274 |
-
```
|
275 |
-
|
276 |
-
<div align=center>
|
277 |
-
<figure>
|
278 |
-
<img src="description/notebook_steps/inference_play.jpg">
|
279 |
-
<figcaption>在Notebook中使用微调好的模型合成音频</figcaption>
|
280 |
-
</figure>
|
281 |
-
</div>
|
282 |
-
|
283 |
-
点击播放控件即可体验合成音频。
|
284 |
-
|
285 |
-
## KAN-TTS最佳实践
|
286 |
-
### 环境搭建
|
287 |
-
获取KAN-TTS源码, 后续操作默认在代码库根目录下执行
|
288 |
-
|
289 |
-
```bash
|
290 |
-
git clone -b develop https://github.com/alibaba-damo-academy/KAN-TTS.git
|
291 |
-
cd KAN-TTS
|
292 |
-
```
|
293 |
-
|
294 |
-
我们推荐使用Anaconda来搭建Python虚拟环境,使用以下命令创建(目前只兼容Linux x86系统):
|
295 |
-
|
296 |
-
```bash
|
297 |
-
# 防止使用pip安装时出现网络问题,建议切换国内pip源
|
298 |
-
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
|
299 |
-
|
300 |
-
# 创建虚拟环境
|
301 |
-
conda env create -f environment.yaml
|
302 |
-
|
303 |
-
# 激活虚拟环境
|
304 |
-
conda activate maas
|
305 |
-
```
|
306 |
-
|
307 |
-
|
308 |
-
### 拉取预训练模型
|
309 |
-
ModelScope中文个性化语音合成模型是达摩院语音实验室在1000多小时4000多人数据集上训练产出的预训练模型,我们以此为basemodel做后续微调。
|
310 |
-
使用git命令拉取模型,在拉取前,首先你需要安装git-lfs, 具体的安装教程见Git Large File Storage,安装完成后执行以下命令:
|
311 |
-
|
312 |
-
```bash
|
313 |
-
# 克隆预训练模型
|
314 |
-
git clone https://www.modelscope.cn/damo/speech_personal_sambert-hifigan_nsf_tts_zh-cn_pretrain_16k.git
|
315 |
-
```
|
316 |
-
|
317 |
-
### 数据获取与自动标注
|
318 |
-
|
319 |
-
目前KAN-TTS个性化语音合成支持达摩院TTS标准数据格式和普通音频格式。
|
320 |
-
其中达摩院TTS标准数据格式,wav文件夹下存放了音频文件,prosody文件夹下的.txt文件对应的是音频文件的文本标注,interval文件夹下存放的是音素级别的时间戳标注,如下:
|
321 |
-
```
|
322 |
-
.
|
323 |
-
├── interval
|
324 |
-
│ ├── 500001.interval
|
325 |
-
│ ├── 500002.interval
|
326 |
-
│ ├── 500003.interval
|
327 |
-
│ ├── ...
|
328 |
-
│ └── 500020.interval
|
329 |
-
├── prosody
|
330 |
-
│ └── prosody.txt
|
331 |
-
└── wav
|
332 |
-
├── 500001.wav
|
333 |
-
├── 500002.wav
|
334 |
-
├── ...
|
335 |
-
└── 500020.wav
|
336 |
-
```
|
337 |
-
|
338 |
-
普通音频数据,不携带时间戳标注和prosody标注,如下:
|
339 |
-
```
|
340 |
-
.
|
341 |
-
└── wav
|
342 |
-
├── 1.wav
|
343 |
-
├── 2.wav
|
344 |
-
├── ...
|
345 |
-
└── 20.wav
|
346 |
-
```
|
347 |
-
|
348 |
-
**快速开始**:你可以从ModelScope下载经过阿里标准格式处理的[AISHELL-3开源语音合成数据集](https://modelscope.cn/datasets/speech_tts/AISHELL-3/summary),用来进行后续操作。如果你只有普通音频格式的数据,那么可以采用PTTS Autolabel自动化标注工具进行格式转换,下面介绍使用Notebook 进行PTTS Autolable自动化标注的方式。
|
349 |
-
|
350 |
-
#### PTTS Autolable自动化标注
|
351 |
-
|
352 |
-
打开右上角的Notebook,上传[sample_test_male](https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/test_male.zip)的20条���频文件到目录如/mnt/workspace/Data/ptts_spk0_wav下面
|
353 |
-
```
|
354 |
-
ptts_spk0_wav
|
355 |
-
├── 01_000001.wav
|
356 |
-
├── 01_000002.wav
|
357 |
-
├── 01_000003.wav
|
358 |
-
├── 01_000004.wav
|
359 |
-
├── 01_000005.wav
|
360 |
-
├── 01_000006.wav
|
361 |
-
├── 01_000007.wav
|
362 |
-
├── 01_000008.wav
|
363 |
-
├── 01_000009.wav
|
364 |
-
├── 01_000010.wav
|
365 |
-
├── 01_000011.wav
|
366 |
-
├── 01_000012.wav
|
367 |
-
├── 01_000013.wav
|
368 |
-
├── 01_000014.wav
|
369 |
-
├── 01_000015.wav
|
370 |
-
├── 01_000016.wav
|
371 |
-
├── 01_000017.wav
|
372 |
-
├── 01_000018.wav
|
373 |
-
├── 01_000019.wav
|
374 |
-
└── 01_000020.wav
|
375 |
-
```
|
376 |
-
在Notebook的Jupyter中安装tts-autolabel
|
377 |
-
|
378 |
-
``` Python
|
379 |
-
# 运行此代码块安装tts-autolabel
|
380 |
-
import sys
|
381 |
-
!{sys.executable} -m pip install tts-autolabel -f https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo.html
|
382 |
-
```
|
383 |
-
``` Python
|
384 |
-
# 导入run_auto_label工具, 初次运行会下载相关库文件
|
385 |
-
from modelscope.tools import run_auto_label
|
386 |
-
```
|
387 |
-
|
388 |
-
``` Python
|
389 |
-
# 运行 autolabel进行自动标注,20句音频的自动标注约4分钟
|
390 |
-
import os
|
391 |
-
|
392 |
-
input_wav = '/mnt/workspace/Data/ptts_spk0_wav' # wav audio path
|
393 |
-
work_dir = '/mnt/workspace/Data/ptts_spk0_autolabel' # output path
|
394 |
-
os.makedirs(work_dir, exist_ok=True)
|
395 |
-
|
396 |
-
ret, report = run_auto_label(input_wav = input_wav,
|
397 |
-
work_dir = work_dir,
|
398 |
-
resource_revision='v1.0.4')
|
399 |
-
print(report)
|
400 |
-
```
|
401 |
-
|
402 |
-
完成数据标注后,下载对应文件夹`/mnt/workspace/Data/ptts_spk0_autolabel`, 使用`KAN-TTS`的数据前处理脚本做训练前数据准备。
|
403 |
-
|
404 |
-
我们选择个性化语音合成配置文件进行特征提取操作,这里我们以提供的16k采样率为例kantts/configs/audio_config_se_16k.yaml
|
405 |
-
运行以下命令来进行特征提取,其中--speaker代表该数据集对应发音人的名称,用户可以随意命名。
|
406 |
-
```bash
|
407 |
-
# 特征提取
|
408 |
-
python kantts/preprocess/data_process.py --voice_input_dir ptts_spk0_autolabel --voice_output_dir training_stage/test_male_ptts_feats --audio_config kantts/configs/audio_config_se_16k.yaml --speaker F7 --se_model speech_personal_sambert-hifigan_nsf_tts_zh-cn_pretrain_16k/basemodel_16k/speaker_embedding/se.*
|
409 |
-
|
410 |
-
# 扩充epoch
|
411 |
-
stage0=training_stage
|
412 |
-
voice=test_male_ptts_feats
|
413 |
-
|
414 |
-
cat $stage0/$voice/am_valid.lst >> $stage0/$voice/am_train.lst
|
415 |
-
lines=0
|
416 |
-
while [ $lines -lt 400 ]
|
417 |
-
do
|
418 |
-
shuf $stage0/$voice/am_train.lst >> $stage0/$voice/am_train.lst.tmp
|
419 |
-
lines=$(wc -l < "$stage0/$voice/am_train.lst.tmp")
|
420 |
-
done
|
421 |
-
mv $stage0/$voice/am_train.lst.tmp $stage0/$voice/am_train.lst
|
422 |
-
```
|
423 |
-
|
424 |
-
个性化语音合成只需要20句目标说话人的语音,特征提取只需要运行一小段时间,提取完毕后你会在training_stage/test_male_ptts_feats目录下得到如下结构的文件:
|
425 |
-
```
|
426 |
-
# 基于阿里标准格式数据所提取出的特征目录
|
427 |
-
├── am_train.lst
|
428 |
-
├── am_valid.lst
|
429 |
-
├── audio_config.yaml
|
430 |
-
├── badlist.txt
|
431 |
-
├── data_process_stdout.log
|
432 |
-
├── duration
|
433 |
-
├── energy
|
434 |
-
├── f0
|
435 |
-
├── frame_energy
|
436 |
-
├── frame_f0
|
437 |
-
├── frame_uv
|
438 |
-
├── mel
|
439 |
-
├── raw_duration
|
440 |
-
├── raw_metafile.txt
|
441 |
-
├── Script.xml
|
442 |
-
├── se
|
443 |
-
├── train.lst
|
444 |
-
├── valid.lst
|
445 |
-
└── wav
|
446 |
-
```
|
447 |
-
至此数据准备工作就算完成了。
|
448 |
-
|
449 |
-
微调声学模型
|
450 |
-
KAN-TTS的训练脚本是配置驱动的,我们使用预训练模型中的speech_personal_sambert-hifigan_nsf_tts_zh-cn_pretrain_16k/basemodel_16k/sambert/config.yaml作为训练配置文件。
|
451 |
-
我们提供默认的PTTS 默认使用的finetune参数值,希望在basemodel的基础上继续微调一定步数并保存,即train_max_steps配置项。
|
452 |
-
|
453 |
-
```bash
|
454 |
-
# 将train_max_steps改为 2400301
|
455 |
-
...
|
456 |
-
train_max_steps: 2400301
|
457 |
-
...
|
458 |
-
```
|
459 |
-
完成上述必要的配置项修改后,我们就可以使用以下命令训练声学模型了:
|
460 |
-
```bash
|
461 |
-
# 训练声学模型
|
462 |
-
CUDA_VISIBLE_DEVICES=0 python kantts/bin/train_sambert.py --model_config speech_personal_sambert-hifigan_nsf_tts_zh-cn_pretrain_16k/basemodel_16k/sambert/config.yaml --root_dir training_stage/test_male_ptts_feats --stage_dir training_stage/test_male_ptts_sambert_ckpt --resume_path speech_personal_sambert-hifigan_nsf_tts_zh-cn_pretrain_16k/basemodel_16k/sambert/ckpt/checkpoint_*.pth
|
463 |
-
```
|
464 |
-
|
465 |
-
体验微调模型效果
|
466 |
-
在声学模型微调完毕后,我们就可以使用产出的模型文件和预训练的声码器来合成语音了,在此之前需要做一些准备工作。
|
467 |
-
|
468 |
-
将我们想要合成的文本写入一个文件test.txt,每句话按行分隔,如下所示
|
469 |
-
```
|
470 |
-
徐玠诡谲多智,善揣摩,知道徐知询不可辅佐,掌握着他的短处以归附徐知诰。
|
471 |
-
许乐夫生于山东省临朐县杨善镇大辛庄,毕业于抗大一分校。
|
472 |
-
宣统元年(1909年),顺德绅士冯国材在香山大黄圃成立安洲农务分会,管辖东海十六沙,冯国材任总理。
|
473 |
-
学生们大多住在校区宿舍,通过参加不同的体育文化俱乐部及社交活动,形成一个友谊长存的社会圈。
|
474 |
-
学校的“三节一会”(艺术节、社团节、科技节、运动会)是显示青春才华的盛大活动。
|
475 |
-
雪是先天自闭症患者,不懂与人沟通,却拥有灵敏听觉,而且对复杂动作过目不忘。
|
476 |
-
勋章通过一柱状螺孔和螺钉附着在衣物上。
|
477 |
-
雅恩雷根斯堡足球俱乐部()是一家位于德国雷根斯堡的足球俱乐部,处于德国足球丙级联赛。
|
478 |
-
亚历山大·格罗滕迪克于1957年证明了一个深远的推广,现在叫做格罗滕迪克–黎曼–罗赫定理。
|
479 |
-
```
|
480 |
-
|
481 |
-
运行以下命令进行合成,其中se_file为特征提取环节抽取的speaker embedding,voc_ckpt为basemodel_16k中的预训练模型:
|
482 |
-
|
483 |
-
``` bash
|
484 |
-
# 运行合成语音
|
485 |
-
CUDA_VISIBLE_DEVICES=0 python kantts/bin/text_to_wav.py --txt test.txt --output_dir res/test_male_ptts_syn --res_zip speech_sambert-hifigan_tts_zh-cn_multisp_pretrain_16k/resource.zip --am_ckpt training_stage/test_male_ptts_sambert_ckpt/ckpt/checkpoint_2400300.pth --voc_ckpt speech_sambert-hifigan_tts_zh-cn_multisp_pretrain_16k/hifigan/ckpt/checkpoint_2400000.pth --se_file training_stage/test_male_ptts_feats/se/se.npy
|
486 |
-
```
|
487 |
-
|
488 |
-
完成后在res/test_male_ptts_syn/res_wavs文件夹下就可以获得合成结果
|
489 |
-
```
|
490 |
-
.
|
491 |
-
├── 0.wav
|
492 |
-
├── 1.wav
|
493 |
-
├── 2.wav
|
494 |
-
├── 3.wav
|
495 |
-
├── 4.wav
|
496 |
-
├── 5.wav
|
497 |
-
├── 6.wav
|
498 |
-
├── 7.wav
|
499 |
-
└── 8.wav
|
500 |
-
```
|
501 |
-
|
502 |
-
合成样音
|
503 |
-
|
504 |
-
<audio id="audio" controls="" preload="none">
|
505 |
-
<source src="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/ptts_modelcard_assets/wavs/synthesis/7.wav">
|
506 |
-
</audio>
|
507 |
-
<audio id="audio" controls="" preload="none">
|
508 |
-
<source src="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/ptts_modelcard_assets/wavs/synthesis/8.wav">
|
509 |
-
</audio>
|
510 |
-
<audio id="audio" controls="" preload="none">
|
511 |
-
<source src="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/ptts_modelcard_assets/wavs/synthesis/9.wav">
|
512 |
-
</audio>
|
513 |
-
|
514 |
-
原始录音
|
515 |
-
|
516 |
-
<audio id="audio" controls="" preload="none">
|
517 |
-
<source src="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/ptts_modelcard_assets/wavs/recordings/01_000003.wav">
|
518 |
-
</audio>
|
519 |
-
<audio id="audio" controls="" preload="none">
|
520 |
-
<source id="mp3" src="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/ptts_modelcard_assets/wavs/recordings/01_000004.wav">
|
521 |
-
</audio>
|
522 |
-
<audio id="audio" controls="" preload="none">
|
523 |
-
<source id="mp3" src="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/TTS/download_files/ptts_modelcard_assets/wavs/recordings/01_000005.wav">
|
524 |
-
</audio>
|
525 |
-
|
526 |
-
## 模型局限性以及可能的偏差
|
527 |
-
* 该发音人支持中文及英文混合,TN规则为中文
|
528 |
-
|
529 |
-
## 训练数据介绍
|
530 |
-
使用约4000个不同发音人,共计约1000小时数据训练, 主要为中文语料, 包含少量英文语料。
|
531 |
-
|
532 |
-
## 模型训练流程
|
533 |
-
模型所需训练数据格式为:音频(.wav), 文本标注(.txt), 音素时长标注(.interval), 个性化语音合成模型微调训练时间需要2~5分钟。
|
534 |
-
|
535 |
-
### 预处理
|
536 |
-
模型训练需对音频文件提取声学特征(梅尔频谱);音素时长根据配置项中的帧长将时间单位转换成帧数;文本标注,根据配置项中的音素集、音调分类、边界分类转换成对应的one-hot编号;
|
537 |
-
|
538 |
-
|
539 |
-
## 引用
|
540 |
-
如果你觉得这个该模型对有所帮助,请考虑引用下面的相关的论文:
|
541 |
-
|
542 |
-
```BibTeX
|
543 |
-
@inproceedings{li2020robutrans,
|
544 |
-
title={Robutrans: A robust transformer-based text-to-speech model},
|
545 |
-
author={Li, Naihan and Liu, Yanqing and Wu, Yu and Liu, Shujie and Zhao, Sheng and Liu, Ming},
|
546 |
-
booktitle={Proceedings of the AAAI Conference on Artificial Intelligence},
|
547 |
-
volume={34},
|
548 |
-
number={05},
|
549 |
-
pages={8228--8235},
|
550 |
-
year={2020}
|
551 |
-
}
|
552 |
-
```
|
553 |
-
|
554 |
-
```BibTeX
|
555 |
-
@article{devlin2018bert,
|
556 |
-
title={Bert: Pre-training of deep bidirectional transformers for language understanding},
|
557 |
-
author={Devlin, Jacob and Chang, Ming-Wei and Lee, Kenton and Toutanova, Kristina},
|
558 |
-
journal={arXiv preprint arXiv:1810.04805},
|
559 |
-
year={2018}
|
560 |
-
}
|
561 |
-
```
|
562 |
-
```BibTeX
|
563 |
-
@article{kong2020hifi,
|
564 |
-
title={Hifi-gan: Generative adversarial networks for efficient and high fidelity speech synthesis},
|
565 |
-
author={Kong, Jungil and Kim, Jaehyeon and Bae, Jaekyoung},
|
566 |
-
journal={Advances in Neural Information Processing Systems},
|
567 |
-
volume={33},
|
568 |
-
pages={17022--17033},
|
569 |
-
year={2020}
|
570 |
-
}
|
571 |
-
```
|
572 |
-
|
573 |
-
本模型参考了以下实现
|
574 |
-
- [1] [ming024's FastSpeech2 Implementation](https://github.com/ming024/FastSpeech2)
|
575 |
-
- [2] [jik876/hifi-gan](https://github.com/jik876/hifi-gan)
|
576 |
-
- [3] [kan-bayashi/ParallelWaveGAN](https://github.com/kan-bayashi/ParallelWaveGAN)
|
577 |
-
- [4] [mozilla/TTS](https://github.com/mozilla/TTS)
|
578 |
-
- [5] [espnet/espnet](https://github.com/espnet/espnet)
|
579 |
-
|
580 |
-
|
581 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/basemodel_16k/audio_config_se_16k.yaml
DELETED
@@ -1,28 +0,0 @@
|
|
1 |
-
# Audio processing configs
|
2 |
-
|
3 |
-
audio_config:
|
4 |
-
# Preprocess
|
5 |
-
wav_normalize: True
|
6 |
-
trim_silence: True
|
7 |
-
trim_silence_threshold_db: 60
|
8 |
-
preemphasize: False
|
9 |
-
|
10 |
-
# Feature extraction
|
11 |
-
sampling_rate: 16000
|
12 |
-
hop_length: 200
|
13 |
-
win_length: 1000
|
14 |
-
n_fft: 2048
|
15 |
-
n_mels: 80
|
16 |
-
fmin: 0.0
|
17 |
-
fmax: 8000.0
|
18 |
-
phone_level_feature: True
|
19 |
-
se_feature: True
|
20 |
-
|
21 |
-
# Normalization
|
22 |
-
norm_type: "mean_std" # "mean_std" or "global"
|
23 |
-
max_norm: 1.0
|
24 |
-
symmetric: False
|
25 |
-
min_level_db: -100.0
|
26 |
-
ref_level_db: 20
|
27 |
-
|
28 |
-
num_workers: 16
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/basemodel_16k/hifigan/ckpt/checkpoint_2400000.pth
DELETED
@@ -1,3 +0,0 @@
|
|
1 |
-
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:0986149a5a7e57e128f9bad6d8937a7f5567c53f73fe0770ee8c56e0dfc02325
|
3 |
-
size 907767067
|
|
|
|
|
|
|
|
orig_model/basemodel_16k/hifigan/config.yaml
DELETED
@@ -1,133 +0,0 @@
|
|
1 |
-
Loss:
|
2 |
-
discriminator_adv_loss:
|
3 |
-
enable: true
|
4 |
-
params: {average_by_discriminators: false}
|
5 |
-
weights: 1.0
|
6 |
-
feat_match_loss:
|
7 |
-
enable: true
|
8 |
-
params: {average_by_discriminators: false, average_by_layers: false}
|
9 |
-
weights: 2.0
|
10 |
-
generator_adv_loss:
|
11 |
-
enable: true
|
12 |
-
params: {average_by_discriminators: false}
|
13 |
-
weights: 1.0
|
14 |
-
mel_loss:
|
15 |
-
enable: true
|
16 |
-
params: {fft_size: 2048, fmax: 8000, fmin: 0, fs: 16000, hop_size: 200, log_base: null,
|
17 |
-
num_mels: 80, win_length: 1000, window: hann}
|
18 |
-
weights: 45.0
|
19 |
-
stft_loss: {enable: false}
|
20 |
-
subband_stft_loss:
|
21 |
-
enable: false
|
22 |
-
params:
|
23 |
-
fft_sizes: [384, 683, 171]
|
24 |
-
hop_sizes: [35, 75, 15]
|
25 |
-
win_lengths: [150, 300, 60]
|
26 |
-
window: hann_window
|
27 |
-
Model:
|
28 |
-
Generator:
|
29 |
-
optimizer:
|
30 |
-
params:
|
31 |
-
betas: [0.5, 0.9]
|
32 |
-
lr: 0.0002
|
33 |
-
weight_decay: 0.0
|
34 |
-
type: Adam
|
35 |
-
params:
|
36 |
-
bias: true
|
37 |
-
causal: false
|
38 |
-
channels: 256
|
39 |
-
in_channels: 80
|
40 |
-
kernel_size: 7
|
41 |
-
nonlinear_activation: LeakyReLU
|
42 |
-
nonlinear_activation_params: {negative_slope: 0.1}
|
43 |
-
nsf_params: {nb_harmonics: 7, nsf_f0_global_maximum: 730.0, nsf_f0_global_minimum: 30.0,
|
44 |
-
nsf_norm_type: none, sampling_rate: 16000}
|
45 |
-
out_channels: 1
|
46 |
-
resblock_dilations:
|
47 |
-
- [1, 3, 5, 7]
|
48 |
-
- [1, 3, 5, 7]
|
49 |
-
- [1, 3, 5, 7]
|
50 |
-
resblock_kernel_sizes: [3, 7, 11]
|
51 |
-
upsample_kernal_sizes: [20, 11, 4, 4]
|
52 |
-
upsample_scales: [10, 5, 2, 2]
|
53 |
-
use_weight_norm: true
|
54 |
-
scheduler:
|
55 |
-
params:
|
56 |
-
gamma: 0.5
|
57 |
-
milestones: [200000, 400000, 600000, 800000]
|
58 |
-
type: MultiStepLR
|
59 |
-
MultiPeriodDiscriminator:
|
60 |
-
optimizer:
|
61 |
-
params:
|
62 |
-
betas: [0.5, 0.9]
|
63 |
-
lr: 0.0002
|
64 |
-
weight_decay: 0.0
|
65 |
-
type: Adam
|
66 |
-
params:
|
67 |
-
discriminator_params:
|
68 |
-
bias: true
|
69 |
-
channels: 32
|
70 |
-
downsample_scales: [3, 3, 3, 3, 1]
|
71 |
-
in_channels: 1
|
72 |
-
kernel_sizes: [5, 3]
|
73 |
-
max_downsample_channels: 1024
|
74 |
-
nonlinear_activation: LeakyReLU
|
75 |
-
nonlinear_activation_params: {negative_slope: 0.1}
|
76 |
-
out_channels: 1
|
77 |
-
use_spectral_norm: false
|
78 |
-
periods: [2, 3, 5, 7, 11]
|
79 |
-
scheduler:
|
80 |
-
params:
|
81 |
-
gamma: 0.5
|
82 |
-
milestones: [200000, 400000, 600000, 800000]
|
83 |
-
type: MultiStepLR
|
84 |
-
MultiScaleDiscriminator:
|
85 |
-
optimizer:
|
86 |
-
params:
|
87 |
-
betas: [0.5, 0.9]
|
88 |
-
lr: 0.0002
|
89 |
-
weight_decay: 0.0
|
90 |
-
type: Adam
|
91 |
-
params:
|
92 |
-
discriminator_params:
|
93 |
-
bias: true
|
94 |
-
channels: 128
|
95 |
-
downsample_scales: [4, 4, 4, 4, 1]
|
96 |
-
in_channels: 1
|
97 |
-
kernel_sizes: [15, 41, 5, 3]
|
98 |
-
max_downsample_channels: 1024
|
99 |
-
max_groups: 16
|
100 |
-
nonlinear_activation: LeakyReLU
|
101 |
-
nonlinear_activation_params: {negative_slope: 0.1}
|
102 |
-
out_channels: 1
|
103 |
-
downsample_pooling: DWT
|
104 |
-
downsample_pooling_params: {kernel_size: 4, padding: 2, stride: 2}
|
105 |
-
follow_official_norm: true
|
106 |
-
scales: 3
|
107 |
-
scheduler:
|
108 |
-
params:
|
109 |
-
gamma: 0.5
|
110 |
-
milestones: [200000, 400000, 600000, 800000]
|
111 |
-
type: MultiStepLR
|
112 |
-
allow_cache: false
|
113 |
-
audio_config: {fmax: 8000.0, fmin: 0.0, hop_length: 200, max_norm: 1.0, min_level_db: -100.0,
|
114 |
-
n_fft: 2048, n_mels: 80, norm_type: mean_std, num_workers: 16, phone_level_feature: true,
|
115 |
-
preemphasize: false, ref_level_db: 20, sampling_rate: 16000, symmetric: false, trim_silence: true,
|
116 |
-
trim_silence_threshold_db: 60, wav_normalize: true, win_length: 1000}
|
117 |
-
batch_max_steps: 9600
|
118 |
-
batch_size: 16
|
119 |
-
create_time: '2023-02-02 14:59:17'
|
120 |
-
discriminator_grad_norm: -1
|
121 |
-
discriminator_train_start_steps: 0
|
122 |
-
eval_interval_steps: 10000
|
123 |
-
generator_grad_norm: -1
|
124 |
-
generator_train_start_steps: 1
|
125 |
-
git_revision_hash: a0976425309c09c3338851d4ee37c1611deb4f42
|
126 |
-
log_interval_steps: 1000
|
127 |
-
model_type: hifigan
|
128 |
-
num_save_intermediate_results: 4
|
129 |
-
num_workers: 2
|
130 |
-
pin_memory: true
|
131 |
-
remove_short_samples: false
|
132 |
-
save_interval_steps: 20000
|
133 |
-
train_max_steps: 2500000
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/basemodel_16k/sambert/ckpt/checkpoint_2400000.pth
DELETED
@@ -1,3 +0,0 @@
|
|
1 |
-
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:c01be288195e05dd658494714247abb64c367cde5b4723a0e1f808a70c7ba0c4
|
3 |
-
size 157757249
|
|
|
|
|
|
|
|
orig_model/basemodel_16k/sambert/config.yaml
DELETED
@@ -1,84 +0,0 @@
|
|
1 |
-
Loss:
|
2 |
-
MelReconLoss:
|
3 |
-
enable: true
|
4 |
-
params: {loss_type: mae}
|
5 |
-
ProsodyReconLoss:
|
6 |
-
enable: true
|
7 |
-
params: {loss_type: mae}
|
8 |
-
Model:
|
9 |
-
KanTtsSAMBERT:
|
10 |
-
optimizer:
|
11 |
-
params:
|
12 |
-
betas: [0.9, 0.98]
|
13 |
-
eps: 1.0e-09
|
14 |
-
lr: 0.001
|
15 |
-
weight_decay: 0.0
|
16 |
-
type: Adam
|
17 |
-
params:
|
18 |
-
MAS: false
|
19 |
-
NSF: true
|
20 |
-
SE: true
|
21 |
-
decoder_attention_dropout: 0.1
|
22 |
-
decoder_dropout: 0.1
|
23 |
-
decoder_ffn_inner_dim: 1024
|
24 |
-
decoder_num_heads: 8
|
25 |
-
decoder_num_layers: 12
|
26 |
-
decoder_num_units: 128
|
27 |
-
decoder_prenet_units: [256, 256]
|
28 |
-
decoder_relu_dropout: 0.1
|
29 |
-
dur_pred_lstm_units: 128
|
30 |
-
dur_pred_prenet_units: [128, 128]
|
31 |
-
embedding_dim: 512
|
32 |
-
emotion_units: 32
|
33 |
-
encoder_attention_dropout: 0.1
|
34 |
-
encoder_dropout: 0.1
|
35 |
-
encoder_ffn_inner_dim: 1024
|
36 |
-
encoder_num_heads: 8
|
37 |
-
encoder_num_layers: 8
|
38 |
-
encoder_num_units: 128
|
39 |
-
encoder_projection_units: 32
|
40 |
-
encoder_relu_dropout: 0.1
|
41 |
-
max_len: 800
|
42 |
-
nsf_f0_global_maximum: 730.0
|
43 |
-
nsf_f0_global_minimum: 30.0
|
44 |
-
nsf_norm_type: global
|
45 |
-
num_mels: 82
|
46 |
-
outputs_per_step: 3
|
47 |
-
postnet_dropout: 0.1
|
48 |
-
postnet_ffn_inner_dim: 512
|
49 |
-
postnet_filter_size: 41
|
50 |
-
postnet_fsmn_num_layers: 4
|
51 |
-
postnet_lstm_units: 128
|
52 |
-
postnet_num_memory_units: 256
|
53 |
-
postnet_shift: 17
|
54 |
-
predictor_dropout: 0.1
|
55 |
-
predictor_ffn_inner_dim: 256
|
56 |
-
predictor_filter_size: 41
|
57 |
-
predictor_fsmn_num_layers: 3
|
58 |
-
predictor_lstm_units: 128
|
59 |
-
predictor_num_memory_units: 128
|
60 |
-
predictor_shift: 0
|
61 |
-
speaker_units: 192
|
62 |
-
scheduler:
|
63 |
-
params: {warmup_steps: 4000}
|
64 |
-
type: NoamLR
|
65 |
-
allow_cache: false
|
66 |
-
audio_config: {fmax: 8000.0, fmin: 0.0, hop_length: 200, max_norm: 1.0, min_level_db: -100.0,
|
67 |
-
n_fft: 2048, n_mels: 80, norm_type: mean_std, num_workers: 16, phone_level_feature: true,
|
68 |
-
preemphasize: false, ref_level_db: 20, sampling_rate: 16000, symmetric: false, trim_silence: true,
|
69 |
-
trim_silence_threshold_db: 60, wav_normalize: true, win_length: 1000}
|
70 |
-
batch_size: 32
|
71 |
-
create_time: '2023-02-02 23:14:31'
|
72 |
-
eval_interval_steps: 10000000000000000
|
73 |
-
git_revision_hash: d16755444c9baf23348213211a5ed9035458ecf0
|
74 |
-
grad_norm: 1.0
|
75 |
-
linguistic_unit: {cleaners: english_cleaners, lfeat_type_list: 'sy,tone,syllable_flag,word_segment,emo_category,speaker_category',
|
76 |
-
speaker_list: F7}
|
77 |
-
log_interval_steps: 50
|
78 |
-
model_type: sambert
|
79 |
-
num_save_intermediate_results: 4
|
80 |
-
num_workers: 4
|
81 |
-
pin_memory: false
|
82 |
-
remove_short_samples: false
|
83 |
-
save_interval_steps: 100
|
84 |
-
train_max_steps: 2400301
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/basemodel_16k/speaker_embedding/se.model
DELETED
@@ -1,3 +0,0 @@
|
|
1 |
-
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:baf2213c1d6bc1d0be46dd88c9a04e50558d177c1d6364d9d627475693bfae40
|
3 |
-
size 28078831
|
|
|
|
|
|
|
|
orig_model/basemodel_16k/speaker_embedding/se.onnx
DELETED
@@ -1,3 +0,0 @@
|
|
1 |
-
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:baf2213c1d6bc1d0be46dd88c9a04e50558d177c1d6364d9d627475693bfae40
|
3 |
-
size 28078831
|
|
|
|
|
|
|
|
orig_model/configuration.json
DELETED
@@ -1,155 +0,0 @@
|
|
1 |
-
{
|
2 |
-
"framework": "PyTorch",
|
3 |
-
"task" : "text-to-speech",
|
4 |
-
"model" : {
|
5 |
-
"type" : "sambert-hifigan",
|
6 |
-
"lang_type" : "zhcn",
|
7 |
-
"sample_rate" : 16000,
|
8 |
-
"custom_ckpt": {
|
9 |
-
"voice_name" : "F7",
|
10 |
-
"am_ckpt" : "basemodel_16k/sambert/ckpt",
|
11 |
-
"am_config" : "basemodel_16k/sambert/config.yaml",
|
12 |
-
"voc_ckpt" : "basemodel_16k/hifigan/ckpt",
|
13 |
-
"voc_config" : "basemodel_16k/hifigan/config.yaml",
|
14 |
-
"audio_config" : "basemodel_16k/audio_config_se_16k.yaml",
|
15 |
-
"se_model" : "basemodel_16k/speaker_embedding/se.onnx"
|
16 |
-
},
|
17 |
-
"am": {
|
18 |
-
"am": {
|
19 |
-
"max_len": 800,
|
20 |
-
|
21 |
-
"embedding_dim": 512,
|
22 |
-
"encoder_num_layers": 8,
|
23 |
-
"encoder_num_heads": 8,
|
24 |
-
"encoder_num_units": 128,
|
25 |
-
"encoder_ffn_inner_dim": 1024,
|
26 |
-
"encoder_dropout": 0.1,
|
27 |
-
"encoder_attention_dropout": 0.1,
|
28 |
-
"encoder_relu_dropout": 0.1,
|
29 |
-
"encoder_projection_units": 32,
|
30 |
-
|
31 |
-
"speaker_units": 512,
|
32 |
-
"emotion_units": 32,
|
33 |
-
|
34 |
-
"predictor_filter_size": 41,
|
35 |
-
"predictor_fsmn_num_layers": 3,
|
36 |
-
"predictor_num_memory_units": 128,
|
37 |
-
"predictor_ffn_inner_dim": 256,
|
38 |
-
"predictor_dropout": 0.1,
|
39 |
-
"predictor_shift": 0,
|
40 |
-
"predictor_lstm_units": 128,
|
41 |
-
"dur_pred_prenet_units": [128, 128],
|
42 |
-
"dur_pred_lstm_units": 128,
|
43 |
-
|
44 |
-
"decoder_prenet_units": [256, 256],
|
45 |
-
"decoder_num_layers": 12,
|
46 |
-
"decoder_num_heads": 8,
|
47 |
-
"decoder_num_units": 128,
|
48 |
-
"decoder_ffn_inner_dim": 1024,
|
49 |
-
"decoder_dropout": 0.1,
|
50 |
-
"decoder_attention_dropout": 0.1,
|
51 |
-
"decoder_relu_dropout": 0.1,
|
52 |
-
|
53 |
-
"outputs_per_step": 3,
|
54 |
-
"num_mels": 82,
|
55 |
-
|
56 |
-
"postnet_filter_size": 41,
|
57 |
-
"postnet_fsmn_num_layers": 4,
|
58 |
-
"postnet_num_memory_units": 256,
|
59 |
-
"postnet_ffn_inner_dim": 512,
|
60 |
-
"postnet_dropout": 0.1,
|
61 |
-
"postnet_shift": 17,
|
62 |
-
"postnet_lstm_units": 128,
|
63 |
-
|
64 |
-
|
65 |
-
"nsf_f0_global_maximum": 730.0,
|
66 |
-
"nsf_f0_global_minimum": 30.0,
|
67 |
-
"nsf_norm_type": "global"
|
68 |
-
},
|
69 |
-
|
70 |
-
"audio": {
|
71 |
-
"frame_shift_ms": 12.5
|
72 |
-
},
|
73 |
-
|
74 |
-
"linguistic_unit": {
|
75 |
-
"cleaners": "english_cleaners",
|
76 |
-
"lfeat_type_list": "sy,tone,syllable_flag,word_segment,emo_category,speaker_category",
|
77 |
-
"sy": "dict/sy_dict.txt",
|
78 |
-
"tone": "dict/tone_dict.txt",
|
79 |
-
"syllable_flag": "dict/syllable_flag_dict.txt",
|
80 |
-
"word_segment": "dict/word_segment_dict.txt",
|
81 |
-
"emo_category": "dict/emo_category_dict.txt",
|
82 |
-
"speaker_category": "dict/speaker_dict.txt"
|
83 |
-
},
|
84 |
-
|
85 |
-
"num_gpus": 1,
|
86 |
-
"batch_size": 32,
|
87 |
-
"group_size": 1024,
|
88 |
-
"learning_rate": 0.001,
|
89 |
-
"adam_b1": 0.9,
|
90 |
-
"adam_b2": 0.98,
|
91 |
-
"seed": 1234,
|
92 |
-
|
93 |
-
"num_workers": 4,
|
94 |
-
|
95 |
-
"dist_config": {
|
96 |
-
"dist_backend": "nccl",
|
97 |
-
"dist_url": "tcp://localhost:11111",
|
98 |
-
"world_size": 1
|
99 |
-
}
|
100 |
-
|
101 |
-
},
|
102 |
-
"vocoder" : {
|
103 |
-
"resblock": "1",
|
104 |
-
"num_gpus": 1,
|
105 |
-
"batch_size": 16,
|
106 |
-
"learning_rate": 0.0002,
|
107 |
-
"adam_b1": 0.8,
|
108 |
-
"adam_b2": 0.99,
|
109 |
-
"lr_decay": 0.999,
|
110 |
-
"seed": 1234,
|
111 |
-
|
112 |
-
"bias": true,
|
113 |
-
"causal": false,
|
114 |
-
"nsf_params" : {
|
115 |
-
"nb_harmonics": 7,
|
116 |
-
"nsf_f0_global_maximum": 730.0,
|
117 |
-
"nsf_f0_global_minimum": 30.0,
|
118 |
-
"nsf_norm_type": "global",
|
119 |
-
"sampling_rate": 16000
|
120 |
-
},
|
121 |
-
|
122 |
-
"upsample_rates": [10,5,2,2],
|
123 |
-
"upsample_kernel_sizes": [20,11,4,4],
|
124 |
-
"upsample_initial_channel": 256,
|
125 |
-
"resblock_kernel_sizes": [3,7,11],
|
126 |
-
"resblock_dilation_sizes": [[1,3,5,7], [1,3,5,7], [1,3,5,7]],
|
127 |
-
|
128 |
-
"segment_size": 6400,
|
129 |
-
"num_mels": 80,
|
130 |
-
"num_freq": 1025,
|
131 |
-
"n_fft": 2048,
|
132 |
-
"hop_size": 200,
|
133 |
-
"win_size": 1000,
|
134 |
-
|
135 |
-
"sampling_rate": 16000,
|
136 |
-
|
137 |
-
"fmin": 0,
|
138 |
-
"fmax": 8000,
|
139 |
-
"fmax_for_loss": null,
|
140 |
-
|
141 |
-
"num_workers": 4,
|
142 |
-
|
143 |
-
"dist_config": {
|
144 |
-
"dist_backend": "nccl",
|
145 |
-
"dist_url": "tcp://localhost:54312",
|
146 |
-
"world_size": 1
|
147 |
-
}
|
148 |
-
}
|
149 |
-
},
|
150 |
-
"train": {
|
151 |
-
},
|
152 |
-
"pipeline": {
|
153 |
-
"type": "sambert-hifigan-tts"
|
154 |
-
}
|
155 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/description/aishell3.png
DELETED
Binary file (547 kB)
|
|
orig_model/description/hifigan.jpg
DELETED
Binary file (52.5 kB)
|
|
orig_model/description/notebook_steps/autolabel_done.jpg
DELETED
Git LFS Details
|
orig_model/description/notebook_steps/autolabel_setting.jpg
DELETED
Binary file (463 kB)
|
|
orig_model/description/notebook_steps/build_trainer.jpg
DELETED
Git LFS Details
|
orig_model/description/notebook_steps/fetch_nltk_data.jpg
DELETED
Git LFS Details
|
orig_model/description/notebook_steps/inference.jpg
DELETED
Git LFS Details
|
orig_model/description/notebook_steps/inference_play.jpg
DELETED
Git LFS Details
|
orig_model/description/notebook_steps/training.jpg
DELETED
Git LFS Details
|
orig_model/description/notebook_steps/upload_wavs.jpg
DELETED
Git LFS Details
|
orig_model/description/ptts_normal.png
DELETED
Binary file (115 kB)
|
|
orig_model/description/ptts_structure.png
DELETED
Binary file (232 kB)
|
|
orig_model/description/ptts_vs_normal.png
DELETED
Binary file (74.1 kB)
|
|
orig_model/description/sambert.jpg
DELETED
Binary file (68.7 kB)
|
|
orig_model/description/speaker_embedding.png
DELETED
Binary file (154 kB)
|
|
orig_model/description/tts-system.jpg
DELETED
Binary file (65.1 kB)
|
|
orig_model/description/wav/ptts/6.wav
DELETED
Binary file (141 kB)
|
|
orig_model/description/wav/ptts/7.wav
DELETED
Binary file (295 kB)
|
|
orig_model/description/wav/ptts/8.wav
DELETED
Binary file (335 kB)
|
|
orig_model/description/wav/record/SSB00180288.wav
DELETED
Binary file (53.5 kB)
|
|
orig_model/description/wav/record/SSB00180500.wav
DELETED
Binary file (101 kB)
|
|
orig_model/description/wav/record/SSB00180503.wav
DELETED
Binary file (46.1 kB)
|
|
orig_model/resource.zip
DELETED
@@ -1,3 +0,0 @@
|
|
1 |
-
version https://git-lfs.github.com/spec/v1
|
2 |
-
oid sha256:3d7eb353f4a09aa7ef826145ff4dd7aaa80c6c970cc7055c9d016d67771ad0fe
|
3 |
-
size 247832832
|
|
|
|
|
|
|
|
orig_model/resource/festival/Sable.v0_2.dtd
DELETED
@@ -1,137 +0,0 @@
|
|
1 |
-
<!-- <!DOCTYPE sable SYSTEM "Sable.v0_2.dtd" [ -->
|
2 |
-
<!--;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-->
|
3 |
-
<!-- -->
|
4 |
-
<!-- Centre for Speech Technology Research -->
|
5 |
-
<!-- University of Edinburgh, UK -->
|
6 |
-
<!-- Copyright (c) 1998 -->
|
7 |
-
<!-- All Rights Reserved. -->
|
8 |
-
<!-- -->
|
9 |
-
<!-- Permission is hereby granted, free of charge, to use and distribute -->
|
10 |
-
<!-- this software and its documentation without restriction, including -->
|
11 |
-
<!-- without limitation the rights to use, copy, modify, merge, publish, -->
|
12 |
-
<!-- distribute, sublicense, and/or sell copies of this work, and to -->
|
13 |
-
<!-- permit persons to whom this work is furnished to do so, subject to -->
|
14 |
-
<!-- the following conditions: -->
|
15 |
-
<!-- 1. The code must retain the above copyright notice, this list of -->
|
16 |
-
<!-- conditions and the following disclaimer. -->
|
17 |
-
<!-- 2. Any modifications must be clearly marked as such. -->
|
18 |
-
<!-- 3. Original authors' names are not deleted. -->
|
19 |
-
<!-- 4. The authors' names are not used to endorse or promote products -->
|
20 |
-
<!-- derived from this software without specific prior written -->
|
21 |
-
<!-- permission. -->
|
22 |
-
<!-- -->
|
23 |
-
<!-- THE UNIVERSITY OF EDINBURGH AND THE CONTRIBUTORS TO THIS WORK -->
|
24 |
-
<!-- DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING -->
|
25 |
-
<!-- ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT -->
|
26 |
-
<!-- SHALL THE UNIVERSITY OF EDINBURGH NOR THE CONTRIBUTORS BE LIABLE -->
|
27 |
-
<!-- FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -->
|
28 |
-
<!-- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN -->
|
29 |
-
<!-- AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, -->
|
30 |
-
<!-- ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF -->
|
31 |
-
<!-- THIS SOFTWARE. -->
|
32 |
-
<!-- -->
|
33 |
-
<!-- -->
|
34 |
-
<!-- An early draft of SABLE 0.1 (Jan 8th 1998) -->
|
35 |
-
<!-- (Alan W Black [email protected]) -->
|
36 |
-
<!-- This not an official DTD just one that allows a mock up of the -->
|
37 |
-
<!-- system for Festival-1.2.1 and later -->
|
38 |
-
<!-- -->
|
39 |
-
<!-- Modified to be XML compliant April 2nd 1998 -->
|
40 |
-
<!-- -->
|
41 |
-
<!-- Modified for SABLE 0.2 (August 15, 1998) -->
|
42 |
-
<!-- (Richard Sproat [email protected]) -->
|
43 |
-
<!-- -->
|
44 |
-
<!-- Note that in order to use this as both an XML and SGML DTD, we need -->
|
45 |
-
<!-- to declare OMITTAG NO in the accompanying sable.decl for SGML. -->
|
46 |
-
<!-- This means that end tags are REQUIRED for a sable document to be -->
|
47 |
-
<!-- conformant, even when viewed as an SGML document. -->
|
48 |
-
|
49 |
-
<!ENTITY % baseelements "EMPH |
|
50 |
-
BREAK |
|
51 |
-
PITCH |
|
52 |
-
RATE |
|
53 |
-
VOLUME |
|
54 |
-
AUDIO |
|
55 |
-
ENGINE |
|
56 |
-
MARKER |
|
57 |
-
PRON |
|
58 |
-
SAYAS |
|
59 |
-
LANGUAGE |
|
60 |
-
SPEAKER |
|
61 |
-
DIV">
|
62 |
-
|
63 |
-
<!ELEMENT SABLE (#PCDATA| %baseelements; )*>
|
64 |
-
|
65 |
-
<!-- The non-hierarchical ones -->
|
66 |
-
<!ELEMENT BREAK EMPTY >
|
67 |
-
<!ATTLIST BREAK
|
68 |
-
LEVEL (large|medium|small|none|NUMBER) "medium"
|
69 |
-
TYPE (quest|excl|period|comma) #IMPLIED
|
70 |
-
MSEC CDATA #IMPLIED
|
71 |
-
MARK CDATA #IMPLIED>
|
72 |
-
<!ELEMENT AUDIO EMPTY >
|
73 |
-
<!ATTLIST AUDIO
|
74 |
-
SRC CDATA #IMPLIED
|
75 |
-
MODE (background|insertion) "insertion"
|
76 |
-
LEVEL CDATA #IMPLIED
|
77 |
-
MARK CDATA #IMPLIED>
|
78 |
-
<!ELEMENT MARKER EMPTY >
|
79 |
-
<!ATTLIST MARKER
|
80 |
-
MARK CDATA #IMPLIED>
|
81 |
-
|
82 |
-
<!-- The non-nestable ones -->
|
83 |
-
|
84 |
-
<!ELEMENT PRON (#PCDATA) >
|
85 |
-
<!ATTLIST PRON IPA CDATA #IMPLIED
|
86 |
-
SUB CDATA #IMPLIED
|
87 |
-
ORIGIN CDATA #IMPLIED
|
88 |
-
MARK CDATA #IMPLIED>
|
89 |
-
<!ELEMENT SAYAS (#PCDATA) >
|
90 |
-
<!ATTLIST SAYAS MODE (literal|date|time|phone|net|postal|currency|math|fraction|measure|ordinal|cardinal|name) #REQUIRED
|
91 |
-
MODETYPE (DMY|MDY|YMD|YM|MY|MD|HM|HMS|EMAIL|URL) #IMPLIED
|
92 |
-
MARK CDATA #IMPLIED>
|
93 |
-
|
94 |
-
<!-- The nestable ones -->
|
95 |
-
|
96 |
-
<!ELEMENT EMPH ( #PCDATA | %baseelements; )*>
|
97 |
-
<!ATTLIST EMPH LEVEL (Strong|Moderate|None|Reduced|NUMBER) "moderate"
|
98 |
-
MARK CDATA #IMPLIED>
|
99 |
-
<!ELEMENT PITCH ( #PCDATA | %baseelements; )*>
|
100 |
-
<!ATTLIST PITCH BASE CDATA "0%"
|
101 |
-
MIDDLE CDATA "0%"
|
102 |
-
RANGE CDATA "0%"
|
103 |
-
MARK CDATA #IMPLIED>
|
104 |
-
<!ELEMENT RATE ( #PCDATA | %baseelements; )*>
|
105 |
-
<!ATTLIST RATE SPEED CDATA "0%"
|
106 |
-
MARK CDATA #IMPLIED>
|
107 |
-
<!ELEMENT VOLUME ( #PCDATA | %baseelements; )*>
|
108 |
-
<!ATTLIST VOLUME LEVEL CDATA "medium"
|
109 |
-
MARK CDATA #IMPLIED>
|
110 |
-
<!ELEMENT ENGINE ( #PCDATA | %baseelements; )*>
|
111 |
-
<!ATTLIST ENGINE ID CDATA #IMPLIED
|
112 |
-
DATA CDATA #IMPLIED
|
113 |
-
MARK CDATA #IMPLIED>
|
114 |
-
|
115 |
-
<!ELEMENT LANGUAGE ( #PCDATA | %baseelements; )*>
|
116 |
-
<!ATTLIST LANGUAGE ID CDATA #IMPLIED
|
117 |
-
CODE CDATA #IMPLIED
|
118 |
-
MARK CDATA #IMPLIED>
|
119 |
-
<!ELEMENT SPEAKER ( #PCDATA | %baseelements; )*>
|
120 |
-
<!ATTLIST SPEAKER GENDER (male|female) #IMPLIED
|
121 |
-
AGE (older|middle|younger|teen|child) #IMPLIED
|
122 |
-
NAME CDATA #IMPLIED
|
123 |
-
MARK CDATA #IMPLIED>
|
124 |
-
|
125 |
-
<!ELEMENT DIV ( #PCDATA | %baseelements; )*>
|
126 |
-
<!ATTLIST DIV TYPE (sentence|paragraph) #IMPLIED
|
127 |
-
MARK CDATA #IMPLIED>
|
128 |
-
|
129 |
-
<!-- Character entities for latin 1 -->
|
130 |
-
|
131 |
-
<!ENTITY % ISOlat1 PUBLIC
|
132 |
-
"-//SABLE//ENTITIES Added Latin 1 for SABLE//EN"
|
133 |
-
"sable-latin.ent" >
|
134 |
-
%ISOlat1;
|
135 |
-
|
136 |
-
|
137 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/Singing.v0_1.dtd
DELETED
@@ -1,34 +0,0 @@
|
|
1 |
-
<!-- <!DOCTYPE singing SYSTEM "Singing.v0_1.dtd" [ -->
|
2 |
-
|
3 |
-
<!ENTITY % baseelements "PITCH |
|
4 |
-
DURATION
|
5 |
-
">
|
6 |
-
|
7 |
-
<!ELEMENT SINGING (#PCDATA| %baseelements; )*>
|
8 |
-
<!ATTLIST SINGING BPM CDATA "120"
|
9 |
-
MARK CDATA #IMPLIED>
|
10 |
-
|
11 |
-
<!ELEMENT PITCH ( #PCDATA | %baseelements; )*>
|
12 |
-
<!ATTLIST PITCH FREQ CDATA "X"
|
13 |
-
NOTE CDATA "X"
|
14 |
-
MARK CDATA #IMPLIED>
|
15 |
-
|
16 |
-
<!ELEMENT DURATION ( #PCDATA | %baseelements; )*>
|
17 |
-
<!ATTLIST DURATION SECONDS CDATA "X"
|
18 |
-
BEATS CDATA "X"
|
19 |
-
MARK CDATA #IMPLIED>
|
20 |
-
|
21 |
-
<!ELEMENT REST ( #PCDATA | %baseelements; )*>
|
22 |
-
<!ATTLIST REST SECONDS CDATA "X"
|
23 |
-
BEATS CDATA "X"
|
24 |
-
MARK CDATA #IMPLIED>
|
25 |
-
|
26 |
-
<!-- Character entities for latin 1 -->
|
27 |
-
|
28 |
-
<!ENTITY % ISOlat1 PUBLIC
|
29 |
-
"-//SINGING//ENTITIES Added Latin 1 for SINGING//EN"
|
30 |
-
"sable-latin.ent" >
|
31 |
-
%ISOlat1;
|
32 |
-
|
33 |
-
|
34 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/VCLocalRules
DELETED
@@ -1,8 +0,0 @@
|
|
1 |
-
SIOD = siod.scm web.scm cstr.scm fringe.scm
|
2 |
-
|
3 |
-
.copy_from_est: $(SIOD)
|
4 |
-
|
5 |
-
$(SIOD) :
|
6 |
-
@echo 'Copy $@ from EST/lib/siod'
|
7 |
-
-del $@
|
8 |
-
copy $(EST)\lib\siod\$@ $@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/apml.scm
DELETED
@@ -1,551 +0,0 @@
|
|
1 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2 |
-
;;; ;;
|
3 |
-
;;; Centre for Speech Technology Research ;;
|
4 |
-
;;; University of Edinburgh, UK ;;
|
5 |
-
;;; Copyright (c) 2002 ;;
|
6 |
-
;;; All Rights Reserved. ;;
|
7 |
-
;;; ;;
|
8 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;
|
9 |
-
;;; this software and its documentation without restriction, including ;;
|
10 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;
|
11 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;
|
12 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;
|
13 |
-
;;; the following conditions: ;;
|
14 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;
|
15 |
-
;;; conditions and the following disclaimer. ;;
|
16 |
-
;;; 2. Any modifications must be clearly marked as such. ;;
|
17 |
-
;;; 3. Original authors' names are not deleted. ;;
|
18 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;
|
19 |
-
;;; derived from this software without specific prior written ;;
|
20 |
-
;;; permission. ;;
|
21 |
-
;;; ;;
|
22 |
-
;;; THE UNIVERSITY OF EDINBURGH AND THE CONTRIBUTORS TO THIS WORK ;;
|
23 |
-
;;; DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ;;
|
24 |
-
;;; ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT ;;
|
25 |
-
;;; SHALL THE UNIVERSITY OF EDINBURGH NOR THE CONTRIBUTORS BE LIABLE ;;
|
26 |
-
;;; FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ;;
|
27 |
-
;;; WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN ;;
|
28 |
-
;;; AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ;;
|
29 |
-
;;; ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF ;;
|
30 |
-
;;; THIS SOFTWARE. ;;
|
31 |
-
;;; ;;
|
32 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
33 |
-
;;; Author: Rob Clark
|
34 |
-
;;; Date: July 2002
|
35 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
36 |
-
;;
|
37 |
-
;; Sets up the current voice to synthesise from APML.
|
38 |
-
;;
|
39 |
-
;;
|
40 |
-
|
41 |
-
(require 'apml_f2bf0lr)
|
42 |
-
(require 'apml_kaldurtreeZ)
|
43 |
-
|
44 |
-
;; Default pitch settings (if unspecified in current voice.)
|
45 |
-
|
46 |
-
(defvar apml_default_pitch_mean 170 )
|
47 |
-
(defvar apml_default_pitch_standard_deviation 34 )
|
48 |
-
|
49 |
-
;; apml sythesis wrappers.
|
50 |
-
|
51 |
-
(define (apml_client_synth apml)
|
52 |
-
"(apml_client_synth apml)
|
53 |
-
Synthesise apml and return waveform(s) to client."
|
54 |
-
(utt.send.wave.client (apml_synth apml)))
|
55 |
-
|
56 |
-
(define (apml_synth apml)
|
57 |
-
"(apml_synth xml)
|
58 |
-
Synthesis an apml string."
|
59 |
-
(let ((tmpfile (make_tmp_filename))
|
60 |
-
utt)
|
61 |
-
(string_to_file tmpfile apml)
|
62 |
-
(set! utt (apml_file_synth tmpfile))
|
63 |
-
(delete-file tmpfile)
|
64 |
-
utt))
|
65 |
-
|
66 |
-
(define (apml_file_synth filename)
|
67 |
-
"(apml_file_synth filename)
|
68 |
-
Synthesis an apml file."
|
69 |
-
(let ((utt (Utterance Tokens nil)))
|
70 |
-
(utt.load utt filename)
|
71 |
-
(utt.synth utt)))
|
72 |
-
|
73 |
-
(define (string_to_file file s)
|
74 |
-
"(string_to_file file string)
|
75 |
-
Write string to file."
|
76 |
-
(let ((fd))
|
77 |
-
(set! fd (fopen file "wb"))
|
78 |
-
(format fd "%s" s)
|
79 |
-
(fclose fd)))
|
80 |
-
|
81 |
-
|
82 |
-
;;;
|
83 |
-
;;; Phrasing.
|
84 |
-
;;;
|
85 |
-
|
86 |
-
;; phrasing CART.
|
87 |
-
;
|
88 |
-
; It has been decided that by default, only punctuation should affect
|
89 |
-
; phrasing (and subsequently pauses)
|
90 |
-
;
|
91 |
-
(set! apml_phrase_tree
|
92 |
-
'
|
93 |
-
((lisp_apml_punc in ("?" "." ":")) ; big punctuation
|
94 |
-
((BB))
|
95 |
-
((lisp_apml_punc in ("'" "\"" "," ";")) ; else little punctuation
|
96 |
-
((B))
|
97 |
-
((lisp_apml_last_word is 1)
|
98 |
-
((BB)) ; need a BB at the end!
|
99 |
-
((NB)))))) ; else nothing
|
100 |
-
|
101 |
-
;; feature functions for phrasing
|
102 |
-
(define (apml_punc word)
|
103 |
-
(item.feat (item.relation.parent word 'Token) 'punc))
|
104 |
-
|
105 |
-
(define (apml_last_word word)
|
106 |
-
(if (item.next word)
|
107 |
-
"0" "1"))
|
108 |
-
|
109 |
-
|
110 |
-
;;;
|
111 |
-
;;; Pauses
|
112 |
-
;;;
|
113 |
-
|
114 |
-
;; feature functions for pauses
|
115 |
-
(define (apml_is_pause word)
|
116 |
-
(if (item.relation (item.relation.parent word 'Token) 'Pause)
|
117 |
-
t
|
118 |
-
nil))
|
119 |
-
|
120 |
-
(define (apml_pause word)
|
121 |
-
(if (item.relation word 'Pause)
|
122 |
-
(item.feat (item.relation.parent (item.relation.parent word 'Token) 'Pause) "sec")
|
123 |
-
0))
|
124 |
-
|
125 |
-
(define (Apml_Pauses utt)
|
126 |
-
"(Pauses UTT)
|
127 |
-
Predict pause insertion for apml."
|
128 |
-
(let ((words (utt.relation.items utt 'Word)) lastword tpname)
|
129 |
-
(if words
|
130 |
-
(begin
|
131 |
-
(insert_initial_pause utt) ;; always have a start pause
|
132 |
-
(set! lastword (car (last words)))
|
133 |
-
(mapcar
|
134 |
-
(lambda (w)
|
135 |
-
(let ((pbreak (item.feat w "pbreak"))
|
136 |
-
(emph (item.feat w "R:Token.parent.EMPH")))
|
137 |
-
(cond
|
138 |
-
((apml_is_pause w)
|
139 |
-
(insert_pause utt w))
|
140 |
-
((or (string-equal "B" pbreak)
|
141 |
-
(string-equal "BB" pbreak))
|
142 |
-
(insert_pause utt w))
|
143 |
-
((equal? w lastword)
|
144 |
-
(insert_pause utt w)))))
|
145 |
-
words)
|
146 |
-
;; The embarassing bit. Remove any words labelled as punc or fpunc
|
147 |
-
(mapcar
|
148 |
-
(lambda (w)
|
149 |
-
(let ((pos (item.feat w "pos")))
|
150 |
-
(if (or (string-equal "punc" pos)
|
151 |
-
(string-equal "fpunc" pos))
|
152 |
-
(let ((pbreak (item.feat w "pbreak"))
|
153 |
-
(wp (item.relation w 'Phrase)))
|
154 |
-
(if (and (string-matches pbreak "BB?")
|
155 |
-
(item.relation.prev w 'Word))
|
156 |
-
(item.set_feat
|
157 |
-
(item.relation.prev w 'Word) "pbreak" pbreak))
|
158 |
-
(item.relation.remove w 'Word)
|
159 |
-
;; can't refer to w as we've just deleted it
|
160 |
-
(item.relation.remove wp 'Phrase)))))
|
161 |
-
words)))
|
162 |
-
utt))
|
163 |
-
|
164 |
-
|
165 |
-
|
166 |
-
;;;
|
167 |
-
;;; Intonation.
|
168 |
-
;;;
|
169 |
-
|
170 |
-
;; Accent prediction (well transfer really).
|
171 |
-
;;
|
172 |
-
;; We treat L+H* L-H% on a single syllable as a special case.
|
173 |
-
|
174 |
-
(set! apml_accent_cart
|
175 |
-
'
|
176 |
-
((lisp_apml_accent is "Hstar")
|
177 |
-
((H*))
|
178 |
-
((lisp_apml_accent is "Lstar")
|
179 |
-
((L*))
|
180 |
-
((lisp_apml_LHLH is "LHLH")
|
181 |
-
((L+H*L-H%))
|
182 |
-
((lisp_apml_accent is "LplusHstar")
|
183 |
-
((L+H*))
|
184 |
-
((lisp_apml_accent is "LstarplusH")
|
185 |
-
((L*+H))
|
186 |
-
((NONE))))))))
|
187 |
-
|
188 |
-
(set! apml_boundary_cart
|
189 |
-
'
|
190 |
-
((lisp_apml_boundary is "LL")
|
191 |
-
((L-L%))
|
192 |
-
((lisp_apml_LHLH is "LHLH")
|
193 |
-
((NONE)) ; this is dealt with by the accent feature
|
194 |
-
((lisp_apml_boundary is "LH")
|
195 |
-
((L-H%))
|
196 |
-
((lisp_apml_boundary is "HH")
|
197 |
-
((H-H%))
|
198 |
-
((lisp_apml_boundary is "HL")
|
199 |
-
((H-L%))
|
200 |
-
((NONE))))))))
|
201 |
-
|
202 |
-
;; feature functions.
|
203 |
-
(define (apml_accent syl)
|
204 |
-
(let ((token (item.relation.parent (item.relation.parent syl 'SylStructure) 'Token)))
|
205 |
-
(if (and (eq (item.feat syl 'stress) 1)
|
206 |
-
(item.relation.parent token 'Emphasis))
|
207 |
-
(item.feat (item.relation.parent token 'Emphasis) 'x-pitchaccent)
|
208 |
-
0)))
|
209 |
-
|
210 |
-
(define (apml_boundary syl)
|
211 |
-
(let ((token (item.relation.parent (item.relation.parent syl 'SylStructure) 'Token)))
|
212 |
-
(if (and (> (item.feat syl 'syl_break) 0)
|
213 |
-
(item.relation.parent token 'Boundary))
|
214 |
-
(item.feat (item.relation.parent token 'Boundary) 'type)
|
215 |
-
0)))
|
216 |
-
|
217 |
-
(define (apml_LHLH syl)
|
218 |
-
(let ((accent (apml_accent syl))
|
219 |
-
(boundary (apml_boundary syl)))
|
220 |
-
(if (and (string-equal accent "LplusHstar")
|
221 |
-
(string-equal boundary "LH"))
|
222 |
-
"LHLH"
|
223 |
-
0)))
|
224 |
-
|
225 |
-
|
226 |
-
(define (apml_seg_is_LHLH_vowel seg)
|
227 |
-
(if (and (string-equal (apml_LHLH (item.relation.parent seg 'SylStructure))
|
228 |
-
"LHLH")
|
229 |
-
(string-equal (item.feat seg 'ph_vc) "+"))
|
230 |
-
"LHLH"
|
231 |
-
0))
|
232 |
-
|
233 |
-
|
234 |
-
;;;; feature functions:
|
235 |
-
|
236 |
-
(define (apml_tgtype syl)
|
237 |
-
(let ((l (apml_boundl (item.relation.parent syl 'SylStructure)))
|
238 |
-
(r (apml_boundr (item.relation.parent syl 'SylStructure))))
|
239 |
-
(if (eq (item.feat syl 'accented) 0)
|
240 |
-
0 ; this is a quirk related to the way the models were trained
|
241 |
-
(cond
|
242 |
-
((eq l 0)
|
243 |
-
1)
|
244 |
-
((eq r 1)
|
245 |
-
3)
|
246 |
-
(t 2)))))
|
247 |
-
|
248 |
-
|
249 |
-
(define (apml_iecount syl)
|
250 |
-
(if (eq (item.feat syl 'accented) 0)
|
251 |
-
0 ; this is a quirk related to the way the models were trained
|
252 |
-
(+ (item.feat syl 'asyl_in) 1)))
|
253 |
-
|
254 |
-
;; suport functions.
|
255 |
-
(define (apml_boundl word)
|
256 |
-
"(apml_boundl word)
|
257 |
-
Number of boundaries in this performative to the left of this word."
|
258 |
-
(let ((w (item.prev word))
|
259 |
-
(c 0))
|
260 |
-
(while (and w (apml_same_p w word))
|
261 |
-
(if (item.relation.parent (item.relation.parent w 'Token) 'Boundary)
|
262 |
-
(set! c (+ c 1)))
|
263 |
-
(set! w (item.prev w)))
|
264 |
-
c))
|
265 |
-
|
266 |
-
(define (apml_boundr word)
|
267 |
-
"(apml_boundr word)
|
268 |
-
Number of boundaries in this performative to the right of this word."
|
269 |
-
(let ((w word)
|
270 |
-
(c 0))
|
271 |
-
(while (and w (apml_same_p w word))
|
272 |
-
(if (item.relation.parent (item.relation.parent w 'Token) 'Boundary)
|
273 |
-
(set! c (+ c 1)))
|
274 |
-
(set! w (item.next w)))
|
275 |
-
c))
|
276 |
-
|
277 |
-
(define (apml_same_p w1 w2)
|
278 |
-
"(apml_same_p w1 w2)
|
279 |
-
Are these two words in the same performative?"
|
280 |
-
(let ((p1 (item.relation.parent (item.relation.parent w1 'Token) 'SemStructure))
|
281 |
-
(p2 (item.relation.parent (item.relation.parent w1 'Token) 'SemStructure)))
|
282 |
-
(if (and (item.parent p1) (item.parent p2)) ; not true if theme/rheme omitted.
|
283 |
-
(equal? (item.parent p1) (item.parent p2))
|
284 |
-
(equal? p1 p2))))
|
285 |
-
|
286 |
-
;;;
|
287 |
-
;;; segment timings
|
288 |
-
;;;
|
289 |
-
|
290 |
-
(define (apml_seg_times utt)
|
291 |
-
"(apml_seg_times utt)
|
292 |
-
Output the segment timings for an apml utterance."
|
293 |
-
(let ((segs (utt.relation.items utt 'Segment)))
|
294 |
-
(mapcar
|
295 |
-
(lambda (x)
|
296 |
-
(format t "%s %s\n" (item.name x) (item.feat x 'end)))
|
297 |
-
segs)
|
298 |
-
t))
|
299 |
-
|
300 |
-
;;;
|
301 |
-
;;; Additional functions for f0model.
|
302 |
-
;;;
|
303 |
-
|
304 |
-
|
305 |
-
(define (find_hstar_left syl)
|
306 |
-
"(find_hstar_left syl)
|
307 |
-
If the closest accent or boundary to the left is H* return how many syllables away it is. Returns 0 if nearest accent is not H*"
|
308 |
-
(let ((count 0))
|
309 |
-
;; if this syllable has a pitch event
|
310 |
-
(if (or (not (string-equal (item.feat syl 'tobi_accent) "NONE"))
|
311 |
-
(not (string-equal (item.feat syl 'tobi_endtone) "NONE")))
|
312 |
-
0)
|
313 |
-
(while (and syl
|
314 |
-
(string-equal (item.feat syl 'tobi_accent) "NONE")
|
315 |
-
(string-equal (item.feat syl 'tobi_endtone) "NONE"))
|
316 |
-
(set! count (+ count 1))
|
317 |
-
(set! syl (item.prev syl)))
|
318 |
-
(cond
|
319 |
-
;; run out of syllables before finding accent
|
320 |
-
((null syl)
|
321 |
-
0)
|
322 |
-
((string-equal (item.feat syl 'tobi_accent) "H*")
|
323 |
-
count)
|
324 |
-
(t 0))))
|
325 |
-
|
326 |
-
(define (find_ll_right syl)
|
327 |
-
"(find_ll_right syl)
|
328 |
-
If the closest accent or boundary to the right is L-L% return how many syllables away it is. Returns 0 if nearest is not L-L%."
|
329 |
-
(let ((count 0))
|
330 |
-
;; if this syllable has a pitch event
|
331 |
-
(if (or (not (string-equal (item.feat syl 'tobi_accent) "NONE"))
|
332 |
-
(not (string-equal (item.feat syl 'tobi_endtone) "NONE")))
|
333 |
-
0)
|
334 |
-
(while (and syl
|
335 |
-
(string-equal (item.feat syl 'tobi_accent) "NONE")
|
336 |
-
(string-equal (item.feat syl 'tobi_endtone) "NONE"))
|
337 |
-
(set! count (+ count 1))
|
338 |
-
(set! syl (item.next syl)))
|
339 |
-
(cond
|
340 |
-
;; run out of syllables before finding boundary
|
341 |
-
((null syl)
|
342 |
-
0)
|
343 |
-
((string-equal (item.feat syl 'tobi_endtone) "L-L%")
|
344 |
-
count)
|
345 |
-
(t 0))))
|
346 |
-
|
347 |
-
(define (l_spread syl)
|
348 |
-
"(l_spread syl)
|
349 |
-
Proportion of pitch lowering required due to L- spreading backwards."
|
350 |
-
(let ((l (find_hstar_left syl))
|
351 |
-
(r (find_ll_right syl)))
|
352 |
-
(cond
|
353 |
-
((or (eq l 0)
|
354 |
-
(eq r 0))
|
355 |
-
0)
|
356 |
-
(t
|
357 |
-
(/ r (- (+ l r) 1))))))
|
358 |
-
|
359 |
-
|
360 |
-
;;;
|
361 |
-
;;; Debuging and other useful stuff.
|
362 |
-
;;;
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
(define (apml_print_semstruct utt)
|
367 |
-
"(apml_print_semstruct utt)
|
368 |
-
Pretty print APML semantic structure."
|
369 |
-
(let ((i (utt.relation.first utt 'SemStructure)))
|
370 |
-
(while (not (null i))
|
371 |
-
(apml_pss_item 0 i)
|
372 |
-
(apml_pss_daughters 1 (item.daughters i))
|
373 |
-
(set! i (item.next i)))))
|
374 |
-
|
375 |
-
(define (apml_pss_daughters depth list)
|
376 |
-
(mapcar
|
377 |
-
(lambda (x)
|
378 |
-
(apml_pss_item depth x)
|
379 |
-
(apml_pss_daughters (+ depth 1) (item.daughters x))
|
380 |
-
)
|
381 |
-
list))
|
382 |
-
|
383 |
-
|
384 |
-
(define (apml_pss_item depth item)
|
385 |
-
(let ((c 0))
|
386 |
-
(while (< c depth)
|
387 |
-
(format t " ")
|
388 |
-
(set! c (+ c 1)))
|
389 |
-
(format t "%s\n" (item.name item))))
|
390 |
-
|
391 |
-
|
392 |
-
(define (apml_print_words utt)
|
393 |
-
"(apml_print_words utt)
|
394 |
-
Pretty print APML words with associated accents."
|
395 |
-
(mapcar
|
396 |
-
(lambda (x)
|
397 |
-
(format t "%s (" (item.name x))
|
398 |
-
(apml_pww_accent x)
|
399 |
-
(apml_pww_boundary x)
|
400 |
-
(apml_pww_pause x)
|
401 |
-
(format t ")\n"))
|
402 |
-
(utt.relation.items utt 'Word))
|
403 |
-
t)
|
404 |
-
|
405 |
-
(define (apml_pww_accent item)
|
406 |
-
(let ((p (item.relation.parent (item.relation.parent item 'Token) 'Emphasis)))
|
407 |
-
(if p (apml_ppw_list (item.features p)))))
|
408 |
-
|
409 |
-
(define (apml_pww_boundary item)
|
410 |
-
(let ((p (item.relation.parent (item.relation.parent item 'Token) 'Boundary)))
|
411 |
-
(if p (apml_ppw_list (item.features p)))))
|
412 |
-
|
413 |
-
(define (apml_pww_pause item)
|
414 |
-
(let ((p (item.relation.parent (item.relation.parent item 'Token) 'Pause)))
|
415 |
-
(if p (apml_ppw_list (item.features p)))))
|
416 |
-
|
417 |
-
(define (apml_ppw_list l)
|
418 |
-
(mapcar
|
419 |
-
(lambda (x)
|
420 |
-
(format t " %s" x))
|
421 |
-
(flatten l)))
|
422 |
-
|
423 |
-
|
424 |
-
(define (apml_print_sylstructure utt filename)
|
425 |
-
"(apml_print_sylstructure utt filename)
|
426 |
-
Pretty print APML syllable structure. Filename t for stdout"
|
427 |
-
(let (fd)
|
428 |
-
(if (not (eq? filename t))
|
429 |
-
(set! fd (fopen filename "wb"))
|
430 |
-
(set! fd t))
|
431 |
-
(mapcar
|
432 |
-
(lambda (x)
|
433 |
-
(format fd "%s\n" (item.name x))
|
434 |
-
(apml_psyl fd x))
|
435 |
-
(utt.relation.items utt 'Word))
|
436 |
-
t))
|
437 |
-
|
438 |
-
(define (apml_psyl fd word)
|
439 |
-
(mapcar
|
440 |
-
(lambda (x)
|
441 |
-
(apml_psegs fd x)
|
442 |
-
(if (eq (item.feat x 'stress) 1)
|
443 |
-
(format fd " (1)"))
|
444 |
-
(if (item.relation.daughter1 x 'Intonation)
|
445 |
-
(begin
|
446 |
-
(let ((ie (item.relation.daughter1 x 'Intonation)))
|
447 |
-
(format fd " [")
|
448 |
-
(while ie
|
449 |
-
(format fd "%s" (item.name ie))
|
450 |
-
(set! ie (item.next ie))
|
451 |
-
(if ie (format t " ")))
|
452 |
-
(format fd "]"))))
|
453 |
-
(format fd "\n"))
|
454 |
-
(item.daughters (item.relation word 'SylStructure))))
|
455 |
-
|
456 |
-
(define (apml_psegs fd syl)
|
457 |
-
(let ((segs (item.daughters syl)))
|
458 |
-
(format fd " ")
|
459 |
-
(while segs
|
460 |
-
(format fd "%s" (item.name (car segs)))
|
461 |
-
(if (cdr segs)
|
462 |
-
(format fd "."))
|
463 |
-
(set! segs (cdr segs)))))
|
464 |
-
|
465 |
-
|
466 |
-
(define (apml_get_lr_params)
|
467 |
-
(let ((m 0)
|
468 |
-
(s 0))
|
469 |
-
(if (or (equal? (Parameter.get 'Int_Target_Method) Int_Targets_LR)
|
470 |
-
(equal? (Parameter.get 'Int_Target_Method) Int_Targets_5_LR))
|
471 |
-
(begin
|
472 |
-
(set! m (car (cdr (car int_lr_params))))
|
473 |
-
(set! s (car (cdr (car (cdr int_lr_params))))))
|
474 |
-
(begin
|
475 |
-
(set! m apml_default_pitch_mean)
|
476 |
-
(set! s apml_default_pitch_standard_deviation)))
|
477 |
-
(list m s)))
|
478 |
-
|
479 |
-
|
480 |
-
|
481 |
-
|
482 |
-
(define (apml_initialise)
|
483 |
-
"(apml_initialise)
|
484 |
-
Set up the current voice for apml use."
|
485 |
-
(if (not (string-matches current-voice ".*multisyn.*")) ; nothing if multisyn
|
486 |
-
(cond
|
487 |
-
((or (string-equal (Parameter.get 'Language) "americanenglish")
|
488 |
-
(string-equal (Parameter.get 'Language) "britishenglish"))
|
489 |
-
(begin
|
490 |
-
(format t "Initialising APML for English.\n")
|
491 |
-
;; Phrasing.
|
492 |
-
(Parameter.set 'Phrase_Method 'cart_tree)
|
493 |
-
(set! phrase_cart_tree apml_phrase_tree)
|
494 |
-
;; Pauses.
|
495 |
-
;;(set! duration_cart_tree apml_kal_duration_cart_tree)
|
496 |
-
;;(set! duration_ph_info apml_kal_durs)
|
497 |
-
;;(Parameter.set 'Pause_Method Apml_Pauses)
|
498 |
-
;; Lexicon.
|
499 |
-
;;;; We now assume the lexicon you have already set is suitable,
|
500 |
-
;;;; You probably want to ensure this is "apmlcmu" or "unilex"
|
501 |
-
;;(if (not (member_string "apmlcmu" (lex.list)))
|
502 |
-
;; (load (path-append lexdir "apmlcmu/apmlcmulex.scm")))
|
503 |
-
;;(lex.select "apmlcmu")
|
504 |
-
;; Add other lex entries here:
|
505 |
-
;;(lex.add.entry '("minerals" nil (((m ih n) 1) ((er) 0) ((ax l z) 0))))
|
506 |
-
;;(lex.add.entry '("fibre" nil (((f ay b) 1) ((er) 0))))
|
507 |
-
;;(lex.add.entry '("dont" v (((d ow n t) 1))))
|
508 |
-
;;(lex.add.entry '("pectoris" nil (((p eh k) 2) ((t ao r) 1) ((ih s) 0))))
|
509 |
-
;;(lex.add.entry '("sideeffects" nil (((s ay d) 1) ((ax f) 0) ((eh k t s) 2))))
|
510 |
-
|
511 |
-
;; Intonation events.
|
512 |
-
(set! int_accent_cart_tree apml_accent_cart)
|
513 |
-
(set! int_tone_cart_tree apml_boundary_cart)
|
514 |
-
(Parameter.set 'Int_Method Intonation_Tree)
|
515 |
-
;; Intonation f0 contour.
|
516 |
-
(set! f0_lr_start apml_f2b_f0_lr_start)
|
517 |
-
(set! f0_lr_left apml_f2b_f0_lr_left)
|
518 |
-
(set! f0_lr_mid apml_f2b_f0_lr_mid)
|
519 |
-
(set! f0_lr_right apml_f2b_f0_lr_right)
|
520 |
-
(set! f0_lr_end apml_f2b_f0_lr_end)
|
521 |
-
(set! int_lr_params
|
522 |
-
(list (list 'target_f0_mean (car (apml_get_lr_params)))
|
523 |
-
(list 'target_f0_std (car (cdr (apml_get_lr_params))))
|
524 |
-
(list 'model_f0_mean 170)
|
525 |
-
(list 'model_f0_std 40)))
|
526 |
-
(Parameter.set 'Int_Target_Method Int_Targets_5_LR)
|
527 |
-
nil))
|
528 |
-
((string-equal (Parameter.get 'Language) "italian")
|
529 |
-
(begin
|
530 |
-
(format t "Initialising APML for Italian.\n")
|
531 |
-
;; Phrasing.
|
532 |
-
(Parameter.set 'Phrase_Method 'cart_tree)
|
533 |
-
(set! phrase_cart_tree apml_phrase_tree)
|
534 |
-
;; Intonation events.
|
535 |
-
(set! int_accent_cart_tree apml_accent_cart)
|
536 |
-
(set! int_tone_cart_tree apml_boundary_cart)
|
537 |
-
(Parameter.set 'Int_Method Intonation_Tree)
|
538 |
-
;; Intonation f0 contour.
|
539 |
-
(set! f0_lr_start apml_f2b_f0_lr_start)
|
540 |
-
(set! f0_lr_mid apml_f2b_f0_lr_mid)
|
541 |
-
(set! f0_lr_end apml_f2b_f0_lr_end)
|
542 |
-
(set! int_lr_params
|
543 |
-
(list (list 'target_f0_mean (car (apml_get_lr_params)))
|
544 |
-
(list 'target_f0_std (car (cdr (apml_get_lr_params))))
|
545 |
-
(list 'model_f0_mean 170)
|
546 |
-
(list 'model_f0_std 34)))
|
547 |
-
(Parameter.set 'Int_Target_Method Int_Targets_LR)
|
548 |
-
nil))
|
549 |
-
(t nil))))
|
550 |
-
|
551 |
-
(provide 'apml)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/apml_f2bf0lr.scm
DELETED
@@ -1,530 +0,0 @@
|
|
1 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2 |
-
;;; ;;
|
3 |
-
;;; Centre for Speech Technology Research ;;
|
4 |
-
;;; University of Edinburgh, UK ;;
|
5 |
-
;;; Copyright (c) 2002 ;;
|
6 |
-
;;; All Rights Reserved. ;;
|
7 |
-
;;; ;;
|
8 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;
|
9 |
-
;;; this software and its documentation without restriction, including ;;
|
10 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;
|
11 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;
|
12 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;
|
13 |
-
;;; the following conditions: ;;
|
14 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;
|
15 |
-
;;; conditions and the following disclaimer. ;;
|
16 |
-
;;; 2. Any modifications must be clearly marked as such. ;;
|
17 |
-
;;; 3. Original authors' names are not deleted. ;;
|
18 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;
|
19 |
-
;;; derived from this software without specific prior written ;;
|
20 |
-
;;; permission. ;;
|
21 |
-
;;; ;;
|
22 |
-
;;; THE UNIVERSITY OF EDINBURGH AND THE CONTRIBUTORS TO THIS WORK ;;
|
23 |
-
;;; DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ;;
|
24 |
-
;;; ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT ;;
|
25 |
-
;;; SHALL THE UNIVERSITY OF EDINBURGH NOR THE CONTRIBUTORS BE LIABLE ;;
|
26 |
-
;;; FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ;;
|
27 |
-
;;; WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN ;;
|
28 |
-
;;; AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ;;
|
29 |
-
;;; ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF ;;
|
30 |
-
;;; THIS SOFTWARE. ;;
|
31 |
-
;;; ;;
|
32 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
33 |
-
;;; Author: Rob Clark
|
34 |
-
;;; Date: July 2002
|
35 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
36 |
-
;;
|
37 |
-
;; APML.f0 trees.
|
38 |
-
;;
|
39 |
-
;;
|
40 |
-
|
41 |
-
(set! apml_f2b_f0_lr_start
|
42 |
-
'(
|
43 |
-
( Intercept 163.9871 )
|
44 |
-
( pp.lisp_apml_tgtype -3.1750 (1) )
|
45 |
-
( p.lisp_apml_tgtype 5.0332 (1) )
|
46 |
-
( lisp_apml_tgtype 0.0000 (1) )
|
47 |
-
( n.lisp_apml_tgtype 17.7799 (1) )
|
48 |
-
( nn.lisp_apml_tgtype 13.6845 (1) )
|
49 |
-
( pp.lisp_apml_tgtype 0.0000 (2) )
|
50 |
-
( p.lisp_apml_tgtype 0.0000 (2) )
|
51 |
-
( lisp_apml_tgtype 0.0000 (2) )
|
52 |
-
( n.lisp_apml_tgtype 0.0000 (2) )
|
53 |
-
( nn.lisp_apml_tgtype 0.0000 (2) )
|
54 |
-
( pp.lisp_apml_tgtype 0.0000 (3) )
|
55 |
-
( p.lisp_apml_tgtype 0.0000 (3) )
|
56 |
-
( lisp_apml_tgtype -9.7245 (3) )
|
57 |
-
( n.lisp_apml_tgtype 0.0000 (3) )
|
58 |
-
( nn.lisp_apml_tgtype -2.4009 (3) )
|
59 |
-
( pp.lisp_apml_iecount 0.0000 )
|
60 |
-
( p.lisp_apml_iecount -0.4484 )
|
61 |
-
( lisp_apml_iecount 0.0000 )
|
62 |
-
( n.lisp_apml_iecount -2.0165 )
|
63 |
-
( nn.lisp_apml_iecount 0.0000 )
|
64 |
-
( pp.tobi_accent 0.0000 (H*) )
|
65 |
-
( p.tobi_accent 11.1239 (H*) )
|
66 |
-
( tobi_accent 21.5164 (H*) )
|
67 |
-
( n.tobi_accent -2.5990 (H*) )
|
68 |
-
( nn.tobi_accent -6.5307 (H*) )
|
69 |
-
( pp.tobi_accent 0.0000 (L*) )
|
70 |
-
( p.tobi_accent -10.0000 (L*) )
|
71 |
-
( tobi_accent -5.0000 (L*) )
|
72 |
-
( n.tobi_accent -10.6798 (L*) )
|
73 |
-
( nn.tobi_accent -5.6561 (L*) )
|
74 |
-
( pp.tobi_accent 5.3577 (L*+H) )
|
75 |
-
( p.tobi_accent 60.0000 (L*+H) )
|
76 |
-
( tobi_accent -5.0000 (L*+H) )
|
77 |
-
( n.tobi_accent 0.0000 (L*+H) )
|
78 |
-
( nn.tobi_accent 0.0000 (L*+H) )
|
79 |
-
( pp.tobi_accent 0.0000 (L+H*) )
|
80 |
-
( p.tobi_accent 11.1200 (L+H*) )
|
81 |
-
( tobi_accent 21.5200 (L+H*) )
|
82 |
-
( n.tobi_accent -2.6000 (L+H*) )
|
83 |
-
( nn.tobi_accent -6.5300 (L+H*) )
|
84 |
-
( pp.tobi_endtone 0.0000 (L-L%) )
|
85 |
-
( p.tobi_endtone -0.6164 (L-L%) )
|
86 |
-
( tobi_endtone -50 (L-L%) )
|
87 |
-
( n.tobi_endtone -10.8729 (L-L%) )
|
88 |
-
( nn.tobi_endtone -7.6522 (L-L%) )
|
89 |
-
( pp.tobi_endtone 0.7583 (L-H%) )
|
90 |
-
( p.tobi_endtone 0.0000 (L-H%) )
|
91 |
-
( tobi_endtone -20.0000 (L-H%) )
|
92 |
-
( n.tobi_endtone -11.8935 (L-H%) )
|
93 |
-
( nn.tobi_endtone -7.2012 (L-H%) )
|
94 |
-
( pp.tobi_endtone 0.0000 (H-L%) )
|
95 |
-
( p.tobi_endtone 0.0000 (H-L%) )
|
96 |
-
( tobi_endtone 4.0790 (H-L%) )
|
97 |
-
( n.tobi_endtone -19.3463 (H-L%) )
|
98 |
-
( nn.tobi_endtone -29.3615 (H-L%) )
|
99 |
-
( pp.tobi_endtone 0.0000 (H-H%) )
|
100 |
-
( p.tobi_endtone 0.0000 (H-H%) )
|
101 |
-
( tobi_endtone 0.0000 (H-H%) )
|
102 |
-
( n.tobi_endtone 0.0000 (H-H%) )
|
103 |
-
( nn.tobi_endtone 0.0000 (H-H%) )
|
104 |
-
( pp.tobi_endtone 0.0000 (L-) )
|
105 |
-
( p.tobi_endtone -15.1702 (L-) )
|
106 |
-
( tobi_endtone 0.0000 (L-) )
|
107 |
-
( n.tobi_endtone -14.5562 (L-) )
|
108 |
-
( nn.tobi_endtone 0.0000 (L-) )
|
109 |
-
( pp.tobi_endtone -13.5046 (H-) )
|
110 |
-
( p.tobi_endtone 0.0000 (H-) )
|
111 |
-
( tobi_endtone 6.3377 (H-) )
|
112 |
-
( n.tobi_endtone -6.8631 (H-) )
|
113 |
-
( nn.tobi_endtone 0.0000 (H-) )
|
114 |
-
( p.tobi_accent 60.0000 (L+H*L-H%) )
|
115 |
-
( tobi_accent -60.0000 (L+H*L-H%) )
|
116 |
-
( n.tobi_accent 0.0000 (L+H*L-H%) )
|
117 |
-
( pp.syl_break 0.0000 )
|
118 |
-
( p.syl_break 0.0000 )
|
119 |
-
( syl_break 0.6417 )
|
120 |
-
( n.syl_break 1.3532 )
|
121 |
-
( nn.syl_break 1.0724 )
|
122 |
-
( pp.stress 0.0000 )
|
123 |
-
( p.stress -0.6193 )
|
124 |
-
( stress 2.4121 )
|
125 |
-
( n.stress 0.0000 )
|
126 |
-
( nn.stress 2.5478 )
|
127 |
-
( syl_in -1.4373 )
|
128 |
-
( syl_out 0.4181 )
|
129 |
-
( ssyl_in 0.0000 )
|
130 |
-
( ssyl_out 0.6125 )
|
131 |
-
( asyl_in 0.0000 )
|
132 |
-
( asyl_out 0.9906 )
|
133 |
-
( last_accent 0.0000 )
|
134 |
-
( next_accent -0.3700 )
|
135 |
-
( sub_phrases 0.0000 )
|
136 |
-
( lisp_l_spread -60.0000 )
|
137 |
-
))
|
138 |
-
|
139 |
-
(set! apml_f2b_f0_lr_left
|
140 |
-
'(
|
141 |
-
( Intercept 162.1173 )
|
142 |
-
( pp.lisp_apml_tgtype -1.5875 (1) )
|
143 |
-
( p.lisp_apml_tgtype 4.8101 (1) )
|
144 |
-
( lisp_apml_tgtype 12.8265 (1) )
|
145 |
-
( n.lisp_apml_tgtype 16.3027 (1) )
|
146 |
-
( nn.lisp_apml_tgtype 13.3225 (1) )
|
147 |
-
( pp.lisp_apml_tgtype 0.0000 (2) )
|
148 |
-
( p.lisp_apml_tgtype 1.7434 (2) )
|
149 |
-
( lisp_apml_tgtype 6.7783 (2) )
|
150 |
-
( n.lisp_apml_tgtype 0.6679 (2) )
|
151 |
-
( nn.lisp_apml_tgtype 0.0000 (2) )
|
152 |
-
( pp.lisp_apml_tgtype 1.6494 (3) )
|
153 |
-
( p.lisp_apml_tgtype 1.2861 (3) )
|
154 |
-
( lisp_apml_tgtype -2.0724 (3) )
|
155 |
-
( n.lisp_apml_tgtype 0.0000 (3) )
|
156 |
-
( nn.lisp_apml_tgtype -1.2004 (3) )
|
157 |
-
( pp.lisp_apml_iecount 0.0000 )
|
158 |
-
( p.lisp_apml_iecount -0.5857 )
|
159 |
-
( lisp_apml_iecount 0.0000 )
|
160 |
-
( n.lisp_apml_iecount -2.3543 )
|
161 |
-
( nn.lisp_apml_iecount 0.0000 )
|
162 |
-
( pp.tobi_accent 0.0000 (H*) )
|
163 |
-
( p.tobi_accent 8.5867 (H*) )
|
164 |
-
( tobi_accent 21.2169 (H*) )
|
165 |
-
( n.tobi_accent -1.2995 (H*) )
|
166 |
-
( nn.tobi_accent -6.5056 (H*) )
|
167 |
-
( pp.tobi_accent 0.0000 (L*) )
|
168 |
-
( p.tobi_accent -7.5000 (L*) )
|
169 |
-
( tobi_accent -25.0000 (L*) )
|
170 |
-
( n.tobi_accent -8.3939 (L*) )
|
171 |
-
( nn.tobi_accent -4.5688 (L*) )
|
172 |
-
( pp.tobi_accent 2.6789 (L*+H) )
|
173 |
-
( p.tobi_accent 45.0000 (L*+H) )
|
174 |
-
( tobi_accent -17.5000 (L*+H) )
|
175 |
-
( n.tobi_accent -1.3600 (L*+H) )
|
176 |
-
( nn.tobi_accent 0.0000 (L*+H) )
|
177 |
-
( pp.tobi_accent 0.0000 (L+H*) )
|
178 |
-
( p.tobi_accent 8.5850 (L+H*) )
|
179 |
-
( tobi_accent 21.2200 (L+H*) )
|
180 |
-
( n.tobi_accent -1.3000 (L+H*) )
|
181 |
-
( nn.tobi_accent -6.5050 (L+H*) )
|
182 |
-
( pp.tobi_endtone 1.8117 (L-L%) )
|
183 |
-
( p.tobi_endtone -0.1681 (L-L%) )
|
184 |
-
( tobi_endtone -70 (L-L%) )
|
185 |
-
( n.tobi_endtone -8.9334 (L-L%) )
|
186 |
-
( nn.tobi_endtone -8.4034 (L-L%) )
|
187 |
-
( pp.tobi_endtone 1.2099 (L-H%) )
|
188 |
-
( p.tobi_endtone 1.1220 (L-H%) )
|
189 |
-
( tobi_endtone -10.0000 (L-H%) )
|
190 |
-
( n.tobi_endtone -5.9467 (L-H%) )
|
191 |
-
( nn.tobi_endtone -6.9072 (L-H%) )
|
192 |
-
( pp.tobi_endtone 0.0000 (H-L%) )
|
193 |
-
( p.tobi_endtone 0.0000 (H-L%) )
|
194 |
-
( tobi_endtone 2.0395 (H-L%) )
|
195 |
-
( n.tobi_endtone -12.3940 (H-L%) )
|
196 |
-
( nn.tobi_endtone -24.2593 (H-L%) )
|
197 |
-
( pp.tobi_endtone 0.0000 (H-H%) )
|
198 |
-
( p.tobi_endtone 0.0000 (H-H%) )
|
199 |
-
( tobi_endtone 0.0000 (H-H%) )
|
200 |
-
( n.tobi_endtone 0.0000 (H-H%) )
|
201 |
-
( nn.tobi_endtone 16.1076 (H-H%) )
|
202 |
-
( pp.tobi_endtone -1.8913 (L-) )
|
203 |
-
( p.tobi_endtone -15.5650 (L-) )
|
204 |
-
( tobi_endtone -18.3620 (L-) )
|
205 |
-
( n.tobi_endtone -9.8322 (L-) )
|
206 |
-
( nn.tobi_endtone -1.8182 (L-) )
|
207 |
-
( pp.tobi_endtone -13.4429 (H-) )
|
208 |
-
( p.tobi_endtone 0.0000 (H-) )
|
209 |
-
( tobi_endtone 1.9053 (H-) )
|
210 |
-
( n.tobi_endtone -3.4315 (H-) )
|
211 |
-
( nn.tobi_endtone 0.0000 (H-) )
|
212 |
-
( p.tobi_accent 0.0000 (L+H*L-H%) )
|
213 |
-
( tobi_accent 10.0000 (L+H*L-H%) )
|
214 |
-
( n.tobi_accent 0.0000 (L+H*L-H%) )
|
215 |
-
( pp.syl_break 0.3501 )
|
216 |
-
( p.syl_break -0.8121 )
|
217 |
-
( syl_break 0.3209 )
|
218 |
-
( n.syl_break 0.7486 )
|
219 |
-
( nn.syl_break 0.8182 )
|
220 |
-
( pp.stress -0.9778 )
|
221 |
-
( p.stress -0.3096 )
|
222 |
-
( stress 2.7752 )
|
223 |
-
( n.stress 0.9976 )
|
224 |
-
( nn.stress 2.7343 )
|
225 |
-
( syl_in -1.9845 )
|
226 |
-
( syl_out 0.7142 )
|
227 |
-
( ssyl_in 1.0376 )
|
228 |
-
( ssyl_out 0.3062 )
|
229 |
-
( asyl_in 0.0000 )
|
230 |
-
( asyl_out 0.4953 )
|
231 |
-
( last_accent 0.0000 )
|
232 |
-
( next_accent 0.1084 )
|
233 |
-
( sub_phrases 0.0000 )
|
234 |
-
( lisp_l_spread -60.0000 )
|
235 |
-
))
|
236 |
-
|
237 |
-
(set! apml_f2b_f0_lr_mid
|
238 |
-
'(
|
239 |
-
( Intercept 160.2474 )
|
240 |
-
( pp.lisp_apml_tgtype 0.0000 (1) )
|
241 |
-
( p.lisp_apml_tgtype 4.5869 (1) )
|
242 |
-
( lisp_apml_tgtype 25.6530 (1) )
|
243 |
-
( n.lisp_apml_tgtype 14.8255 (1) )
|
244 |
-
( nn.lisp_apml_tgtype 12.9605 (1) )
|
245 |
-
( pp.lisp_apml_tgtype 0.0000 (2) )
|
246 |
-
( p.lisp_apml_tgtype 3.4867 (2) )
|
247 |
-
( lisp_apml_tgtype 13.5566 (2) )
|
248 |
-
( n.lisp_apml_tgtype 1.3359 (2) )
|
249 |
-
( nn.lisp_apml_tgtype 0.0000 (2) )
|
250 |
-
( pp.lisp_apml_tgtype 3.2989 (3) )
|
251 |
-
( p.lisp_apml_tgtype 2.5723 (3) )
|
252 |
-
( lisp_apml_tgtype 5.5798 (3) )
|
253 |
-
( n.lisp_apml_tgtype 0.0000 (3) )
|
254 |
-
( nn.lisp_apml_tgtype 0.0000 (3) )
|
255 |
-
( pp.lisp_apml_iecount 0.0000 )
|
256 |
-
( p.lisp_apml_iecount -0.7231 )
|
257 |
-
( lisp_apml_iecount 0.0000 )
|
258 |
-
( n.lisp_apml_iecount -2.6922 )
|
259 |
-
( nn.lisp_apml_iecount 0.0000 )
|
260 |
-
( pp.tobi_accent 0.0000 (H*) )
|
261 |
-
( p.tobi_accent 6.0496 (H*) )
|
262 |
-
( tobi_accent 20.9174 (H*) )
|
263 |
-
( n.tobi_accent 0.0000 (H*) )
|
264 |
-
( nn.tobi_accent -6.4804 (H*) )
|
265 |
-
( pp.tobi_accent 0.0000 (L*) )
|
266 |
-
( p.tobi_accent -5.0000 (L*) )
|
267 |
-
( tobi_accent -45.0000 (L*) )
|
268 |
-
( n.tobi_accent -6.1079 (L*) )
|
269 |
-
( nn.tobi_accent -3.4815 (L*) )
|
270 |
-
( pp.tobi_accent 0.0000 (L*+H) )
|
271 |
-
( p.tobi_accent 30.0000 (L*+H) )
|
272 |
-
( tobi_accent -30.0000 (L*+H) )
|
273 |
-
( n.tobi_accent -2.7200 (L*+H) )
|
274 |
-
( nn.tobi_accent 0.0000 (L*+H) )
|
275 |
-
( pp.tobi_accent 0.0000 (L+H*) )
|
276 |
-
( p.tobi_accent 6.0500 (L+H*) )
|
277 |
-
( tobi_accent 20.9200 (L+H*) )
|
278 |
-
( n.tobi_accent 0.0000 (L+H*) )
|
279 |
-
( nn.tobi_accent -6.4800 (L+H*) )
|
280 |
-
( pp.tobi_endtone 3.6235 (L-L%) )
|
281 |
-
( p.tobi_endtone 0.2801 (L-L%) )
|
282 |
-
( tobi_endtone -80 (L-L%) )
|
283 |
-
( n.tobi_endtone -6.9938 (L-L%) )
|
284 |
-
( nn.tobi_endtone -9.1546 (L-L%) )
|
285 |
-
( pp.tobi_endtone 1.6616 (L-H%) )
|
286 |
-
( p.tobi_endtone 2.2441 (L-H%) )
|
287 |
-
( tobi_endtone 0.0000 (L-H%) )
|
288 |
-
( n.tobi_endtone 0.0000 (L-H%) )
|
289 |
-
( nn.tobi_endtone -6.6132 (L-H%) )
|
290 |
-
( pp.tobi_endtone 0.0000 (H-L%) )
|
291 |
-
( p.tobi_endtone 0.0000 (H-L%) )
|
292 |
-
( tobi_endtone 0.0000 (H-L%) )
|
293 |
-
( n.tobi_endtone -5.4416 (H-L%) )
|
294 |
-
( nn.tobi_endtone -19.1570 (H-L%) )
|
295 |
-
( pp.tobi_endtone 0.0000 (H-H%) )
|
296 |
-
( p.tobi_endtone 0.0000 (H-H%) )
|
297 |
-
( tobi_endtone 0.0000 (H-H%) )
|
298 |
-
( n.tobi_endtone 0.0000 (H-H%) )
|
299 |
-
( nn.tobi_endtone 32.2151 (H-H%) )
|
300 |
-
( pp.tobi_endtone -3.7825 (L-) )
|
301 |
-
( p.tobi_endtone -15.9598 (L-) )
|
302 |
-
( tobi_endtone -36.7241 (L-) )
|
303 |
-
( n.tobi_endtone -5.1082 (L-) )
|
304 |
-
( nn.tobi_endtone -3.6363 (L-) )
|
305 |
-
( pp.tobi_endtone -13.3813 (H-) )
|
306 |
-
( p.tobi_endtone 0.0000 (H-) )
|
307 |
-
( tobi_endtone -2.5270 (H-) )
|
308 |
-
( n.tobi_endtone 0.0000 (H-) )
|
309 |
-
( nn.tobi_endtone 0.0000 (H-) )
|
310 |
-
( p.tobi_accent 0.0000 (L+H*L-H%) )
|
311 |
-
( tobi_accent 40.0000 (L+H*L-H%) )
|
312 |
-
( n.tobi_accent 0.0000 (L+H*L-H%) )
|
313 |
-
( pp.syl_break 0.7003 )
|
314 |
-
( p.syl_break -1.6241 )
|
315 |
-
( syl_break 0.0000 )
|
316 |
-
( n.syl_break 0.1439 )
|
317 |
-
( nn.syl_break 0.5640 )
|
318 |
-
( pp.stress -1.9556 )
|
319 |
-
( p.stress 0.0000 )
|
320 |
-
( stress 3.1383 )
|
321 |
-
( n.stress 1.9952 )
|
322 |
-
( nn.stress 2.9208 )
|
323 |
-
( syl_in -2.5317 )
|
324 |
-
( syl_out 1.0103 )
|
325 |
-
( ssyl_in 2.0751 )
|
326 |
-
( ssyl_out 0.0000 )
|
327 |
-
( asyl_in 0.0000 )
|
328 |
-
( asyl_out 0.0000 )
|
329 |
-
( last_accent 0.0000 )
|
330 |
-
( next_accent 0.5869 )
|
331 |
-
( sub_phrases 0.0000 )
|
332 |
-
( lisp_l_spread -60.0000 )
|
333 |
-
))
|
334 |
-
|
335 |
-
(set! apml_f2b_f0_lr_right
|
336 |
-
'(
|
337 |
-
( Intercept 162.6687 )
|
338 |
-
( pp.lisp_apml_tgtype -4.0459 (1) )
|
339 |
-
( p.lisp_apml_tgtype 3.0601 (1) )
|
340 |
-
( lisp_apml_tgtype 27.8166 (1) )
|
341 |
-
( n.lisp_apml_tgtype 7.4127 (1) )
|
342 |
-
( nn.lisp_apml_tgtype 11.3458 (1) )
|
343 |
-
( pp.lisp_apml_tgtype -3.8091 (2) )
|
344 |
-
( p.lisp_apml_tgtype 1.7434 (2) )
|
345 |
-
( lisp_apml_tgtype 17.1672 (2) )
|
346 |
-
( n.lisp_apml_tgtype 0.6679 (2) )
|
347 |
-
( nn.lisp_apml_tgtype 0.0000 (2) )
|
348 |
-
( pp.lisp_apml_tgtype 1.6494 (3) )
|
349 |
-
( p.lisp_apml_tgtype 1.2861 (3) )
|
350 |
-
( lisp_apml_tgtype 9.5674 (3) )
|
351 |
-
( n.lisp_apml_tgtype -3.1085 (3) )
|
352 |
-
( nn.lisp_apml_tgtype 0.0000 (3) )
|
353 |
-
( pp.lisp_apml_iecount 0.0000 )
|
354 |
-
( p.lisp_apml_iecount -0.7829 )
|
355 |
-
( lisp_apml_iecount -0.5447 )
|
356 |
-
( n.lisp_apml_iecount -1.3461 )
|
357 |
-
( nn.lisp_apml_iecount -0.7178 )
|
358 |
-
( pp.tobi_accent 0.7904 (H*) )
|
359 |
-
( p.tobi_accent 3.0248 (H*) )
|
360 |
-
( tobi_accent 14.1116 (H*) )
|
361 |
-
( n.tobi_accent 0.0000 (H*) )
|
362 |
-
( nn.tobi_accent -3.2402 (H*) )
|
363 |
-
( pp.tobi_accent 0.0000 (L*) )
|
364 |
-
( p.tobi_accent -2.5000 (L*) )
|
365 |
-
( tobi_accent -32.5000 (L*) )
|
366 |
-
( n.tobi_accent -3.0539 (L*) )
|
367 |
-
( nn.tobi_accent -1.7408 (L*) )
|
368 |
-
( pp.tobi_accent 0.0000 (L*+H) )
|
369 |
-
( p.tobi_accent 17.5000 (L*+H) )
|
370 |
-
( tobi_accent -9.0000 (L*+H) )
|
371 |
-
( n.tobi_accent -2.8025 (L*+H) )
|
372 |
-
( nn.tobi_accent -0.5455 (L*+H) )
|
373 |
-
( pp.tobi_accent 0.7900 (L+H*) )
|
374 |
-
( p.tobi_accent 3.0250 (L+H*) )
|
375 |
-
( tobi_accent 14.1150 (L+H*) )
|
376 |
-
( n.tobi_accent 0.0000 (L+H*) )
|
377 |
-
( nn.tobi_accent -3.2400 (L+H*) )
|
378 |
-
( pp.tobi_endtone 5.7534 (L-L%) )
|
379 |
-
( p.tobi_endtone 0.1401 (L-L%) )
|
380 |
-
( tobi_endtone -65 (L-L%) )
|
381 |
-
( n.tobi_endtone -11.1795 (L-L%) )
|
382 |
-
( nn.tobi_endtone -7.8158 (L-L%) )
|
383 |
-
( pp.tobi_endtone 4.4276 (L-H%) )
|
384 |
-
( p.tobi_endtone 1.1220 (L-H%) )
|
385 |
-
( tobi_endtone 20.0000 (L-H%) )
|
386 |
-
( n.tobi_endtone -6.8995 (L-H%) )
|
387 |
-
( nn.tobi_endtone -6.1219 (L-H%) )
|
388 |
-
( pp.tobi_endtone 2.4327 (H-L%) )
|
389 |
-
( p.tobi_endtone 0.0000 (H-L%) )
|
390 |
-
( tobi_endtone -7.5781 (H-L%) )
|
391 |
-
( n.tobi_endtone -2.7208 (H-L%) )
|
392 |
-
( nn.tobi_endtone -14.4838 (H-L%) )
|
393 |
-
( pp.tobi_endtone 0.0000 (H-H%) )
|
394 |
-
( p.tobi_endtone 0.0000 (H-H%) )
|
395 |
-
( tobi_endtone 0.0000 (H-H%) )
|
396 |
-
( n.tobi_endtone 0.0000 (H-H%) )
|
397 |
-
( nn.tobi_endtone 16.1076 (H-H%) )
|
398 |
-
( pp.tobi_endtone -1.8913 (L-) )
|
399 |
-
( p.tobi_endtone -15.5651 (L-) )
|
400 |
-
( tobi_endtone -40.2021 (L-) )
|
401 |
-
( n.tobi_endtone -2.5541 (L-) )
|
402 |
-
( nn.tobi_endtone -2.2224 (L-) )
|
403 |
-
( pp.tobi_endtone -6.6906 (H-) )
|
404 |
-
( p.tobi_endtone -3.5483 (H-) )
|
405 |
-
( tobi_endtone -1.2635 (H-) )
|
406 |
-
( n.tobi_endtone 0.0000 (H-) )
|
407 |
-
( nn.tobi_endtone 0.0000 (H-) )
|
408 |
-
( p.tobi_accent 0.0000 (L+H*L-H%) )
|
409 |
-
( tobi_accent -40.0000 (L+H*L-H%) )
|
410 |
-
( n.tobi_accent 0.0000 (L+H*L-H%) )
|
411 |
-
( pp.syl_break 0.3501 )
|
412 |
-
( p.syl_break -1.0003 )
|
413 |
-
( syl_break -1.5536 )
|
414 |
-
( n.syl_break 0.0720 )
|
415 |
-
( nn.syl_break 0.5989 )
|
416 |
-
( pp.stress -0.9778 )
|
417 |
-
( p.stress -0.8046 )
|
418 |
-
( stress 1.2124 )
|
419 |
-
( n.stress 3.9715 )
|
420 |
-
( nn.stress 2.3914 )
|
421 |
-
( syl_in -2.3468 )
|
422 |
-
( syl_out 0.9792 )
|
423 |
-
( ssyl_in 2.0463 )
|
424 |
-
( ssyl_out 0.0000 )
|
425 |
-
( asyl_in -0.1460 )
|
426 |
-
( asyl_out 0.0000 )
|
427 |
-
( last_accent -1.0992 )
|
428 |
-
( next_accent 0.2935 )
|
429 |
-
( sub_phrases 0.0000 )
|
430 |
-
( lisp_l_spread -60.0000 )
|
431 |
-
))
|
432 |
-
|
433 |
-
(set! apml_f2b_f0_lr_end
|
434 |
-
'(
|
435 |
-
( Intercept 165.0901 )
|
436 |
-
( pp.lisp_apml_tgtype -8.0918 (1) )
|
437 |
-
( p.lisp_apml_tgtype 1.5332 (1) )
|
438 |
-
( lisp_apml_tgtype 29.9802 (1) )
|
439 |
-
( n.lisp_apml_tgtype 0.0000 (1) )
|
440 |
-
( nn.lisp_apml_tgtype 9.7312 (1) )
|
441 |
-
( pp.lisp_apml_tgtype -7.6181 (2) )
|
442 |
-
( p.lisp_apml_tgtype 0.0000 (2) )
|
443 |
-
( lisp_apml_tgtype 20.7778 (2) )
|
444 |
-
( n.lisp_apml_tgtype 0.0000 (2) )
|
445 |
-
( nn.lisp_apml_tgtype 0.0000 (2) )
|
446 |
-
( pp.lisp_apml_tgtype 0.0000 (3) )
|
447 |
-
( p.lisp_apml_tgtype 0.0000 (3) )
|
448 |
-
( lisp_apml_tgtype 13.5550 (3) )
|
449 |
-
( n.lisp_apml_tgtype -6.2170 (3) )
|
450 |
-
( nn.lisp_apml_tgtype 0.0000 (3) )
|
451 |
-
( pp.lisp_apml_iecount 0.0000 )
|
452 |
-
( p.lisp_apml_iecount -0.8428 )
|
453 |
-
( lisp_apml_iecount -1.0894 )
|
454 |
-
( n.lisp_apml_iecount 0.0000 )
|
455 |
-
( nn.lisp_apml_iecount -1.4355 )
|
456 |
-
( pp.tobi_accent 1.5807 (H*) )
|
457 |
-
( p.tobi_accent 0.0000 (H*) )
|
458 |
-
( tobi_accent 7.3057 (H*) )
|
459 |
-
( n.tobi_accent 0.0000 (H*) )
|
460 |
-
( nn.tobi_accent 0.0000 (H*) )
|
461 |
-
( pp.tobi_accent 0.0000 (L*) )
|
462 |
-
( p.tobi_accent 0.0000 (L*) )
|
463 |
-
( tobi_accent -20.0000 (L*) )
|
464 |
-
( n.tobi_accent 0.0000 (L*) )
|
465 |
-
( nn.tobi_accent 0.0000 (L*) )
|
466 |
-
( pp.tobi_accent 0.0000 (L*+H) )
|
467 |
-
( p.tobi_accent 5.0000 (L*+H) )
|
468 |
-
( tobi_accent 12.0000 (L*+H) )
|
469 |
-
( n.tobi_accent -2.8850 (L*+H) )
|
470 |
-
( nn.tobi_accent -1.0910 (L*+H) )
|
471 |
-
( pp.tobi_accent 1.5800 (L+H*) )
|
472 |
-
( p.tobi_accent 0.0000 (L+H*) )
|
473 |
-
( tobi_accent 7.3100 (L+H*) )
|
474 |
-
( n.tobi_accent 0.0000 (L+H*) )
|
475 |
-
( nn.tobi_accent 0.0000 (L+H*) )
|
476 |
-
( pp.tobi_endtone 7.8833 (L-L%) )
|
477 |
-
( p.tobi_endtone 0.0000 (L-L%) )
|
478 |
-
( tobi_endtone -80 (L-L%) )
|
479 |
-
( n.tobi_endtone -35 (L-L%) )
|
480 |
-
( nn.tobi_endtone -6.4769 (L-L%) )
|
481 |
-
( pp.tobi_endtone 7.1936 (L-H%) )
|
482 |
-
( p.tobi_endtone 0.0000 (L-H%) )
|
483 |
-
( tobi_endtone 40.0000 (L-H%) )
|
484 |
-
( n.tobi_endtone -13.7990 (L-H%) )
|
485 |
-
( nn.tobi_endtone -5.6305 (L-H%) )
|
486 |
-
( pp.tobi_endtone 4.8654 (H-L%) )
|
487 |
-
( p.tobi_endtone 0.0000 (H-L%) )
|
488 |
-
( tobi_endtone -15.1561 (H-L%) )
|
489 |
-
( n.tobi_endtone 0.0000 (H-L%) )
|
490 |
-
( nn.tobi_endtone -9.8107 (H-L%) )
|
491 |
-
( pp.tobi_endtone 0.0000 (H-H%) )
|
492 |
-
( p.tobi_endtone 0.0000 (H-H%) )
|
493 |
-
( tobi_endtone 0.0000 (H-H%) )
|
494 |
-
( n.tobi_endtone 0.0000 (H-H%) )
|
495 |
-
( nn.tobi_endtone 0.0000 (H-H%) )
|
496 |
-
( pp.tobi_endtone 0.0000 (L-) )
|
497 |
-
( p.tobi_endtone -15.1705 (L-) )
|
498 |
-
( tobi_endtone -43.6801 (L-) )
|
499 |
-
( n.tobi_endtone 0.0000 (L-) )
|
500 |
-
( nn.tobi_endtone -0.8085 (L-) )
|
501 |
-
( pp.tobi_endtone 0.0000 (H-) )
|
502 |
-
( p.tobi_endtone -7.0967 (H-) )
|
503 |
-
( tobi_endtone 0.0000 (H-) )
|
504 |
-
( n.tobi_endtone 0.0000 (H-) )
|
505 |
-
( nn.tobi_endtone 0.0000 (H-) )
|
506 |
-
( p.tobi_accent 0.0000 (L+H*L-H%) )
|
507 |
-
( tobi_accent 60.0000 (L+H*L-H%) )
|
508 |
-
( n.tobi_accent -60.0000 (L+H*L-H%) )
|
509 |
-
( pp.syl_break 0.0000 )
|
510 |
-
( p.syl_break -0.3765 )
|
511 |
-
( syl_break -3.1072 )
|
512 |
-
( n.syl_break 0.0000 )
|
513 |
-
( nn.syl_break 0.6338 )
|
514 |
-
( pp.stress 0.0000 )
|
515 |
-
( p.stress -1.6093 )
|
516 |
-
( stress -0.7136 )
|
517 |
-
( n.stress 5.9479 )
|
518 |
-
( nn.stress 1.8619 )
|
519 |
-
( syl_in -2.1619 )
|
520 |
-
( syl_out 0.9481 )
|
521 |
-
( ssyl_in 2.0175 )
|
522 |
-
( ssyl_out 0.0000 )
|
523 |
-
( asyl_in -0.2919 )
|
524 |
-
( asyl_out 0.0000 )
|
525 |
-
( last_accent -2.1984 )
|
526 |
-
( next_accent 0.0000 )
|
527 |
-
( sub_phrases 0.0000 )
|
528 |
-
( lisp_l_spread -60.0000 )
|
529 |
-
))
|
530 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/apml_kaldurtreeZ.scm
DELETED
@@ -1,996 +0,0 @@
|
|
1 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2 |
-
;;; ;;
|
3 |
-
;;; Centre for Speech Technology Research ;;
|
4 |
-
;;; University of Edinburgh, UK ;;
|
5 |
-
;;; Copyright (c) 1996,1997 ;;
|
6 |
-
;;; All Rights Reserved. ;;
|
7 |
-
;;; ;;
|
8 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;
|
9 |
-
;;; this software and its documentation without restriction, including ;;
|
10 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;
|
11 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;
|
12 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;
|
13 |
-
;;; the following conditions: ;;
|
14 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;
|
15 |
-
;;; conditions and the following disclaimer. ;;
|
16 |
-
;;; 2. Any modifications must be clearly marked as such. ;;
|
17 |
-
;;; 3. Original authors' names are not deleted. ;;
|
18 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;
|
19 |
-
;;; derived from this software without specific prior written ;;
|
20 |
-
;;; permission. ;;
|
21 |
-
;;; ;;
|
22 |
-
;;; THE UNIVERSITY OF EDINBURGH AND THE CONTRIBUTORS TO THIS WORK ;;
|
23 |
-
;;; DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ;;
|
24 |
-
;;; ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT ;;
|
25 |
-
;;; SHALL THE UNIVERSITY OF EDINBURGH NOR THE CONTRIBUTORS BE LIABLE ;;
|
26 |
-
;;; FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ;;
|
27 |
-
;;; WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN ;;
|
28 |
-
;;; AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ;;
|
29 |
-
;;; ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF ;;
|
30 |
-
;;; THIS SOFTWARE. ;;
|
31 |
-
;;; ;;
|
32 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
33 |
-
;;;
|
34 |
-
;;; A tree to predict zcore durations build from f2b
|
35 |
-
;;; doesn't use actual phonemes so it can have better generalizations
|
36 |
-
;;;
|
37 |
-
;;; Basically copied from ked
|
38 |
-
;;;
|
39 |
-
|
40 |
-
(set! apml_kal_durs
|
41 |
-
'(
|
42 |
-
(uh 0.067 0.025)
|
43 |
-
(hh 0.061 0.028)
|
44 |
-
(ao 0.138 0.046)
|
45 |
-
(hv 0.053 0.020)
|
46 |
-
(v 0.051 0.019)
|
47 |
-
(ih 0.058 0.023)
|
48 |
-
(el 0.111 0.043)
|
49 |
-
(ey 0.132 0.042)
|
50 |
-
(em 0.080 0.033)
|
51 |
-
(jh 0.094 0.024)
|
52 |
-
(w 0.054 0.023)
|
53 |
-
(uw 0.107 0.044)
|
54 |
-
(ae 0.120 0.036)
|
55 |
-
(en 0.117 0.056)
|
56 |
-
(k 0.089 0.034)
|
57 |
-
(y 0.048 0.025)
|
58 |
-
(axr 0.147 0.035)
|
59 |
-
; (l 0.056 0.026)
|
60 |
-
(l 0.066 0.026)
|
61 |
-
(ng 0.064 0.024)
|
62 |
-
(zh 0.071 0.030)
|
63 |
-
(z 0.079 0.034)
|
64 |
-
(brth 0.246 0.046)
|
65 |
-
(m 0.069 0.028)
|
66 |
-
(iy 0.097 0.041)
|
67 |
-
(n 0.059 0.025)
|
68 |
-
(ah 0.087 0.031)
|
69 |
-
(er 0.086 0.010)
|
70 |
-
(b 0.069 0.024)
|
71 |
-
(pau 0.200 0.1)
|
72 |
-
(aw 0.166 0.053)
|
73 |
-
(p 0.088 0.030)
|
74 |
-
(ch 0.115 0.025)
|
75 |
-
(ow 0.134 0.039)
|
76 |
-
(dh 0.031 0.016)
|
77 |
-
(nx 0.049 0.100)
|
78 |
-
(d 0.048 0.021)
|
79 |
-
(ax 0.046 0.024)
|
80 |
-
(h# 0.060 0.083)
|
81 |
-
(r 0.053 0.031)
|
82 |
-
(eh 0.095 0.036)
|
83 |
-
(ay 0.137 0.047)
|
84 |
-
(oy 0.183 0.050)
|
85 |
-
(f 0.095 0.033)
|
86 |
-
(sh 0.108 0.031)
|
87 |
-
(s 0.102 0.037)
|
88 |
-
(g 0.064 0.021)
|
89 |
-
(dx 0.031 0.016)
|
90 |
-
(th 0.093 0.050)
|
91 |
-
(aa 0.094 0.037)
|
92 |
-
(t 0.070 0.020)
|
93 |
-
)
|
94 |
-
)
|
95 |
-
|
96 |
-
(set! apml_kal_duration_cart_tree
|
97 |
-
'
|
98 |
-
((name is pau)
|
99 |
-
((emph_sil is +)
|
100 |
-
((0.0 -0.5))
|
101 |
-
((p.R:SylStructure.parent.parent.lisp_apml_pause = 0.2)
|
102 |
-
((0.0 0.0))
|
103 |
-
((p.R:SylStructure.parent.parent.lisp_apml_pause = 0.4)
|
104 |
-
((0.0 2.0))
|
105 |
-
((p.R:SylStructure.parent.parent.lisp_apml_pause = 0.6)
|
106 |
-
((0.0 4.0))
|
107 |
-
((p.R:SylStructure.parent.parent.lisp_apml_pause = 0.8)
|
108 |
-
((0.0 6.0))
|
109 |
-
((p.R:SylStructure.parent.parent.lisp_apml_pause = 1.0)
|
110 |
-
((0.0 8.0))
|
111 |
-
((p.R:SylStructure.parent.parent.lisp_apml_pause = 1.5)
|
112 |
-
((0.0 13.0))
|
113 |
-
((p.R:SylStructure.parent.parent.lisp_apml_pause = 2.0)
|
114 |
-
((0.0 18.0))
|
115 |
-
((p.R:SylStructure.parent.parent.lisp_apml_pause = 2.5)
|
116 |
-
((0.0 23.0))
|
117 |
-
((p.R:SylStructure.parent.parent.lisp_apml_pause = 3.0)
|
118 |
-
((0.0 28.0))
|
119 |
-
((p.R:SylStructure.parent.parent.pbreak is BB)
|
120 |
-
((0.0 2.0))
|
121 |
-
((0.0 0.0)))))))))))))
|
122 |
-
((R:SylStructure.parent.accented is 0)
|
123 |
-
((n.ph_ctype is 0)
|
124 |
-
((p.ph_vlng is 0)
|
125 |
-
((R:SylStructure.parent.syl_codasize < 1.5)
|
126 |
-
((p.ph_ctype is n)
|
127 |
-
((ph_ctype is f)
|
128 |
-
((0.559208 -0.783163))
|
129 |
-
((1.05215 -0.222704)))
|
130 |
-
((ph_ctype is s)
|
131 |
-
((R:SylStructure.parent.syl_break is 2)
|
132 |
-
((0.589948 0.764459))
|
133 |
-
((R:SylStructure.parent.asyl_in < 0.7)
|
134 |
-
((1.06385 0.567944))
|
135 |
-
((0.691943 0.0530272))))
|
136 |
-
((ph_vlng is l)
|
137 |
-
((pp.ph_vfront is 1)
|
138 |
-
((1.06991 0.766486))
|
139 |
-
((R:SylStructure.parent.syl_break is 1)
|
140 |
-
((0.69665 0.279248))
|
141 |
-
((0.670353 0.0567774))))
|
142 |
-
((p.ph_ctype is s)
|
143 |
-
((seg_onsetcoda is coda)
|
144 |
-
((0.828638 -0.038356))
|
145 |
-
((ph_ctype is f)
|
146 |
-
((0.7631 -0.545853))
|
147 |
-
((0.49329 -0.765994))))
|
148 |
-
((R:SylStructure.parent.parent.gpos is det)
|
149 |
-
((R:SylStructure.parent.last_accent < 0.3)
|
150 |
-
((R:SylStructure.parent.sub_phrases < 1)
|
151 |
-
((0.811686 0.160195))
|
152 |
-
((0.799015 0.713958)))
|
153 |
-
((0.731599 -0.215472)))
|
154 |
-
((ph_ctype is r)
|
155 |
-
((0.673487 0.092772))
|
156 |
-
((R:SylStructure.parent.asyl_in < 1)
|
157 |
-
((0.745273 0.00132813))
|
158 |
-
((0.75457 -0.334898)))))))))
|
159 |
-
((pos_in_syl < 0.5)
|
160 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 2)
|
161 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.2)
|
162 |
-
((0.902446 -0.041618))
|
163 |
-
((R:SylStructure.parent.sub_phrases < 2.3)
|
164 |
-
((0.900629 0.262952))
|
165 |
-
((1.18474 0.594794))))
|
166 |
-
((seg_onset_stop is 0)
|
167 |
-
((R:SylStructure.parent.position_type is mid)
|
168 |
-
((0.512323 -0.760444))
|
169 |
-
((R:SylStructure.parent.syl_out < 6.8)
|
170 |
-
((pp.ph_vlng is a)
|
171 |
-
((0.640575 -0.450449))
|
172 |
-
((ph_ctype is f)
|
173 |
-
((R:SylStructure.parent.sub_phrases < 1.3)
|
174 |
-
((0.862876 -0.296956))
|
175 |
-
((R:SylStructure.parent.syl_out < 2.4)
|
176 |
-
((0.803215 0.0422868))
|
177 |
-
((0.877856 -0.154465))))
|
178 |
-
((R:SylStructure.parent.syl_out < 3.6)
|
179 |
-
((R:SylStructure.parent.syl_out < 1.2)
|
180 |
-
((0.567081 -0.264199))
|
181 |
-
((0.598043 -0.541738)))
|
182 |
-
((0.676843 -0.166623)))))
|
183 |
-
((0.691678 -0.57173))))
|
184 |
-
((R:SylStructure.parent.parent.gpos is cc)
|
185 |
-
((1.15995 0.313289))
|
186 |
-
((pp.ph_vfront is 1)
|
187 |
-
((0.555993 0.0695819))
|
188 |
-
((R:SylStructure.parent.asyl_in < 1.2)
|
189 |
-
((R:SylStructure.parent.sub_phrases < 2.7)
|
190 |
-
((0.721635 -0.367088))
|
191 |
-
((0.71919 -0.194887)))
|
192 |
-
((0.547052 -0.0637491)))))))
|
193 |
-
((ph_ctype is s)
|
194 |
-
((R:SylStructure.parent.syl_break is 0)
|
195 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 1)
|
196 |
-
((0.650007 -0.333421))
|
197 |
-
((0.846301 -0.165383)))
|
198 |
-
((0.527756 -0.516332)))
|
199 |
-
((R:SylStructure.parent.syl_break is 0)
|
200 |
-
((p.ph_ctype is s)
|
201 |
-
((0.504414 -0.779112))
|
202 |
-
((0.812498 -0.337611)))
|
203 |
-
((pos_in_syl < 1.4)
|
204 |
-
((0.513041 -0.745807))
|
205 |
-
((p.ph_ctype is s)
|
206 |
-
((0.350582 -1.04907))
|
207 |
-
((0.362 -0.914974))))))))
|
208 |
-
((R:SylStructure.parent.syl_break is 0)
|
209 |
-
((ph_ctype is n)
|
210 |
-
((R:SylStructure.parent.position_type is initial)
|
211 |
-
((pos_in_syl < 1.2)
|
212 |
-
((0.580485 0.172658))
|
213 |
-
((0.630973 -0.101423)))
|
214 |
-
((0.577937 -0.360092)))
|
215 |
-
((R:SylStructure.parent.syl_out < 2.9)
|
216 |
-
((R:SylStructure.parent.syl_out < 1.1)
|
217 |
-
((R:SylStructure.parent.position_type is initial)
|
218 |
-
((0.896092 0.764189))
|
219 |
-
((R:SylStructure.parent.sub_phrases < 3.6)
|
220 |
-
((ph_ctype is s)
|
221 |
-
((0.877362 0.555132))
|
222 |
-
((0.604511 0.369882)))
|
223 |
-
((0.799982 0.666966))))
|
224 |
-
((seg_onsetcoda is coda)
|
225 |
-
((p.ph_vlng is a)
|
226 |
-
((R:SylStructure.parent.last_accent < 0.4)
|
227 |
-
((0.800736 0.240634))
|
228 |
-
((0.720606 0.486176)))
|
229 |
-
((1.18173 0.573811)))
|
230 |
-
((0.607147 0.194468))))
|
231 |
-
((ph_ctype is r)
|
232 |
-
((0.88377 0.499383))
|
233 |
-
((R:SylStructure.parent.last_accent < 0.5)
|
234 |
-
((R:SylStructure.parent.position_type is initial)
|
235 |
-
((R:SylStructure.parent.parent.word_numsyls < 2.4)
|
236 |
-
((0.62798 0.0737318))
|
237 |
-
((0.787334 0.331014)))
|
238 |
-
((ph_ctype is s)
|
239 |
-
((0.808368 0.0929299))
|
240 |
-
((0.527948 -0.0443271))))
|
241 |
-
((seg_coda_fric is 0)
|
242 |
-
((p.ph_vlng is a)
|
243 |
-
((0.679745 0.517681))
|
244 |
-
((R:SylStructure.parent.sub_phrases < 1.1)
|
245 |
-
((0.759979 0.128316))
|
246 |
-
((0.775233 0.361383))))
|
247 |
-
((R:SylStructure.parent.last_accent < 1.3)
|
248 |
-
((0.696255 0.054136))
|
249 |
-
((0.632425 0.246742))))))))
|
250 |
-
((pos_in_syl < 0.3)
|
251 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 2)
|
252 |
-
((0.847602 0.621547))
|
253 |
-
((ph_ctype is s)
|
254 |
-
((0.880645 0.501679))
|
255 |
-
((R:SylStructure.parent.sub_phrases < 3.3)
|
256 |
-
((R:SylStructure.parent.sub_phrases < 0.3)
|
257 |
-
((0.901014 -0.042049))
|
258 |
-
((0.657493 0.183226)))
|
259 |
-
((0.680126 0.284799)))))
|
260 |
-
((ph_ctype is s)
|
261 |
-
((p.ph_vlng is s)
|
262 |
-
((0.670033 -0.820934))
|
263 |
-
((0.863306 -0.348735)))
|
264 |
-
((ph_ctype is n)
|
265 |
-
((R:SylStructure.parent.asyl_in < 1.2)
|
266 |
-
((0.656966 -0.40092))
|
267 |
-
((0.530966 -0.639366)))
|
268 |
-
((seg_coda_fric is 0)
|
269 |
-
((1.04153 0.364857))
|
270 |
-
((pos_in_syl < 1.2)
|
271 |
-
((R:SylStructure.parent.syl_out < 3.4)
|
272 |
-
((0.81503 -0.00768613))
|
273 |
-
((0.602665 -0.197753)))
|
274 |
-
((0.601844 -0.394632)))))))))
|
275 |
-
((n.ph_ctype is f)
|
276 |
-
((pos_in_syl < 1.5)
|
277 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 2)
|
278 |
-
((pos_in_syl < 0.1)
|
279 |
-
((1.63863 0.938841))
|
280 |
-
((R:SylStructure.parent.position_type is initial)
|
281 |
-
((0.897722 -0.0796637))
|
282 |
-
((nn.ph_vheight is 0)
|
283 |
-
((0.781081 0.480026))
|
284 |
-
((0.779711 0.127175)))))
|
285 |
-
((ph_ctype is r)
|
286 |
-
((p.ph_ctype is s)
|
287 |
-
((0.581329 -0.708767))
|
288 |
-
((0.564366 -0.236212)))
|
289 |
-
((ph_vlng is a)
|
290 |
-
((p.ph_ctype is r)
|
291 |
-
((0.70992 -0.273389))
|
292 |
-
((R:SylStructure.parent.parent.gpos is in)
|
293 |
-
((0.764696 0.0581338))
|
294 |
-
((nn.ph_vheight is 0)
|
295 |
-
((0.977737 0.721904))
|
296 |
-
((R:SylStructure.parent.sub_phrases < 2.2)
|
297 |
-
((pp.ph_vfront is 0)
|
298 |
-
((0.586708 0.0161206))
|
299 |
-
((0.619949 0.227372)))
|
300 |
-
((0.707285 0.445569))))))
|
301 |
-
((ph_ctype is n)
|
302 |
-
((R:SylStructure.parent.syl_break is 1)
|
303 |
-
((nn.ph_vfront is 2)
|
304 |
-
((0.430295 -0.120097))
|
305 |
-
((0.741371 0.219042)))
|
306 |
-
((0.587492 0.321245)))
|
307 |
-
((p.ph_ctype is n)
|
308 |
-
((0.871586 0.134075))
|
309 |
-
((p.ph_ctype is r)
|
310 |
-
((0.490751 -0.466418))
|
311 |
-
((R:SylStructure.parent.syl_codasize < 1.3)
|
312 |
-
((R:SylStructure.parent.sub_phrases < 2.2)
|
313 |
-
((p.ph_ctype is s)
|
314 |
-
((0.407452 -0.425925))
|
315 |
-
((0.644771 -0.542809)))
|
316 |
-
((0.688772 -0.201899)))
|
317 |
-
((ph_vheight is 1)
|
318 |
-
((nn.ph_vheight is 0)
|
319 |
-
((0.692018 0.209018))
|
320 |
-
((0.751345 -0.178136)))
|
321 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.3)
|
322 |
-
((R:SylStructure.parent.asyl_in < 1.5)
|
323 |
-
((0.599633 -0.235593))
|
324 |
-
((0.60042 0.126118)))
|
325 |
-
((p.ph_vlng is a)
|
326 |
-
((0.7148 -0.174812))
|
327 |
-
((R:SylStructure.parent.parent.gpos is content)
|
328 |
-
((0.761296 -0.231509))
|
329 |
-
((0.813081 -0.536405)))))))))))))
|
330 |
-
((ph_ctype is n)
|
331 |
-
((0.898844 0.163343))
|
332 |
-
((p.ph_vlng is s)
|
333 |
-
((seg_coda_fric is 0)
|
334 |
-
((0.752921 -0.45528))
|
335 |
-
((0.890079 -0.0998025)))
|
336 |
-
((ph_ctype is f)
|
337 |
-
((0.729376 -0.930547))
|
338 |
-
((ph_ctype is s)
|
339 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 0)
|
340 |
-
((0.745052 -0.634119))
|
341 |
-
((0.521502 -0.760176)))
|
342 |
-
((R:SylStructure.parent.syl_break is 1)
|
343 |
-
((0.766575 -0.121355))
|
344 |
-
((0.795616 -0.557509))))))))
|
345 |
-
((p.ph_vlng is 0)
|
346 |
-
((p.ph_ctype is r)
|
347 |
-
((ph_vlng is 0)
|
348 |
-
((0.733659 -0.402734))
|
349 |
-
((R:SylStructure.parent.sub_phrases < 1.5)
|
350 |
-
((ph_vlng is s)
|
351 |
-
((0.326176 -0.988478))
|
352 |
-
((n.ph_ctype is s)
|
353 |
-
((0.276471 -0.802536))
|
354 |
-
((0.438283 -0.900628))))
|
355 |
-
((nn.ph_vheight is 0)
|
356 |
-
((ph_vheight is 2)
|
357 |
-
((0.521 -0.768992))
|
358 |
-
((0.615436 -0.574918)))
|
359 |
-
((ph_vheight is 1)
|
360 |
-
((0.387376 -0.756359))
|
361 |
-
((pos_in_syl < 0.3)
|
362 |
-
((0.417235 -0.808937))
|
363 |
-
((0.384043 -0.93315)))))))
|
364 |
-
((ph_vlng is a)
|
365 |
-
((ph_ctype is 0)
|
366 |
-
((n.ph_ctype is s)
|
367 |
-
((p.ph_ctype is f)
|
368 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.2)
|
369 |
-
((0.415908 -0.428493))
|
370 |
-
((pos_in_syl < 0.1)
|
371 |
-
((0.790441 0.0211071))
|
372 |
-
((0.452465 -0.254485))))
|
373 |
-
((p.ph_ctype is s)
|
374 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.2)
|
375 |
-
((0.582447 -0.389966))
|
376 |
-
((0.757648 0.185781)))
|
377 |
-
((R:SylStructure.parent.sub_phrases < 1.4)
|
378 |
-
((0.628965 0.422551))
|
379 |
-
((0.713613 0.145576)))))
|
380 |
-
((seg_onset_stop is 0)
|
381 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 0)
|
382 |
-
((pp.ph_vfront is 1)
|
383 |
-
((0.412363 -0.62319))
|
384 |
-
((R:SylStructure.parent.syl_out < 3.6)
|
385 |
-
((0.729259 -0.317324))
|
386 |
-
((0.441633 -0.591051))))
|
387 |
-
((R:SylStructure.parent.syl_break is 1)
|
388 |
-
((R:SylStructure.parent.sub_phrases < 2.7)
|
389 |
-
((0.457728 -0.405607))
|
390 |
-
((0.532411 -0.313148)))
|
391 |
-
((R:SylStructure.parent.last_accent < 0.3)
|
392 |
-
((1.14175 0.159416))
|
393 |
-
((0.616396 -0.254651)))))
|
394 |
-
((R:SylStructure.parent.position_type is initial)
|
395 |
-
((0.264181 -0.799896))
|
396 |
-
((0.439801 -0.551309)))))
|
397 |
-
((R:SylStructure.parent.position_type is final)
|
398 |
-
((0.552027 -0.707084))
|
399 |
-
((0.585661 -0.901874))))
|
400 |
-
((ph_ctype is s)
|
401 |
-
((pos_in_syl < 1.2)
|
402 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.2)
|
403 |
-
((pp.ph_vfront is 1)
|
404 |
-
((0.607449 0.196466))
|
405 |
-
((0.599662 0.00382414)))
|
406 |
-
((0.64109 -0.12859)))
|
407 |
-
((pp.ph_vfront is 1)
|
408 |
-
((0.720484 -0.219339))
|
409 |
-
((0.688707 -0.516734))))
|
410 |
-
((ph_vlng is s)
|
411 |
-
((n.ph_ctype is s)
|
412 |
-
((R:SylStructure.parent.parent.gpos is content)
|
413 |
-
((R:SylStructure.parent.position_type is single)
|
414 |
-
((0.659206 0.159445))
|
415 |
-
((R:SylStructure.parent.parent.word_numsyls < 3.5)
|
416 |
-
((R:SylStructure.parent.sub_phrases < 2)
|
417 |
-
((0.447186 -0.419103))
|
418 |
-
((0.631822 -0.0928561)))
|
419 |
-
((0.451623 -0.576116))))
|
420 |
-
((ph_vheight is 3)
|
421 |
-
((0.578626 -0.64583))
|
422 |
-
((0.56636 -0.4665))))
|
423 |
-
((R:SylStructure.parent.parent.gpos is in)
|
424 |
-
((0.771516 -0.217292))
|
425 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 2)
|
426 |
-
((0.688571 -0.304382))
|
427 |
-
((R:SylStructure.parent.parent.gpos is content)
|
428 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 1)
|
429 |
-
((n.ph_ctype is n)
|
430 |
-
((0.556085 -0.572203))
|
431 |
-
((0.820173 -0.240338)))
|
432 |
-
((R:SylStructure.parent.parent.word_numsyls < 2.2)
|
433 |
-
((0.595398 -0.588171))
|
434 |
-
((0.524737 -0.95797))))
|
435 |
-
((R:SylStructure.parent.sub_phrases < 3.9)
|
436 |
-
((0.371492 -0.959427))
|
437 |
-
((0.440479 -0.845747)))))))
|
438 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 0)
|
439 |
-
((p.ph_ctype is f)
|
440 |
-
((0.524088 -0.482247))
|
441 |
-
((nn.ph_vheight is 1)
|
442 |
-
((0.587666 -0.632362))
|
443 |
-
((ph_vlng is l)
|
444 |
-
((R:SylStructure.parent.position_type is final)
|
445 |
-
((0.513286 -0.713117))
|
446 |
-
((0.604613 -0.924308)))
|
447 |
-
((R:SylStructure.parent.syl_codasize < 2.2)
|
448 |
-
((0.577997 -0.891342))
|
449 |
-
((0.659804 -1.15252))))))
|
450 |
-
((pp.ph_vlng is s)
|
451 |
-
((ph_ctype is f)
|
452 |
-
((0.813383 -0.599624))
|
453 |
-
((0.984027 -0.0771909)))
|
454 |
-
((p.ph_ctype is f)
|
455 |
-
((R:SylStructure.parent.parent.gpos is in)
|
456 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 1)
|
457 |
-
((0.313572 -1.03242))
|
458 |
-
((0.525854 -0.542799)))
|
459 |
-
((R:SylStructure.parent.syl_out < 2.8)
|
460 |
-
((0.613007 -0.423979))
|
461 |
-
((0.570258 -0.766379))))
|
462 |
-
((R:SylStructure.parent.syl_break is 1)
|
463 |
-
((R:SylStructure.parent.parent.gpos is to)
|
464 |
-
((0.364585 -0.792895))
|
465 |
-
((ph_vlng is l)
|
466 |
-
((0.69143 -0.276816))
|
467 |
-
((0.65673 -0.523721))))
|
468 |
-
((R:SylStructure.parent.syl_out < 3.6)
|
469 |
-
((R:SylStructure.parent.position_type is initial)
|
470 |
-
((0.682096 -0.488102))
|
471 |
-
((0.406364 -0.731758)))
|
472 |
-
((0.584694 -0.822229)))))))))))
|
473 |
-
((n.ph_ctype is r)
|
474 |
-
((R:SylStructure.parent.position_type is initial)
|
475 |
-
((p.ph_vlng is a)
|
476 |
-
((0.797058 1.02334))
|
477 |
-
((ph_ctype is s)
|
478 |
-
((1.0548 0.536277))
|
479 |
-
((0.817253 0.138201))))
|
480 |
-
((R:SylStructure.parent.sub_phrases < 1.1)
|
481 |
-
((R:SylStructure.parent.syl_out < 3.3)
|
482 |
-
((0.884574 -0.23471))
|
483 |
-
((0.772063 -0.525292)))
|
484 |
-
((nn.ph_vfront is 1)
|
485 |
-
((1.25254 0.417485))
|
486 |
-
((0.955557 -0.0781996)))))
|
487 |
-
((pp.ph_vfront is 0)
|
488 |
-
((ph_ctype is f)
|
489 |
-
((n.ph_ctype is s)
|
490 |
-
((R:SylStructure.parent.parent.gpos is content)
|
491 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 0)
|
492 |
-
((0.583506 -0.56941))
|
493 |
-
((0.525949 -0.289362)))
|
494 |
-
((0.749316 -0.0921038)))
|
495 |
-
((p.ph_vlng is s)
|
496 |
-
((0.734234 0.139463))
|
497 |
-
((0.680119 -0.0708717))))
|
498 |
-
((ph_vlng is s)
|
499 |
-
((ph_vheight is 1)
|
500 |
-
((0.908712 -0.618971))
|
501 |
-
((0.55344 -0.840495)))
|
502 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 1.2)
|
503 |
-
((pos_in_syl < 1.2)
|
504 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 2)
|
505 |
-
((0.838715 0.00913392))
|
506 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 1)
|
507 |
-
((ph_vheight is 2)
|
508 |
-
((0.555513 -0.512523))
|
509 |
-
((R:SylStructure.parent.position_type is initial)
|
510 |
-
((0.758711 0.121704))
|
511 |
-
((0.737555 -0.25637))))
|
512 |
-
((R:SylStructure.parent.syl_out < 3.1)
|
513 |
-
((n.ph_ctype is s)
|
514 |
-
((0.611756 -0.474522))
|
515 |
-
((1.05437 -0.247206)))
|
516 |
-
((R:SylStructure.parent.syl_codasize < 2.2)
|
517 |
-
((R:SylStructure.parent.position_type is final)
|
518 |
-
((0.567761 -0.597866))
|
519 |
-
((0.785599 -0.407765)))
|
520 |
-
((0.575598 -0.741256))))))
|
521 |
-
((ph_ctype is s)
|
522 |
-
((n.ph_ctype is s)
|
523 |
-
((0.661069 -1.08426))
|
524 |
-
((0.783184 -0.39789)))
|
525 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 1)
|
526 |
-
((R:SylStructure.parent.sub_phrases < 2.6)
|
527 |
-
((0.511323 -0.666011))
|
528 |
-
((0.691878 -0.499492)))
|
529 |
-
((ph_ctype is r)
|
530 |
-
((0.482131 -0.253186))
|
531 |
-
((0.852955 -0.372832))))))
|
532 |
-
((0.854447 -0.0936489)))))
|
533 |
-
((R:SylStructure.parent.position_type is final)
|
534 |
-
((0.685939 -0.249982))
|
535 |
-
((R:SylStructure.parent.syl_out < 3.2)
|
536 |
-
((0.989843 0.18086))
|
537 |
-
((0.686805 -0.0402908)))))))))
|
538 |
-
((R:SylStructure.parent.syl_out < 2.4)
|
539 |
-
((R:SylStructure.parent.syl_out < 0.2)
|
540 |
-
((seg_onsetcoda is coda)
|
541 |
-
((ph_ctype is s)
|
542 |
-
((R:SylStructure.parent.syl_break is 4)
|
543 |
-
((pp.ph_vlng is 0)
|
544 |
-
((0.959737 1.63203))
|
545 |
-
((1.20714 0.994933)))
|
546 |
-
((n.ph_ctype is 0)
|
547 |
-
((R:SylStructure.parent.syl_break is 2)
|
548 |
-
((0.864809 0.214457))
|
549 |
-
((0.874278 0.730381)))
|
550 |
-
((pp.ph_vfront is 0)
|
551 |
-
((seg_coda_fric is 0)
|
552 |
-
((1.20844 -0.336221))
|
553 |
-
((1.01357 0.468302)))
|
554 |
-
((0.658106 -0.799121)))))
|
555 |
-
((n.ph_ctype is f)
|
556 |
-
((ph_ctype is f)
|
557 |
-
((1.26332 0.0300613))
|
558 |
-
((ph_vlng is d)
|
559 |
-
((1.02719 1.1649))
|
560 |
-
((ph_ctype is 0)
|
561 |
-
((R:SylStructure.parent.asyl_in < 1.2)
|
562 |
-
((1.14048 2.2668))
|
563 |
-
((ph_vheight is 1)
|
564 |
-
((1.15528 1.50375))
|
565 |
-
((1.42406 2.07927))))
|
566 |
-
((R:SylStructure.parent.sub_phrases < 1.1)
|
567 |
-
((0.955892 1.10243))
|
568 |
-
((R:SylStructure.parent.syl_break is 2)
|
569 |
-
((1.32682 1.8432))
|
570 |
-
((1.27582 1.59853)))))))
|
571 |
-
((n.ph_ctype is 0)
|
572 |
-
((ph_ctype is n)
|
573 |
-
((R:SylStructure.parent.syl_break is 2)
|
574 |
-
((1.45399 1.12927))
|
575 |
-
((1.05543 0.442376)))
|
576 |
-
((R:SylStructure.parent.syl_break is 4)
|
577 |
-
((R:SylStructure.parent.position_type is final)
|
578 |
-
((ph_ctype is f)
|
579 |
-
((1.46434 1.76508))
|
580 |
-
((0.978055 0.7486)))
|
581 |
-
((1.2395 2.30826)))
|
582 |
-
((ph_ctype is 0)
|
583 |
-
((0.935325 1.69917))
|
584 |
-
((nn.ph_vfront is 1)
|
585 |
-
((1.20456 1.31128))
|
586 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.2)
|
587 |
-
((nn.ph_vheight is 0)
|
588 |
-
((1.16907 0.212421))
|
589 |
-
((0.952091 0.653094)))
|
590 |
-
((p.ph_ctype is 0)
|
591 |
-
((1.05502 1.25802))
|
592 |
-
((0.818731 0.777568))))))))
|
593 |
-
((ph_ctype is f)
|
594 |
-
((p.ph_ctype is 0)
|
595 |
-
((1.03918 0.163941))
|
596 |
-
((0.737545 -0.167063)))
|
597 |
-
((R:SylStructure.parent.position_type is final)
|
598 |
-
((n.ph_ctype is n)
|
599 |
-
((R:SylStructure.parent.last_accent < 0.5)
|
600 |
-
((R:SylStructure.parent.sub_phrases < 2.8)
|
601 |
-
((0.826207 -0.000859005))
|
602 |
-
((0.871119 0.273433)))
|
603 |
-
((R:SylStructure.parent.parent.word_numsyls < 2.4)
|
604 |
-
((1.17405 1.05694))
|
605 |
-
((0.858394 0.244916))))
|
606 |
-
((R:SylStructure.parent.syl_codasize < 2.2)
|
607 |
-
((p.ph_ctype is 0)
|
608 |
-
((1.14092 1.21187))
|
609 |
-
((R:SylStructure.parent.syl_break is 2)
|
610 |
-
((1.02653 0.59865))
|
611 |
-
((0.94248 1.1634))))
|
612 |
-
((seg_coda_fric is 0)
|
613 |
-
((1.07441 0.292935))
|
614 |
-
((1.15736 0.92574)))))
|
615 |
-
((ph_vlng is s)
|
616 |
-
((R:SylStructure.parent.syl_break is 2)
|
617 |
-
((1.34638 1.23484))
|
618 |
-
((0.951514 2.02008)))
|
619 |
-
((ph_ctype is 0)
|
620 |
-
((p.ph_ctype is r)
|
621 |
-
((0.806106 0.697089))
|
622 |
-
((R:SylStructure.parent.syl_break is 2)
|
623 |
-
((1.10891 0.992197))
|
624 |
-
((1.04657 1.51093))))
|
625 |
-
((1.18165 0.520952)))))))))
|
626 |
-
((p.ph_vlng is 0)
|
627 |
-
((pos_in_syl < 0.7)
|
628 |
-
((R:SylStructure.parent.position_type is final)
|
629 |
-
((ph_ctype is r)
|
630 |
-
((0.966357 0.185827))
|
631 |
-
((ph_ctype is s)
|
632 |
-
((0.647163 0.0332298))
|
633 |
-
((0.692972 -0.534917))))
|
634 |
-
((ph_ctype is s)
|
635 |
-
((0.881521 0.575107))
|
636 |
-
((p.ph_ctype is f)
|
637 |
-
((0.8223 -0.111275))
|
638 |
-
((R:SylStructure.parent.last_accent < 0.3)
|
639 |
-
((0.969188 0.09447))
|
640 |
-
((0.894438 0.381947))))))
|
641 |
-
((p.ph_ctype is f)
|
642 |
-
((0.479748 -0.490108))
|
643 |
-
((0.813125 -0.201268))))
|
644 |
-
((ph_ctype is s)
|
645 |
-
((0.908566 1.20397))
|
646 |
-
((R:SylStructure.parent.last_accent < 1.2)
|
647 |
-
((0.88078 0.636568))
|
648 |
-
((0.978087 1.07763))))))
|
649 |
-
((pos_in_syl < 1.3)
|
650 |
-
((R:SylStructure.parent.syl_break is 0)
|
651 |
-
((pos_in_syl < 0.1)
|
652 |
-
((R:SylStructure.parent.position_type is initial)
|
653 |
-
((p.ph_ctype is n)
|
654 |
-
((0.801651 -0.0163359))
|
655 |
-
((ph_ctype is s)
|
656 |
-
((n.ph_ctype is r)
|
657 |
-
((0.893307 1.07253))
|
658 |
-
((p.ph_vlng is 0)
|
659 |
-
((0.92651 0.525806))
|
660 |
-
((0.652444 0.952792))))
|
661 |
-
((p.ph_vlng is 0)
|
662 |
-
((seg_onsetcoda is coda)
|
663 |
-
((0.820151 0.469117))
|
664 |
-
((p.ph_ctype is f)
|
665 |
-
((0.747972 -0.0716448))
|
666 |
-
((ph_ctype is f)
|
667 |
-
((0.770882 0.457137))
|
668 |
-
((0.840905 0.102492)))))
|
669 |
-
((R:SylStructure.parent.syl_out < 1.1)
|
670 |
-
((0.667824 0.697337))
|
671 |
-
((0.737967 0.375114))))))
|
672 |
-
((ph_vheight is 1)
|
673 |
-
((0.624353 0.410671))
|
674 |
-
((R:SylStructure.parent.asyl_in < 0.8)
|
675 |
-
((0.647905 -0.331055))
|
676 |
-
((p.ph_ctype is s)
|
677 |
-
((0.629039 -0.240616))
|
678 |
-
((0.749277 -0.0191273))))))
|
679 |
-
((ph_vheight is 3)
|
680 |
-
((p.ph_ctype is s)
|
681 |
-
((0.626922 0.556537))
|
682 |
-
((0.789357 0.153892)))
|
683 |
-
((seg_onsetcoda is coda)
|
684 |
-
((n.ph_ctype is 0)
|
685 |
-
((R:SylStructure.parent.parent.word_numsyls < 3.4)
|
686 |
-
((0.744714 0.123242))
|
687 |
-
((0.742039 0.295753)))
|
688 |
-
((seg_coda_fric is 0)
|
689 |
-
((R:SylStructure.parent.parent.word_numsyls < 2.4)
|
690 |
-
((ph_vheight is 1)
|
691 |
-
((0.549715 -0.341018))
|
692 |
-
((0.573641 -0.00893114)))
|
693 |
-
((nn.ph_vfront is 2)
|
694 |
-
((0.67099 -0.744625))
|
695 |
-
((0.664438 -0.302803))))
|
696 |
-
((p.ph_vlng is 0)
|
697 |
-
((0.630028 0.113815))
|
698 |
-
((0.632794 -0.128733)))))
|
699 |
-
((ph_ctype is r)
|
700 |
-
((0.367169 -0.854509))
|
701 |
-
((0.94334 -0.216179))))))
|
702 |
-
((n.ph_ctype is f)
|
703 |
-
((ph_vlng is 0)
|
704 |
-
((1.3089 0.46195))
|
705 |
-
((R:SylStructure.parent.syl_codasize < 1.3)
|
706 |
-
((1.07673 0.657169))
|
707 |
-
((pp.ph_vlng is 0)
|
708 |
-
((0.972319 1.08222))
|
709 |
-
((1.00038 1.46257)))))
|
710 |
-
((p.ph_vlng is l)
|
711 |
-
((1.03617 0.785204))
|
712 |
-
((p.ph_vlng is a)
|
713 |
-
((R:SylStructure.parent.position_type is final)
|
714 |
-
((1.00681 0.321168))
|
715 |
-
((0.928115 0.950834)))
|
716 |
-
((ph_vlng is 0)
|
717 |
-
((pos_in_syl < 0.1)
|
718 |
-
((R:SylStructure.parent.position_type is final)
|
719 |
-
((0.863682 -0.167374))
|
720 |
-
((nn.ph_vheight is 0)
|
721 |
-
((p.ph_ctype is f)
|
722 |
-
((0.773591 -0.00374425))
|
723 |
-
((R:SylStructure.parent.syl_out < 1.1)
|
724 |
-
((0.951802 0.228448))
|
725 |
-
((1.02282 0.504252))))
|
726 |
-
((1.09721 0.736476))))
|
727 |
-
((R:SylStructure.parent.position_type is final)
|
728 |
-
((1.04302 0.0590974))
|
729 |
-
((0.589208 -0.431535))))
|
730 |
-
((n.ph_ctype is 0)
|
731 |
-
((1.27879 1.00642))
|
732 |
-
((ph_vlng is s)
|
733 |
-
((R:SylStructure.parent.asyl_in < 1.4)
|
734 |
-
((0.935787 0.481652))
|
735 |
-
((0.9887 0.749861)))
|
736 |
-
((R:SylStructure.parent.syl_out < 1.1)
|
737 |
-
((R:SylStructure.parent.position_type is final)
|
738 |
-
((0.921307 0.0696307))
|
739 |
-
((0.83675 0.552212)))
|
740 |
-
((0.810076 -0.0479225))))))))))
|
741 |
-
((ph_ctype is s)
|
742 |
-
((n.ph_ctype is s)
|
743 |
-
((0.706959 -1.0609))
|
744 |
-
((p.ph_ctype is n)
|
745 |
-
((0.850614 -0.59933))
|
746 |
-
((n.ph_ctype is r)
|
747 |
-
((0.665947 0.00698725))
|
748 |
-
((n.ph_ctype is 0)
|
749 |
-
((R:SylStructure.parent.position_type is initial)
|
750 |
-
((0.762889 -0.0649044))
|
751 |
-
((0.723956 -0.248899)))
|
752 |
-
((R:SylStructure.parent.sub_phrases < 1.4)
|
753 |
-
((0.632957 -0.601987))
|
754 |
-
((0.889114 -0.302401)))))))
|
755 |
-
((ph_ctype is f)
|
756 |
-
((R:SylStructure.parent.syl_codasize < 2.2)
|
757 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.2)
|
758 |
-
((R:SylStructure.parent.syl_out < 1.1)
|
759 |
-
((0.865267 0.164636))
|
760 |
-
((0.581827 -0.0989051)))
|
761 |
-
((nn.ph_vfront is 2)
|
762 |
-
((0.684459 -0.316836))
|
763 |
-
((0.778854 -0.0961191))))
|
764 |
-
((R:SylStructure.parent.syl_out < 1.1)
|
765 |
-
((p.ph_ctype is s)
|
766 |
-
((0.837964 -0.429437))
|
767 |
-
((0.875304 -0.0652743)))
|
768 |
-
((0.611071 -0.635089))))
|
769 |
-
((p.ph_ctype is r)
|
770 |
-
((R:SylStructure.parent.syl_out < 1.1)
|
771 |
-
((0.762012 0.0139361))
|
772 |
-
((0.567983 -0.454845)))
|
773 |
-
((R:SylStructure.parent.syl_codasize < 2.2)
|
774 |
-
((ph_ctype is l)
|
775 |
-
((1.18845 0.809091))
|
776 |
-
((R:SylStructure.parent.position_type is initial)
|
777 |
-
((ph_ctype is n)
|
778 |
-
((0.773548 -0.277092))
|
779 |
-
((1.01586 0.281001)))
|
780 |
-
((p.ph_ctype is 0)
|
781 |
-
((1.06831 0.699145))
|
782 |
-
((0.924189 0.241873)))))
|
783 |
-
((R:SylStructure.parent.syl_break is 0)
|
784 |
-
((ph_ctype is n)
|
785 |
-
((0.592321 -0.470784))
|
786 |
-
((0.778688 -0.072112)))
|
787 |
-
((n.ph_ctype is s)
|
788 |
-
((1.08848 0.0733489))
|
789 |
-
((1.25674 0.608371))))))))))
|
790 |
-
((pos_in_syl < 0.7)
|
791 |
-
((p.ph_vlng is 0)
|
792 |
-
((R:SylStructure.parent.position_type is mid)
|
793 |
-
((ph_ctype is 0)
|
794 |
-
((ph_vheight is 2)
|
795 |
-
((0.456225 -0.293282))
|
796 |
-
((0.561529 -0.0816115)))
|
797 |
-
((0.6537 -0.504024)))
|
798 |
-
((ph_ctype is s)
|
799 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 2)
|
800 |
-
((1.31586 0.98395))
|
801 |
-
((R:SylStructure.parent.position_type is single)
|
802 |
-
((0.816869 0.634789))
|
803 |
-
((R:SylStructure.parent.syl_out < 4.4)
|
804 |
-
((1.05578 0.479029))
|
805 |
-
((R:SylStructure.parent.asyl_in < 0.4)
|
806 |
-
((1.11813 0.143214))
|
807 |
-
((0.87178 0.406834))))))
|
808 |
-
((n.ph_ctype is n)
|
809 |
-
((R:SylStructure.parent.last_accent < 0.6)
|
810 |
-
((0.838154 -0.415599))
|
811 |
-
((0.924024 0.110288)))
|
812 |
-
((seg_onsetcoda is coda)
|
813 |
-
((nn.ph_vfront is 2)
|
814 |
-
((0.670096 0.0314187))
|
815 |
-
((n.ph_ctype is f)
|
816 |
-
((1.00363 0.693893))
|
817 |
-
((R:SylStructure.parent.syl_out < 6)
|
818 |
-
((0.772363 0.215675))
|
819 |
-
((0.920313 0.574068)))))
|
820 |
-
((R:SylStructure.parent.position_type is final)
|
821 |
-
((0.673837 -0.458142))
|
822 |
-
((R:SylStructure.parent.sub_phrases < 2.8)
|
823 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 2)
|
824 |
-
((0.894817 0.304628))
|
825 |
-
((ph_ctype is n)
|
826 |
-
((0.787302 -0.23094))
|
827 |
-
((R:SylStructure.parent.asyl_in < 1.2)
|
828 |
-
((ph_ctype is f)
|
829 |
-
((R:SylStructure.parent.last_accent < 0.5)
|
830 |
-
((1.12278 0.326954))
|
831 |
-
((0.802236 -0.100616)))
|
832 |
-
((0.791255 -0.0919132)))
|
833 |
-
((0.95233 0.219053)))))
|
834 |
-
((R:SylStructure.parent.position_type is initial)
|
835 |
-
((ph_ctype is f)
|
836 |
-
((1.0616 0.216118))
|
837 |
-
((0.703216 -0.00834086)))
|
838 |
-
((ph_ctype is f)
|
839 |
-
((1.22277 0.761763))
|
840 |
-
((0.904811 0.332721))))))))))
|
841 |
-
((ph_vheight is 0)
|
842 |
-
((p.ph_vlng is s)
|
843 |
-
((0.873379 0.217178))
|
844 |
-
((n.ph_ctype is r)
|
845 |
-
((0.723915 1.29451))
|
846 |
-
((n.ph_ctype is 0)
|
847 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 1)
|
848 |
-
((R:SylStructure.parent.sub_phrases < 4)
|
849 |
-
((seg_coda_fric is 0)
|
850 |
-
((p.ph_vlng is l)
|
851 |
-
((0.849154 0.945261))
|
852 |
-
((0.633261 0.687498)))
|
853 |
-
((0.728546 0.403076)))
|
854 |
-
((0.850962 1.00255)))
|
855 |
-
((0.957999 1.09113)))
|
856 |
-
((0.85771 0.209045)))))
|
857 |
-
((ph_vheight is 2)
|
858 |
-
((0.803401 -0.0544067))
|
859 |
-
((0.681353 0.256045)))))
|
860 |
-
((n.ph_ctype is f)
|
861 |
-
((ph_ctype is s)
|
862 |
-
((p.ph_vlng is 0)
|
863 |
-
((0.479307 -0.9673))
|
864 |
-
((0.700477 -0.351397)))
|
865 |
-
((ph_ctype is f)
|
866 |
-
((0.73467 -0.6233))
|
867 |
-
((R:SylStructure.parent.syl_break is 0)
|
868 |
-
((p.ph_ctype is s)
|
869 |
-
((0.56282 0.266234))
|
870 |
-
((p.ph_ctype is r)
|
871 |
-
((0.446203 -0.302281))
|
872 |
-
((R:SylStructure.parent.sub_phrases < 2.7)
|
873 |
-
((ph_ctype is 0)
|
874 |
-
((0.572016 -0.0102436))
|
875 |
-
((0.497358 -0.274514)))
|
876 |
-
((0.545477 0.0482177)))))
|
877 |
-
((ph_vlng is s)
|
878 |
-
((0.805269 0.888495))
|
879 |
-
((ph_ctype is n)
|
880 |
-
((0.869854 0.653018))
|
881 |
-
((R:SylStructure.parent.sub_phrases < 2.2)
|
882 |
-
((0.735031 0.0612886))
|
883 |
-
((0.771859 0.346637))))))))
|
884 |
-
((R:SylStructure.parent.syl_codasize < 1.4)
|
885 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.3)
|
886 |
-
((R:SylStructure.parent.position_type is initial)
|
887 |
-
((0.743458 0.0411808))
|
888 |
-
((1.13068 0.613305)))
|
889 |
-
((pos_in_syl < 1.2)
|
890 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 1)
|
891 |
-
((1.11481 0.175467))
|
892 |
-
((0.937893 -0.276407)))
|
893 |
-
((0.74264 -0.550878))))
|
894 |
-
((pos_in_syl < 3.4)
|
895 |
-
((seg_onsetcoda is coda)
|
896 |
-
((ph_ctype is r)
|
897 |
-
((n.ph_ctype is s)
|
898 |
-
((0.714319 -0.240328))
|
899 |
-
((p.ph_ctype is 0)
|
900 |
-
((0.976987 0.330352))
|
901 |
-
((1.1781 -0.0816682))))
|
902 |
-
((ph_ctype is l)
|
903 |
-
((n.ph_ctype is 0)
|
904 |
-
((1.39137 0.383533))
|
905 |
-
((0.725585 -0.324515)))
|
906 |
-
((ph_vheight is 3)
|
907 |
-
((ph_vlng is d)
|
908 |
-
((0.802626 -0.62487))
|
909 |
-
((n.ph_ctype is r)
|
910 |
-
((0.661091 -0.513869))
|
911 |
-
((R:SylStructure.parent.position_type is initial)
|
912 |
-
((R:SylStructure.parent.parent.word_numsyls < 2.4)
|
913 |
-
((0.482285 0.207874))
|
914 |
-
((0.401601 -0.0204711)))
|
915 |
-
((0.733755 0.397372)))))
|
916 |
-
((n.ph_ctype is r)
|
917 |
-
((p.ph_ctype is 0)
|
918 |
-
((pos_in_syl < 1.2)
|
919 |
-
((0.666325 0.271734))
|
920 |
-
((nn.ph_vheight is 0)
|
921 |
-
((0.642401 -0.261466))
|
922 |
-
((0.783684 -0.00956571))))
|
923 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.2)
|
924 |
-
((0.692225 -0.381895))
|
925 |
-
((0.741921 -0.0898767))))
|
926 |
-
((nn.ph_vfront is 2)
|
927 |
-
((ph_ctype is s)
|
928 |
-
((0.697527 -1.12626))
|
929 |
-
((n.ph_ctype is s)
|
930 |
-
((ph_vlng is 0)
|
931 |
-
((R:SylStructure.parent.sub_phrases < 2.4)
|
932 |
-
((0.498719 -0.906926))
|
933 |
-
((0.635342 -0.625651)))
|
934 |
-
((0.45886 -0.385089)))
|
935 |
-
((0.848596 -0.359702))))
|
936 |
-
((p.ph_vlng is a)
|
937 |
-
((p.ph_ctype is 0)
|
938 |
-
((0.947278 0.216904))
|
939 |
-
((0.637933 -0.394349)))
|
940 |
-
((p.ph_ctype is r)
|
941 |
-
((R:SylStructure.parent.syl_break is 0)
|
942 |
-
((0.529903 -0.860573))
|
943 |
-
((0.581378 -0.510488)))
|
944 |
-
((ph_vlng is 0)
|
945 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.2)
|
946 |
-
((seg_onset_stop is 0)
|
947 |
-
((R:SylStructure.parent.syl_break is 0)
|
948 |
-
((p.ph_vlng is d)
|
949 |
-
((0.768363 0.0108428))
|
950 |
-
((ph_ctype is s)
|
951 |
-
((0.835756 -0.035054))
|
952 |
-
((ph_ctype is f)
|
953 |
-
((p.ph_vlng is s)
|
954 |
-
((0.602016 -0.179727))
|
955 |
-
((0.640126 -0.297341)))
|
956 |
-
((0.674628 -0.542602)))))
|
957 |
-
((ph_ctype is s)
|
958 |
-
((0.662261 -0.60496))
|
959 |
-
((0.662088 -0.432058))))
|
960 |
-
((R:SylStructure.parent.syl_out < 4.4)
|
961 |
-
((0.582448 -0.389079))
|
962 |
-
((ph_ctype is s)
|
963 |
-
((0.60413 -0.73564))
|
964 |
-
((0.567153 -0.605444)))))
|
965 |
-
((R:SylStructure.parent.R:Syllable.p.syl_break is 2)
|
966 |
-
((0.761115 -0.827377))
|
967 |
-
((ph_ctype is n)
|
968 |
-
((0.855183 -0.275338))
|
969 |
-
((R:SylStructure.parent.syl_break is 0)
|
970 |
-
((0.788288 -0.802801))
|
971 |
-
((R:SylStructure.parent.syl_codasize < 2.2)
|
972 |
-
((0.686134 -0.371234))
|
973 |
-
((0.840184 -0.772883)))))))
|
974 |
-
((pos_in_syl < 1.2)
|
975 |
-
((R:SylStructure.parent.syl_break is 0)
|
976 |
-
((n.ph_ctype is n)
|
977 |
-
((0.423592 -0.655006))
|
978 |
-
((R:SylStructure.parent.syl_out < 4.4)
|
979 |
-
((0.595269 -0.303751))
|
980 |
-
((0.478433 -0.456882))))
|
981 |
-
((0.688133 -0.133182)))
|
982 |
-
((seg_onset_stop is 0)
|
983 |
-
((1.27464 0.114442))
|
984 |
-
((0.406837 -0.167545))))))))))))
|
985 |
-
((ph_ctype is r)
|
986 |
-
((0.462874 -0.87695))
|
987 |
-
((R:SylStructure.parent.R:Syllable.n.syl_onsetsize < 0.2)
|
988 |
-
((0.645442 -0.640572))
|
989 |
-
((0.673717 -0.321322)))))
|
990 |
-
((0.61008 -0.925472))))))))
|
991 |
-
;; RMSE 0.8085 Correlation is 0.5899 Mean (abs) Error 0.6024 (0.5393)
|
992 |
-
|
993 |
-
|
994 |
-
))
|
995 |
-
|
996 |
-
(provide 'apml_kaldurtreeZ)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/cart_aux.scm
DELETED
@@ -1,200 +0,0 @@
|
|
1 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2 |
-
;;; ;;
|
3 |
-
;;; Centre for Speech Technology Research ;;
|
4 |
-
;;; University of Edinburgh, UK ;;
|
5 |
-
;;; Copyright (c) 1996-2011 ;;
|
6 |
-
;;; All Rights Reserved. ;;
|
7 |
-
;;; ;;
|
8 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;
|
9 |
-
;;; this software and its documentation without restriction, including ;;
|
10 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;
|
11 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;
|
12 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;
|
13 |
-
;;; the following conditions: ;;
|
14 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;
|
15 |
-
;;; conditions and the following disclaimer. ;;
|
16 |
-
;;; 2. Any modifications must be clearly marked as such. ;;
|
17 |
-
;;; 3. Original authors' names are not deleted. ;;
|
18 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;
|
19 |
-
;;; derived from this software without specific prior written ;;
|
20 |
-
;;; permission. ;;
|
21 |
-
;;; ;;
|
22 |
-
;;; THE UNIVERSITY OF EDINBURGH AND THE CONTRIBUTORS TO THIS WORK ;;
|
23 |
-
;;; DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ;;
|
24 |
-
;;; ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT ;;
|
25 |
-
;;; SHALL THE UNIVERSITY OF EDINBURGH NOR THE CONTRIBUTORS BE LIABLE ;;
|
26 |
-
;;; FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ;;
|
27 |
-
;;; WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN ;;
|
28 |
-
;;; AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ;;
|
29 |
-
;;; ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF ;;
|
30 |
-
;;; THIS SOFTWARE. ;;
|
31 |
-
;;; ;;
|
32 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
33 |
-
;;;
|
34 |
-
;;; Some functions for manipulating decision trees
|
35 |
-
;;;
|
36 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
37 |
-
|
38 |
-
(define (cart_prune_tree_thresh tree threshold default)
|
39 |
-
"(prune_cart_tree_thresh TREE THRESHOLD DEFAULT)
|
40 |
-
Prune the classification tree TREE so that all tail nodes with
|
41 |
-
a prediction probabality less than THRESHOLD and changed to return
|
42 |
-
DEFAULT instead. This may be used when different mistakes have actually
|
43 |
-
different penalites hence some control of the defaults need to be
|
44 |
-
controlled."
|
45 |
-
(cond
|
46 |
-
((cdr tree) ;; a question
|
47 |
-
(list
|
48 |
-
(car tree)
|
49 |
-
(cart_prune_tree_thresh (car (cdr tree)) threshold default)
|
50 |
-
(cart_prune_tree_thresh (car (cdr (cdr tree))) threshold default)))
|
51 |
-
((< (cart_class_probability (car tree)) threshold)
|
52 |
-
(list (list (list threshold default) default)))
|
53 |
-
(t ;; leave asis
|
54 |
-
tree)))
|
55 |
-
|
56 |
-
(define (cart_class_probability class)
|
57 |
-
"(cart_class_probability CLASS)
|
58 |
-
Returns the probability of the best class in the cart leaf node CLASS.
|
59 |
-
If CLASS simple has a value and now probabilities the probabilities
|
60 |
-
it assume to be 1.0."
|
61 |
-
(let ((val 0.0))
|
62 |
-
(set! val (assoc (car (last class)) class))
|
63 |
-
(if val
|
64 |
-
(car (cdr val))
|
65 |
-
1.0)))
|
66 |
-
|
67 |
-
(define (cart_class_prune_merge tree)
|
68 |
-
"(cart_class_prune_merge tree)
|
69 |
-
Prune all sub trees which are pure. That is they all predict the
|
70 |
-
same class. This can happen when some other pruning technique
|
71 |
-
as modified a sub-tree now making it pure."
|
72 |
-
(let ((pure (cart_tree_pure tree)))
|
73 |
-
(cond
|
74 |
-
(pure pure)
|
75 |
-
((cdr tree);; a question
|
76 |
-
(list
|
77 |
-
(car tree)
|
78 |
-
(cart_class_prune_merge (car (cdr tree)))
|
79 |
-
(cart_class_prune_merge (car (cdr (cdr tree))))))
|
80 |
-
(t;; a leaf leave asis
|
81 |
-
tree))))
|
82 |
-
|
83 |
-
(define (cart_tree_pure tree)
|
84 |
-
"(cart_tree_pure tree)
|
85 |
-
Returns a probability density function if all nodes in this tree
|
86 |
-
predict the same class and nil otherwise"
|
87 |
-
(cond
|
88 |
-
((cdr tree)
|
89 |
-
(let ((left (cart_tree_pure (car (cdr tree))))
|
90 |
-
(right (cart_tree_pure (car (cdr (cdr tree))))))
|
91 |
-
(cond
|
92 |
-
((not left) nil)
|
93 |
-
((not right) nil)
|
94 |
-
((equal? (car (last left)) (car (last right)))
|
95 |
-
left)
|
96 |
-
(t
|
97 |
-
nil))))
|
98 |
-
(t ;; its a leaf, so of couse its pure
|
99 |
-
tree)))
|
100 |
-
|
101 |
-
(define (cart_simplify_tree tree map)
|
102 |
-
"(cart_simplify_tree TREE)
|
103 |
-
Simplify a CART tree by reducing probability density functions to
|
104 |
-
simple single clasifications (no probabilities). This removes valuable
|
105 |
-
information from the tree but makes them smaller easier to read by humans
|
106 |
-
and faster to read by machines. Also the classes may be mapped by the assoc
|
107 |
-
list in map. The bright ones amongst you will note this could be
|
108 |
-
better and merge 'is' operators into 'in' operators in some situations
|
109 |
-
especially if you are ignoring actual probability distributions."
|
110 |
-
(cond
|
111 |
-
((cdr tree)
|
112 |
-
(list
|
113 |
-
(car tree)
|
114 |
-
(cart_simplify_tree (car (cdr tree)) map)
|
115 |
-
(cart_simplify_tree (car (cdr (cdr tree))) map)))
|
116 |
-
(t
|
117 |
-
(let ((class (car (last (car tree)))))
|
118 |
-
(if (assoc class map)
|
119 |
-
(list (cdr (assoc class map)))
|
120 |
-
(list (last (car tree))))))))
|
121 |
-
|
122 |
-
(define (cart_simplify_tree2 tree)
|
123 |
-
"(cart_simplify_tree2 TREE)
|
124 |
-
Simplify a CART tree by reducing probability density functions to
|
125 |
-
only non-zero probabilities."
|
126 |
-
(cond
|
127 |
-
((cdr tree)
|
128 |
-
(list
|
129 |
-
(car tree)
|
130 |
-
(cart_simplify_tree2 (car (cdr tree)))
|
131 |
-
(cart_simplify_tree2 (car (cdr (cdr tree))))))
|
132 |
-
(t
|
133 |
-
(list
|
134 |
-
(cart_remove_zero_probs (car tree))))))
|
135 |
-
|
136 |
-
(define (cart_remove_zero_probs pdf)
|
137 |
-
"(cart_remove_zero_probs pdf)
|
138 |
-
Removes zero probability classes in pdf, last in list
|
139 |
-
is best in class (as from cart leaf node)."
|
140 |
-
(cond
|
141 |
-
((null (cdr pdf)) pdf)
|
142 |
-
((equal? 0 (car (cdr (car pdf))))
|
143 |
-
(cart_remove_zero_probs (cdr pdf)))
|
144 |
-
(t
|
145 |
-
(cons
|
146 |
-
(car pdf)
|
147 |
-
(cart_remove_zero_probs (cdr pdf))))))
|
148 |
-
|
149 |
-
(define (cart_interpret_debug i tree)
|
150 |
-
"(cart_interpret_debug i tree)
|
151 |
-
In comparing output between different implementations (flite vs festival)
|
152 |
-
This prints out the details as it interprets the tree."
|
153 |
-
(cond
|
154 |
-
((cdr tree) ;; question
|
155 |
-
(format t "%s %s %s\n" (car (car tree)) (upcase (cadr (car tree)))
|
156 |
-
(car (cddr (car tree))))
|
157 |
-
(set! a (item.feat i (car (car tree))))
|
158 |
-
(format t "%s\n" a)
|
159 |
-
(cond
|
160 |
-
((string-equal "is" (cadr (car tree)))
|
161 |
-
(if (string-equal a (car (cddr (car tree))))
|
162 |
-
(begin
|
163 |
-
(format t " YES\n")
|
164 |
-
(cart_interpret_debug i (car (cdr tree))))
|
165 |
-
(begin
|
166 |
-
(format t " NO\n")
|
167 |
-
(cart_interpret_debug i (car (cddr tree))))))
|
168 |
-
((string-equal "<" (cadr (car tree)))
|
169 |
-
(if (< (parse-number a) (parse-number (car (cddr (car tree)))))
|
170 |
-
(begin
|
171 |
-
(format t " YES\n")
|
172 |
-
(cart_interpret_debug i (car (cdr tree))))
|
173 |
-
(begin
|
174 |
-
(format t " NO\n")
|
175 |
-
(cart_interpret_debug i (car (cddr tree))))))
|
176 |
-
(t
|
177 |
-
(format t "unknown q type %l\n" (car tree)))))
|
178 |
-
(t ;; leaf
|
179 |
-
(car tree)
|
180 |
-
)))
|
181 |
-
|
182 |
-
;;;
|
183 |
-
;;; Prediction tree for OLS trees
|
184 |
-
;;; applies OLS coefficients from appropriate leaf of tree
|
185 |
-
;;;
|
186 |
-
(define (ols_tree_predict i tree)
|
187 |
-
;; Surprisingly simple function does the necessary work
|
188 |
-
(let ((p (wagon i tree)))
|
189 |
-
(apply
|
190 |
-
+
|
191 |
-
(cons
|
192 |
-
(cadr (car (car p))) ;; Intercept
|
193 |
-
(mapcar
|
194 |
-
(lambda (fp)
|
195 |
-
;; get feature value and multiple by coefficent
|
196 |
-
(* (parse-number (item.feat i (car fp))) (cadr fp)))
|
197 |
-
(cdr (car p)))))))
|
198 |
-
|
199 |
-
(provide 'cart_aux)
|
200 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/clunits.scm
DELETED
@@ -1,287 +0,0 @@
|
|
1 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2 |
-
;;; ;;
|
3 |
-
;;; Carnegie Mellon University and ;;
|
4 |
-
;;; Centre for Speech Technology Research ;;
|
5 |
-
;;; University of Edinburgh, UK ;;
|
6 |
-
;;; Copyright (c) 1998-2001 ;;
|
7 |
-
;;; All Rights Reserved. ;;
|
8 |
-
;;; ;;
|
9 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;
|
10 |
-
;;; this software and its documentation without restriction, including ;;
|
11 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;
|
12 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;
|
13 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;
|
14 |
-
;;; the following conditions: ;;
|
15 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;
|
16 |
-
;;; conditions and the following disclaimer. ;;
|
17 |
-
;;; 2. Any modifications must be clearly marked as such. ;;
|
18 |
-
;;; 3. Original authors' names are not deleted. ;;
|
19 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;
|
20 |
-
;;; derived from this software without specific prior written ;;
|
21 |
-
;;; permission. ;;
|
22 |
-
;;; ;;
|
23 |
-
;;; THE UNIVERSITY OF EDINBURGH, CARNEGIE MELLON UNIVERSITY AND THE ;;
|
24 |
-
;;; CONTRIBUTORS TO THIS WORK DISCLAIM ALL WARRANTIES WITH REGARD TO ;;
|
25 |
-
;;; THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY ;;
|
26 |
-
;;; AND FITNESS, IN NO EVENT SHALL THE UNIVERSITY OF EDINBURGH, CARNEGIE ;;
|
27 |
-
;;; MELLON UNIVERSITY NOR THE CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, ;;
|
28 |
-
;;; INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER ;;
|
29 |
-
;;; RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION ;;
|
30 |
-
;;; OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF ;;
|
31 |
-
;;; OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ;;
|
32 |
-
;;; ;;
|
33 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
34 |
-
;;;
|
35 |
-
;;; Cluster Unit selection support (Black and Taylor Eurospeech '97)
|
36 |
-
;;;
|
37 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
38 |
-
;;;
|
39 |
-
;;; Run-time support, selection and synthesis and some debugging functions
|
40 |
-
;;;
|
41 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
42 |
-
|
43 |
-
(require_module 'clunits)
|
44 |
-
|
45 |
-
(defvar cluster_synth_pre_hooks nil)
|
46 |
-
(defvar cluster_synth_post_hooks nil)
|
47 |
-
|
48 |
-
(defvar clunits_time time) ;; some old voices might use this
|
49 |
-
|
50 |
-
(defSynthType Cluster
|
51 |
-
(apply_hooks cluster_synth_pre_hooks utt)
|
52 |
-
(Clunits_Select utt)
|
53 |
-
(Clunits_Get_Units utt)
|
54 |
-
(Clunits_Join_Units utt)
|
55 |
-
(apply_hooks cluster_synth_post_hooks utt)
|
56 |
-
utt
|
57 |
-
)
|
58 |
-
|
59 |
-
(define (Clunits_Join_Units utt)
|
60 |
-
"(Clunits_Join_Units utt)
|
61 |
-
Join the preselected and gotten units into a waveform."
|
62 |
-
(let ((join_method (get_param 'join_method clunits_params 'simple)))
|
63 |
-
;; Choice of function to put them together
|
64 |
-
(cond
|
65 |
-
((string-equal join_method 'windowed)
|
66 |
-
(Clunits_Windowed_Wave utt)
|
67 |
-
(clunits::fix_segs_durs utt))
|
68 |
-
((string-equal join_method 'smoothedjoin)
|
69 |
-
(Clunits_SmoothedJoin_Wave utt)
|
70 |
-
(clunits::fix_segs_durs utt))
|
71 |
-
((string-equal join_method 'none)
|
72 |
-
t)
|
73 |
-
((string-equal join_method 'modified_lpc)
|
74 |
-
(defvar UniSyn_module_hooks nil)
|
75 |
-
(Param.def "unisyn.window_name" "hanning")
|
76 |
-
(Param.def "unisyn.window_factor" 1.0)
|
77 |
-
(Parameter.def 'us_sigpr 'lpc)
|
78 |
-
(mapcar
|
79 |
-
(lambda (u s)
|
80 |
-
(item.set_feat s "source_end" (item.feat u "end")))
|
81 |
-
(utt.relation.items utt 'Unit)
|
82 |
-
(utt.relation.items utt 'Segment))
|
83 |
-
(us_unit_concat utt)
|
84 |
-
(if (not (member 'f0 (utt.relationnames utt)))
|
85 |
-
(targets_to_f0 utt))
|
86 |
-
(if (utt.relation.last utt 'Segment)
|
87 |
-
(set! pm_end (+ (item.feat (utt.relation.last utt 'Segment) "end")
|
88 |
-
0.02))
|
89 |
-
(set! pm_end 0.02))
|
90 |
-
(us_f0_to_pitchmarks utt 'f0 'TargetCoef pm_end)
|
91 |
-
(us_mapping utt 'segment_single)
|
92 |
-
(us_generate_wave utt (Parameter.get 'us_sigpr)
|
93 |
-
'analysis_period))
|
94 |
-
((string-equal join_method 'smoothed_lpc)
|
95 |
-
; (format t "smoothed_lpc\n")
|
96 |
-
(defvar UniSyn_module_hooks nil)
|
97 |
-
(Param.def "unisyn.window_name" "hanning")
|
98 |
-
(Param.def "unisyn.window_factor" 1.0)
|
99 |
-
(Parameter.def 'us_sigpr 'lpc)
|
100 |
-
(mapcar
|
101 |
-
(lambda (u s)
|
102 |
-
(item.set_feat s "source_end" (item.feat u "end"))
|
103 |
-
(item.set_feat s "unit_duration"
|
104 |
-
(- (item.feat u "seg_end") (item.feat u "seg_start")))
|
105 |
-
)
|
106 |
-
(utt.relation.items utt 'Unit)
|
107 |
-
(utt.relation.items utt 'Segment))
|
108 |
-
(us_unit_concat utt)
|
109 |
-
(mapcar
|
110 |
-
(lambda (u s)
|
111 |
-
(item.set_feat s "num_frames" (item.feat u "num_frames")))
|
112 |
-
(utt.relation.items utt 'Unit)
|
113 |
-
(utt.relation.items utt 'Segment))
|
114 |
-
(if (not (member 'f0 (utt.relationnames utt)))
|
115 |
-
(targets_to_f0 utt))
|
116 |
-
(if (utt.relation.last utt 'Segment)
|
117 |
-
(set! pm_end (+ (item.feat (utt.relation.last utt 'Segment) "end")
|
118 |
-
0.02))
|
119 |
-
(set! pm_end 0.02))
|
120 |
-
(us_f0_to_pitchmarks utt 'f0 'TargetCoef pm_end)
|
121 |
-
(cl_mapping utt clunits_params)
|
122 |
-
(us_generate_wave utt (Parameter.get 'us_sigpr)
|
123 |
-
'analysis_period))
|
124 |
-
(t
|
125 |
-
(Clunits_Simple_Wave utt)))
|
126 |
-
utt
|
127 |
-
)
|
128 |
-
)
|
129 |
-
|
130 |
-
(define (clunits::units_selected utt filename)
|
131 |
-
"(clunits::units_selected utt filename)
|
132 |
-
Output selected unitsfile indexes for each unit in the given utterance.
|
133 |
-
Results saved in given file name, or stdout if filename is \"-\"."
|
134 |
-
(let ((fd (if (string-equal filename "-")
|
135 |
-
t
|
136 |
-
(fopen filename "w")))
|
137 |
-
(end 0)
|
138 |
-
(sample_rate
|
139 |
-
(cadr (assoc 'sample_rate (wave.info (utt.wave utt))))))
|
140 |
-
(format fd "#\n")
|
141 |
-
(mapcar
|
142 |
-
(lambda (s)
|
143 |
-
(let ((dur (/ (- (item.feat s "samp_end")
|
144 |
-
(item.feat s "samp_start"))
|
145 |
-
sample_rate))
|
146 |
-
(start (/ (item.feat s "samp_start") sample_rate)))
|
147 |
-
(set! end (+ end dur))
|
148 |
-
(format fd "%f 125 %s ; %s %10s %f %f %f\n"
|
149 |
-
end
|
150 |
-
(string-before (item.name s) "_")
|
151 |
-
(item.name s)
|
152 |
-
(item.feat s "fileid")
|
153 |
-
(item.feat s "unit_start")
|
154 |
-
(item.feat s "unit_middle")
|
155 |
-
(item.feat s "unit_end"))
|
156 |
-
))
|
157 |
-
(utt.relation.items utt 'Unit))
|
158 |
-
(if (not (string-equal filename "-"))
|
159 |
-
(fclose fd))
|
160 |
-
t))
|
161 |
-
|
162 |
-
(define (clunits::units_segs utt filename)
|
163 |
-
"(clunits::units_segs utt filename)
|
164 |
-
Svaes the unit selections (alone) for display."
|
165 |
-
(let ((fd (if (string-equal filename "-")
|
166 |
-
t
|
167 |
-
(fopen filename "w")))
|
168 |
-
(end 0)
|
169 |
-
(sample_rate
|
170 |
-
(cadr (assoc 'sample_rate (wave.info (utt.wave utt))))))
|
171 |
-
(format fd "#\n")
|
172 |
-
(mapcar
|
173 |
-
(lambda (s)
|
174 |
-
(let ((dur (/ (- (item.feat s "samp_end")
|
175 |
-
(item.feat s "samp_start"))
|
176 |
-
sample_rate))
|
177 |
-
(start (/ (item.feat s "samp_start") sample_rate)))
|
178 |
-
(set! end (+ end dur))
|
179 |
-
(format fd "%f 125 %s \n"
|
180 |
-
end
|
181 |
-
(string-before (item.name s) "_")
|
182 |
-
; (item.name s)
|
183 |
-
)
|
184 |
-
))
|
185 |
-
(utt.relation.items utt 'Unit))
|
186 |
-
(if (not (string-equal filename "-"))
|
187 |
-
(fclose fd))
|
188 |
-
t))
|
189 |
-
|
190 |
-
(define (clunits::fix_segs_durs utt)
|
191 |
-
"(clunits::fix_segs_durs utt)
|
192 |
-
Takes the actual unit times and places then back on the segs."
|
193 |
-
(let ((end 0)
|
194 |
-
(sample_rate
|
195 |
-
(cadr (assoc 'sample_rate (wave.info (utt.wave utt))))))
|
196 |
-
(mapcar
|
197 |
-
(lambda (u s)
|
198 |
-
(let ((dur (/ (- (item.feat u "samp_end")
|
199 |
-
(item.feat u "samp_start"))
|
200 |
-
sample_rate))
|
201 |
-
(seg_start (/ (- (item.feat u "samp_seg_start")
|
202 |
-
(item.feat u "samp_start"))
|
203 |
-
sample_rate)))
|
204 |
-
(if (item.prev s)
|
205 |
-
(item.set_feat (item.prev s) "end"
|
206 |
-
(+ (item.feat s "p.end") seg_start)))
|
207 |
-
(set! end (+ end dur))
|
208 |
-
(item.set_feat s "end" end)))
|
209 |
-
(utt.relation.items utt 'Unit)
|
210 |
-
(utt.relation.items utt 'Segment)
|
211 |
-
)
|
212 |
-
utt))
|
213 |
-
|
214 |
-
(define (clunits::display utt)
|
215 |
-
"(clunits::display utt)
|
216 |
-
Display utterance with emulabel. Note this saves files in
|
217 |
-
scratch/wav/ and scratch/lab/."
|
218 |
-
(let ((id "cl01"))
|
219 |
-
(utt.save.wave utt (format nil "scratch/wav/%s.wav" id))
|
220 |
-
(utt.save.segs utt (format nil "scratch/lab/%s.lab" id))
|
221 |
-
(system "cd scratch; emulabel ../etc/emu_lab cl01 &")
|
222 |
-
t))
|
223 |
-
|
224 |
-
; (define (clunits::debug_resynth_units utt)
|
225 |
-
; "(clunits::debug_resynth_units utt)
|
226 |
-
; Check each of the units in utt against the related label
|
227 |
-
; files and re-synth with any given new boundaries. Note this is
|
228 |
-
; will only work if the segment still overlaps with its original and
|
229 |
-
; also note that with a rebuild of the clunits db a complete different
|
230 |
-
; set of units may be selected for this utterance."
|
231 |
-
; (let ()
|
232 |
-
; (mapcar
|
233 |
-
; (lambda (unit)
|
234 |
-
; (clunits::check_unit_boundaries unit))
|
235 |
-
; (utt.relation.items utt 'Unit))
|
236 |
-
; ;; This can't be done like this ...
|
237 |
-
; (Clunits_Get_Units utt) ;; get unit signal/track stuff
|
238 |
-
; (Clunits_Join_Units utt) ;; make a complete waveform
|
239 |
-
; (apply_hooks cluster_synth_post_hooks utt)
|
240 |
-
; utt)
|
241 |
-
; )
|
242 |
-
|
243 |
-
(define (clunits::join_parameters utt)
|
244 |
-
"(clunits::join_parameters utt)
|
245 |
-
Join selected paremeters (rather than the signal), used in F0 and
|
246 |
-
Articulatory selection."
|
247 |
-
(let ((params nil)
|
248 |
-
(num_channels 0)
|
249 |
-
(num_frames 0 ))
|
250 |
-
|
251 |
-
(mapcar
|
252 |
-
(lambda (unit)
|
253 |
-
(set! num_frames
|
254 |
-
(+ num_frames
|
255 |
-
(track.num_frames (item.feat unit "coefs"))))
|
256 |
-
(set! num_channels (track.num_channels (item.feat unit "coefs")))
|
257 |
-
(format t "coounting %d %d\n" num_frames num_channels)
|
258 |
-
)
|
259 |
-
(utt.relation.items utt 'Unit))
|
260 |
-
|
261 |
-
(set! params (track.resize nil 0 num_channels))
|
262 |
-
|
263 |
-
(mapcar
|
264 |
-
(lambda (unit)
|
265 |
-
(set! frames 0)
|
266 |
-
(format t "inserting \n")
|
267 |
-
(format t "%l %l %l %l %l\n"
|
268 |
-
params (track.num_frames params)
|
269 |
-
(item.feat unit "coefs") 0
|
270 |
-
(track.num_frames (item.feat unit "coefs")))
|
271 |
-
(track.insert
|
272 |
-
params (track.num_frames params)
|
273 |
-
(item.feat unit "coefs") 0
|
274 |
-
(track.num_frames (item.feat unit "coefs")))
|
275 |
-
)
|
276 |
-
(utt.relation.items utt 'Unit))
|
277 |
-
|
278 |
-
(utt.relation.create utt "AllCoefs")
|
279 |
-
(set! coefs_item (utt.relation.append utt "AllCoefs"))
|
280 |
-
(item.set_feat coefs_item "name" "AllCoefs")
|
281 |
-
(item.set_feat coefs_item "AllCoefs" params)
|
282 |
-
|
283 |
-
utt
|
284 |
-
))
|
285 |
-
|
286 |
-
|
287 |
-
(provide 'clunits)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/clunits_build.scm
DELETED
@@ -1,479 +0,0 @@
|
|
1 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2 |
-
;;; ;;
|
3 |
-
;;; Carnegie Mellon University and ;;
|
4 |
-
;;; Centre for Speech Technology Research ;;
|
5 |
-
;;; University of Edinburgh, UK ;;
|
6 |
-
;;; Copyright (c) 1998-2005 ;;
|
7 |
-
;;; All Rights Reserved. ;;
|
8 |
-
;;; ;;
|
9 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;
|
10 |
-
;;; this software and its documentation without restriction, including ;;
|
11 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;
|
12 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;
|
13 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;
|
14 |
-
;;; the following conditions: ;;
|
15 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;
|
16 |
-
;;; conditions and the following disclaimer. ;;
|
17 |
-
;;; 2. Any modifications must be clearly marked as such. ;;
|
18 |
-
;;; 3. Original authors' names are not deleted. ;;
|
19 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;
|
20 |
-
;;; derived from this software without specific prior written ;;
|
21 |
-
;;; permission. ;;
|
22 |
-
;;; ;;
|
23 |
-
;;; THE UNIVERSITY OF EDINBURGH, CARNEGIE MELLON UNIVERSITY AND THE ;;
|
24 |
-
;;; CONTRIBUTORS TO THIS WORK DISCLAIM ALL WARRANTIES WITH REGARD TO ;;
|
25 |
-
;;; THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY ;;
|
26 |
-
;;; AND FITNESS, IN NO EVENT SHALL THE UNIVERSITY OF EDINBURGH, CARNEGIE ;;
|
27 |
-
;;; MELLON UNIVERSITY NOR THE CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, ;;
|
28 |
-
;;; INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER ;;
|
29 |
-
;;; RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION ;;
|
30 |
-
;;; OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF ;;
|
31 |
-
;;; OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ;;
|
32 |
-
;;; ;;
|
33 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
34 |
-
;;;
|
35 |
-
;;; Cluster Unit selection support (Black and Taylor Eurospeech '97)
|
36 |
-
;;;
|
37 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
38 |
-
;;;
|
39 |
-
;;; clunits build support
|
40 |
-
;;;
|
41 |
-
;;; There are five stages to this
|
42 |
-
;;; Load in all utterances
|
43 |
-
;;; Load in their coefficients
|
44 |
-
;;; Collect together the units of the same type
|
45 |
-
;;; build distance tables from them
|
46 |
-
;;; dump features for them
|
47 |
-
;;;
|
48 |
-
|
49 |
-
(require_module 'clunits) ;; C++ modules support
|
50 |
-
(require 'clunits) ;; run time scheme support
|
51 |
-
|
52 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
53 |
-
|
54 |
-
(define (do_all)
|
55 |
-
(let ()
|
56 |
-
|
57 |
-
(format t "Loading utterances and sorting types\n")
|
58 |
-
(set! utterances (acost:db_utts_load clunits_params))
|
59 |
-
(set! unittypes (acost:find_same_types utterances clunits_params))
|
60 |
-
(acost:name_units unittypes)
|
61 |
-
|
62 |
-
(format t "Dumping features for clustering\n")
|
63 |
-
(acost:dump_features unittypes utterances clunits_params)
|
64 |
-
|
65 |
-
(format t "Loading coefficients\n")
|
66 |
-
(acost:utts_load_coeffs utterances)
|
67 |
-
;; If you are short of diskspace try this
|
68 |
-
(acost:disttabs_and_clusters unittypes clunits_params)
|
69 |
-
|
70 |
-
;; or if you have lots of diskspace try
|
71 |
-
; (format t "Building distance tables\n")
|
72 |
-
; (acost:build_disttabs unittypes clunits_params)
|
73 |
-
|
74 |
-
; ;; Build the cluster trees (requires disttabs and features)
|
75 |
-
; (format t "Building cluster trees\n")
|
76 |
-
; (acost:find_clusters (mapcar car unittypes) clunits_params)
|
77 |
-
|
78 |
-
;; Tidy up and put things together
|
79 |
-
(acost:collect_trees (mapcar car unittypes) clunits_params)
|
80 |
-
|
81 |
-
(format t "Saving unit catalogue\n")
|
82 |
-
(acost:save_catalogue utterances clunits_params)
|
83 |
-
|
84 |
-
)
|
85 |
-
)
|
86 |
-
|
87 |
-
(define (do_init)
|
88 |
-
(set! utterances (acost:db_utts_load clunits_params))
|
89 |
-
(set! unittypes (acost:find_same_types utterances clunits_params))
|
90 |
-
(acost:name_units unittypes)
|
91 |
-
t)
|
92 |
-
|
93 |
-
(define (acost:disttabs_and_clusters unittypes clunits_params)
|
94 |
-
"(acost:disttabs_and_custers unittypes)
|
95 |
-
Cause it uses so much diskspace, build each table individually
|
96 |
-
and them the cluster, removing the table before moving on to the
|
97 |
-
next."
|
98 |
-
(mapcar
|
99 |
-
(lambda (uu)
|
100 |
-
(acost:build_disttabs (list uu) clunits_params)
|
101 |
-
(acost:find_clusters (list (car uu)) clunits_params)
|
102 |
-
(delete-file
|
103 |
-
(format nil "%s/%s/%s%s"
|
104 |
-
(get_param 'db_dir clunits_params "./")
|
105 |
-
(get_param 'disttabs_dir clunits_params "disttabs/")
|
106 |
-
(car uu)
|
107 |
-
(get_param 'disttabs_ext clunits_params ".disttab")))
|
108 |
-
)
|
109 |
-
unittypes)
|
110 |
-
t)
|
111 |
-
|
112 |
-
(define (acost:db_utts_load params)
|
113 |
-
"(acost:db_utts_load params)
|
114 |
-
Load in all utterances identified in database."
|
115 |
-
(let ((files (car (cdr (assoc 'files params)))))
|
116 |
-
(set! acost:all_utts
|
117 |
-
(mapcar
|
118 |
-
(lambda (fname)
|
119 |
-
(set! utt_seg (Utterance Text fname))
|
120 |
-
(utt.load utt_seg
|
121 |
-
(string-append
|
122 |
-
(get_param 'db_dir params "./")
|
123 |
-
(get_param 'utts_dir params "festival/utts/")
|
124 |
-
fname
|
125 |
-
(get_param 'utts_ext params ".utt")))
|
126 |
-
utt_seg)
|
127 |
-
files))))
|
128 |
-
|
129 |
-
(define (acost:utts_load_coeffs utterances)
|
130 |
-
"(acost:utts_load_coeffs utterances)
|
131 |
-
Loading the acoustic coefficients of for each utterance."
|
132 |
-
(mapcar
|
133 |
-
(lambda (utt) (acost:utt.load_coeffs utt clunits_params))
|
134 |
-
utterances)
|
135 |
-
t)
|
136 |
-
|
137 |
-
(define (acost:find_same_types utterances params)
|
138 |
-
"(acost:find_same_types utterances)
|
139 |
-
Find all the stream items of the same type and collect them into
|
140 |
-
lists of that type."
|
141 |
-
(let ((clunit_name_feat (get_param 'clunit_name_feat params "name"))
|
142 |
-
(clunit_relation (get_param 'clunit_relation params "Segment")))
|
143 |
-
(set! acost:unittypes nil)
|
144 |
-
(mapcar
|
145 |
-
(lambda (u)
|
146 |
-
(mapcar
|
147 |
-
(lambda (s)
|
148 |
-
(let ((cname (item.feat s clunit_name_feat)))
|
149 |
-
(if (not (string-equal "ignore" cname))
|
150 |
-
(begin
|
151 |
-
(item.set_feat s "clunit_name" (item.feat s clunit_name_feat))
|
152 |
-
(let ((p (assoc (item.feat s "clunit_name") acost:unittypes)))
|
153 |
-
(if p
|
154 |
-
(set-cdr! p (cons s (cdr p)))
|
155 |
-
(set! acost:unittypes
|
156 |
-
(cons
|
157 |
-
(list (item.feat s "clunit_name") s)
|
158 |
-
acost:unittypes))))))))
|
159 |
-
(utt.relation.items u clunit_relation)))
|
160 |
-
utterances)
|
161 |
-
(acost:prune_unittypes acost:unittypes params)))
|
162 |
-
|
163 |
-
(define (acost:prune_unittypes unittypes params)
|
164 |
-
"(acost:prune_unittypes unittypes)
|
165 |
-
If unit types are complex (contain an _) then remove all unittypes sets
|
166 |
-
with less than unittype_prune_threshold (typically 3)."
|
167 |
-
(if (string-matches (car (car unittypes)) ".*_.*")
|
168 |
-
(let ((ut nil) (pt (get_param 'unittype_prune_threshold params 0)))
|
169 |
-
(while unittypes
|
170 |
-
(if (or (eq? pt 0)
|
171 |
-
(> (length (cdr (car unittypes))) pt))
|
172 |
-
(set! ut (cons (car unittypes) ut)))
|
173 |
-
(set! unittypes (cdr unittypes)))
|
174 |
-
(reverse ut))
|
175 |
-
unittypes))
|
176 |
-
|
177 |
-
(define (acost:name_units unittypes)
|
178 |
-
"(acost:name_units unittypes)
|
179 |
-
Names each unit with a unique id and number the occurrences of each type."
|
180 |
-
(let ((idnum 0) (tynum 0))
|
181 |
-
(mapcar
|
182 |
-
(lambda (s)
|
183 |
-
(set! tynum 0)
|
184 |
-
(mapcar
|
185 |
-
(lambda (si)
|
186 |
-
(item.set_feat si "unitid" idnum)
|
187 |
-
(set! idnum (+ 1 idnum))
|
188 |
-
(item.set_feat si "occurid" tynum)
|
189 |
-
(set! tynum (+ 1 tynum)))
|
190 |
-
(cdr s))
|
191 |
-
(format t "units \"%s\" %d\n" (car s) tynum))
|
192 |
-
unittypes)
|
193 |
-
(format t "total units %d\n" idnum)
|
194 |
-
idnum))
|
195 |
-
|
196 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
197 |
-
;;; Generating feature files
|
198 |
-
|
199 |
-
(define (acost:dump_features unittypes utterances params)
|
200 |
-
"(acost:dump_features unittypes utterances params)
|
201 |
-
Do multiple passes over the utterances for each unittype and
|
202 |
-
dump the desired features. This would be easier if utterances
|
203 |
-
weren't require for feature functions."
|
204 |
-
(mapcar
|
205 |
-
(lambda (utype)
|
206 |
-
(acost:dump_features_utype
|
207 |
-
(car utype)
|
208 |
-
(cdr utype)
|
209 |
-
utterances
|
210 |
-
params))
|
211 |
-
unittypes)
|
212 |
-
t)
|
213 |
-
|
214 |
-
(define (acost:dump_features_utype utype uitems utterances params)
|
215 |
-
"(acost:dump_features_utype utype utterances params)
|
216 |
-
Dump features for all items of type utype."
|
217 |
-
(let ((fd (fopen
|
218 |
-
(string-append
|
219 |
-
(get_param 'db_dir params "./")
|
220 |
-
(get_param 'feats_dir params "festival/feats/")
|
221 |
-
utype
|
222 |
-
(get_param 'feats_ext params ".feats"))
|
223 |
-
"w"))
|
224 |
-
(feats (car (cdr (assoc 'feats params)))))
|
225 |
-
(format t "Dumping features for %s\n" utype)
|
226 |
-
(mapcar
|
227 |
-
(lambda (s)
|
228 |
-
(mapcar
|
229 |
-
(lambda (f)
|
230 |
-
(set! fval (unwind-protect (item.feat s f) "0"))
|
231 |
-
(if (or (string-equal "" fval)
|
232 |
-
(string-equal " " fval))
|
233 |
-
(format fd "%l " fval)
|
234 |
-
(format fd "%s " fval)))
|
235 |
-
feats)
|
236 |
-
(format fd "\n"))
|
237 |
-
uitems)
|
238 |
-
(fclose fd)))
|
239 |
-
|
240 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
241 |
-
;;; Tree building functions
|
242 |
-
|
243 |
-
(defvar wagon-balance-size 0)
|
244 |
-
|
245 |
-
(define (acost:find_clusters unittypes clunits_params)
|
246 |
-
"Use wagon to find the best clusters."
|
247 |
-
(mapcar
|
248 |
-
(lambda (unittype)
|
249 |
-
(build_tree unittype clunits_params))
|
250 |
-
unittypes)
|
251 |
-
t)
|
252 |
-
|
253 |
-
(define (build_tree unittype clunits_params)
|
254 |
-
"Build tree with Wagon for this unittype."
|
255 |
-
(let ((command
|
256 |
-
(format nil "%s -desc %s -data '%s' -balance %s -distmatrix '%s' -stop %s -output '%s' %s"
|
257 |
-
(get_param 'wagon_progname clunits_params "wagon")
|
258 |
-
(if (probe_file
|
259 |
-
(string-append
|
260 |
-
(get_param 'db_dir clunits_params "./")
|
261 |
-
(get_param 'wagon_field_desc clunits_params "wagon")
|
262 |
-
"." unittype))
|
263 |
-
;; So there can be unittype specific desc files
|
264 |
-
(string-append
|
265 |
-
(get_param 'db_dir clunits_params "./")
|
266 |
-
(get_param 'wagon_field_desc clunits_params "wagon")
|
267 |
-
"." unittype)
|
268 |
-
(string-append
|
269 |
-
(get_param 'db_dir clunits_params "./")
|
270 |
-
(get_param 'wagon_field_desc clunits_params "wagon")))
|
271 |
-
(string-append
|
272 |
-
(get_param 'db_dir clunits_params "./")
|
273 |
-
(get_param 'feats_dir clunits_params "festival/feats/")
|
274 |
-
unittype
|
275 |
-
(get_param 'feats_ext clunits_params ".feats"))
|
276 |
-
(get_param 'wagon_balance_size clunits_params 0)
|
277 |
-
(string-append
|
278 |
-
(get_param 'db_dir clunits_params "./")
|
279 |
-
(get_param 'disttabs_dir clunits_params "festival/disttabs/")
|
280 |
-
unittype
|
281 |
-
(get_param 'disttabs_ext clunits_params ".disttab"))
|
282 |
-
(get_param 'wagon_cluster_size clunits_params 10)
|
283 |
-
(string-append
|
284 |
-
(get_param 'db_dir clunits_params "./")
|
285 |
-
(get_param 'trees_dir clunits_params "festival/trees/")
|
286 |
-
unittype
|
287 |
-
(get_param 'trees_ext clunits_params ".tree"))
|
288 |
-
(get_param 'wagon_other_params clunits_params "")
|
289 |
-
)))
|
290 |
-
(format t "%s\n" command)
|
291 |
-
(system command)))
|
292 |
-
|
293 |
-
(defvar clunits_tree_minimum_leafs 0)
|
294 |
-
(define (acost:collect_trees unittypes params)
|
295 |
-
"Collect the trees into one file as an assoc list"
|
296 |
-
(let ((fd (fopen
|
297 |
-
(string-append
|
298 |
-
(get_param 'db_dir params "./")
|
299 |
-
(get_param 'trees_dir params "festival/trees/")
|
300 |
-
(get_param 'index_name params "all.")
|
301 |
-
(get_param 'trees_ext params ".tree"))
|
302 |
-
"wb"))
|
303 |
-
(tree_pref
|
304 |
-
(string-append
|
305 |
-
(get_param 'db_dir params "./")
|
306 |
-
(get_param 'trees_dir params "festival/trees/")))
|
307 |
-
(cluster_prune_limit (get_param 'cluster_prune_limit params 0))
|
308 |
-
(cluster_merge (get_param 'cluster_merge params 0)))
|
309 |
-
(format fd ";; Autogenerated list of selection trees\n")
|
310 |
-
(mapcar
|
311 |
-
(lambda (fp)
|
312 |
-
(format fd ";; %l %l\n" (car fp) (car (cdr fp))))
|
313 |
-
params)
|
314 |
-
(format fd "(set! clunits_selection_trees '(\n")
|
315 |
-
(mapcar
|
316 |
-
(lambda (unit)
|
317 |
-
(set! tree (car (load (string-append tree_pref unit ".tree") t)))
|
318 |
-
(if (> cluster_prune_limit 0)
|
319 |
-
(set! tree (cluster_tree_prune tree cluster_prune_limit)))
|
320 |
-
(if (> cluster_merge 0)
|
321 |
-
(set! tree (tree_merge_leafs tree cluster_merge)))
|
322 |
-
(if (boundp 'temp_tree_convert)
|
323 |
-
(set! tree (temp_tree_convert)))
|
324 |
-
(if (> (tree_num_units tree) clunits_tree_minimum_leafs)
|
325 |
-
(pprintf (list unit tree) fd)))
|
326 |
-
unittypes)
|
327 |
-
(format fd "))\n")
|
328 |
-
(fclose fd)))
|
329 |
-
|
330 |
-
(define (cluster_tree_prune_in_line prune_limit)
|
331 |
-
"(cluster_tree_prune_in_line)
|
332 |
-
Prune number of units in each cluster in each tree *by* prune_limit,
|
333 |
-
if negative, or *to* prune_limit, if positive."
|
334 |
-
(set! sucs_select_trees
|
335 |
-
(mapcar
|
336 |
-
(lambda (t)
|
337 |
-
(cluster_tree_prune t prune_limit))
|
338 |
-
sucs_select_trees)))
|
339 |
-
|
340 |
-
(define (tree_merge_leafs tree depth)
|
341 |
-
"(tree_merge_leafs tree depth)
|
342 |
-
Merge the leafs of the tree at goven depth. This allows the trees
|
343 |
-
to be pruned then the single leafs joined together into larger
|
344 |
-
clusters (so the viterbi part has something to do)."
|
345 |
-
(let ((num_leafs (tree_num_leafs tree)))
|
346 |
-
(cond
|
347 |
-
((< num_leafs 2) tree) ;; already at the foot
|
348 |
-
((< num_leafs depth)
|
349 |
-
(tree_collect_leafs tree))
|
350 |
-
(t
|
351 |
-
(list
|
352 |
-
(car tree)
|
353 |
-
(tree_merge_leafs (car (cdr tree)) depth)
|
354 |
-
(tree_merge_leafs (car (cdr (cdr tree))) depth))))))
|
355 |
-
|
356 |
-
(define (tree_num_leafs tree)
|
357 |
-
"(tree_num_leafs tree)
|
358 |
-
Number of leafs of given tree."
|
359 |
-
(cond
|
360 |
-
((cdr tree)
|
361 |
-
(+
|
362 |
-
(tree_num_leafs (car (cdr tree)))
|
363 |
-
(tree_num_leafs (car (cdr (cdr tree))))))
|
364 |
-
(t
|
365 |
-
1)))
|
366 |
-
|
367 |
-
(define (tree_num_units tree)
|
368 |
-
"(tree_num_units tree)
|
369 |
-
Number of leafs of given tree."
|
370 |
-
(cond
|
371 |
-
((cdr tree)
|
372 |
-
(+
|
373 |
-
(tree_num_units (car (cdr tree)))
|
374 |
-
(tree_num_units (car (cdr (cdr tree))))))
|
375 |
-
(t
|
376 |
-
(length (caar tree))
|
377 |
-
)))
|
378 |
-
|
379 |
-
(define (tree_collect_leafs tree)
|
380 |
-
"(tree_collect_leafs tree)
|
381 |
-
Combine all units in the leafs."
|
382 |
-
(cond
|
383 |
-
((cdr tree)
|
384 |
-
(let ((a (tree_collect_leafs (car (cdr tree))))
|
385 |
-
(b (tree_collect_leafs (car (cdr (cdr tree))))))
|
386 |
-
(list
|
387 |
-
(list
|
388 |
-
(append
|
389 |
-
(caar a)
|
390 |
-
(caar b))
|
391 |
-
10.0))))
|
392 |
-
(t
|
393 |
-
tree)))
|
394 |
-
|
395 |
-
(define (cluster_tree_prune tree prune_limit)
|
396 |
-
"(cluster_tree_prune TREE PRUNE_LIMIT)
|
397 |
-
Reduce the number of elements in the (CART) tree leaves to PRUNE_LIMIT
|
398 |
-
removing the ones further from the cluster centre. Maybe later this should
|
399 |
-
have guards on minimum number of units that must remain in the tree and
|
400 |
-
a per unit type limit."
|
401 |
-
(cond
|
402 |
-
((cdr tree) ;; a question
|
403 |
-
(list
|
404 |
-
(car tree)
|
405 |
-
(cluster_tree_prune (car (cdr tree)) prune_limit)
|
406 |
-
(cluster_tree_prune (car (cdr (cdr tree))) prune_limit)))
|
407 |
-
(t ;; tree leave
|
408 |
-
(list
|
409 |
-
(list
|
410 |
-
(remove_n_worst
|
411 |
-
(car (car tree))
|
412 |
-
(if (< prune_limit 0)
|
413 |
-
(* -1 prune_limit)
|
414 |
-
(- (length (car (car tree))) prune_limit)))
|
415 |
-
(car (cdr (car tree))))))))
|
416 |
-
|
417 |
-
(define (remove_n_worst lll togo)
|
418 |
-
"(remove_n_worst lll togo)
|
419 |
-
Remove togo worst items from lll."
|
420 |
-
(cond
|
421 |
-
((< togo 0)
|
422 |
-
lll)
|
423 |
-
((equal? 0 togo)
|
424 |
-
lll)
|
425 |
-
(t
|
426 |
-
(remove_n_worst
|
427 |
-
(remove (worst_unit (cdr lll) (car lll)) lll)
|
428 |
-
(- togo 1)))))
|
429 |
-
|
430 |
-
(define (worst_unit lll worst_so_far)
|
431 |
-
"(worst_unit lll worst_so_far)
|
432 |
-
Returns unit with worst score in list."
|
433 |
-
(cond
|
434 |
-
((null lll)
|
435 |
-
worst_so_far)
|
436 |
-
((< (car (cdr worst_so_far)) (car (cdr (car lll))))
|
437 |
-
(worst_unit (cdr lll) (car lll)))
|
438 |
-
(t
|
439 |
-
(worst_unit (cdr lll) worst_so_far))))
|
440 |
-
|
441 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
442 |
-
;;; Save the unit catalogue for use in the run-time index
|
443 |
-
|
444 |
-
(define (acost:save_catalogue utterances clunits_params)
|
445 |
-
"(acost:save_catalogue utterances clunits_params)
|
446 |
-
Save the catalogue with named units with times."
|
447 |
-
(let ((fd (fopen
|
448 |
-
(string-append
|
449 |
-
(get_param 'db_dir clunits_params "./")
|
450 |
-
(get_param 'catalogue_dir clunits_params "trees/")
|
451 |
-
(get_param 'index_name clunits_params "catalogue.")
|
452 |
-
".catalogue")
|
453 |
-
"wb"))
|
454 |
-
(num_units 0)
|
455 |
-
)
|
456 |
-
(format fd "EST_File index\n")
|
457 |
-
(format fd "DataType ascii\n")
|
458 |
-
(format fd "NumEntries %d\n"
|
459 |
-
(apply
|
460 |
-
+ (mapcar (lambda (u)
|
461 |
-
(length (utt.relation.items u 'Segment))) utterances)))
|
462 |
-
(format fd "IndexName %s\n" (get_param 'index_name clunits_params "cluser"))
|
463 |
-
(format fd "EST_Header_End\n")
|
464 |
-
(mapcar
|
465 |
-
(lambda (u)
|
466 |
-
(mapcar
|
467 |
-
(lambda (s)
|
468 |
-
(format fd "%s_%s %s %f %f %f\n"
|
469 |
-
(item.feat s "clunit_name")
|
470 |
-
(item.feat s 'occurid)
|
471 |
-
(utt.feat u 'fileid)
|
472 |
-
(item.feat s 'segment_start)
|
473 |
-
(item.feat s 'segment_mid)
|
474 |
-
(item.feat s 'segment_end)))
|
475 |
-
(utt.relation.items u 'Segment)))
|
476 |
-
utterances)
|
477 |
-
(fclose fd)))
|
478 |
-
|
479 |
-
(provide 'clunits_build.scm)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/cmusphinx2_phones.scm
DELETED
@@ -1,119 +0,0 @@
|
|
1 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2 |
-
;;; ;;;
|
3 |
-
;;; Carnegie Mellon University ;;;
|
4 |
-
;;; and Alan W Black and Kevin Lenzo ;;;
|
5 |
-
;;; Copyright (c) 1998-2000 ;;;
|
6 |
-
;;; All Rights Reserved. ;;;
|
7 |
-
;;; ;;;
|
8 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;;
|
9 |
-
;;; this software and its documentation without restriction, including ;;;
|
10 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;;
|
11 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;;
|
12 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;;
|
13 |
-
;;; the following conditions: ;;;
|
14 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;;
|
15 |
-
;;; conditions and the following disclaimer. ;;;
|
16 |
-
;;; 2. Any modifications must be clearly marked as such. ;;;
|
17 |
-
;;; 3. Original authors' names are not deleted. ;;;
|
18 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;;
|
19 |
-
;;; derived from this software without specific prior written ;;;
|
20 |
-
;;; permission. ;;;
|
21 |
-
;;; ;;;
|
22 |
-
;;; CARNEGIE MELLON UNIVERSITY AND THE CONTRIBUTORS TO THIS WORK ;;;
|
23 |
-
;;; DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ;;;
|
24 |
-
;;; ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT ;;;
|
25 |
-
;;; SHALL CARNEGIE MELLON UNIVERSITY NOR THE CONTRIBUTORS BE LIABLE ;;;
|
26 |
-
;;; FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ;;;
|
27 |
-
;;; WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN ;;;
|
28 |
-
;;; AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ;;;
|
29 |
-
;;; ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF ;;;
|
30 |
-
;;; THIS SOFTWARE. ;;;
|
31 |
-
;;; ;;;
|
32 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
33 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
34 |
-
;;;
|
35 |
-
;;; A definition of the cmusphinx2 phone set used in the BU RADIO FM
|
36 |
-
;;; corpus, some people call this the darpa set. This one
|
37 |
-
;;; has the closures removed
|
38 |
-
;;;
|
39 |
-
|
40 |
-
(defPhoneSet
|
41 |
-
cmusphinx2
|
42 |
-
;;; Phone Features
|
43 |
-
(;; vowel or consonant
|
44 |
-
(vc + -)
|
45 |
-
;; vowel length: short long dipthong schwa
|
46 |
-
(vlng s l d a 0)
|
47 |
-
;; vowel height: high mid low
|
48 |
-
(vheight 1 2 3 0)
|
49 |
-
;; vowel frontness: front mid back
|
50 |
-
(vfront 1 2 3 0)
|
51 |
-
;; lip rounding
|
52 |
-
(vrnd + - 0)
|
53 |
-
;; consonant type: stop fricative affricate nasal lateral approximant
|
54 |
-
(ctype s f a n l r 0)
|
55 |
-
;; place of articulation: labial alveolar palatal labio-dental
|
56 |
-
;; dental velar glottal
|
57 |
-
(cplace l a p b d v g 0)
|
58 |
-
;; consonant voicing
|
59 |
-
(cvox + - 0)
|
60 |
-
)
|
61 |
-
;; Phone set members
|
62 |
-
(
|
63 |
-
|
64 |
-
;; Note these features were set by awb so they are wrong !!!
|
65 |
-
|
66 |
-
; phone vc vl vh vf vr ct cp cv
|
67 |
-
(AA + l 3 3 - 0 0 0) ;; father
|
68 |
-
(AE + s 3 1 - 0 0 0) ;; fat
|
69 |
-
(AH + s 2 2 - 0 0 0) ;; but
|
70 |
-
(AO + l 3 3 + 0 0 0) ;; lawn
|
71 |
-
(AW + d 3 2 - 0 0 0) ;; how
|
72 |
-
(AX + a 2 2 - 0 0 0) ;; about
|
73 |
-
(AXR + a 2 2 - r a +)
|
74 |
-
(AY + d 3 2 - 0 0 0) ;; hide
|
75 |
-
(B - 0 0 0 0 s l +)
|
76 |
-
(CH - 0 0 0 0 a p -)
|
77 |
-
(D - 0 0 0 0 s a +)
|
78 |
-
(DH - 0 0 0 0 f d +)
|
79 |
-
(DX - 0 0 0 0 s a +)
|
80 |
-
(EH + s 2 1 - 0 0 0) ;; get
|
81 |
-
(ER + a 2 2 - r 0 0)
|
82 |
-
(EY + d 2 1 - 0 0 0) ;; gate
|
83 |
-
(F - 0 0 0 0 f b -)
|
84 |
-
(G - 0 0 0 0 s v +)
|
85 |
-
(HH - 0 0 0 0 f g -)
|
86 |
-
(IH + s 1 1 - 0 0 0) ;; bit
|
87 |
-
(IY + l 1 1 - 0 0 0) ;; beet
|
88 |
-
(JH - 0 0 0 0 a p +)
|
89 |
-
(K - 0 0 0 0 s v -)
|
90 |
-
(L - 0 0 0 0 l a +)
|
91 |
-
(M - 0 0 0 0 n l +)
|
92 |
-
(N - 0 0 0 0 n a +)
|
93 |
-
(NG - 0 0 0 0 n v +)
|
94 |
-
(OW + d 2 3 + 0 0 0) ;; lone
|
95 |
-
(OY + d 2 3 + 0 0 0) ;; toy
|
96 |
-
(P - 0 0 0 0 s l -)
|
97 |
-
(R - 0 0 0 0 r a +)
|
98 |
-
(S - 0 0 0 0 f a -)
|
99 |
-
(SH - 0 0 0 0 f p -)
|
100 |
-
(T - 0 0 0 0 s a -)
|
101 |
-
(TH - 0 0 0 0 f d -)
|
102 |
-
(UH + s 1 3 + 0 0 0) ;; full
|
103 |
-
(UW + l 1 3 + 0 0 0) ;; fool
|
104 |
-
(V - 0 0 0 0 f b +)
|
105 |
-
(W - 0 0 0 0 r l +)
|
106 |
-
(Y - 0 0 0 0 r p +)
|
107 |
-
(Z - 0 0 0 0 f a +)
|
108 |
-
(ZH - 0 0 0 0 f p +)
|
109 |
-
(SIL - 0 0 0 0 0 0 -) ; added
|
110 |
-
)
|
111 |
-
)
|
112 |
-
|
113 |
-
(PhoneSet.silences '(SIL))
|
114 |
-
|
115 |
-
(provide 'cmusphinx2_phones)
|
116 |
-
|
117 |
-
|
118 |
-
|
119 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/cslush.scm
DELETED
@@ -1,79 +0,0 @@
|
|
1 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2 |
-
;;; ;;
|
3 |
-
;;; Centre for Speech Technology Research ;;
|
4 |
-
;;; University of Edinburgh, UK ;;
|
5 |
-
;;; Copyright (c) 1996,1997 ;;
|
6 |
-
;;; All Rights Reserved. ;;
|
7 |
-
;;; ;;
|
8 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;
|
9 |
-
;;; this software and its documentation without restriction, including ;;
|
10 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;
|
11 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;
|
12 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;
|
13 |
-
;;; the following conditions: ;;
|
14 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;
|
15 |
-
;;; conditions and the following disclaimer. ;;
|
16 |
-
;;; 2. Any modifications must be clearly marked as such. ;;
|
17 |
-
;;; 3. Original authors' names are not deleted. ;;
|
18 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;
|
19 |
-
;;; derived from this software without specific prior written ;;
|
20 |
-
;;; permission. ;;
|
21 |
-
;;; ;;
|
22 |
-
;;; THE UNIVERSITY OF EDINBURGH AND THE CONTRIBUTORS TO THIS WORK ;;
|
23 |
-
;;; DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ;;
|
24 |
-
;;; ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT ;;
|
25 |
-
;;; SHALL THE UNIVERSITY OF EDINBURGH NOR THE CONTRIBUTORS BE LIABLE ;;
|
26 |
-
;;; FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ;;
|
27 |
-
;;; WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN ;;
|
28 |
-
;;; AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ;;
|
29 |
-
;;; ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF ;;
|
30 |
-
;;; THIS SOFTWARE. ;;
|
31 |
-
;;; ;;
|
32 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
33 |
-
;;;
|
34 |
-
;;; Functions specific to using Festival in cslush part of the OGI toolkit
|
35 |
-
;;; The OGI toolkit is a complete dialog building system with speech
|
36 |
-
;;; recognition and synthesis (Festival) it is available for free for
|
37 |
-
;;; research purposes from
|
38 |
-
;;; http://www.cse.ogi.edu/CSLU/toolkit/toolkit.html
|
39 |
-
;;;
|
40 |
-
;;; Note this cslush interface requires you to compile festival
|
41 |
-
;;; with tcl (7.6)
|
42 |
-
;;;
|
43 |
-
;;; The functions replace the C++ level functions Jacques H. de Villiers
|
44 |
-
;;; <[email protected]> from CSLU wrote for the previous version
|
45 |
-
;;;
|
46 |
-
|
47 |
-
(if (not (member 'tcl *modules*))
|
48 |
-
(error "cslush: can't load cslush, TCL not supported in this installation of Festival."))
|
49 |
-
|
50 |
-
(define (cslush.getwave utt)
|
51 |
-
"(cslush.getwave UTT)
|
52 |
-
Extract wave memory info, pass this to wave import in CSLUsh."
|
53 |
-
(format nil "%s %s %s"
|
54 |
-
(utt.wave.info utt 'data_addr)
|
55 |
-
(utt.wave.info utt 'num_samples)
|
56 |
-
(utt.wave.info utt 'sample_rate)))
|
57 |
-
|
58 |
-
(define (cslush.getphone utt)
|
59 |
-
"(cslush.getphone UTT)
|
60 |
-
Return segment names a single string of phones, for use to pass to
|
61 |
-
TCL."
|
62 |
-
(let ((phones ""))
|
63 |
-
(mapcar
|
64 |
-
(lambda (s)
|
65 |
-
(if (string-equal phones "")
|
66 |
-
(set! phones (format nil "%s" (utt.streamitem.feat utt s 'name)))
|
67 |
-
(set! phones (format nil "%s %s"
|
68 |
-
phones (utt.streamitem.feat utt s 'name)))))
|
69 |
-
(utt.stream utt 'Segment))
|
70 |
-
phones))
|
71 |
-
|
72 |
-
(define (cslush TCLCOMMAND)
|
73 |
-
"(cslush TCLCOMMAND)
|
74 |
-
Pass TCLCOMMAND to TCL interpreter, returns what TCL returns as a
|
75 |
-
string."
|
76 |
-
(tcl_eval TCLCOMMAND))
|
77 |
-
|
78 |
-
|
79 |
-
(provide 'cslush)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/cstr.scm
DELETED
@@ -1,121 +0,0 @@
|
|
1 |
-
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
6 |
-
;;; DO NOT EDIT THIS FILE ON PAIN OF MORE PAIN.
|
7 |
-
;;;
|
8 |
-
;;; The master copy of this file is in ../../speech_tools/lib/siod/cstr.scm
|
9 |
-
;;; and is copied here at build time.
|
10 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
24 |
-
;;; ;;
|
25 |
-
;;; Centre for Speech Technology Research ;;
|
26 |
-
;;; University of Edinburgh, UK ;;
|
27 |
-
;;; Copyright (c) 1996,1997 ;;
|
28 |
-
;;; All Rights Reserved. ;;
|
29 |
-
;;; ;;
|
30 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;
|
31 |
-
;;; this software and its documentation without restriction, including ;;
|
32 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;
|
33 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;
|
34 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;
|
35 |
-
;;; the following conditions: ;;
|
36 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;
|
37 |
-
;;; conditions and the following disclaimer. ;;
|
38 |
-
;;; 2. Any modifications must be clearly marked as such. ;;
|
39 |
-
;;; 3. Original authors' names are not deleted. ;;
|
40 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;
|
41 |
-
;;; derived from this software without specific prior written ;;
|
42 |
-
;;; permission. ;;
|
43 |
-
;;; ;;
|
44 |
-
;;; THE UNIVERSITY OF EDINBURGH AND THE CONTRIBUTORS TO THIS WORK ;;
|
45 |
-
;;; DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ;;
|
46 |
-
;;; ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT ;;
|
47 |
-
;;; SHALL THE UNIVERSITY OF EDINBURGH NOR THE CONTRIBUTORS BE LIABLE ;;
|
48 |
-
;;; FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ;;
|
49 |
-
;;; WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN ;;
|
50 |
-
;;; AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ;;
|
51 |
-
;;; ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF ;;
|
52 |
-
;;; THIS SOFTWARE. ;;
|
53 |
-
;;; ;;
|
54 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
55 |
-
;;;
|
56 |
-
;;; CSTR siod extensions.
|
57 |
-
|
58 |
-
;(defvar Parameter nil
|
59 |
-
; "Parameter
|
60 |
-
; An assoc-list of parameters and values for various parts of the speech
|
61 |
-
; synthesis system. This is used by the functions Parameter.set
|
62 |
-
; Parameter.def and Parameter.get as well as internal C++ functions.")
|
63 |
-
|
64 |
-
(defvar Param (feats.make)
|
65 |
-
"Param
|
66 |
-
A feature set for arbitrary parameters for modules.")
|
67 |
-
|
68 |
-
(define (Param.set name val)
|
69 |
-
"(Param.set NAME VAL)
|
70 |
-
Set parameter NAME to VAL (deleting any previous setting)"
|
71 |
-
(feats.set Param name val))
|
72 |
-
|
73 |
-
(define (Parameter.set name val)
|
74 |
-
"(Parameter.set NAME VAL)
|
75 |
-
Set parameter NAME to VAL (deleting any previous setting). This is
|
76 |
-
an old function and you should use Param.set instead."
|
77 |
-
(Param.set name val)
|
78 |
-
val
|
79 |
-
)
|
80 |
-
|
81 |
-
(define (Parameter.def name val)
|
82 |
-
"(Parameter.def NAME VAL)
|
83 |
-
Set parameter NAME to VAL if not already set. This is an OLD function
|
84 |
-
you shold use Param.def instead."
|
85 |
-
(Param.def name val)
|
86 |
-
)
|
87 |
-
|
88 |
-
(define (Param.def name val)
|
89 |
-
"(Param.def NAME VAL)
|
90 |
-
Set parameter NAME to VAL if not already set"
|
91 |
-
(if (not (feats.present Param name))
|
92 |
-
(feats.set Param name val)))
|
93 |
-
|
94 |
-
(define (Parameter.get name)
|
95 |
-
"(Parameter.get NAME)
|
96 |
-
Get parameter NAME's value (nil if unset). This is an OLD function
|
97 |
-
and may not exist in later versions (or change functionality). This
|
98 |
-
function (unlike Param.get) may return sylbols (rather than strings
|
99 |
-
if the val doesn't contain whitespace (to allow older functions to
|
100 |
-
still work."
|
101 |
-
(let ((val (Param.get name)))
|
102 |
-
(if (and (eq? 'string (typeof val))
|
103 |
-
(not (string-matches val ".*[ \t\r\n].*")))
|
104 |
-
(intern val)
|
105 |
-
val))
|
106 |
-
)
|
107 |
-
|
108 |
-
(define (Param.get name)
|
109 |
-
"(Param.get NAME)
|
110 |
-
Get parameter NAME's value (nil if unset)"
|
111 |
-
(feats.get Param name))
|
112 |
-
|
113 |
-
(define (get_param name params default)
|
114 |
-
"(get_param name params default)
|
115 |
-
Get named parameters in params returning default if its not present."
|
116 |
-
(let ((pair (assoc name params)))
|
117 |
-
(if pair
|
118 |
-
(car (cdr pair))
|
119 |
-
default)))
|
120 |
-
|
121 |
-
(provide 'cstr)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/darpa_phones.scm
DELETED
@@ -1,115 +0,0 @@
|
|
1 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2 |
-
;;; ;;
|
3 |
-
;;; Centre for Speech Technology Research ;;
|
4 |
-
;;; University of Edinburgh, UK ;;
|
5 |
-
;;; Copyright (c) 1999 ;;
|
6 |
-
;;; All Rights Reserved. ;;
|
7 |
-
;;; ;;
|
8 |
-
;;; Permission is hereby granted, free of charge, to use and distribute ;;
|
9 |
-
;;; this software and its documentation without restriction, including ;;
|
10 |
-
;;; without limitation the rights to use, copy, modify, merge, publish, ;;
|
11 |
-
;;; distribute, sublicense, and/or sell copies of this work, and to ;;
|
12 |
-
;;; permit persons to whom this work is furnished to do so, subject to ;;
|
13 |
-
;;; the following conditions: ;;
|
14 |
-
;;; 1. The code must retain the above copyright notice, this list of ;;
|
15 |
-
;;; conditions and the following disclaimer. ;;
|
16 |
-
;;; 2. Any modifications must be clearly marked as such. ;;
|
17 |
-
;;; 3. Original authors' names are not deleted. ;;
|
18 |
-
;;; 4. The authors' names are not used to endorse or promote products ;;
|
19 |
-
;;; derived from this software without specific prior written ;;
|
20 |
-
;;; permission. ;;
|
21 |
-
;;; ;;
|
22 |
-
;;; THE UNIVERSITY OF EDINBURGH AND THE CONTRIBUTORS TO THIS WORK ;;
|
23 |
-
;;; DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ;;
|
24 |
-
;;; ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT ;;
|
25 |
-
;;; SHALL THE UNIVERSITY OF EDINBURGH NOR THE CONTRIBUTORS BE LIABLE ;;
|
26 |
-
;;; FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES ;;
|
27 |
-
;;; WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN ;;
|
28 |
-
;;; AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ;;
|
29 |
-
;;; ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF ;;
|
30 |
-
;;; THIS SOFTWARE. ;;
|
31 |
-
;;; ;;
|
32 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
33 |
-
;;; Author: Alan W Black
|
34 |
-
;;; Date: April 1999
|
35 |
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
36 |
-
;;;
|
37 |
-
;;; (yet another) darpa definition
|
38 |
-
;;;
|
39 |
-
|
40 |
-
(require 'phoneset)
|
41 |
-
|
42 |
-
(set! darpa_fs (cadr
|
43 |
-
(defPhoneSet
|
44 |
-
darpa
|
45 |
-
(Features
|
46 |
-
(vowel (syllabic + -)
|
47 |
-
(length long short diphthong schwa)
|
48 |
-
(height high mid low)
|
49 |
-
(front front mid back)
|
50 |
-
(round + -))
|
51 |
-
(consonant
|
52 |
-
(syllabic + -)
|
53 |
-
(manner stop affricate fricative approximant nasal)
|
54 |
-
(place alveolar dental labial palatal velar)
|
55 |
-
(voicing + -))
|
56 |
-
(silence
|
57 |
-
(syllabic -)))
|
58 |
-
(Phones
|
59 |
-
;; type syl length height front round
|
60 |
-
(aa vowel + long low back -)
|
61 |
-
(ae vowel + short low front -)
|
62 |
-
(ah vowel + short mid mid -)
|
63 |
-
(ao vowel + long low front +)
|
64 |
-
(aw vowel + diphthong low mid -)
|
65 |
-
(ax vowel + schwa mid mid -)
|
66 |
-
(axr vowel + schwa mid mid -)
|
67 |
-
(ay vowel + diphthong low mid -)
|
68 |
-
(eh vowel + short mid front -)
|
69 |
-
(ey vowel + diphthong mid front -)
|
70 |
-
(ih vowel + short high front -)
|
71 |
-
(iy vowel + long high front -)
|
72 |
-
(ow vowel + diphthong mid back +)
|
73 |
-
(oy vowel + diphthong mid back +)
|
74 |
-
(uh vowel + short high back +)
|
75 |
-
(uw vowel + long high back +)
|
76 |
-
;; type syl manner place voicing
|
77 |
-
(b consonant - stop labial +)
|
78 |
-
(ch consonant - affricate alveolar -)
|
79 |
-
(d consonant - stop alveolar +)
|
80 |
-
(dh consonant - fricative dental +)
|
81 |
-
(dx consonant - stop alveolar +)
|
82 |
-
(el consonant + approximant alveolar +)
|
83 |
-
(em consonant + nasal labial +)
|
84 |
-
(en consonant + stop alveolar +)
|
85 |
-
(er consonant + approximant alveolar +)
|
86 |
-
(f consonant - fricative labial -)
|
87 |
-
(g consonant - stop velar +)
|
88 |
-
(hh consonant - fricative velar -)
|
89 |
-
(jh consonant - affricate alveolar +)
|
90 |
-
(k consonant - stop velar -)
|
91 |
-
(l consonant - approximant alveolar +)
|
92 |
-
(m consonant - nasal labial +)
|
93 |
-
(n consonant - nasal alveolar +)
|
94 |
-
(nx consonant - nasal alveolar +)
|
95 |
-
(ng consonant - nasal velar +)
|
96 |
-
(p consonant - stop labial -)
|
97 |
-
(r consonant - approximant alveolar +)
|
98 |
-
(s consonant - fricative alveolar -)
|
99 |
-
(sh consonant - fricative palatal -)
|
100 |
-
(t consonant - stop alveolar -)
|
101 |
-
(th consonant - fricative dental -)
|
102 |
-
(v consonant - fricative labial +)
|
103 |
-
(w consonant - approximant velar +)
|
104 |
-
(y consonant - approximant palatal +)
|
105 |
-
(z consonant - fricative alveolar +)
|
106 |
-
(zh consonant - fricative palatal +)
|
107 |
-
(pau silence -)
|
108 |
-
; (sil silence -)
|
109 |
-
))))
|
110 |
-
|
111 |
-
(provide 'darpa_phones)
|
112 |
-
|
113 |
-
|
114 |
-
|
115 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/dicts/cmu/COPYING
DELETED
@@ -1,35 +0,0 @@
|
|
1 |
-
|
2 |
-
This directory contains an American English Lexicon and letter to
|
3 |
-
sournd rules based on CMUDICT 0.4. This distribution falls under
|
4 |
-
the following copyright. CMUDICT falls under a simialr free licence
|
5 |
-
that has no commercial restrictions.
|
6 |
-
|
7 |
-
Centre for Speech Technology Research
|
8 |
-
University of Edinburgh, UK
|
9 |
-
Copyright (c) 1996,1997
|
10 |
-
All Rights Reserved.
|
11 |
-
|
12 |
-
Permission is hereby granted, free of charge, to use and distribute
|
13 |
-
this software and its documentation without restriction, including
|
14 |
-
without limitation the rights to use, copy, modify, merge, publish,
|
15 |
-
distribute, sublicense, and/or sell copies of this work, and to
|
16 |
-
permit persons to whom this work is furnished to do so, subject to
|
17 |
-
the following conditions:
|
18 |
-
1. The code must retain the above copyright notice, this list of
|
19 |
-
conditions and the following disclaimer.
|
20 |
-
2. Any modifications must be clearly marked as such.
|
21 |
-
3. Original authors' names are not deleted.
|
22 |
-
4. The authors' names are not used to endorse or promote products
|
23 |
-
derived from this software without specific prior written
|
24 |
-
permission.
|
25 |
-
|
26 |
-
THE UNIVERSITY OF EDINBURGH AND THE CONTRIBUTORS TO THIS WORK
|
27 |
-
DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
|
28 |
-
ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT
|
29 |
-
SHALL THE UNIVERSITY OF EDINBURGH NOR THE CONTRIBUTORS BE LIABLE
|
30 |
-
FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
31 |
-
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN
|
32 |
-
AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
|
33 |
-
ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
|
34 |
-
THIS SOFTWARE.
|
35 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/dicts/cmu/allowables.scm
DELETED
@@ -1,102 +0,0 @@
|
|
1 |
-
(require 'lts_build)
|
2 |
-
(set! allowables
|
3 |
-
'((a _epsilon_ aa aa1 aa0
|
4 |
-
ax ax1 ax0
|
5 |
-
eh eh1 eh0
|
6 |
-
ah ah1 ah0
|
7 |
-
ae ae1 ae0
|
8 |
-
ey ey1 ey0
|
9 |
-
ay ay1 ay0
|
10 |
-
er er1 er0
|
11 |
-
y-ax0 y-ah1 y-ah0
|
12 |
-
aw aw1 aw0
|
13 |
-
ao ao1 ao0
|
14 |
-
ih ih1 ih0
|
15 |
-
w-ax0 w-ah1 w-ah0
|
16 |
-
ow ow1 ow0
|
17 |
-
w-ey w-ey1 ey0
|
18 |
-
iy iy1 iy0)
|
19 |
-
(b _epsilon_ b p )
|
20 |
-
(c _epsilon_ k ch s sh t-s )
|
21 |
-
(d _epsilon_ d t jh)
|
22 |
-
(e _epsilon_ ih ih1 ih0
|
23 |
-
ax ax1 ax0
|
24 |
-
iy iy1 iy0
|
25 |
-
er er1 er0
|
26 |
-
ax ah1 ah0
|
27 |
-
eh eh1 eh0
|
28 |
-
ey ey1 ey0
|
29 |
-
uw uw1 uw0
|
30 |
-
ay ay1 ay0
|
31 |
-
ow ow1 ow0
|
32 |
-
y-uw y-uw1 y-uw0
|
33 |
-
oy oy1 oy0
|
34 |
-
aa aa1 aa0)
|
35 |
-
(f _epsilon_ f )
|
36 |
-
(g _epsilon_ g jh zh k f)
|
37 |
-
(h _epsilon_ hh )
|
38 |
-
(i _epsilon_ iy iy1 iy0
|
39 |
-
ax ax1 ax0
|
40 |
-
ih ih1 ih0
|
41 |
-
ah ah1 ah0
|
42 |
-
ax ah1 ah0
|
43 |
-
ay ay1 ay0
|
44 |
-
y
|
45 |
-
aa aa1 aa0
|
46 |
-
ae ae1 ae0
|
47 |
-
w-ax0 w-ah1 w-ah0
|
48 |
-
eh eh1 eh0
|
49 |
-
er er0 er1 )
|
50 |
-
(j _epsilon_ jh y hh zh)
|
51 |
-
(k _epsilon_ k )
|
52 |
-
(l _epsilon_ l ax-l y ax0-l)
|
53 |
-
(m _epsilon_ m ax-m m-ax0 ax0-m m-ax0
|
54 |
-
m-ae m-ae1 m-ae0
|
55 |
-
m-ih m-ih0 )
|
56 |
-
(n _epsilon_ n ng n-y)
|
57 |
-
(o _epsilon_ ax ax0 ah1 ah0
|
58 |
-
ao ao1 ao0
|
59 |
-
ow ow1 ow0
|
60 |
-
uw uw1 uw0
|
61 |
-
er er1 er0
|
62 |
-
aa aa1 aa0
|
63 |
-
aw aw1 aw0
|
64 |
-
oy oy1 oy0
|
65 |
-
uh uh1 uh0
|
66 |
-
w
|
67 |
-
w-ax0 w-ah1 w-ah0
|
68 |
-
aa aa1 aa0
|
69 |
-
ih ih1 ih0
|
70 |
-
ae ae1 ae0)
|
71 |
-
(p _epsilon_ p f)
|
72 |
-
(q _epsilon_ k )
|
73 |
-
(r _epsilon_ r er1 er er0 )
|
74 |
-
(s _epsilon_ s sh z zh ch)
|
75 |
-
(t _epsilon_ t th sh ch dh d s zh)
|
76 |
-
(u _epsilon_
|
77 |
-
ax ax0
|
78 |
-
ah ah1 ah0
|
79 |
-
uw uw1 uw0
|
80 |
-
er er1 er0
|
81 |
-
uh uh1 uh0
|
82 |
-
y-uw y-uw1 y-uw0
|
83 |
-
ax-w ah1-w ah0-w
|
84 |
-
y-er y-er1 y-er0
|
85 |
-
y-ax y-ax0 y-ah1 y-ah0
|
86 |
-
w
|
87 |
-
ih ih1 ih0
|
88 |
-
ao ao1 ao0
|
89 |
-
eh eh1 eh0
|
90 |
-
y-uh y-uh1 y-uh0 )
|
91 |
-
(v _epsilon_ v f)
|
92 |
-
(w _epsilon_ w v f)
|
93 |
-
(x _epsilon_ k-s g-z ng-z k-sh z g-zh zh)
|
94 |
-
(y _epsilon_
|
95 |
-
iy iy1 iy0
|
96 |
-
ih ih1 ih0
|
97 |
-
ay ay1 ay0
|
98 |
-
y
|
99 |
-
ax ax0 ah1 ah0)
|
100 |
-
(z _epsilon_ z t-s zh s)
|
101 |
-
(# #)))
|
102 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
orig_model/resource/festival/dicts/cmu/cmu2ft
DELETED
@@ -1,21 +0,0 @@
|
|
1 |
-
#!/bin/sh
|
2 |
-
#
|
3 |
-
# Converts cmulexicon to Festival format
|
4 |
-
#
|
5 |
-
# usage: cmu2ft cmudict.0.1 cmu_lex.scm
|
6 |
-
|
7 |
-
#sed 's/er0/er0 r/' | sed 's/er1/er1 r/' | sed 's/er2/er2 r/' |
|
8 |
-
|
9 |
-
echo >$2
|
10 |
-
echo ";; CMUDICT-0.4 Converted to Festival lexicon format" >>$2
|
11 |
-
cat $1 | tr "[A-Z]" "[a-z]" | sed 's/ah0/ax/g' |
|
12 |
-
tr 2 1 |
|
13 |
-
awk '{if ($1 == "##")
|
14 |
-
printf(";; %s\n",$0);
|
15 |
-
else if ($1 ~ /^[a-z][a-z]*$/)
|
16 |
-
{ printf("(")
|
17 |
-
printf("\"%s\" nil (%s",$1,$2)
|
18 |
-
for (i=3; i <= NF; i++)
|
19 |
-
printf " %s",$i
|
20 |
-
printf "))\n"
|
21 |
-
}} ' >> $2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|