Adding Looping method to existing Praat Scripts

There are many great praat scripts out there (here’s my collection).

Mietta’s Praat scripts (http://www.helsinki.fi/~lennes/praat-scripts/ ), for example, are particularly useful for doing various things with praat.

However, one problem I’m constantly facing is that Mietta’s scripts usually work with 1 sound file at a time. I have to import sound files one by one, and then run the scripts. For example, if you want to cut a long sound file into several pieces, you have to import the sound file and the corresponding textgrid file to praat, and then run the script. Only after that, you can start cutting a second sound file. It was fine when there are only a couple of sound files. But now I am working on hundreds of files (827 to be precise). That means, I have to import sound files 827 times, and run the script 827 times. It is time-consuming.

I therefore added some codes to Mietta’s save_intervals_to_wav_sound_files.praat, so that the script will automatically look for all the sound files and their corresponding textgrids in one folder, and cut them.

Here’s the original script:http://www.helsinki.fi/~lennes/praat-scripts/public/save_intervals_to_wav_sound_files.praat

Here’s the edited one:
https://github.com/lokigao/praatScripts/blob/master/Loop_save_labeled_intervals_to_wav_sound_files.praat

My Posts on Nantong Chinese

Here are my posts about my native language: Nantong Chinese.

Nantong Chinese is just a side-project of mine, and the articles I wrote are less than academic. However, they could be the first step toward more rigorous academic inquires. Although I wrote the following posts purely for fun, I did provide references whenever other people’s views were used.  The Language Attitude Survey was done with my collaborators in China.

Please let me know if you have any suggestions. Thank you!

Note: the following posts are also on the Nantong Dialect Web (南通方言网).

Linguistics

  1. Why do Nantong People Prefer “Eating” Tea?
  2. The Speech Act of Sentence-Final Particles in Imperative Mood.
  3. The Relationship between Tone Shape and Tone Length in Nantong Chinese.
  4. The Tone Shape of Nantong Chinese–an SSANOVA Analysis
  5. Bibliographies of Nantong Chinese Research 

Language Attitude Survey

  1. Who is still speaking Nantong Chinese (Report 1)
  2. How frequent is Nantong Chinese used in everyday life (Report 2) 
  3. The general public’s attitude toward Nantong Chinese (Report 3)

南通人为什么管“喝茶”叫“吃茶”?

note: I’ve been writing short articles for a website called 南通方言网 (Nantong Dialect Web). The following is one of them. Since the target audience is Chinese speakers, I wrote all the articles in Chinese. I am re-posting them here just to keep a record. For my fellow Nantong people out there, please let me know what you think. Thank you!

This page shows you all my posts about nantong Chinese

南通人喜用一个“吃”字。喝茶叫吃茶,抽烟叫吃烟。不管是固体、液体,还是气体,凡是能放到嘴里吞下去的,都可以用一个“吃”字。

网上曾有人讲,“吃茶”、“吃烟”体现了南通人的豪爽。也有人说,人喝茶的时候难免会把茶叶喝进嘴里,很多人习惯把茶叶嚼嚼吃下去,而不是吐掉,故而有了吃茶一说。这两种说法正确与否,我们不知道。但是“吃茶、吃烟”这种说法不是南通的特例。从东北到浙江到广东,从江苏到云南到四川,都有人管“喝茶”叫“吃茶”。细想来,“吃茶”其实是一个更广泛的用法,“喝茶”确是普通话的“创新”。

这个“吃”字,在古汉语里是口吃、结巴的意思。表示进食的那个字写作“喫”(chī)。汉字简化以后,“喫”和“吃”合并成了一个字。

汉代许慎的《说文解字》中,“喫”字是吃东西的意思(食也)。唐代杜甫有诗曰“對酒不能喫”(《送李校書詩》),可见“喫”在唐代就有了“饮用”的意思,“喝酒”就可以说成“喫酒”。明初的《洪武正韵》中,“喫”就解释为“饮”的意思。(我们在下文中仍然用简化字,下文中的“吃”字是“喫”的意思,表示食用)。

说到“吃茶”不能不提赵州禅师从谂的一段公案。赵州从谂禅师(778年-897年),俗姓郝,唐代著名高僧。曾有两位僧人从远方来到赵州,向赵州禅师请教如何是禅。赵州禅师问其中的一个,“你以前来过吗?”那个人回答:“没有来过。”赵州禅师说:“吃茶去!” 赵州禅师转向另一个僧人,问:“你来过吗?”这个僧人说:“我曾经来过。”赵州禅师说:“吃茶去!”这时,引领那两个僧人到赵州禅师身边来的监院就好奇地问:“禅师,怎么来过的你让他吃茶去,未曾来过的你也让他吃茶去呢?” 赵州禅师称呼了监院的名字,监院答应了一声,赵州禅师说:“吃茶去!” (《五灯会元》卷四

赵州禅师的一个“吃茶去”体现了佛家的淡泊,禅机无限,我们恐难完全体会。但是从他用的这个“吃“字,我们可以知道 南通话里的“吃茶”一词不是南通人的独创,而是古代汉语的孑遗。

至于说,为什么现代汉语普通话里要说“喝茶”,而不说“吃茶”,这就涉及到“喝”这个字的语义演变了。“喝”这个字在古代是叫喊的意思,比如“大声断喝”,并无“饮用”的意思。到底是什么时候“喝”有了“饮用”的意思,我们下次再谈。

吃茶

南通话祈使句句末语气助词—助词的言语行为

南通话用在祈使句末尾的语气有如下几个
1. sa, 例:你吃sa
2. sei 例:你吃sei
3. bau 例:你吃bau

这个几个语气助词有不同的言语行为(speech act), 表示不同的意思。我提出一点感性的认识,请大家指正。
1. “sa” 表示命令而不是请求。
2. “sei” 表示请求而不是命令。
我举例说明。
a)你帮帮我的忙sa
b)你帮帮我的忙sei
a)句是命令的口吻,说话者可能都不耐烦了。
b)句是一个探讨请求的口吻。请人帮忙,用sei 显得比较恰当。”你帮帮我的忙sei” 表示了请求。而“你帮帮我的忙sa” 就带有了命令的口吻,仿佛别人欠你的,应该帮你的忙。

3. ”bau” 是表示建议,建议某人做某事。“你过来bau” 表示的是建议别人过来,而不是请求或命令别人过来。

====验证方法

我想我们是不是可以通过加入词的方式来辨别助词的语用 ( 下文 *号 标注的句子与我个人的语感不合)
1. 表建议,加“建议”
a) * 我建议你还是来sa
b) * 我建议你还是来sei
c) 我建议你还是来bau
这里只有1c) 读起来顺,其他两个都不顺。说明建议的语气和 bau最契合。

2. 表催促,加“怎么天天都要我催你的sei.”
a) 起来sa!怎么天天早上都要我催你的sei.
b) ?起来sei 怎么天天早上都要我催你的sei.
c) *起来bau!怎么天天早上都要我催你的sei.
我个人语感上,a) 句可说,c) 句不可说,b) 句我不肯定(我倾向于可以说)。
命令的口吻可以通过语调来体现,不用语气助词也可以。但命令的口吻似乎无法与sei 和 bau 共存,
d) 起来sa! 我命令你!
e) *起来sei ! 我命令你!
f) *起来bau ! 我命令你!

3. 表请求,加“求求”
a) *我求求你登点儿来sa
b) 我求求你登点儿来sei
c) 我求求你登点儿来bau
这三例可以说明 sa 跟 “请求” 的语气是矛盾的。 sei 和 bau 和 “请求”不矛盾。

由上9例我们可以看出 sei 和 bau, 正如你所说,都可以表示 请求(邀请),但bau可表建议,sei 不可以。bau 和 sei 似乎不能与”命令“的语气共存。当然我这个“加词”的方法不一定对。

另外 sa 似乎还有另一个用法,
4. sa 表挑衅/激将(daring)

a) 你试试看sa! 我不拎起来弄你个巴掌!
b) *你试试看sei! 我不拎起来弄你个巴掌!
c) *你试试看bau! 我不拎起来弄你个巴掌!

4 中的例子跟整个句子的语调相关,而不仅仅是sa。问题是 sa 在这里可能不是表示催促。

南通话声调调型与调长

作者:高志晏

声调的调型(上升还是下降等)对音节的长短有一定影响。曲折调型一般比较长,下降调型一般比较短,比如普通话里的第三声就要比第四声长 (Tseng, 1990)。 另外,上升调一般比下降调要长,比如普通话里的第二声就比第四声长 (Yuan, 2012)。

南通话与普通话的一个区别是,南通话有入声调类。我们对入声调类的认识一般是入声音节都很短促,故而入声音节又叫促声韵。根据前人的研究,特别是敖小平先生的实验研究,南通话的入声不是一个平调,或者说南通话的入声调型是有上下波动的。具体说来,阴入是一个下降调,阳入是一个上升调。根据调型与调长的关系,我们可以预测南通话里的阴入要比阳入短。

为了具体研究南通话的调型与调长,我在上一篇文章的基础上作了进一步分析。在本次分析中,我采用了上篇文章里所录的语音。在取基频采样点的时候,我按时间为单位,每秒取100个点。比如,如果一个音节的长度是1秒钟,那么我就取100个点,如果一个音节的长度是500毫秒,那么我就取50个点。

下图为我根据采样点绘制的图。其中实线为平均值,宽带部分为上下1个标准差。

从上图,我们可以看出上升调(阳平)的确是要比下降调(阴去)要长一些。曲折调(阳去)总的来说要比其他调型都长。入声调要比舒声调短,但是上升的入声调(阳入)要比下降的入声调(阴入)长一些。这些现象都与前人关于普通话声调的相关研究完全一致。

为进一步调查调型对声调长短的影响,我做了一个简单的线性回归分析。以声调调类为自变量,以声调长短为因变量。结果显示:

1.阴平

阳平比阴去长 (p<0.01),阴平比两个入声都要长 (p<0.001)

3. 阳平

阳平比阴去长 (p<0.05),阳平比阳去短(p<0.05),阳平比两个入声都要长(p<0.001)

4. 阴上

阴上比阳去短(p<0.05), 阴上比两个入声都要长(p<0.001)

5. 阴去

阴去比阳去短(p<0.001),阴去比阴平、阳平都短。阴去比阴入长(p<0.05),但不一定比阳入长(p=0.059)

6. 阳去

阳去比阴去、阴上、阳平都要长,比两个入声也都要长(p<0.001)

7. 入声

阴入和阳入的长短区别不显著(p=0.663)

下方柱状图显示了南通话声调长短与调类的关系。其中误差条显示95%置信区间。

参考文献:

Tseng, C.-Y. (1990). An acoustic phonetic study on tones in Mandarin Chinese. Taipei, Taiwan: Institute of History and Philology Academia Science.

Yuan, Jiahong. 2012. The Effects of Speaking Rate and Intonation on the Duration of Tones in Mandarin Chinese. Proceedings of Speech Prosody. 22-25 May 2014. Shanghai, China.

Why Don’t We Speak Like Yoda?——Reflections on Gibson et al. (2013)

Note: I wrote this reflection for a class some time ago. Now I realized that the syntactic analysis in the following article is not correct.

Gibson, E., Piantadosi, S.T., Brink, K., Bergen, L., Lim, E., & Saxe, R. (2013). A noisy-channel account of crosslinguistic word-order variation. Psychological Science, 24, 1079-1088.

Gilbson et. al. (2013) reminds me of Master Yoda from the Star Wars universe, who has a preference for OSV structures. “Patience you must have.” “Your father he is, defeat him you must.” These are a few of Yoda’s masterpieces. Yoda’s speech sounds alien because the OSV structure is rarely used as a canonical word order in human languages. According to Tomlin (2014), less than 1% of the known human languages use OSV canonically. I emphasize “canonical” here because un-canonical usages of OSV are possible in many languages. The un-canonical usage of OSV in English always involves the intentional focus of the “O”. For example, I can emphasize the number of votes Trump received by saying “100 million votes, Trump got!” But this utterance is un-canonical and the object “100 million votes” has to be accented. From the perspective of the noisy-channel theory, OSV is equally inefficient as SOV, because the absence of either the noun phrase for O or the noun phrase for S will result in confusions about whether the noun phrase got left is a patient or an agent.

The problem at this point is why Gibson et. al. (2013)’s participants prefer SOV over OSV, given that both of the two structures are equally inefficient. Or, in the case of O being inanimate, OSV seems to be equally efficient as SOV. It is really puzzling as to why English-speaking participants in Gibson et. al. (2013) used SOV but not OSV. If Akhtar (2001)’s data-driven model is correct, then we would expect English-speaking adults to use OSV instead of SOV, because OSV, however un-canonical it is, actually exists in English, while SOV never occurs in English. Gibson et. al. (2013) stated at the beginning of the paper that SOV is somewhat a default word order in human languages, which is another way to say that SOV is part of the universal grammar. However, the notion of SOV being a default word order is probably against the general implication of the noisy-channel theory. As Shannon’s theory of communication requires efficiency, we would expect a default word order to be efficient if Shannon’s theory indeed applies in human communication. However, the SOV structure is apparently less efficient than the SVO structure for the reasons given on p.1080. Therefore, I think there are two problems with the data and arguments presented in Gibson et. al. (2013). (1) Since SOV and OSV are equally efficient (or inefficient), why do people prefer the former over the latter? (2) Since SOV is less efficient than SVO, why do people use SOV as the default?

The first question cannot be answered by either the noisy-channel theory or the data-driven model. The second question might be answered by taking into account the animacy of Os. Gibson et. al. (2013) show that SOV is preferred when the O is inanimate; while SVO is preferred when both S and O are animate. The claim is that an inanimate O in SOV will not cause confusion even if the S is missing, because inanimate objects cannot function as an agent. This argument is not necessarily accurate. Considering the following two sentences:

(a) The ball hit[agent] the goalkeeper[patient].    (b) The ball[agent] the goalkeeper[patient] hit.

“The ball” is inanimate, and yet it functions as agent in (a). (b) is the SOV version of (a). If either “the ball” or “the goalkeeper” is missing from (b), the intended meaning will be very hard to recover. However, if SVO is the default word order (i.e. example (a)), then the absence of “the ball” or “the goalkeeper” will not confuse people that much, because SVO tells us that whatever occurs on the left side of the verb is the S and whatever occurs on the right side of the verb is the O. In other words, SVO is much efficient than SOV even when O is inanimate. Choosing SOV as the default is in fact choosing inefficiency over efficiency, which is against the efficiency requirement of the noisy-channel theory.

Although the noisy-channel theory and the data-driven model cannot sufficiently account for the aforementioned two problems, the parameter setting theory is fully equipped to deal with these questions. I am adopting a simplified X-bar theory to show the solutions to problem 1 and problem 2. In the following syntactic trees, (3) shows the structure of SVO sentences, (4) shows the structure of SOV structures. V’ is the syntactic head of a verb phrase (VP).

(3) SVO structure

(4) SOV structure

    

The parameter setting of VPs requires that S occurs as a specifier of VP, which means S cannot occur in between V and O. In other words, OSV structure is highly problematic if not impossible. Yoda’s syntax is thus very alien. For SVO structures, the locations of syntactic heads are inconsistent. The head of VP is on the right, but the head of V’ is on the left. For SOV structures, the locations of syntactic heads are consistent. VP has its head on the right, and V’ has its head on the right too. Since (4) is syntactically more consistent than (3), the preference for (4) over (3) in fact reflects people’s bias for regularity. In conclusion, I appreciate the statistical learning paradigm and the application of information theory in language analysis, but the value of the parameter setting theory should not be categorically disregarded.

References

Tomlin, R. S. (2014). Basic Word Order (Reprint edition). Routledge.