image manipulation software written in python than can:
1. find the most common pixel color and change all pixels that color to white. and then...
2. remove (make white) all groups of connected non-white pixels on a white background except for the largest (most number of pixels) group. the output should be just the largest group of non white pixels on a white backround
The software should be able to execute over all images in a file and save the output images in another file and if an error occurs automatically skip to the next image - it is preferable if the Pillow library is used for the task