ImportError: libta_lib.so.0: cannot open shared object file: No such file or directory

I had the same issue. See below for what I did to fix it.

installing

wget http://prdownloads.sourceforge.net/ta-lib/ta-lib-0.4.0-src.tar.gz
tar -xzf ta-lib-0.4.0-src.tar.gz
cd ta-lib/
./configure --prefix=/usr
make
Sudo make install
pip install numpy

If you don't have it installed

pip install TA-Lib 

if you do have it installed

pip install --upgrade --force-reinstall TA-Lib

hope this helps someone :)


add the foldername to ldconfig:

sudo -s 
echo "include /usr/local/lib" >> /etc/ld.so.conf
ldconfig 

For me, following worked:

/usr/local/lib
  1. put above line to /etc/ld.so.conf
  2. execute sudo ldconfig.

Tags:

Python

Ubuntu