summaryrefslogtreecommitdiff
path: root/speech_utils
diff options
context:
space:
mode:
authorDeterminant <[email protected]>2015-08-14 11:51:42 +0800
committerDeterminant <[email protected]>2015-08-14 11:51:42 +0800
commit96a32415ab43377cf1575bd3f4f2980f58028209 (patch)
tree30a2d92d73e8f40ac87b79f6f56e227bfc4eea6e /speech_utils
parentc177a7549bd90670af4b29fa813ddea32cfe0f78 (diff)
add implementation for kaldi io (by ymz)
Diffstat (limited to 'speech_utils')
-rw-r--r--speech_utils/init.lua8
1 files changed, 6 insertions, 2 deletions
diff --git a/speech_utils/init.lua b/speech_utils/init.lua
index 9690e71..3500eb4 100644
--- a/speech_utils/init.lua
+++ b/speech_utils/init.lua
@@ -10,8 +10,12 @@ function nerv.speech_utils.global_transf(feat_utter, global_transf,
local expanded = gconf.cumat_type(feat_utter:nrow(), feat_utter:ncol() * step)
expanded:expand_frm(feat_utter, frm_ext)
-- rearrange the feature (``transpose'' operation in TNet)
- rearranged = expanded:create()
- rearranged:rearrange_frm(expanded, step)
+ if gconf.rearrange then
+ rearranged = expanded:create()
+ rearranged:rearrange_frm(expanded, step)
+ else
+ rearranged = expanded
+ end
else
rearranged = feat_utter
end