WebFaction
Community site: login faq

Following the advice here I easy_installed matplotlib using the following commands:

mkdir -p ~/bin ~/lib/python2.6
easy_install-2.6 matplotlib

After installation finished (with some warnings) I tried the following and received an error:

[username@webXXX mydjangoapp]$ python2.6
Python 2.6.5 (r265:79063, Nov 23 2010, 02:02:03)
[GCC 4.1.2 20080704 (Red Hat 4.1.2-48)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import matplotlib.pyplot as plt
/home/username/lib/python2.6/matplotlib-0.91.1-py2.6-linux-i686.egg/matplotlib/__init__.py:62: DeprecationWarning: the md5 module is deprecated; use hashlib instead
  import md5, os, re, shutil, sys, warnings
/home/username/lib/python2.6/matplotlib-0.91.1-py2.6-linux-i686.egg/pytz/tzinfo.py:5: DeprecationWarning: the sets module is deprecated
  from sets import Set
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/username/lib/python2.6/matplotlib-0.91.1-py2.6-linux-i686.egg/matplotlib/pyplot.py", line 6, in <module>
    from matplotlib.figure import Figure, figaspect
  File "/home/username/lib/python2.6/matplotlib-0.91.1-py2.6-linux-i686.egg/matplotlib/figure.py", line 10, in <module>
    from axes import Axes, Subplot, PolarSubplot, PolarAxes
  File "/home/username/lib/python2.6/matplotlib-0.91.1-py2.6-linux-i686.egg/matplotlib/axes.py", line 6, in <module>
    import matplotlib.numerix.npyma as ma
  File "/home/username/lib/python2.6/matplotlib-0.91.1-py2.6-linux-i686.egg/matplotlib/numerix/__init__.py", line 166, in <module>
    __import__('ma', g, l)
  File "/home/username/lib/python2.6/matplotlib-0.91.1-py2.6-linux-i686.egg/matplotlib/numerix/ma/__init__.py", line 16, in <module>
    from numpy.core.ma import *
ImportError: No module named ma

How can I resolve this?

UPDATE: I tried to easy_install numpy - turns out it's already installed:

[username@webXXX ~]$ easy_install-2.6 numpy
Searching for numpy
Best match: numpy 1.2.1
Adding numpy 1.2.1 to easy-install.pth file

Using /usr/local/lib/python2.6/site-packages
Processing dependencies for numpy
Finished processing dependencies for numpy

I tried the import after this again and it failed again

asked 07 Feb '11, 12:11

Jonathan
281813
accept rate: 0%

edited 07 Feb '11, 16:40


It looks like matplotlib 1.0.1 was recently released, but easy_install and pip aren't fetching the new packages yet.

I just tried this on my webfaction account and it worked:

easy_install-2.6 http://sourceforge.net/projects/matplotlib/files/matplotlib/matplotlib-1.0.1/matplotlib-1.0.1.tar.gz/download

There is also a new version of numpy (1.5 vs WebFaction's 1.2), but the pre-installed one worked fine with matplotlib 1.0.1

permanent link

answered 07 Feb '11, 17:45

Michael Bunsen
414
accept rate: 50%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×337
×7
×5

question asked: 07 Feb '11, 12:11

question was seen: 10,901 times

last updated: 07 Feb '11, 17:45

                              
WEBFACTION
REACH US
SUPPORT
LEGAL
© COPYRIGHT 2003-2020 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM