Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
15 lines (11 sloc) 362 Bytes
from PIL import Image
import glob
for name in glob.glob('*.tif'):
im = Image.open(name)
name = str(name).rstrip(".tif")
im.save(name + '.jpg', 'JPEG')
for name in glob.glob('*.tiff'):
im = Image.open(name)
name = str(name).rstrip(".tiff")
im.save(name + '.jpg', 'JPEG')
print "Conversion from tif/tiff to jpg completed!"