[AstroPy] bouncing balls problem in EPD 7.3-2

Tom Aldcroft aldcroft@head.cfa.harvard....
Sun Aug 5 08:21:52 CDT 2012

Hi Juan,

Last year the CfA Python users group talked about this issue over
lunch.  We also saw the same issues you mentioned, depending on the
platform (Mac, linux) and the GUI backend (Tk, Gtk, Qt).  Basically in
some cases issuing multiple draw() commands within a running script
would not update the plot until the script finished.  So you are not
doing anything wrong, but the simple bouncing_balls.py technique does
not work across all platforms / backends.

It looks like matplotlib (at least version 1.1) has an animation
subpackage that hopefully smooths over these differences to provide a
uniform and reliable way to animate.  See:


- Tom

On Fri, Aug 3, 2012 at 11:26 PM, Dr. Juan E Cabanela Ph.D.
<cabanela@mnstate.edu> wrote:
> Hello all,
>     I went through the Python 4 Astronomers website last summer to learn python.  At that time, I took the route of installing EPD (32-bit OSX version) on my MacBook Pro and working with that.  It went well.
>     This year, I am interested in using Python in a Computational Physics course and so I was installing EPD 7.3-2 on my Mac.  I have discovered that I now have an odd problem where the bounce.py script from
>    http://python4astronomers.github.com/contest/bounce.html
> no longer runs properly in 'ipython -pylab'.  Instead of animating the motion of the balls, the script seems to hang for a moment, then displays what appears to be the last frame of motion of the balls.  I have confirmed this behavior for EPD 7.3-2 (32-bit OSX) installed under Lion and Mountain Lion.  Was there a recent change to Python that would have propagated through EPD 7.3-2 and could be affecting these animations?
> Juan
> --
> Dr. Juan Cabanela                    218-477-2453 (V)  218-477-2290 (F)
> Minnesota State University Moorhead     WWW: http://www.cabanela.com/
> Dept. of Physics and Astronomy      Twitter: Juan_Kinda_Guy
> 1104 Seventh Ave South, Hagen 307B       IM: AstroJuanCab (AIM)
> Moorhead, MN 56563                           cabanela@mnstate.edu (MSN)
>                                              juancab@gmail.com (GTalk)
>    Public PGP Key available at: http://www.cabanela.com/juan_public.asc
> _______________________________________________
> AstroPy mailing list
> AstroPy@scipy.org
> http://mail.scipy.org/mailman/listinfo/astropy

More information about the AstroPy mailing list