Image Processing with SciPy – scipy.ndimage:-


scipy.ndimage is a submodule of SciPy which is mostly used for performing an image related operation

ndimage means the "n" dimensional image.

SciPy Image Processing provides Geometrics transformation (rotate, crop, flip), image filtering (sharp and de nosing), display image, image segmentation, classification and features extraction.
MISC Package in SciPy contains prebuilt images which can be used to perform image manipulation task

from scipy import misc
from matplotlib import pyplot as plt
import numpy as np
#get face image of panda from misc package
panda = misc.face()
#plot or show image of face
plt.imshow( panda )

plt.show()



flip_down = np.flipud(misc.face())
plt.imshow(flip_down)
plt.show()
from scipy import ndimage, misc
from matplotlib import pyplot as plt
panda = misc.face()
#rotatation function of scipy for image – image rotated 135 degree
panda_rotate = ndimage.rotate(panda, 135)
plt.imshow(panda_rotate)
plt.show()

Post a Comment

If you have any doubt in programming or join online classes then you can contact us by comment .

Previous Post Next Post