Re: [Matplotlib-users] bug report

2015-09-17 Thread Bobby Wilkins
One more note: changing the plot type from loglog to just plot, the errors
also go away.

On Thu, Sep 17, 2015 at 11:23 PM, Bobby Wilkins 
wrote:

> I installed CPython 2.7.10, and the appropriate versions of the same
> packages, and I still get the same error:
>
--
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] bug report

2015-09-17 Thread Bobby Wilkins
I installed CPython 2.7.10, and the appropriate versions of the same
packages, and I still get the same error:

[c:\python\dev\homework1] pip list
backports.ssl-match-hostname (3.4.0.2)
certifi (2015.9.6.2)
decorator (4.0.2)
functools32 (3.2.3.post2)
ipykernel (4.0.3)
ipyparallel (4.0.2)
ipython (4.0.0)
ipython-genutils (0.1.0)
ipywidgets (4.0.2)
Jinja2 (2.8)
jsonschema (2.5.1)
jupyter (1.0.0)
jupyter-client (4.0.0)
jupyter-console (4.0.2)
jupyter-core (4.0.5)
MarkupSafe (0.23)
matplotlib (1.4.3)
mistune (0.7.1)
nbconvert (4.0.0)
nbformat (4.0.0)
notebook (4.0.4)
numpy (1.9.2)
path.py (8.1.1)
pickleshare (0.5)
Pillow (2.9.0)
pip (7.1.2)
Pygments (2.0.2)
pyparsing (2.0.3)
pyreadline (2.1)
python-dateutil (2.4.2)
pytz (2015.4)
pyzmq (14.7.0)
qtconsole (4.0.0)
scipy (0.16.0)
setuptools (18.3)
simplegeneric (0.8.1)
six (1.9.0)
tornado (4.2.1)
traitlets (4.0.0)

Note: the program does not error if last "if" in the source reads:

if (maxTerm<32)#: or ((myFigBase<4) and (maxTerm<64)):

If I change it to something like this:

if (maxTerm<32) or ((myFigBase<4) and (maxTerm<64)):

... I get the below error:

[c:\python\dev\homework1] python PHYS404-homework1-problem3-rev05.py
Traceback (most recent call last):
  File "PHYS404-homework1-problem3-rev05.py", line 196, in 
graphMyetoNegX(mySlices,myRuns,0,1,0)
  File "PHYS404-homework1-problem3-rev05.py", line 185, in graphMyetoNegX

plt.savefig(figStrName+str(myFigBase*3+3).zfill(2)+figStrExt,bbox_inches='tight')
  File "C:\Python27\lib\site-packages\matplotlib\pyplot.py", line 577, in
savefig
res = fig.savefig(*args, **kwargs)
  File "C:\Python27\lib\site-packages\matplotlib\figure.py", line 1476, in
savefig
self.canvas.print_figure(*args, **kwargs)
  File "C:\Python27\lib\site-packages\matplotlib\backend_bases.py", line
2158, in print_figure
**kwargs)
  File "C:\Python27\lib\site-packages\matplotlib\backends\backend_agg.py",
line 521, in print_png
FigureCanvasAgg.draw(self)
  File "C:\Python27\lib\site-packages\matplotlib\backends\backend_agg.py",
line 469, in draw
self.figure.draw(self.renderer)
  File "C:\Python27\lib\site-packages\matplotlib\artist.py", line 59, in
draw_wrapper
draw(artist, renderer, *args, **kwargs)
  File "C:\Python27\lib\site-packages\matplotlib\figure.py", line 1085, in
draw
func(*args)
  File "C:\Python27\lib\site-packages\matplotlib\artist.py", line 59, in
draw_wrapper
draw(artist, renderer, *args, **kwargs)
  File "C:\Python27\lib\site-packages\matplotlib\axes\_base.py", line 2110,
in draw
a.draw(renderer)
  File "C:\Python27\lib\site-packages\matplotlib\artist.py", line 59, in
draw_wrapper
draw(artist, renderer, *args, **kwargs)
  File "C:\Python27\lib\site-packages\matplotlib\text.py", line 642, in draw
ismath=ismath, mtext=mtext)
  File "C:\Python27\lib\site-packages\matplotlib\backends\backend_agg.py",
line 206, in draw_text
font.get_image(), np.round(x - xd), np.round(y + yd) + 1, angle, gc)
  File "C:\Python27\lib\site-packages\numpy\core\fromnumeric.py", line
2648, in round_
return round(decimals, out)
  File "C:\Python27\lib\site-packages\numpy\ma\core.py", line 4903, in round
result._mask = self._mask
AttributeError: 'numpy.float64' object has no attribute '_mask'

On Thu, Sep 17, 2015 at 6:46 AM, Bobby Wilkins 
wrote:

> Thank you all.
>
> I am using Python 3.4.3.
>
> I meant to include a pip list:
>
> Assimulo (2.8)
> decorator (4.0.2)
> gmpy2 (2.0.7)
> ipykernel (4.0.3)
> ipython (4.0.0)
> ipython-genutils (0.1.0)
> ipywidgets (4.0.2)
> Jinja2 (2.8)
> jsonschema (2.5.1)
> jupyter-client (4.0.0)
> jupyter-core (4.0.4)
> MarkupSafe (0.23)
> matplotlib (1.4.3)
> mistune (0.7.1)
> nbconvert (4.0.0)
> nbformat (4.0.0)
> nose (1.3.7)
> notebook (4.0.4)
> numpy (1.9.2)
> pandas (0.16.2)
> path.py (8.1)
> pickleshare (0.5)
> pip (7.1.2)
> Pygments (2.0.2)
> pyparsing (2.0.3)
> pyreadline (2.0)
> python-dateutil (2.4.2)
> pytz (2015.4)
> pyzmq (14.7.0)
> requests (2.7.0)
> scipy (0.16.0)
> setuptools (18.2)
> simplegeneric (0.8.1)
> six (1.9.0)
> sympy (0.7.6)
> testpath (0.2)
> tornado (4.2.1)
> traitlets (4.0.0)
>
> So, if the program works for Python 2.7 but not 3.4.3, maybe that is the
> problem?  Let me try to install Python 2.7 tonight and see what that does.
>
> On Wed, Sep 16, 2015 at 8:39 AM, Sterling Smith 
> wrote:
>
>> Works fine for
>>
>> {{{
>>  : python
>> Python 2.7.10 (default, Sep 15 2015, 11:26:42)
>> [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)] on darwin
>> Type "help", "copyright", "credits" or "license" for more information.
>> /Users/smithsp/.pyhistory
>> >>> import matplotlib
>> >>> matplotlib.__version__
>> '1.4.3'
>> >>> import numpy
>> >>> numpy.__version__
>> '1.9.2'
>> >>> matplotlib.get_backend()
>> u’MacOSX'
>> }}}
>>
>> All are obtained through MacPorts on OSX 10.9.5.
>>
>> -Sterling
>>
>>
>>
>> On Sep 16, 2015, at 6:50AM, Benjamin Root  wrote:
>>
>> > Btw, I can't reproduce the problem using matplotlib master, numpy
>> master and linux.

Re: [Matplotlib-users] bug report

2015-09-17 Thread Christoph Gohlke
I can reproduce the AttributeError on all Python versions and the crash 
(in Python's _tkinter.pyd extension) on Python 3.4.

As a workaround you might try to upgrade to matplotlib 1.5, which seems 
to work for me.

Christoph


On 9/17/2015 6:46 AM, Bobby Wilkins wrote:
> Thank you all.
>
> I am using Python 3.4.3.
>
> I meant to include a pip list:
>
> Assimulo (2.8)
> decorator (4.0.2)
> gmpy2 (2.0.7)
> ipykernel (4.0.3)
> ipython (4.0.0)
> ipython-genutils (0.1.0)
> ipywidgets (4.0.2)
> Jinja2 (2.8)
> jsonschema (2.5.1)
> jupyter-client (4.0.0)
> jupyter-core (4.0.4)
> MarkupSafe (0.23)
> matplotlib (1.4.3)
> mistune (0.7.1)
> nbconvert (4.0.0)
> nbformat (4.0.0)
> nose (1.3.7)
> notebook (4.0.4)
> numpy (1.9.2)
> pandas (0.16.2)
> path.py (8.1)
> pickleshare (0.5)
> pip (7.1.2)
> Pygments (2.0.2)
> pyparsing (2.0.3)
> pyreadline (2.0)
> python-dateutil (2.4.2)
> pytz (2015.4)
> pyzmq (14.7.0)
> requests (2.7.0)
> scipy (0.16.0)
> setuptools (18.2)
> simplegeneric (0.8.1)
> six (1.9.0)
> sympy (0.7.6)
> testpath (0.2)
> tornado (4.2.1)
> traitlets (4.0.0)
>
> So, if the program works for Python 2.7 but not 3.4.3, maybe that is the
> problem?  Let me try to install Python 2.7 tonight and see what that does.
>
> On Wed, Sep 16, 2015 at 8:39 AM, Sterling Smith  > wrote:
>
> Works fine for
>
> {{{
>   : python
> Python 2.7.10 (default, Sep 15 2015, 11:26:42)
> [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> /Users/smithsp/.pyhistory
> >>> import matplotlib
> >>> matplotlib.__version__
> '1.4.3'
> >>> import numpy
> >>> numpy.__version__
> '1.9.2'
> >>> matplotlib.get_backend()
> u’MacOSX'
> }}}
>
> All are obtained through MacPorts on OSX 10.9.5.
>
> -Sterling
>
>
>
> On Sep 16, 2015, at 6:50AM, Benjamin Root  > wrote:
>
> > Btw, I can't reproduce the problem using matplotlib master, numpy 
> master and linux. I know it isn't at all similar to your setup, but it is a 
> data point.
> >
> > On Wed, Sep 16, 2015 at 9:43 AM, Benjamin Root  > wrote:
> > What version of numpy do you have installed?
> >
> > On Wed, Sep 16, 2015 at 5:35 AM, Bobby Wilkins  > wrote:
> > OS: Windows 8.1 Pro
> >
> > matplotlib version: 1.4.3
> >
> > where obtained:http://www.lfd.uci.edu/~gohlke/pythonlibs/
> 
> >
> > customizations: none
> >
> > Sample Program: attached py file; this is a Physics homework problem; I 
> have the answers I need, but would like to fix the errors to be able to label 
> all lines.
> >
> > Debug output in attached output.txt file
> >
> > If you uncomment line 180, the error is reported as if it came from 
> that line even though there is no float64 on that line (savefig).  If 
> commented, it does not report a line from my .py file...
> >
> > If you make line 170 read as follows, the error goes away:
> >
> > if (maxTerm<32):
> >
> > This suggests to me that the additional labels for the 32, 64, 128, and 
> 154 term runs is what is triggering the bug, but I cannot figure out what it 
> is.
> >
> > Also, separate note, just about any time I make figures, when closing 
> the last figure I get a python.exe app crash and this message:
> >
> > alloc: invalid block: 044E7680: 0 d
> >
> >
> > Thank you for any help,
> > Bobby
> >
> >
> > 
> --
> > Monitor Your Dynamic Infrastructure at Any Scale With Datadog!
> > Get real-time metrics from all of your servers, apps and tools
> > in one place.
> > SourceForge users - Click here to start your Free Trial of Datadog now!
> >http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140
> > ___
> > Matplotlib-users mailing list
> >Matplotlib-users@lists.sourceforge.net
> 
> >https://lists.sourceforge.net/lists/listinfo/matplotlib-users
> >
> >
> >
> > 
> --
> > Monitor Your Dynamic Infrastructure at Any Scale With Datadog!
> > Get real-time metrics from all of your servers, apps and tools
> > in one place.
> > SourceForge users - Click here to start your Free Trial of Datadog now!
> 
> >http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140___
> > Matplotlib-users mailing list
> >Matplotlib-users@lists.sourceforge.net
> 
> >https://lists.sourceforge.net/l

[Matplotlib-users] How to install matplotlib for python33?

2015-09-17 Thread Zaiwen Gong

Hi,

I am trying to install matplotlib on my RedHat Linux 6.5 with Python33.

Unfortunately, 'matplotlib' rpm isn't available for python33. 
`python-matplotlib` is included only for python2.6 from Red Hat Linux 6.5.

So I try installing the latest module from matplotlib source using 'python 
easy_install'.

#*scl enable python33 'bash'*
#*easy_install -m matplotlib
*
The install finished fine, but I am still get this error when I tried to import 
matplotlib. Is there anything else that I need to config?

# scl enable python33 'python'
Python 3.3.2 (default, Mar 20 2014, 20:25:51)
[GCC 4.4.6 20120305 (Red Hat 4.4.6-4)] on linux
Type "help", "copyright", "credits" or "license" for more information.

import numpy
import scipy
import matplotlib

Traceback (most recent call last):
  File "", line 1, in 
ImportError: No module named 'matplotlib'


Below is the console when I run "easy_install -m matplotlib".
*At the end, it says "Finished processing dependencies for matplotlib". 
Does that mean matplotlib is not really installed yet?*

Do I miss any steps?

** 


Searching for matplotlib
Reading https://pypi.python.org/simple/matplotlib/
Reading http://matplotlib.org
Reading http://matplotlib.sourceforge.net
Reading http://sourceforge.net/project/showfiles.php?group_id=80706
Reading 
http://sourceforge.net/project/showfiles.php?group_id=80706&package_id=82474 

Reading 
http://sourceforge.net/projects/matplotlib/files/matplotlib/matplotlib-1.1.0/ 

Reading 
http://sourceforge.net/projects/matplotlib/files/matplotlib/matplotlib-1.1.1/ 

Reading 
https://sourceforge.net/project/showfiles.php?group_id=80706&package_id=278194 

Reading 
https://sourceforge.net/project/showfiles.php?group_id=80706&package_id=82474 

Reading 
https://sourceforge.net/projects/matplotlib/files/matplotlib/matplotlib-0.99.1/ 

Reading 
https://sourceforge.net/projects/matplotlib/files/matplotlib/matplotlib-0.99.3/ 

Reading 
https://sourceforge.net/projects/matplotlib/files/matplotlib/matplotlib-1.0
Reading 
https://sourceforge.net/projects/matplotlib/files/matplotlib/matplotlib-1.0.1/ 


Best match: matplotlib 1.4.3
Downloading 
https://pypi.python.org/packages/source/m/matplotlib/matplotlib-1.4.3.tar.gz#md5=86af2e3e3c61849ac7576a6f5ca44267 


Processing matplotlib-1.4.3.tar.gz
Writing /tmp/easy_install-uiv2i6/matplotlib-1.4.3/setup.cfg
Running matplotlib-1.4.3/setup.py -q bdist_egg --dist-dir 
/tmp/easy_install-uiv2i6/matplotlib-1.4.3/egg-dist-tmp-dn5itl
 


Edit setup.cfg to change the build options

BUILDING MATPLOTLIB
matplotlib: yes [1.4.3]
python: yes [3.3.2 (default, Mar 20 2014, 20:25:51) [GCC
4.4.6 20120305 (Red Hat 4.4.6-4)]]
  platform: yes [linux]

REQUIRED DEPENDENCIES AND EXTENSIONS
 numpy: yes [version 1.7.1]
   six: yes [The installed version of six is 1.3.0 but 
a the minimum required version is 1.4. pip/easy install will attempt to 
install a newer version.]
  dateutil: yes [dateutil was not found. It is required for 
date axis support. pip/easy_install may attempt to install it after 
matplotlib.]
  pytz: yes [pytz was not found. pip will attempt to 
install it after matplotlib.]
   tornado: yes [tornado was not found. It is required for 
the WebAgg backend. pip/easy_install may attempt to install it after 
matplotlib.]
 pyparsing: yes [pyparsing was not found. It is required 
for mathtext support. pip/easy_install may attempt to install it after 
matplotlib.]
 pycxx: yes [Official versions of PyCXX are not 
compatible with matplotlib on Python 3.x, since they lack support for 
the buffer object.  Using local copy]
libagg: yes [pkg-config information for 'libagg' could 
not be found. Using local copy.]

  freetype: yes [version 2.3.11]
   png: yes [version 1.2.49]
 qhull: yes [pkg-config information for 'qhull' could 
not be

found. Using local copy.]

OPTIONAL SUBPACKAGES
   sample_data: yes [installing]
  toolkits: yes [installing]
 tests: yes [using nose version 1.3.0 / using 
unittest.mock]
toolkits_tests: yes [using nose version 1.3.0 / using 
unittest.mock]


OPTIONAL BACKEND EXTENSIONS
macosx: no  [Mac OS-X only]
qt5agg: no  [PyQt5 not found]
qt4agg: no  [PyQt4 not found]
pyside: no  [PySide not found]
   gtk3agg: no  [Requires pygobject to be installed.]
 gtk3cairo: no  [Requires cairocffi or pycairo to be 
installed.]

gtkagg: no  [Requires pygtk]
 tkagg: no  [The C/C++ header for Tk (tk.h) could not 
be found.  You may 

Re: [Matplotlib-users] bug report

2015-09-17 Thread Bobby Wilkins
Thank you all.

I am using Python 3.4.3.

I meant to include a pip list:

Assimulo (2.8)
decorator (4.0.2)
gmpy2 (2.0.7)
ipykernel (4.0.3)
ipython (4.0.0)
ipython-genutils (0.1.0)
ipywidgets (4.0.2)
Jinja2 (2.8)
jsonschema (2.5.1)
jupyter-client (4.0.0)
jupyter-core (4.0.4)
MarkupSafe (0.23)
matplotlib (1.4.3)
mistune (0.7.1)
nbconvert (4.0.0)
nbformat (4.0.0)
nose (1.3.7)
notebook (4.0.4)
numpy (1.9.2)
pandas (0.16.2)
path.py (8.1)
pickleshare (0.5)
pip (7.1.2)
Pygments (2.0.2)
pyparsing (2.0.3)
pyreadline (2.0)
python-dateutil (2.4.2)
pytz (2015.4)
pyzmq (14.7.0)
requests (2.7.0)
scipy (0.16.0)
setuptools (18.2)
simplegeneric (0.8.1)
six (1.9.0)
sympy (0.7.6)
testpath (0.2)
tornado (4.2.1)
traitlets (4.0.0)

So, if the program works for Python 2.7 but not 3.4.3, maybe that is the
problem?  Let me try to install Python 2.7 tonight and see what that does.

On Wed, Sep 16, 2015 at 8:39 AM, Sterling Smith 
wrote:

> Works fine for
>
> {{{
>  : python
> Python 2.7.10 (default, Sep 15 2015, 11:26:42)
> [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.57)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> /Users/smithsp/.pyhistory
> >>> import matplotlib
> >>> matplotlib.__version__
> '1.4.3'
> >>> import numpy
> >>> numpy.__version__
> '1.9.2'
> >>> matplotlib.get_backend()
> u’MacOSX'
> }}}
>
> All are obtained through MacPorts on OSX 10.9.5.
>
> -Sterling
>
>
>
> On Sep 16, 2015, at 6:50AM, Benjamin Root  wrote:
>
> > Btw, I can't reproduce the problem using matplotlib master, numpy master
> and linux. I know it isn't at all similar to your setup, but it is a data
> point.
> >
> > On Wed, Sep 16, 2015 at 9:43 AM, Benjamin Root 
> wrote:
> > What version of numpy do you have installed?
> >
> > On Wed, Sep 16, 2015 at 5:35 AM, Bobby Wilkins 
> wrote:
> > OS: Windows 8.1 Pro
> >
> > matplotlib version: 1.4.3
> >
> > where obtained: http://www.lfd.uci.edu/~gohlke/pythonlibs/
> >
> > customizations: none
> >
> > Sample Program: attached py file; this is a Physics homework problem; I
> have the answers I need, but would like to fix the errors to be able to
> label all lines.
> >
> > Debug output in attached output.txt file
> >
> > If you uncomment line 180, the error is reported as if it came from that
> line even though there is no float64 on that line (savefig).  If commented,
> it does not report a line from my .py file...
> >
> > If you make line 170 read as follows, the error goes away:
> >
> > if (maxTerm<32):
> >
> > This suggests to me that the additional labels for the 32, 64, 128, and
> 154 term runs is what is triggering the bug, but I cannot figure out what
> it is.
> >
> > Also, separate note, just about any time I make figures, when closing
> the last figure I get a python.exe app crash and this message:
> >
> > alloc: invalid block: 044E7680: 0 d
> >
> >
> > Thank you for any help,
> > Bobby
> >
> >
> >
> --
> > Monitor Your Dynamic Infrastructure at Any Scale With Datadog!
> > Get real-time metrics from all of your servers, apps and tools
> > in one place.
> > SourceForge users - Click here to start your Free Trial of Datadog now!
> > http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140
> > ___
> > Matplotlib-users mailing list
> > Matplotlib-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/matplotlib-users
> >
> >
> >
> >
> --
> > Monitor Your Dynamic Infrastructure at Any Scale With Datadog!
> > Get real-time metrics from all of your servers, apps and tools
> > in one place.
> > SourceForge users - Click here to start your Free Trial of Datadog now!
> >
> http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140___
> > Matplotlib-users mailing list
> > Matplotlib-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/matplotlib-users
>
>
--
Monitor Your Dynamic Infrastructure at Any Scale With Datadog!
Get real-time metrics from all of your servers, apps and tools
in one place.
SourceForge users - Click here to start your Free Trial of Datadog now!
http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users