Adaptive Sharpen is similar to normal sharpening but the only difference is sharpen the image more intensely around the pixels with detectable edges, and less intensely away from the edges. Hence output image is more defined and clearer than normal sharpen.
Syntax :
wand.image.adaptive_sharpen(radius, sigma, channel)Parameters :
Parameter Input Type Description radius numbers.Real size of gaussian aperture. sigma numbers.real Standard deviation of the gaussian filter. channel basestring Apply the sharpen effect on a specific channel. Optional and None by default.
Source Image:
# import Image from wand.image modulefrom wand.image import Image # Read image using Image functionwith Image(filename ="koala.jpeg") as img: # generating sharp image using adaptive_sharpen() function. img.adaptive_sharpen(radius = 8, sigma = 4) img.save(filename ="askoala.jpeg") |
Output:
Example 2:
Increasing value of radius and sigma
# import Image from wand.image modulefrom wand.image import Image # Read image using Image functionwith Image(filename ="koala.jpeg") as img: # generating sharp image using adaptive_sharpen() function. img.adaptive_sharpen(radius = 20, sigma = 10) img.save(filename ="askoala2.jpeg") |
Output:
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course. And to begin with your Machine Learning Journey, join the Machine Learning – Basic Level Course


