fix import error when using new version of Pillow