Skip to content
This repository was archived by the owner on Aug 8, 2024. It is now read-only.
This repository was archived by the owner on Aug 8, 2024. It is now read-only.

Problem with scipy superpack and "get_fontconfig_fonts" in matplotlib.pyplot #39

Closed

Description

@rappoccio

Hi,

Firstly : Thanks for providing this package, it's wonderful. I encouraged the students in my class to use it for our installations. However, one of them is having trouble that I can't seem to wrap my head around.

She installed via the shell script, and everything works except pyplot. When running pyplot, we get :

Traceback (most recent call last):
File "", line 1, in
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/pyplot.py", line 26, in
import matplotlib.colorbar
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/colorbar.py", line 33, in
import matplotlib.collections as collections
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/collections.py", line 26, in
import matplotlib.backend_bases as backend_bases
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/backend_bases.py", line 54, in
import matplotlib.textpath as textpath
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/textpath.py", line 18, in
import matplotlib.font_manager as font_manager
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/font_manager.py", line 1354, in
_rebuild()
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/font_manager.py", line 1339, in _rebuild
fontManager = FontManager()
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/font_manager.py", line 987, in init
self.ttffiles = findSystemFonts(paths) + findSystemFonts()
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/font_manager.py", line 316, in findSystemFonts
for f in get_fontconfig_fonts(fontext):
File "/Library/Python/2.7/site-packages/matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg/matplotlib/font_manager.py", line 280, in get_fontconfig_fonts
for line in output.split('\n'):
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe5 in position 8918: ordinal not in range(128)

The directory contents are :

dhcp205-160-006:software maralalyari$ ls /Library/Python/2.7/site-packages/
Jinja2-2.7.1-py2.7.egg patsy-0.2.1-py2.7.egg
MarkupSafe-0.18-py2.7-macosx-10.8-intel.egg pika-0.9.13-py2.7.egg
Pygments-1.6-py2.7.egg pip-1.4.1-py2.7.egg
README pymc-2.2-py2.7-macosx-10.8-intel.egg
Sphinx-1.2b1-py2.7.egg pyparsing-1.5.7-py2.7.egg
docutils-0.11-py2.7.egg pytz-2013d-py2.7.egg
easy-install.pth pyzmq-13.1.0-py2.7-macosx-10.6-intel.egg
ipython-1.0.0-py2.7.egg readline-6.2.4.1-py2.7-macosx-10.7-intel.egg
ipython-2.0.0_dev-py2.7.egg scikit_learn-0.14_git-py2.7-macosx-10.8-intel.egg
matplotlib-1.4.x-py2.7-macosx-10.8-intel.egg scipy-0.14.0.dev_2a4ba40-py2.7-macosx-10.8-intel.egg
nose-1.3.0-py2.7.egg six-1.4.1-py2.7.egg
numpy-1.9.0.dev_c50e60d-py2.7-macosx-10.8-x86_64.egg statsmodels-0.6.0-py2.7-macosx-10.8-intel.egg
pandas-0.12.0_307_g3a2fe0b-py2.7-macosx-10.8-intel.egg tornado-3.1.1-py2.7.egg

The python installed is :

dhcp205-160-006:software maralalyari$ which python
/Library/Frameworks/Python.framework/Versions/2.7/bin/python
dhcp205-160-006:software maralalyari$ python -i
Python 2.7.5 (v2.7.5:ab05e7dd2788, May 13 2013, 13:18:45)
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type "help", "copyright", "credits" or "license" for more information.

Do you have any suggestions here?

Thanks,
Sal Rappoccio

Activity

  1. fonnesbeck commented on Sep 6, 2013

    @fonnesbeck
    Owner

    Apparently this is a bug that pops up from time to time, though I have not seen it myself. I notice that she is using Python 2.7.5, rather than the python that is pre-installed on OS X 10.8.4. You might try installing it to this version instead, unless you have a reason to use an alternate distribution. If you do want to use a different Python, you might try Anaconda, which includes the scientific packages pre-installed.

    FWIW, here is an explanation about the error.

  2. rappoccio commented on Sep 7, 2013

    @rappoccio
    Author

    Thanks a lot, Chris! I'll get the 2.7.2 (or .3, I don't remember) set up for her.

    Thanks again for this really great tool, and for the prompt feedback!

    Cheers,
    Sal Rappoccio

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions