from PIL import Image import math src = Image.open('/opt/files/Universities/LSU/LSU v1 Artwork/png/LSU v1 Can Cooler - 12.png').convert('RGBA') W, H = src.size R = W / (2 * math.pi) cx = 648 outW = int(2 * R) out = Image.new('RGBA', (outW, H)) for ox in range(outW): x = -0.999 + 1.998 * ox / (outW - 1) s = (cx + R * math.asin(x)) % W i0 = int(s) col = src.crop((i0, 0, i0 + 1, H)) if i0 + 1 <= W else src.crop((W - 1, 0, W, H)) out.paste(col, (ox, 0)) out.save('/opt/files/imgy/lsu-all-products-parts/cc_front_art.png') print(out.size)