Compile and install Kaldi in Ubuntu12.04

Source: Internet
Author: User
Tags cuda toolkit automake
The installation process is troublesome because colleagues need kaldi to work. Record the tossing process here. OS: Ubuntu12.04 (amd64) Principal of kaldi

The installation process is troublesome because colleagues need kaldi to work. Record the tossing process here.

OS: Ubuntu 12.04 (amd64)

Kaldi http://svn.code.sf.net/p/kaldi/code/ I downloaded here is stable

Svn co http://svn.code.sf.net/p/kaldi/code/stable kaldi-stable

"Before compilation, you need to change the sph2pipe_v2.5.tar.gz. The address in the source code cannot be connected and cannot be downloaded. You need to change it to the address of sourceforge. The strange thing is that the addresses of other packages are sourceforge, why is this http://merlin.fit.vutbr.cz/kaldi/sph2pipe_v2.5.tar.gz"

Edit kaldi-stable/tools/Makefile and change the sph2pipe in the last part to the following address:

Sph2pipe_v2.5.tar.gz:

Http://merlin.fit.vutbr.cz/kaldi/sph2pipe_v2.5.tar.gz wget-T 10-t 3

Sph2pipe_v2.5.tar.gz:

Http://sourceforge.net/projects/kaldi/files/sph2pipe_v2.5.tar.gz wget-T 10-t 3

After the address is modified, make can be performed.

Cd kaldi-stable/tools

Make automatically downloads the corresponding software package, decompress the package, and so on. No intervention is required unless an error occurs in the middle.

Error ..... Because the automake autoconf libtool was not used before, an error occurred while performing the irstlm step... Install the three software automake autoconf libtool

Patching file src/lmtable. h
Patching file src/interpolate-lm.cpp
Touch irstlm/. patched
Cd irstlm ;\
(./Regenerate-makefiles.sh |./regenerate-makefiles.sh )&&\
./Configure -- prefix 'pwd'
Calling
Calling...
/Regenerate-makefiles.sh: line 52:-I: command not found
Aclocal failed
Calling
Calling...
/Regenerate-makefiles.sh: line 52:-I: command not found
Aclocal failed

Install dependency

Aptitude install automake autoconf libtool-y

Continue make ....

Make clean

Make-j4

Cd ../src

./Configure

Make-j4

-------------------------------------------------------------------------

If you need the nnetbin tool, you have to download the version .....-_-!!

Svn co http://svn.code.sf.net/p/kaldi/code/trunk

Root @ GPU :~ /Kaldi-trunk/src #./configure
Processing...
Checking OpenFST library in/root/kaldi-trunk/tools/openfst...
Checking OpenFst library was patched.
Backing up kaldi. mk to kaldi. mk. bak
Doing OS specific ations...
On Linux: Checking for linear algebra header files...
Using ATLAS as the linear algebra library.
Atlas found in/usr/lib
... No libatlas. so in/usr/lib/atlas
... No libatlas. so in/usr/lib/atlas-sse2.
... No libatlas. so in/usr/lib/atlas-sse3.
... No libatlas. so in/usr/lib64
... No libatlas. so in/usr/lib64/atlas
... No libatlas. so in/usr/lib64/atlas-sse2
... No libatlas. so in/usr/lib64/atlas-sse3
... No libatlas. so in/usr/local/lib
... No libatlas. so in/usr/local/lib/atlas
... No libatlas. so in/usr/local/lib/atlas-sse2
... No libatlas. so in/usr/local/lib/atlas-sse3
... No libatlas. so in/usr/local/lib64
... No libatlas. so in/usr/local/lib64/atlas
... No libatlas. so in/usr/local/lib64/atlas-sse2
... No libatlas. so in/usr/local/lib64/atlas-sse3
... No libatlas. so in/root/kaldi-trunk/src/../tools/ATLAS/build/install/lib/
... No libatlas. so in/root/kaldi-trunk/tools/ATLAS/lib
Looking for ATLAS libs in/usr/lib
Using library-L/usr/lib-llapack as ATLAS's CLAPACK library.
Using CUDA toolkit/usr/local/cuda (nvcc compiler and runtime libraries)
Static = [false] Speex library not found: You can still build Kaldi without Speex.
Successfully configured for Linux [dynamic libraries] with ATLASLIBS =-L/usr/lib-llapack-lcblas-latlas-lf77blas
Exp () time: 0.00276494
Expf () time: 0.00307679
* ** WARNING: expf () seems to be slower than exp () on your machine. This is a known bug in old versions of glibc. Please consider updating glibc .***
* ** Kaldi will be configured to use exp () instead of expf () in base/kaldi-math.h Exp () routine for single-precision floats .***

I don't know if we need to upgrade glibc.

Linux upgrade Glibc http://www.linuxidc.com/Linux/2015-04/116472.htm

Installation and compilation http://www.linuxidc.com/Linux/2014-01/95843.htm of Kaldi Speech Recognition library in Linux

This article permanently updates the link address: Http://www.linuxidc.com/Linux/2015-07/120455.htm

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.