diff options
Diffstat (limited to 'htk_io/init.lua')
-rw-r--r-- | htk_io/init.lua | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/htk_io/init.lua b/htk_io/init.lua index abaa794..b360b67 100644 --- a/htk_io/init.lua +++ b/htk_io/init.lua @@ -14,12 +14,14 @@ function TNetReader:__init(global_conf, reader_conf) reader_conf.conf_file, reader_conf.frm_ext) self.lab_repo = {} - for id, mlf_spec in pairs(reader_conf.mlfs) do - self.lab_repo[id] = nerv.TNetLabelRepo(mlf_spec.file, - mlf_spec.format, - mlf_spec.format_arg, - mlf_spec.dir, - mlf_spec.ext) + if reader_conf.mlfs then + for id, mlf_spec in pairs(reader_conf.mlfs) do + self.lab_repo[id] = nerv.TNetLabelRepo(mlf_spec.file, + mlf_spec.format, + mlf_spec.format_arg, + mlf_spec.dir, + mlf_spec.ext) + end end end |