Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Matplotlib is a python library for data visualization. When I attempt to display a graph on the screen, I get the following error/warnings:

2012-12-21 16:40:05.532 python[9705:903] *** __NSAutoreleaseNoPool(): Object 0x103e25d80 of class NSCFArray autoreleased with no pool in place - just leaking
2012-12-21 16:40:05.534 python[9705:903] *** __NSAutoreleaseNoPool(): Object 0x103e26820 of class __NSFastEnumerationEnumerator autoreleased with no pool in place - just leaking
2012-12-21 16:40:05.535 python[9705:903] *** __NSAutoreleaseNoPool(): Object 0x103e9f080 of class NSObject autoreleased with no pool in place - just leaking

At this point the window displaying the graph remains stubbornly hidden behind all other windows, and furthermore the calling code remains frozen until one closes the display window by clicking on the close button.

FWIW, the steps that produce these results are (output omitted):

% ipython
In[1] import matplotlib.pyplot as plt
In[2] plt.plot([1, 3, 2, 4])
Out[3]: [<matplotlib.lines.Line2D at 0x106aabd90>]
In[3] plt.show()

(At this point the iPython shell becomes unresponsive.)

ALso, FWIW, I've observed exactly the same behavior with multiple styles of installation (on the same machine), including installs that use either the system-supplied python, or the one installed by homebrew, or one I install form source off my home directory.

Any ideas of what may be going on, or what I could do about it?

share|improve this question

closed as off topic by Zoredache, Ward, EEAA, Scott Pack, mdpc Dec 22 '12 at 3:01

Questions on Server Fault are expected to relate to professional server, networking, or related infrastructure administration within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

show() is a blocking call if it's running on non-interactive mode (outside ipython), so "freezing the code" may be expected behaviour. I think the way you're importing matplotlib (instead of using it directly in the shell) is making it run in non-interactive mode. Have you tried running the code in a script? –  goncalopp Dec 22 '12 at 0:14
also, I don't think serverfault is the best place to ask this. StackOverflow may be a better candidate –  goncalopp Dec 22 '12 at 0:27
add comment

Browse other questions tagged or ask your own question.