summaryrefslogtreecommitdiff
path: root/speech_utils
diff options
context:
space:
mode:
authorYimmon Zhuang <[email protected]>2015-08-27 13:24:12 +0800
committerYimmon Zhuang <[email protected]>2015-08-27 13:24:12 +0800
commit77084d50207b6078460e83fe6f069967a6e11ccc (patch)
treec7e64fe9669c29825d47ed5b745c559d38090878 /speech_utils
parent76d64a91f72a19221e7ff9461860b214cbff216f (diff)
parentb50ec827c6fd7d95375e627a1bedd1236ef02e8c (diff)
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'speech_utils')
-rw-r--r--speech_utils/init.lua21
1 files changed, 2 insertions, 19 deletions
diff --git a/speech_utils/init.lua b/speech_utils/init.lua
index 7d5651f..f89f4fd 100644
--- a/speech_utils/init.lua
+++ b/speech_utils/init.lua
@@ -2,26 +2,9 @@ nerv.speech_utils = {}
function nerv.speech_utils.global_transf(feat_utter, global_transf,
frm_ext, frm_trim, gconf)
- local rearranged
--- feat_utter = gconf.cumat_type.new_from_host(feat_utter)
- if frm_ext ~= nil and frm_ext > 0 then
- local step = frm_ext * 2 + 1
- -- expand the feature
- 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)
- if gconf.rearrange then
- rearranged = expanded:create()
- rearranged:rearrange_frm(expanded, step)
- else
- rearranged = expanded
- end
- else
- rearranged = feat_utter
- end
-- prepare for transf
- local input = {rearranged}
- local output = {rearranged:create()}
+ local input = {feat_utter}
+ local output = {feat_utter:create()}
-- do transf
global_transf:init(input[1]:nrow())
global_transf:propagate(input, output)