diff options
author | Determinant <[email protected]> | 2016-05-08 11:40:13 +0800 |
---|---|---|
committer | Determinant <[email protected]> | 2016-05-08 11:40:13 +0800 |
commit | 3101d1f9c1b2e31fbde75c1c9de5f6872340f5f7 (patch) | |
tree | 2f6bcf926ab3ebdedb5e4920a884ac5031e698b7 /kaldi_io/init.lua | |
parent | 2da71705cab5a583c642441f8321ddbaf0c7cb42 (diff) |
change decoder API (adapted to `trainer.lua`); remove redundant options in kaldi_io
Diffstat (limited to 'kaldi_io/init.lua')
-rw-r--r-- | kaldi_io/init.lua | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/kaldi_io/init.lua b/kaldi_io/init.lua index bec2589..5325630 100644 --- a/kaldi_io/init.lua +++ b/kaldi_io/init.lua @@ -21,16 +21,18 @@ function KaldiReader:__init(global_conf, reader_conf) self.lab_repo = {} if reader_conf.mlfs then for id, mlf_spec in pairs(reader_conf.mlfs) do - if mlf_spec.format == nil then - nerv.error("format spec is expected for label %s", id) + if mlf_spec.targets_rspecifier == nil then + nerv.error("target spec is expected for label %s", id) end - self.lab_repo[id] = nerv.KaldiLabelRepo(mlf_spec.targets_rspecifier, - mlf_spec.format) + self.lab_repo[id] = nerv.KaldiLabelRepo(mlf_spec.targets_rspecifier) end end self.lookup_repo = {} if reader_conf.lookup then for id, lookup_spec in pairs(reader_conf.lookup) do + if lookup_spec.targets_rspecifier == nil then + nerv.error("target spec is expected for label %s", id) + end if lookup_spec.map_rspecifier == nil then nerv.error("map spec is expected for lookup %s", id) end |