After successfully compiled and installed caffe
and pycaffe
, I got undefined symbol: cairo_surface_get_device_scale
when trying to import caffe
in Python.
>>> import caffe
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/neozero/caffe/python/caffe/__init__.py", line 1, in <module>
from .pycaffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, RMSPropSolver, AdaDeltaSolver, AdamSolver
File "/home/neozero/caffe/python/caffe/pycaffe.py", line 13, in <module>
from ._caffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, \
ImportError: /usr/lib/libgdk-3.so.0: undefined symbol: cairo_surface_get_device_scale
I have googled that upgrade the cairo
might help. But it did not help. I use Arch Linux and have every thing upgraded and reinstalled cairo-1.14.6
, which is the latest version, but it still did not work.
$ pacman -Qs cairo
local/cairo 1.14.6-1
Cairo vector graphics library
local/cairomm 1.12.0-2
C++ bindings to Cairo vector graphics library
local/goocanvas 2.0.2-1
A cairo canvas widget for GTK+
local/libtiger 0.3.4-4
A rendering library for Kate streams using Pango and Cairo
local/pixman 0.34.0-1
The pixel-manipulation library for X and cairo
local/python-cairo 1.10.0-6
Python bindings for the cairo graphics library
local/python2-cairo 1.10.0-2
Python2 bindings for the cairo graphics library
Thanks for your help!