Search code examples
pythonimagepython-3.xmetadatawand

How to remove image metadata using wand python


I use wand-py but I can't write into Image.metadata , what shoud I do?


Solution

  • use Image.strip() method:

    with Image(filename='i0.jpg') as img:
        img.strip()
        img.save(filename='i1.jpg')
    

    see more detail in the doc.