Re: [Matplotlib-users] Symbol not found

2010-06-25 Thread Benjamin Root
Oh, wait a minute, you are doing a Frameworks install on a Mac. I think
there are others here that might be able to comment on Mac installs.

Ben

On Fri, Jun 25, 2010 at 3:31 PM, Ranjit Chacko  wrote:

> Hi Ben,
>
> Thanks for the tips. How do I check the TrueType fonts? Googling matplotlib
> developer wiki doesn't turn up anything. There isn't anything in the
> ~/.matplotlib directory. I just went ahead and recompiled numpy and
> matplotlib, and got the same error.
>
> -Ranjit
>
>
> On Fri, Jun 25, 2010 at 12:59 PM, Benjamin Root  wrote:
>
>> Ranjit,
>>
>> There are a couple of possibilities.  The first is that the TrueType fonts
>> packages weren't detected during the build, so matplotlib compiled without
>> it, leading to your issue.  I have also seen an issue where your
>> ~/.matplotlib/ needs to be cleaned out of font-related files.  Another
>> possibility has to do with building both numpy and matplotlib.  I have found
>> that if I update the numpy source code and rebuild it, then I have to
>> rebuild matplotlib. Now that you managed to get a complete build.  I would
>> go back and completely eliminate the build directories of matplotlib (and
>> numpy, if you have it), and rebuild.  Build numpy first if you have that
>> from source, and then build matplotlib.
>>
>> So, first double-check your TrueType Font packages and see if you comply
>> with the dependencies listed on the developer wiki.  If so, then check your
>> .matplotlib directory for any fontCache files and remove it.  Lastly, do a
>> complete clean and rebuild of matplotlib (the cleaning part is very
>> important).
>>
>> I hope that helps,
>> Ben Root
>>
>> On Fri, Jun 25, 2010 at 11:56 AM, Ranjit Chacko wrote:
>>
>>> I finally somehow managed to get matplotlib to compile but now when I try
>>> to import matplotlib.pyplot I get the following error:
>>>
>>> Traceback (most recent call last):
>>>   File "", line 1, in 
>>> AttributeError: 'module' object has no attribute 'pyplot'
>>> >>> from matplotlib import pyplot as plot
>>> Traceback (most recent call last):
>>>   File "", line 1, in 
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/pyplot.py",
>>> line 6, in 
>>> from matplotlib.figure import Figure, figaspect
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/figure.py",
>>> line 18, in 
>>> from axes import Axes, SubplotBase, subplot_class_factory
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axes.py",
>>> line 12, in 
>>> import matplotlib.axis as maxis
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axis.py",
>>> line 10, in 
>>> import matplotlib.font_manager as font_manager
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/font_manager.py",
>>> line 52, in 
>>> from matplotlib import ft2font
>>> ImportError:
>>> dlopen(/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so,
>>> 2): Symbol not found: _FT_Attach_File
>>>   Referenced from:
>>> /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so
>>>   Expected in: dynamic lookup
>>>
>>> What is going wrong here?
>>>
>>> Thanks,
>>>
>>> -Ranjit
>>>
>>>
>>>
>>> --
>>> ThinkGeek and WIRED's GeekDad team up for the Ultimate
>>> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
>>> lucky parental unit.  See the prize list and enter to win:
>>> http://p.sf.net/sfu/thinkgeek-promo
>>> ___
>>> Matplotlib-users mailing list
>>> Matplotlib-users@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>>>
>>>
>>
>
--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Symbol not found

2010-06-25 Thread Benjamin Root
Sorry, it isn't a developer wiki (numpy and scipy have that...).  But here
are the requirements to make sure that they are installed.

http://matplotlib.sourceforge.net/users/installing.html#build-requirements

Ben Root

On Fri, Jun 25, 2010 at 3:31 PM, Ranjit Chacko  wrote:

> Hi Ben,
>
> Thanks for the tips. How do I check the TrueType fonts? Googling matplotlib
> developer wiki doesn't turn up anything. There isn't anything in the
> ~/.matplotlib directory. I just went ahead and recompiled numpy and
> matplotlib, and got the same error.
>
> -Ranjit
>
>
> On Fri, Jun 25, 2010 at 12:59 PM, Benjamin Root  wrote:
>
>> Ranjit,
>>
>> There are a couple of possibilities.  The first is that the TrueType fonts
>> packages weren't detected during the build, so matplotlib compiled without
>> it, leading to your issue.  I have also seen an issue where your
>> ~/.matplotlib/ needs to be cleaned out of font-related files.  Another
>> possibility has to do with building both numpy and matplotlib.  I have found
>> that if I update the numpy source code and rebuild it, then I have to
>> rebuild matplotlib. Now that you managed to get a complete build.  I would
>> go back and completely eliminate the build directories of matplotlib (and
>> numpy, if you have it), and rebuild.  Build numpy first if you have that
>> from source, and then build matplotlib.
>>
>> So, first double-check your TrueType Font packages and see if you comply
>> with the dependencies listed on the developer wiki.  If so, then check your
>> .matplotlib directory for any fontCache files and remove it.  Lastly, do a
>> complete clean and rebuild of matplotlib (the cleaning part is very
>> important).
>>
>> I hope that helps,
>> Ben Root
>>
>> On Fri, Jun 25, 2010 at 11:56 AM, Ranjit Chacko wrote:
>>
>>> I finally somehow managed to get matplotlib to compile but now when I try
>>> to import matplotlib.pyplot I get the following error:
>>>
>>> Traceback (most recent call last):
>>>   File "", line 1, in 
>>> AttributeError: 'module' object has no attribute 'pyplot'
>>> >>> from matplotlib import pyplot as plot
>>> Traceback (most recent call last):
>>>   File "", line 1, in 
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/pyplot.py",
>>> line 6, in 
>>> from matplotlib.figure import Figure, figaspect
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/figure.py",
>>> line 18, in 
>>> from axes import Axes, SubplotBase, subplot_class_factory
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axes.py",
>>> line 12, in 
>>> import matplotlib.axis as maxis
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axis.py",
>>> line 10, in 
>>> import matplotlib.font_manager as font_manager
>>>   File
>>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/font_manager.py",
>>> line 52, in 
>>> from matplotlib import ft2font
>>> ImportError:
>>> dlopen(/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so,
>>> 2): Symbol not found: _FT_Attach_File
>>>   Referenced from:
>>> /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so
>>>   Expected in: dynamic lookup
>>>
>>> What is going wrong here?
>>>
>>> Thanks,
>>>
>>> -Ranjit
>>>
>>>
>>>
>>> --
>>> ThinkGeek and WIRED's GeekDad team up for the Ultimate
>>> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
>>> lucky parental unit.  See the prize list and enter to win:
>>> http://p.sf.net/sfu/thinkgeek-promo
>>> ___
>>> Matplotlib-users mailing list
>>> Matplotlib-users@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>>>
>>>
>>
>
--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Symbol not found

2010-06-25 Thread Ranjit Chacko
Hi Ben,

Thanks for the tips. How do I check the TrueType fonts? Googling matplotlib
developer wiki doesn't turn up anything. There isn't anything in the
~/.matplotlib directory. I just went ahead and recompiled numpy and
matplotlib, and got the same error.

-Ranjit

On Fri, Jun 25, 2010 at 12:59 PM, Benjamin Root  wrote:

> Ranjit,
>
> There are a couple of possibilities.  The first is that the TrueType fonts
> packages weren't detected during the build, so matplotlib compiled without
> it, leading to your issue.  I have also seen an issue where your
> ~/.matplotlib/ needs to be cleaned out of font-related files.  Another
> possibility has to do with building both numpy and matplotlib.  I have found
> that if I update the numpy source code and rebuild it, then I have to
> rebuild matplotlib. Now that you managed to get a complete build.  I would
> go back and completely eliminate the build directories of matplotlib (and
> numpy, if you have it), and rebuild.  Build numpy first if you have that
> from source, and then build matplotlib.
>
> So, first double-check your TrueType Font packages and see if you comply
> with the dependencies listed on the developer wiki.  If so, then check your
> .matplotlib directory for any fontCache files and remove it.  Lastly, do a
> complete clean and rebuild of matplotlib (the cleaning part is very
> important).
>
> I hope that helps,
> Ben Root
>
> On Fri, Jun 25, 2010 at 11:56 AM, Ranjit Chacko wrote:
>
>> I finally somehow managed to get matplotlib to compile but now when I try
>> to import matplotlib.pyplot I get the following error:
>>
>> Traceback (most recent call last):
>>   File "", line 1, in 
>> AttributeError: 'module' object has no attribute 'pyplot'
>> >>> from matplotlib import pyplot as plot
>> Traceback (most recent call last):
>>   File "", line 1, in 
>>   File
>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/pyplot.py",
>> line 6, in 
>> from matplotlib.figure import Figure, figaspect
>>   File
>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/figure.py",
>> line 18, in 
>> from axes import Axes, SubplotBase, subplot_class_factory
>>   File
>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axes.py",
>> line 12, in 
>> import matplotlib.axis as maxis
>>   File
>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axis.py",
>> line 10, in 
>> import matplotlib.font_manager as font_manager
>>   File
>> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/font_manager.py",
>> line 52, in 
>> from matplotlib import ft2font
>> ImportError:
>> dlopen(/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so,
>> 2): Symbol not found: _FT_Attach_File
>>   Referenced from:
>> /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so
>>   Expected in: dynamic lookup
>>
>> What is going wrong here?
>>
>> Thanks,
>>
>> -Ranjit
>>
>>
>>
>> --
>> ThinkGeek and WIRED's GeekDad team up for the Ultimate
>> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
>> lucky parental unit.  See the prize list and enter to win:
>> http://p.sf.net/sfu/thinkgeek-promo
>> ___
>> Matplotlib-users mailing list
>> Matplotlib-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>>
>>
>
--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Symbol not found

2010-06-25 Thread Benjamin Root
Ranjit,

There are a couple of possibilities.  The first is that the TrueType fonts
packages weren't detected during the build, so matplotlib compiled without
it, leading to your issue.  I have also seen an issue where your
~/.matplotlib/ needs to be cleaned out of font-related files.  Another
possibility has to do with building both numpy and matplotlib.  I have found
that if I update the numpy source code and rebuild it, then I have to
rebuild matplotlib. Now that you managed to get a complete build.  I would
go back and completely eliminate the build directories of matplotlib (and
numpy, if you have it), and rebuild.  Build numpy first if you have that
from source, and then build matplotlib.

So, first double-check your TrueType Font packages and see if you comply
with the dependencies listed on the developer wiki.  If so, then check your
.matplotlib directory for any fontCache files and remove it.  Lastly, do a
complete clean and rebuild of matplotlib (the cleaning part is very
important).

I hope that helps,
Ben Root

On Fri, Jun 25, 2010 at 11:56 AM, Ranjit Chacko  wrote:

> I finally somehow managed to get matplotlib to compile but now when I try
> to import matplotlib.pyplot I get the following error:
>
> Traceback (most recent call last):
>   File "", line 1, in 
> AttributeError: 'module' object has no attribute 'pyplot'
> >>> from matplotlib import pyplot as plot
> Traceback (most recent call last):
>   File "", line 1, in 
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/pyplot.py",
> line 6, in 
> from matplotlib.figure import Figure, figaspect
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/figure.py",
> line 18, in 
> from axes import Axes, SubplotBase, subplot_class_factory
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axes.py",
> line 12, in 
> import matplotlib.axis as maxis
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axis.py",
> line 10, in 
> import matplotlib.font_manager as font_manager
>   File
> "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/font_manager.py",
> line 52, in 
> from matplotlib import ft2font
> ImportError:
> dlopen(/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so,
> 2): Symbol not found: _FT_Attach_File
>   Referenced from:
> /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so
>   Expected in: dynamic lookup
>
> What is going wrong here?
>
> Thanks,
>
> -Ranjit
>
>
>
> --
> ThinkGeek and WIRED's GeekDad team up for the Ultimate
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
> lucky parental unit.  See the prize list and enter to win:
> http://p.sf.net/sfu/thinkgeek-promo
> ___
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
>
--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] basemap broken with matplotlib 0.99.3?

2010-06-25 Thread PHobson
Success! (well, the import worked)

Christoph, thanks so much for the link, it is awesome! It can't be said enough 
that this is an awesome project and I'm so glad and thankful that it exists.

> -Original Message-
> From: Christoph Gohlke [mailto:cgoh...@uci.edu]
> Sent: Friday, June 25, 2010 11:37 AM
> To: matplotlib-users@lists.sourceforge.net
> Subject: Re: [Matplotlib-users] basemap broken with matplotlib 0.99.3?
> 
> IIRC basemap contains Cython code, which would need to be "recythonized"
> with the latest Cython version in order to work with numpy 1.4.1. If you
> don't mind trying developer releases, use basemap 0.99.5 from
> , which should work
> with numpy 1.4.1.
> 
> Christoph
> 
> 
> On 6/25/2010 11:21 AM, phob...@geosyntec.com wrote:
> > Bill,
> >
> > Unfortunately, I don't have a solution for you. I just wanted to chime
> in and say that I'm getting the same error. I'm on XP, py2.6, mpl0.99.3,
> np1.4.1, sp0.8.0b1. Basemap came from the latest Windows binary on
> Sourceforge.
> > -paul
> >
> >> -Original Message-
> >> From: Bill Eaton [mailto:e...@aeroantenna.com]
> >> Sent: Wednesday, June 23, 2010 8:24 AM
> >> To: matplotlib-users@lists.sourceforge.net
> >> Subject: [Matplotlib-users] basemap broken with matplotlib 0.99.3?
> >>
> >> I stumbled across a basemap demo a couple of days ago and was
> immediately
> >> enchanted.
> >>
> >> I can't get it to install nicely on a Windoze box with matplotlib
> 0.99.3.
> >> When I try the famous
> >>from mpl_toolkits.basemap import Basemap
> >> directive, I get
> >>In [1]: from mpl_toolkits.basemap import Basemap
> >> --
> ---
> >> --
> >> ValueErrorTraceback (most recent call
> >> last)
> >>
> >> C:\Documents and Settings\Bill.DC1\  in()
> >>
> >> C:\Python26\lib\site-packages\mpl_toolkits\basemap\__init__.py in
> >> ()
> >>   36 from matplotlib.lines import Line2D
> >>   37 from matplotlib.transforms import Bbox
> >> --->  38 import pyproj, sys, os, math, dbflib
> >>   39 from proj import Proj
> >>   40 import numpy as np
> >>
> >> C:\Python26\lib\site-packages\mpl_toolkits\basemap\pyproj.py in
> >> ()
> >>   46 CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. """
> >>   47
> >> --->  48 from _proj import Proj as _Proj
> >>   49 from _geod import Geod as _Geod
> >>   50 from _proj import _transform
> >>
> >> C:\Documents and Settings\Bill.DC1\c_numpy.pxd in _proj
> >> (src/_proj.c:3234)()
> >>
> >> ValueError: numpy.dtype does not appear to be the correct type object
> >>
> >> I tried manually installing many of the prerequisites (which should be
> >> bundled) and also reinstalling MPL. But still no joy.
> >>
> >> On my Linux box running 0.99.0, I was able to install basemap and run
> one
> >> of
> >> the example codes. Works quite nicely.
> >>
> >>
> >>
> >>
> >> --
> ---
> >> -
> >> ThinkGeek and WIRED's GeekDad team up for the Ultimate
> >> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
> >> lucky parental unit.  See the prize list and enter to win:
> >> http://p.sf.net/sfu/thinkgeek-promo
> >> ___
> >> Matplotlib-users mailing list
> >> Matplotlib-users@lists.sourceforge.net
> >> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
> >
> > ---
> ---
> > ThinkGeek and WIRED's GeekDad team up for the Ultimate
> > GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
> > lucky parental unit.  See the prize list and enter to win:
> > http://p.sf.net/sfu/thinkgeek-promo
> > ___
> > Matplotlib-users mailing list
> > Matplotlib-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/matplotlib-users
> >
> >
> 
> -
> -
> ThinkGeek and WIRED's GeekDad team up for the Ultimate
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
> lucky parental unit.  See the prize list and enter to win:
> http://p.sf.net/sfu/thinkgeek-promo
> ___
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users

--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] basemap broken with matplotlib 0.99.3?

2010-06-25 Thread Christoph Gohlke
IIRC basemap contains Cython code, which would need to be "recythonized" 
with the latest Cython version in order to work with numpy 1.4.1. If you 
don't mind trying developer releases, use basemap 0.99.5 from 
, which should work 
with numpy 1.4.1.

Christoph


On 6/25/2010 11:21 AM, phob...@geosyntec.com wrote:
> Bill,
>
> Unfortunately, I don't have a solution for you. I just wanted to chime in and 
> say that I'm getting the same error. I'm on XP, py2.6, mpl0.99.3, np1.4.1, 
> sp0.8.0b1. Basemap came from the latest Windows binary on Sourceforge.
> -paul
>
>> -Original Message-
>> From: Bill Eaton [mailto:e...@aeroantenna.com]
>> Sent: Wednesday, June 23, 2010 8:24 AM
>> To: matplotlib-users@lists.sourceforge.net
>> Subject: [Matplotlib-users] basemap broken with matplotlib 0.99.3?
>>
>> I stumbled across a basemap demo a couple of days ago and was immediately
>> enchanted.
>>
>> I can't get it to install nicely on a Windoze box with matplotlib 0.99.3.
>> When I try the famous
>>from mpl_toolkits.basemap import Basemap
>> directive, I get
>>In [1]: from mpl_toolkits.basemap import Basemap
>> -
>> --
>> ValueErrorTraceback (most recent call
>> last)
>>
>> C:\Documents and Settings\Bill.DC1\  in()
>>
>> C:\Python26\lib\site-packages\mpl_toolkits\basemap\__init__.py in
>> ()
>>   36 from matplotlib.lines import Line2D
>>   37 from matplotlib.transforms import Bbox
>> --->  38 import pyproj, sys, os, math, dbflib
>>   39 from proj import Proj
>>   40 import numpy as np
>>
>> C:\Python26\lib\site-packages\mpl_toolkits\basemap\pyproj.py in
>> ()
>>   46 CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. """
>>   47
>> --->  48 from _proj import Proj as _Proj
>>   49 from _geod import Geod as _Geod
>>   50 from _proj import _transform
>>
>> C:\Documents and Settings\Bill.DC1\c_numpy.pxd in _proj
>> (src/_proj.c:3234)()
>>
>> ValueError: numpy.dtype does not appear to be the correct type object
>>
>> I tried manually installing many of the prerequisites (which should be
>> bundled) and also reinstalling MPL. But still no joy.
>>
>> On my Linux box running 0.99.0, I was able to install basemap and run one
>> of
>> the example codes. Works quite nicely.
>>
>>
>>
>>
>> -
>> -
>> ThinkGeek and WIRED's GeekDad team up for the Ultimate
>> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
>> lucky parental unit.  See the prize list and enter to win:
>> http://p.sf.net/sfu/thinkgeek-promo
>> ___
>> Matplotlib-users mailing list
>> Matplotlib-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
> --
> ThinkGeek and WIRED's GeekDad team up for the Ultimate
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
> lucky parental unit.  See the prize list and enter to win:
> http://p.sf.net/sfu/thinkgeek-promo
> ___
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
>

--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] basemap broken with matplotlib 0.99.3?

2010-06-25 Thread Jeff Whitaker
On 6/25/10 12:21 PM, phob...@geosyntec.com wrote:
> Bill,
>
> Unfortunately, I don't have a solution for you. I just wanted to chime in and 
> say that I'm getting the same error. I'm on XP, py2.6, mpl0.99.3, np1.4.1, 
> sp0.8.0b1. Basemap came from the latest Windows binary on Sourceforge.
> -paul
>

Bill,Paul:  I'm pretty sure this is due to a binary incompatibilty 
between cython extensions compiled with numpy < 1.4 and numpy >= 1.4.  
The installer was probably created with numpy 1.2.1, and you  have numpy 
1.4.1.  Unfortunately, I don't have the ability to make windows 
installers, so you'll either have to compile basemap yourself on 
windows, or downgrade your numpy.

-Jeff
>
>> -Original Message-
>> From: Bill Eaton [mailto:e...@aeroantenna.com]
>> Sent: Wednesday, June 23, 2010 8:24 AM
>> To: matplotlib-users@lists.sourceforge.net
>> Subject: [Matplotlib-users] basemap broken with matplotlib 0.99.3?
>>
>> I stumbled across a basemap demo a couple of days ago and was immediately
>> enchanted.
>>
>> I can't get it to install nicely on a Windoze box with matplotlib 0.99.3.
>> When I try the famous
>>from mpl_toolkits.basemap import Basemap
>> directive, I get
>>In [1]: from mpl_toolkits.basemap import Basemap
>> -
>> --
>> ValueErrorTraceback (most recent call
>> last)
>>
>> C:\Documents and Settings\Bill.DC1\  in()
>>
>> C:\Python26\lib\site-packages\mpl_toolkits\basemap\__init__.py in
>> ()
>>   36 from matplotlib.lines import Line2D
>>   37 from matplotlib.transforms import Bbox
>> --->  38 import pyproj, sys, os, math, dbflib
>>   39 from proj import Proj
>>   40 import numpy as np
>>
>> C:\Python26\lib\site-packages\mpl_toolkits\basemap\pyproj.py in
>> ()
>>   46 CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. """
>>   47
>> --->  48 from _proj import Proj as _Proj
>>   49 from _geod import Geod as _Geod
>>   50 from _proj import _transform
>>
>> C:\Documents and Settings\Bill.DC1\c_numpy.pxd in _proj
>> (src/_proj.c:3234)()
>>
>> ValueError: numpy.dtype does not appear to be the correct type object
>>
>> I tried manually installing many of the prerequisites (which should be
>> bundled) and also reinstalling MPL. But still no joy.
>>
>> On my Linux box running 0.99.0, I was able to install basemap and run one
>> of
>> the example codes. Works quite nicely.
>>
>>
>>
>>
>> -
>> -
>> ThinkGeek and WIRED's GeekDad team up for the Ultimate
>> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
>> lucky parental unit.  See the prize list and enter to win:
>> http://p.sf.net/sfu/thinkgeek-promo
>> ___
>> Matplotlib-users mailing list
>> Matplotlib-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>>  
> --
> ThinkGeek and WIRED's GeekDad team up for the Ultimate
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
> lucky parental unit.  See the prize list and enter to win:
> http://p.sf.net/sfu/thinkgeek-promo
> ___
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>


-- 
Jeffrey S. Whitaker Phone  : (303)497-6313
Meteorologist   FAX: (303)497-6449
NOAA/OAR/PSD  R/PSD1Email  : jeffrey.s.whita...@noaa.gov
325 BroadwayOffice : Skaggs Research Cntr 1D-113
Boulder, CO, USA 80303-3328 Web: http://tinyurl.com/5telg


--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] basemap broken with matplotlib 0.99.3?

2010-06-25 Thread PHobson
Bill,

Unfortunately, I don't have a solution for you. I just wanted to chime in and 
say that I'm getting the same error. I'm on XP, py2.6, mpl0.99.3, np1.4.1, 
sp0.8.0b1. Basemap came from the latest Windows binary on Sourceforge. 
-paul

> -Original Message-
> From: Bill Eaton [mailto:e...@aeroantenna.com]
> Sent: Wednesday, June 23, 2010 8:24 AM
> To: matplotlib-users@lists.sourceforge.net
> Subject: [Matplotlib-users] basemap broken with matplotlib 0.99.3?
> 
> I stumbled across a basemap demo a couple of days ago and was immediately
> enchanted.
> 
> I can't get it to install nicely on a Windoze box with matplotlib 0.99.3.
> When I try the famous
>   from mpl_toolkits.basemap import Basemap
> directive, I get
>   In [1]: from mpl_toolkits.basemap import Basemap
> -
> --
> ValueErrorTraceback (most recent call
> last)
> 
> C:\Documents and Settings\Bill.DC1\ in ()
> 
> C:\Python26\lib\site-packages\mpl_toolkits\basemap\__init__.py in
> ()
>  36 from matplotlib.lines import Line2D
>  37 from matplotlib.transforms import Bbox
> ---> 38 import pyproj, sys, os, math, dbflib
>  39 from proj import Proj
>  40 import numpy as np
> 
> C:\Python26\lib\site-packages\mpl_toolkits\basemap\pyproj.py in
> ()
>  46 CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. """
>  47
> ---> 48 from _proj import Proj as _Proj
>  49 from _geod import Geod as _Geod
>  50 from _proj import _transform
> 
> C:\Documents and Settings\Bill.DC1\c_numpy.pxd in _proj
> (src/_proj.c:3234)()
> 
> ValueError: numpy.dtype does not appear to be the correct type object
> 
> I tried manually installing many of the prerequisites (which should be
> bundled) and also reinstalling MPL. But still no joy.
> 
> On my Linux box running 0.99.0, I was able to install basemap and run one
> of
> the example codes. Works quite nicely.
> 
> 
> 
> 
> -
> -
> ThinkGeek and WIRED's GeekDad team up for the Ultimate
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
> lucky parental unit.  See the prize list and enter to win:
> http://p.sf.net/sfu/thinkgeek-promo
> ___
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users

--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Mac OS X 10.6 dmg install

2010-06-25 Thread Tim Gray
On Jun 25, 2010 at 10:01 AM -0700, Christopher Barker wrote:
> Anyway, it's been common practice to build binaries for the python.org 
> python -- it's the way to reach the widest audience. MPL used to do this. I 
> suspect the latest binary is a mistake, but if not, it should be Clearly 
> labeled as for the ApplePython2.6-osx-10.6, and ideally, a python.org 
> compatible binary provided as well. I'm sorry I can't find the time to do 
> that myself right now.

I'll be ok for the time being.  I've been using matplotlib, scipy, and numpy 
(and variants) for the past 5 years or so on OS X.  Every time I go to 
upgrade, the recommended procedure changes.  The previous version still runs 
however, so I'll survive.

It would be useful though to make a note for whoever packages official 
releases of matplotlib for OS X to make sure they are targeting the 
python.org install of python.  numpy and scipy also do this.  It makes it a 
lot easier to push python as a Matlab/IDL replacement if potential users can 
just download four dmgs (python, numpy, scipy, and matplotlib) and it all 
just works out of the box.

Thanks for the help!

Tim

--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Mac OS X 10.6 dmg install

2010-06-25 Thread Christopher Barker
Tim Gray wrote:
> The 0.99.1.1 installer places 
> files in the appropriate location for python.org 2.6.5.  The 0.99.3 
> installer places files in the appropriate location for the OS X bundled 
> version of python (2.6.1) that we have been warned not to use.

Well, it's not the worst thing in the world to use Apple's python, but I 
still don't think that it's the best either:
   - The Apple python has never been updated
   - Anything built for it will only work on 10.6
   - you can't use py2app and get a fully self-contained binary
   - I can't remember the others.

Anyway, it's been common practice to build binaries for the python.org 
python -- it's the way to reach the widest audience. MPL used to do 
this. I suspect the latest binary is a mistake, but if not, it should be 
Clearly labeled as for the ApplePython2.6-osx-10.6, and ideally, a 
python.org compatible binary provided as well. I'm sorry I can't find 
the time to do that myself right now.

-Chris



-- 
Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R(206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115   (206) 526-6317   main reception

chris.bar...@noaa.gov

--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


[Matplotlib-users] Symbol not found

2010-06-25 Thread Ranjit Chacko
I finally somehow managed to get matplotlib to compile but now when I try to
import matplotlib.pyplot I get the following error:

Traceback (most recent call last):
  File "", line 1, in 
AttributeError: 'module' object has no attribute 'pyplot'
>>> from matplotlib import pyplot as plot
Traceback (most recent call last):
  File "", line 1, in 
  File
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/pyplot.py",
line 6, in 
from matplotlib.figure import Figure, figaspect
  File
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/figure.py",
line 18, in 
from axes import Axes, SubplotBase, subplot_class_factory
  File
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axes.py",
line 12, in 
import matplotlib.axis as maxis
  File
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/axis.py",
line 10, in 
import matplotlib.font_manager as font_manager
  File
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/font_manager.py",
line 52, in 
from matplotlib import ft2font
ImportError:
dlopen(/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so,
2): Symbol not found: _FT_Attach_File
  Referenced from:
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/ft2font.so
  Expected in: dynamic lookup

What is going wrong here?

Thanks,

-Ranjit
--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Matplotlib-users Digest, Vol 49, Issue 66

2010-06-25 Thread Ranjit Chacko
I tried compiling matplotlib following these directions and it failed on the
build step. Any idea what's going wrong here:



gcc-4.0 -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk
-fno-strict-aliasing -fno-common -dynamic -DNDEBUG -g -O3
-DPY_ARRAY_UNIQUE_SYMBOL=MPL_ARRAY_API
-I/System/Library/Frameworks/Tcl.framework/Headers
-I/System/Library/Frameworks/Tcl.framework/Versions/Current/PrivateHeaders
-I/System/Library/Frameworks/Tk.framework/Headers
-I/System/Library/Frameworks/Tk.framework/Versions/Current/PrivateHeaders
-I.
-I/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/numpy/core/include
-Isrc -Iagg24/include -I.
-I/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/numpy/core/include
-I/opt/local/include/freetype2 -I/opt/local/include -I.
-I/Library/Frameworks/Python.framework/Versions/2.6/include/python2.6 -c
CXX/cxxextensions.c -o build/temp.macosx-10.3-fat-2.6/CXX/cxxextensions.o
-framework Tcl -framework Tk
i686-apple-darwin10-gcc-4.0.1: -framework: linker input file unused because
linking not done
i686-apple-darwin10-gcc-4.0.1: Tcl: linker input file unused because linking
not done
i686-apple-darwin10-gcc-4.0.1: -framework: linker input file unused because
linking not done
i686-apple-darwin10-gcc-4.0.1: Tk: linker input file unused because linking
not done
powerpc-apple-darwin10-gcc-4.0.1: -framework: linker input file unused
because linking not done
powerpc-apple-darwin10-gcc-4.0.1: Tcl: linker input file unused because
linking not done
powerpc-apple-darwin10-gcc-4.0.1: -framework: linker input file unused
because linking not done
powerpc-apple-darwin10-gcc-4.0.1: Tk: linker input file unused because
linking not done
c++ -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk -g
-bundle -undefined dynamic_lookup
build/temp.macosx-10.3-fat-2.6/src/agg_py_transforms.o
build/temp.macosx-10.3-fat-2.6/src/_tkagg.o
build/temp.macosx-10.3-fat-2.6/CXX/cxx_extensions.o
build/temp.macosx-10.3-fat-2.6/CXX/cxxsupport.o
build/temp.macosx-10.3-fat-2.6/CXX/IndirectPythonInterface.o
build/temp.macosx-10.3-fat-2.6/CXX/cxxextensions.o -L/opt/local/lib -lstdc++
-lm -lfreetype -lz -lz -lstdc++ -lm -o
build/lib.macosx-10.3-fat-2.6/matplotlib/backends/_tkagg.so -framework Tcl
-framework Tk
ld: warning: in /opt/local/lib/libfreetype.dylib, file was built for
unsupported file format which is not the architecture being linked (ppc)
ld: warning: in /opt/local/lib/libz.dylib, file was built for unsupported
file format which is not the architecture being linked (ppc)
ld: in /opt/local/lib/libxml2.2.dylib, file was built for unsupported file
format which is not the architecture being linked (ppc) for architecture ppc
collect2: ld returned 1 exit status
ld: warning: in /opt/local/lib/libfreetype.dylib, file was built for
unsupported file format which is not the architecture being linked (i386)
ld: warning: in /opt/local/lib/libz.dylib, file was built for unsupported
file format which is not the architecture being linked (i386)
ld: in /opt/local/lib/libxml2.2.dylib, file was built for unsupported file
format which is not the architecture being linked (i386) for architecture
i386
collect2: ld returned 1 exit status
lipo: can't open input file: /var/tmp//ccuCbz2a.out (No such file or
directory)
error: command 'c++' failed with exit status 1


--
>
> Message: 1
> Date: Thu, 24 Jun 2010 20:58:37 -0400
> From: Adam J Richards 
> Subject: Re: [Matplotlib-users] Mac OS X 10.6 dmg install (Tim Gray)
> To: matplotlib-users@lists.sourceforge.net
> Message-ID: <4c23ff3d.1000...@gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> Hi Tim,
>
>  From what I gather you are trying to install everything from source the
> trying to install via the dmg.  I did a fresh install of python,
> matplotlib and a number of other packages today (on 10.6) and maybe it
> would be helpful to see how to install from source.  When installing
> Python, be sure to use --enable-framework.  I used a /usr/local prefix
> though this may be somewhere else for you.
>
> $ wget http://www.python.org/ftp/python/2.6.5/Python-2.6.5.tar.bz2
> $ tar -jxvf Python-2.6.5.tar.bz2
> $ cd Python-2.6.5
> $ ./configure --prefix=/usr/local --enable-framework
> $ make
> $ make install
>
> It appears that you have already installed numpy and so you would also
> need the following:
>
> dateutils
> $ sudo wget
> http://labix.org/download/python-dateutil/python-dateutil-1.5.tar.gz
> $ sudo tar xzf python-dateutil-1.5.tar.gz
> $ cd python-dateutil-1.5
> $ sudo /usr/local/bin/python setup.py install
>
> freetype
> $
>
> http://download.savannah.gnu.org/releases-noredirect/freetype/freetype-2.3.12.tar.gz
> $ sudo tar xzf freetype-2.3.12.tar.gz
> $ cd freetype-2.3.12
> $ sudo ./configure --prefix=/usr/local
> $ sudo make
> $ sudo make install
>
> libpng
> $ sudo wget
>
> http://sourceforge.net/projects/libpng/files/01-li

Re: [Matplotlib-users] Reverse y-axis?

2010-06-25 Thread Joe Kington
There's no single function to do it, but just reversing the current ylimits
manually is a one-liner.  ("plt" is "matplotlib.pyplot", here)

plt.ylim(plt.ylim()[::-1])

Hope that helps,
-Joe


On Fri, Jun 25, 2010 at 6:41 AM, Preben Randhol  wrote:

> Hi
>
> I need to plot some data vs depth. In stead of giving depths as
> 0,-1000,-2000, I want to give the depths as 0,1000,2000 but when plotting
> the data goes downwards (as if they had been negative). Can I get the
> y-axis to reverse so it goes downwards and not upwards?
>
>
>
>
>
> --
> ThinkGeek and WIRED's GeekDad team up for the Ultimate
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
> lucky parental unit.  See the prize list and enter to win:
> http://p.sf.net/sfu/thinkgeek-promo
> ___
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Reverse y-axis?

2010-06-25 Thread Michael Droettboom
On 06/25/2010 07:41 AM, Preben Randhol wrote:
> Hi
>
> I need to plot some data vs depth. In stead of giving depths as
> 0,-1000,-2000, I want to give the depths as 0,1000,2000 but when plotting
> the data goes downwards (as if they had been negative). Can I get the
> y-axis to reverse so it goes downwards and not upwards?
>
If using the OO interface:

axes.invert_yaxis()

or

axes.set_ylim(2000, 0) # note the larger value first

or with the pylab interface:

ylim(2000, 0)

Mike

-- 
Michael Droettboom
Science Software Branch
Space Telescope Science Institute
Baltimore, Maryland, USA


--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Mac OS X 10.6 dmg install (Tim Gray)

2010-06-25 Thread Ian Stokes-Rees


On 6/25/10 8:23 AM, Christopher Brewster wrote:
> I have followed these instructions to (almost ) the letter.
> Only difference is that python was already installed at 
> /Library/Frameworks/Python.framework/Versions/2.6/bin/python
> I also re-installed numpy.
>
> Still no good with always the same problem - the absence of numpy.core.ma

FWIW, I have had exactly this same problem, though I have not attempted
the very helpful instructions others have supplied in response to this
thread.

I am in the undesirable situation of using different Python
distributions depending on what features I require: either my "main"
copy, for most operations (some other applications I have installed will
only use this), EPD (32-bit) when I want all the bells and whistles of
EPD, and in some circumstances I opt for a customized version of Sage
Math which includes specialized packages that install easily.

Ian

--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Mac OS X 10.6 dmg install (Tim Gray)

2010-06-25 Thread Tim Gray
On Jun 24, 2010 at 09:37 PM -0700, Hana Sevcikova wrote:
> I think you just need to direct the PYTHONPATH variable to the place where 
> matplotlib is installed. My PYTHONPATH looks like this:
>
> /Library/Frameworks/Python.framework/Versions/Current/lib/python2.6/site-packages:/Library/Python/2.6/site-packages

I think that underscores the problem.  The matplotlib OS X dmg installer 
installs matplotlib in the site-packages directory for the system default 
install of Python (2.6.1).  Everywhere I read insists that on OS X you 
should install python.org's python, which puts it's site-packages in the 
location you say.  The numpy installer puts stuff in the right place.  But 
matplotlib is not there.

--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Mac OS X 10.6 dmg install

2010-06-25 Thread Tim Gray
On Jun 24, 2010 at 04:52 PM -0400, Tim Gray wrote:
> I'm updating my python install but am running into problems with 
> matplotlib,
> as always.  This time around I'd thought I'd use the .dmg installer.  I've
> already installed Python 2.6.5 from python.org and numpy from scipy.org.
> Both of these work.  I noticed the matplotlib installer wants to install to
> /Library/Python/2.6/site-packages, even though the appropriate location for
> the python.org install is in
> /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages.
> As a result, when I run python 2.6.5 from python.org, it doesn't 
> matplotlib.

To clarify, I've taken screen shots of the 0.99.3 and 0.99.1.1 dmg 
installers.  If you look in the bottom pane of the window, you will see the 
install location which you cannot change.  The 0.99.1.1 installer places 
files in the appropriate location for python.org 2.6.5.  The 0.99.3 
installer places files in the appropriate location for the OS X bundled 
version of python (2.6.1) that we have been warned not to use.



--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


[Matplotlib-users] Reverse y-axis?

2010-06-25 Thread Preben Randhol
Hi

I need to plot some data vs depth. In stead of giving depths as
0,-1000,-2000, I want to give the depths as 0,1000,2000 but when plotting
the data goes downwards (as if they had been negative). Can I get the
y-axis to reverse so it goes downwards and not upwards?




--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] Mac OS X 10.6 dmg install (Tim Gray)

2010-06-25 Thread Christopher Brewster
I have followed these instructions to (almost ) the letter.
Only difference is that python was already installed at 
/Library/Frameworks/Python.framework/Versions/2.6/bin/python
I also re-installed numpy.

Still no good with always the same problem - the absence of numpy.core.ma

Any suggestions?

Christopher





>>> from pylab import randn, hist
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/__init__.py:62:
 DeprecationWarning: the md5 module is deprecated; use hashlib instead
  import md5, os, re, shutil, sys, warnings
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/pytz/tzinfo.py:5:
 DeprecationWarning: the sets module is deprecated
  from sets import Set
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/__init__.py:606:
 UserWarning: Bad val "MacOSX" on line #31
"backend  : MacOSX
"
in file 
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/mpl-data/matplotlibrc"
Unrecognized backend string "macosx": valid strings are ['Cairo', 'GD', 
'CocoaAgg', 'GDK', 'PS', 'GTKAgg', 'GTK', 'Paint', 'QtAgg', 'Template', 'Agg2', 
'Aqt', 'FltkAgg', 'TkAgg', 'WX', 'Qt4Agg', 'EMF', 'Agg', 'SVG', 'GTKCairo', 
'WXAgg', 'Pdf']
  "%s"\n\t%s' % (val, cnt, line, fname, msg))
Traceback (most recent call last):
  File "", line 1, in 
  File 
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/pylab.py",
 line 1, in 
from matplotlib.pylab import *
  File 
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/pylab.py",
 line 206, in 
from matplotlib.numerix import npyma as ma
  File 
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/numerix/__init__.py",
 line 166, in 
__import__('ma', g, l)
  File 
"/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/matplotlib/numerix/ma/__init__.py",
 line 16, in 
from numpy.core.ma import *
ImportError: No module named ma





On 25 Jun 2010, at 01:58, Adam J Richards wrote:

> Hi Tim,
> 
> From what I gather you are trying to install everything from source the 
> trying to install via the dmg.  I did a fresh install of python, 
> matplotlib and a number of other packages today (on 10.6) and maybe it 
> would be helpful to see how to install from source.  When installing 
> Python, be sure to use --enable-framework.  I used a /usr/local prefix 
> though this may be somewhere else for you.
> 
> $ wget http://www.python.org/ftp/python/2.6.5/Python-2.6.5.tar.bz2
> $ tar -jxvf Python-2.6.5.tar.bz2
> $ cd Python-2.6.5
> $ ./configure --prefix=/usr/local --enable-framework
> $ make
> $ make install
> 
> It appears that you have already installed numpy and so you would also 
> need the following:
> 
> dateutils
> $ sudo wget 
> http://labix.org/download/python-dateutil/python-dateutil-1.5.tar.gz
> $ sudo tar xzf python-dateutil-1.5.tar.gz
> $ cd python-dateutil-1.5
> $ sudo /usr/local/bin/python setup.py install
> 
> freetype
> $ 
> http://download.savannah.gnu.org/releases-noredirect/freetype/freetype-2.3.12.tar.gz
> $ sudo tar xzf freetype-2.3.12.tar.gz
> $ cd freetype-2.3.12
> $ sudo ./configure --prefix=/usr/local
> $ sudo make
> $ sudo make install
> 
> libpng
> $ sudo wget 
> http://sourceforge.net/projects/libpng/files/01-libpng-master/1.4.2/libpng-1.4.2.tar.gz/download
> $ sudo tar xzf libpng-1.4.2.tar.gz
> $ cd libpng-1.4.2
> $ sudo ./configure --prefix=/usr/local
> $ sudo make
> $ sudo make install
> 
> pkconfig
> $ sudo wget http://pkgconfig.freedesktop.org/releases/pkg-config-0.22.tar.gz
> $ sudo tar xzf pkg-config-0.22.tar.gz
> $ cd pkg-config-0.22
> $ sudo ./configure --prefix=/usr/local
> $ sudo make
> $ sudo make install
> 
> Finally, you should be able to install matplotlib from source using,
> $ sudo wget 
> http://sourceforge.net/projects/matplotlib/files/matplotlib/matplotlib-0.99.3/matplotlib-0.99.3.tar.gz/download
> $ sudo tar xzf matplotlib-0.99.3.tar.gz
> $ cd matplotlib-0.99.3
> $ sudo /usr/local/bin/python setup.py build
> $ sudo /usr/local/bin/python setup.py install_*
> *_
> Hopefully this helps.
> 
> -Adam Richards
> 
> Duke University
> 
> --
> ThinkGeek and WIRED's GeekDad team up for the Ultimate 
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
> lucky parental unit.  See the prize list and enter to win: 
> http://p.sf.net/sfu/thinkgeek-promo
> ___
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users


--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list

[Matplotlib-users] scatter plot with discrete colorbar

2010-06-25 Thread German Ocampo
Hi

 I'm using the following code for insert a scatter plot in a figure in Qt.

vmin=min(r_time[:])
vmax=max(r_time[:])
valores=np.arange(vmin,vmax+1)
a1=self.ui.axes4.scatter(r_east,r_nort,vmin=vmin,vmax=vmax,c=r_time,edgecolors="none")
b1=self.ui.fig2.colorbar(a1,values=valores,format="%.3f",spacing="uniform")

The plot is ok and and the colors in the colorbar are ok, but for
some reason the  ticks are missing. I tried

b1=self.ui.fig2.colorbar(a1,values=valores,ticks=valores,format="%.3f",spacing="uniform")

but still the ticks doesn't appear.

How can I get the ticks in the colorbar?

Thanks

German

--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users