def soften(img): """ Soften image :param img: PIL image object :return: PIL image object """ img = img.filter(ImageFilter.SMOOTH) return img