from PIL import Image

im = Image.open("ada.jpg")

new_im = Image.new("RGB", im.size)

width, height = im.size

for y in range(1, height - 1):
    for x in range(1, width - 1):
        pixel = im.getpixel((x, y))
        new_im.putpixel((width - 1 - x, y), pixel)

new_im.show()
