Abdul Abdul <abdul.s...@gmail.com> Wrote in message: > I came across an example that starts as follows: > > from scipy.ndimage import filters > img = zeros(im.shape) > > What does the second line mean here? Is it setting the image pixels to zero? > What is "shape" here? >
This example is incomplete. Neither zeros nor im are defined in the python versions I have installed, and shape is an attribute of im, whatever type that is. Your example needs at least another import, probably like from numpy import zeros http://docs.scipy.org/doc/numpy/reference/generated/numpy.zeros.html But I can't guess what im might be, unless it's some numpy instance. The other thing missing from the example is the python version. -- DaveA -- https://mail.python.org/mailman/listinfo/python-list