1 # Test Initial Recognition
4 word test_dir ../../test
5 word testreference_dir ../wordlists/CoGMandarinSounds
10 Create Strings as file list... TestList 'test_dir$'/*.wav
11 numberOfTestReferences = Get number of strings
13 for j from 1 to numberOfTestReferences
14 select Strings TestList
15 testFile$ = Get string... 'j'
17 pinyin$ = replace_regex$(testFile$, "^([a-z]+[0-9]+)[0-9a-zA-Z_\-\.]*$", "\1", 0)
19 execute InitialRecognition.praat 'pinyin$' 'test_dir$'/'testFile$' 'testreference_dir$'
21 result$ < lastInitialRecognitionResult.txt
22 printline 'pinyin$': 'result$'
25 select Strings TestList