summaryrefslogtreecommitdiff
path: root/speech_utils
diff options
context:
space:
mode:
authorDeterminant <[email protected]>2015-08-26 14:25:56 +0800
committerDeterminant <[email protected]>2015-08-26 14:25:56 +0800
commit6495879e76dc0a2efe7b214b58d1d73a4ed3a931 (patch)
tree5ebabd090381b571615a9c7bc1d1e6eb43654a25 /speech_utils
parentdf4545867c32ff1b8e48317c04ea39503dbe0767 (diff)
remove global_transf in IO modules; see asr_trainer.lua
Diffstat (limited to 'speech_utils')
-rw-r--r--speech_utils/init.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/speech_utils/init.lua b/speech_utils/init.lua
index a2d1dc9..7d5651f 100644
--- a/speech_utils/init.lua
+++ b/speech_utils/init.lua
@@ -3,7 +3,7 @@ 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)
+-- 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
@@ -26,8 +26,8 @@ function nerv.speech_utils.global_transf(feat_utter, global_transf,
global_transf:init(input[1]:nrow())
global_transf:propagate(input, output)
-- trim frames
- expanded = gconf.mmat_type(output[1]:nrow() - frm_trim * 2, output[1]:ncol())
- output[1]:copy_toh(expanded, frm_trim, feat_utter:nrow() - frm_trim)
+ expanded = gconf.cumat_type(output[1]:nrow() - frm_trim * 2, output[1]:ncol())
+ expanded:copy_fromd(output[1], frm_trim, feat_utter:nrow() - frm_trim)
collectgarbage("collect")
return expanded
end