Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: /lib/x86_64-linux-gnu/librsvg-2.so.2: undefined symbol: cairo_tag_end #6805

Open
TWMazza opened this issue Jul 19, 2019 · 0 comments

Comments

@TWMazza
Copy link

commented Jul 19, 2019

Issue summary

After many failed attempts and messed up Linux installations I've successfully compiled Caffe, Protobuf and DeepDream, just to face an error when running the deepdreaming.py script for the first time. I'm not sure if the Caffe Git is the right place to post this report to, although it looks like an error during import of Caffe - my sincere apologies if I failed to pick the correct Git.

python deepdreaming.py --help and other parameters result in the below error message:

python deepdreaming.py --help
Traceback (most recent call last):
File "deepdreaming.py", line 13, in
import caffe
File "/home/twmlive/deepdream/caffe/python/caffe/init.py", line 1, in
from .pycaffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, RMSPropSolver, AdaDeltaSolver, AdamSolver, NCCL, Timer
File "/home/twmlive/deepdream/caffe/python/caffe/pycaffe.py", line 13, in
from ._caffe import Net, SGDSolver, NesterovSolver, AdaGradSolver,
ImportError: /lib/x86_64-linux-gnu/librsvg-2.so.2: undefined symbol: cairo_tag_end

Steps to reproduce

  • Open jupyter notebook in DeepDream directory
  • Create new terminal
  • Run python deepdreaming.py with any parameters, eg --help
  • Also happens outside the notebook

Steps before steps to reproduce

To be able to run DeepDream with as little interference as possible, I've installed Debian 10 latest from a netinstall USB drive with Debian Desktop Environment, GNOME, MATE and the standard system utilities (in previous attempts I installed MATE only rather than MATE and GNOME and faced the similar issues). After installing and setting up the system with some basic tools (like Timeshift, gparted, gdebi, Handbrake, libdvd-pkg, ffmpeg, Chrome and Opera, ...), I've been following a brief set of instructions found on Knight-of-pi.org to set up DeepDream. Though I had to make a few adjustments that may or may not be related to this:

  • ipython notebook doesn't exist anymore, so I had to use jupyter notebook instead

  • Makefile.config has been modified
    -- Uncomment CPU_Only=1
    -- Comment PYTHON_INCLUDE for Python 2.7 (to resolve issue during compilation due to missing numpy)
    -- Uncomment ANACONDA_HOME and point to /home/twmlive/anaconda2
    -- Uncomment PYTHON_INCLUDE for Anaconda
    -- Comment PYTHON_LIB for Python 2.7
    -- Uncomment PYTHON_LIB for Anaconda
    -- Add the libhdf5-directories mentioned in your common issues section to INCLUDE_DIRS and LIBRARY_DIRS
    -- Uncomment USE_PKG_CONFIG := 1 for OpenCV

  • libhdf5_hl.so.100 was missing (not sure if it was during make runtest or make pycaffe, and so was libhdf5.so.103, and a third hdf5-related file I cannot recall the name of anymore. I had to ln -T three links in total to the anaconda2-libs in order to solve the issue and get make going.

There was a lot of troubleshooting going on yesterday, so I may have missed one or two details. It was only the compilation process for pycaffe being so difficult, after that everything else worked quite well with barely any trouble. Also, this is probably the 50th attempt (not kidding, since once I mess up I cannot fix it and gotta start over again) in setting up a clean Debian (or other Linux distros) for DeepDream and DeepDreamVideo.

Tried solutions

  • apt reinstall librsvg2-2
  • I've also installed a bunch of cairo-related packages, mostly the -dev stuff via atp but cannot recall all the packages

I've also tried to downgrade librsvg2-2 since I read a post about this error popping up a year ago related to some other application on Linux. But I gave up this idea since, according to the forum thread, they figured out it was only happening with a certain version of librsvg and in few environments only, so likely it has nothing to do with the lib but with the environment instead. Anyways, none of the installed packages had an impact on the problem, the error message did not change.

System configuration

  • Operating system: Debian 10 Buster (stable, latest)
  • Compiler: gcc (Debian 8.3.0-6) 8.3.0
  • CUDA version (if applicable): none
  • CUDNN version (if applicable): none
  • BLAS: Atlas (default)
  • Python version (if using pycaffe): Anaconda 2.7
  • MATLAB version (if using matcaffe): none

Issue checklist

  • read the guidelines and removed the first paragraph
  • written a short summary and detailed steps to reproduce
  • explained how solutions to related problems failed (tick if found none)
  • filled system configuration
  • attached relevant logs/config files (tick if not applicable)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.