Python PIL | ImageOps.solarize() method Last Updated : 23 Dec, 2021 Summarize Comments Improve Suggest changes Share Like Article Like Report PIL is the Python Imaging Library which provides the python interpreter with image editing capabilities. The ImageOps module contains a number of ‘ready-made’ image processing operations. This module is somewhat experimental, and most operators only work on L and RGB images.ImageOps.solarize() Invert all pixel values above a threshold, threshold simply means image segmentation. Syntax: PIL.ImageOps.solarize(image, threshold=130) Parameters: image – The image to solarize. threshold – All pixels above this grayscale level are inverted.Returns: An image. Image Used: Python3 # Importing Image and ImageOps module from PIL package from PIL import Image, ImageOps # creating a image1 object im1 = Image.open(r"C:\Users\System-Pc\Desktop\a.JPG") # image segmentation # using threshold value = 130 # applying solarize method im2 = ImageOps.solarize(im1, threshold = 130) im2.show() Output: Comment More infoAdvertise with us Next Article Python PIL | Image.resize() method S Sunitamamgai Follow Improve Article Tags : Python Python-pil Practice Tags : python Similar Reads Python PIL | Image.resize() method PIL is the Python Imaging Library which provides the python interpreter with image editing capabilities. The Image module provides a class with the same name which is used to represent a PIL image. The module also provides a number of factory functions, including functions to load images from files, 4 min read Python PIL | Image.save() method PIL is the Python Imaging Library which provides the python interpreter with image editing capabilities. The Image module provides a class with the same name which is used to represent a PIL image. The module also provides a number of factory functions, including functions to load images from files, 3 min read Python PIL | Image.quantize() method PIL is the Python Imaging Library which provides the python interpreter with image editing capabilities. The Image module provides a class with the same name which is used to represent a PIL image. The module also provides a number of factory functions, including functions to load images from files, 1 min read Python PIL | Image.split() method PIL is the Python Imaging Library which provides the python interpreter with image editing capabilities. Image.split() method is used to split the image into individual bands. This method returns a tuple of individual image bands from an image. Splitting an âRGBâ image creates three new images each 1 min read Python PIL | Image.show() method PIL is the Python Imaging Library which provides the python interpreter with image editing capabilities. The Image module provides a class with the same name which is used to represent a PIL image. The module also provides a number of factory functions, including functions to load images from files, 1 min read Python PIL | Image.transform() method PIL is the Python Imaging Library which provides the python interpreter with image editing capabilities. The Image module provides a class with the same name which is used to represent a PIL image. The module also provides a number of factory functions, including functions to load images from files, 1 min read Like