I'm trying to move a program over to Python, and part if this relies on a shell script where I process some images with ImageMagick. I've installed wand, the ctypes-based ImageMagick bindings for Python but I can't figure out how to get my original code translated.
Here's the command line code, which uses CONVERT and OPTIMIZE.
convert -delay $theDelay /path/to/images/$theDateStamp*.png -layers optimize -write /path/to/animationFolder/NewAnimatedGIFfile-$theDateStamp.gif -delete 1--1 -resize 200x200 /path/to/animationFolder/NewStaticGIFthumb-$theDateStamp-t.gif
Basically, the script goes to a folder where I have downloaded time-stamped images and creates an animated GIF with only those images that meet the timestamp requirement; saves it to the animation folder; then it creates a thumbnail of that animated gif by deleting the frames, resizing, and saving the single gif image to the same folder, with a "-t" addition to the name.