Re: [Numpy-discussion] Drawing circles in a numpy array

2011-01-11 Thread totonixs...@gmail.com
On Mon, Jan 10, 2011 at 11:53 AM, totonixs...@gmail.com wrote: > Hi all, > > I have this problem: Given some point draw a circle centered in this > point with radius r. I'm doing that using numpy this way (Snippet code > from here [1]): > # Create the initial black and white image import

[Numpy-discussion] Drawing circles in a numpy array

2011-01-10 Thread totonixs...@gmail.com
Hi all, I have this problem: Given some point draw a circle centered in this point with radius r. I'm doing that using numpy this way (Snippet code from here [1]): >>> # Create the initial black and white image >>> import numpy as np >>> from scipy import ndimage >>> a = np.zeros((512, 512)).asty