精通
英语
和
开源
,
擅长
开发
与
培训
,
胸怀四海
第一信赖
I have been trying to run make_mfcc.sh on my data, but I encountered these errors (copied from the log):我一直在尝试对数据运行make_mfcc.sh,但是遇到了以下错误(从日志中复制):
compute-mfcc-feats --verbose=2 --config=conf/mfcc.conf scp,p:exp/make_mfcc/train/wav_train.9.scp ark:-
copy-feats --compress=true ark:- ark,scp:/Users/enzyme156/desktop/KALDI/data/mfcc/raw_mfcc_train.9.ark,/Users/enzyme156/desktop/KALDI/data/mfcc/raw_mfcc_train.9.scp
VLOG[2] (compute-mfcc-feats:main():compute-mfcc-feats.cc:178) Processed features for key utt_TuNTC1-1-45
VLOG[2] (compute-mfcc-feats:main():compute-mfcc-feats.cc:178) Processed features for key utt_TuNTC1-2-41
bash: line 1: 668 Broken pipe: 13 compute-mfcc-feats --verbose=2 --config=conf/mfcc.conf scp,p:exp/make_mfcc/train/wav_train.9.scp ark:-
672 Segmentation fault: 11 | copy-feats --compress=true ark:- ark,scp:/Users/enzyme156/desktop/KALDI/data/mfcc/raw_mfcc_train.9.ark,/Users/enzyme156/desktop/KALDI/data/mfcc/raw_mfcc_train.9.scp
There was a previous thread here on segmentation faults and I tried running make_mfcc with both gcc 4.7 and gcc 4.8, but they all returned the same error...之前有一个关于分段错误的线程,我尝试同时使用gcc 4.7和gcc 4.8运行make_mfcc,但是它们都返回了相同的错误...
Try running尝试运行
gdb --args compute-mfcc-feats --verbose=2 --config=conf/mfcc.conf
scp,p:exp/make_mfcc/train/wav_train.9.scp ark:/dev/nulland at the (gdb) prompt type "r" When it crashes, do "bt" and show us the backtrace.
Most likely the error can be fixed, though, by running "make clean" and "make". Probably it's due to you changing gcc version.
并在(gdb)提示符下键入“ r”,
当其崩溃时,执行“ bt”并向我们显示回溯。不过,很可能可以通过运行“ make clean”和
“ make” 来修复错误。可能是由于您更改了gcc版本。
I tried ./configure, make clean and make in /src with gcc 4.7, but I still got the same errors. Unfortunately gbd doesn't work well with Mavericks and I am trying to fix that so that I can give you an error log, but in the meantime do you have any other suggestions as to what the problem might be?我尝试了./configure,使用gcc 4.7 make clean和make重新编译了源代码,但是仍然出现相同的错误。不幸的是,gbd在Mavericks上无法很好地工作,我正在尝试解决该问题,以便为您提供错误日志,但是与此同时,您对问题可能有其他建议吗?
From http://ntraft.com/installing-gdb-on-os-x-mavericks/ it looks like gdb
is not expected to work well on OS X Mavericks. If you can figure out how
to use lldb and get a stack trace that way, then I may be able to help you.
But apparently if you use the MacPorts version of gdb it can work OK even
on Mavericks.
Likely the underlying problem will show up directly if you do "make test",
and giving us some information about which test program failed and what its
output was before it failed will be useful. By the output I mean the
stderr/stdout, which is not shown by "make test", you have to run the
failing test program directly from the command line.
从http://ntraft.com/installing-gdb-on-os-x-mavericks/看来,gdb似乎不能在OS X Mavericks上很好地工作。如果您能弄清楚如何
使用lldb并以这种方式获取堆栈跟踪,那么我也许可以为您提供帮助。
但是显然,如果您使用MacDB版本的gdb,即使在Mavericks上也可以正常工作。
如果您执行“进行测试”,则潜在的问题很可能会直接显示出来,
并向我们提供有关哪个测试程序失败以及
失败之前输出的信息将很有用。对于输出,我的意思是
stderr / stdout(未通过“ make test”显示),您必须直接从命令行运行失败的测试程序。
I managed to get gdb to work on Mavericks. After running the command you gave me and typing 'r', I got a bunch of lines reporting "processed features for utterance", and :
LOG (compute-mfcc-feats:main():compute-mfcc-feats.cc:181) Done 20 out of 20 utterances.
bt gives > No stack.
So it seems like the program isn't crashing anywhere. When I tried the extracting features command in the KALDI guide, though, crashes still occurred.
我设法让gdb在Mavericks上工作。运行您给我的命令并键入“ r”后,我得到了很多行,报告“处理话语特征”,以及:
日志(compute-mfcc-feats:main():compute-mfcc-feats.cc:181)在20声中完成20声。
bt给出>没有堆栈。
因此,似乎该程序没有在任何地方崩溃。但是,当我在KALDI指南中尝试提取功能命令时,仍然发生崩溃。
Running "make test" gives errors as follows:运行“ make test”会产生以下错误:
Running matrix-lib-test .../bin/sh: line 1: 1377 Abort trap: 6 ./$x > /dev/null 2>&1
... FAIL
Running kaldi-gpsr-test ...... SUCCESS运行matrix-lib-test给出:
make[1]: [test] Error 1
make: [matrix/test] Error 2
Running matrix-lib-test gives:
VLOG[3] (StepSizeIteration():optimization.cc:240) In step size iteration, function value changed -1.23504 to -1.23503
VLOG[2] (StepSizeIteration():optimization.cc:316) Too many steps in line search -> restarting.
VLOG[3] (StepSizeIteration():optimization.cc:323) d = 1.04427, iter = 0, action = reject
VLOG[3] (StepSizeIteration():optimization.cc:376) Restarting computation.
VLOG[2] (UnitTestLbfgs():matrix-lib-test.cc:3074) L-BFGS finished after 82 function evaluations.
KALDI_ASSERT: at UnitTestLinearCgd:matrix-lib-test.cc:3117, failed: error < 1.0e-05 * b.Norm(2.0)
Stack trace is:
0 matrix-lib-test 0x00000001088af26e ZN5kaldi18KaldiGetStackTraceEv + 54
1 matrix-lib-test 0x00000001088af4eb _ZN5kaldi19KaldiAssertFailure_EPKcS1_iS1 + 202
2 matrix-lib-test 0x00000001087f9d35 _ZN5kaldiL17UnitTestLinearCgdIfEEvv + 657
3 matrix-lib-test 0x00000001087f64dc _ZN5kaldiL14MatrixUnitTestIfEEvb + 60
4 matrix-lib-test 0x00000001087f624c main + 27
5 libdyld.dylib 0x00007fff91c105fd start + 1
Abort trap: 6
That test failure is probably not a problem, I can just change the
tolerance.
Probably the command did not work because the second command, copy-feats,
failed.
To test this you can do
测试失败可能不是问题,我可以更改容差。
该命令可能不起作用,因为第二个命令copy-feats
失败。
要对此进行测试,可以执行
gdb --args copy-feats --compress=true "compute-mfcc-feats --verbose=2
--config=conf/mfcc.conf scp,p:exp/make_mfcc/train/wav_train.9.scp ark:- |"
ark,scp:/Users/enzyme156/desktop/KALDI/data/mfcc/raw_
mfcc_train.9.ark,/Users/
(or replace gdb with lldb in that command),
and type at the prompt
r
and then
bt
when it crashes.
(或在该命令中用lldb替换gdb),
然后在提示符
r 处键入
,然后 在崩溃时输入
bt
OK, I gave you the wrong command line. Try好的,我给您错误的命令行。尝试
/usr/local/bin/copy-feats --compress=true 'ark:compute-mfcc-feats --verbose=2 --config=conf/mfcc.conf scp,p:exp/make_mfcc/train/wav_train.9.scp ark:- |' ark:/dev/null
I have figured out the problem. In order to run compute_mfcc_feats and copy_feats I copied the binary files to my usr/local/bin/ folder (this might not be the right way to do it perhaps...?), and forgot to update them when I switched to gcc 4.7 and configured src again. I used the new version of the binary files and feature extraction was successful.我已经解决了问题。为了运行compute_mfcc_feats和copy_feats,我将二进制文件复制到了我的usr / local / bin /文件夹中(也许这不是正确的方法……?),当我切换到gcc 4.7时忘记了再次配置src并更新它们。我使用了新版本的二进制文件,并且功能提取成功。