1

I am getting the following error on importing seaborn (both python and matplotlib were installed successfully):

 import seaborn
 File "/usr/lib/python2.7/site-packages/seaborn/__init__.py", line 6, in <modul                                                                                                                e>
from .rcmod import *
 File "/usr/lib/python2.7/site-packages/seaborn/rcmod.py", line 8, in <module>
from . import palettes, _orig_rc_params
 File "/usr/lib/python2.7/site-packages/seaborn/palettes.py", line 12, in <modu                                                                                                                le>
from .utils import desaturate, set_hls_values, get_color_cycle
 File "/usr/lib/python2.7/site-packages/seaborn/utils.py", line 12, in <module>
import matplotlib.pyplot as plt
 File "/usr/lib/python2.7/site-packages/matplotlib/pyplot.py", line 115, in <mo                                                                                                                dule>
_backend_mod, new_figure_manager, draw_if_interactive, _show = pylab_setup()
 File "/usr/lib/python2.7/site-packages/matplotlib/backends/__init__.py", line                                                                                                                 32, in pylab_setup
globals(),locals(),[backend_name],0)
 File "/usr/lib/python2.7/site-packages/matplotlib/backends/backend_tkagg.py",                                                                                                                 line 13, in <module>
import matplotlib.backends.tkagg as tkagg
 File "/usr/lib/python2.7/site-packages/matplotlib/backends/tkagg.py", line 9,                                                                                                                 in <module>
from matplotlib.backends import _tkagg
RuntimeError: No such process

I checked for the solution, but which involves installing tk-dev, but it seems this package is not available anymore.

$ pip install tk-dev
Collecting tk-dev
Could not find a version that satisfies the requirement tk-dev (from versions:                                                                                                                 )
No matching distribution found for tk-dev

So how do I resolve this error now?

Community
  • 1
  • 1
user828647
  • 505
  • 1
  • 10
  • 27
  • 1
    `tk-dev` is not a python package so you can not install with pip. The package is called `tcl-tk-devel` on cygwin and you can install it with setup. – matzeri Feb 22 '17 at 21:09
  • 1
    `tcl-tk-devel` is already installed in cygwin, should I re-install? – user828647 Feb 23 '17 at 19:40
  • I'm having the exact same problem, with Python 3.7. Already installed tcl-tk-devel via the cygwin setup. Note the import statement specifies that _tkagg must be in (for me) /usr/lib/python3.7/site-packages/matplotlib/backends . And it is there! File _tkagg.cpython-37m-x86_64-cygwin.dll . For some reason the import fails to load it. – Phil Goetz Apr 02 '20 at 20:50

0 Answers0