__init__.py 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. """Pillow (Fork of the Python Imaging Library)
  2. Pillow is the friendly PIL fork by Jeffrey A. Clark and contributors.
  3. https://github.com/python-pillow/Pillow/
  4. Pillow is forked from PIL 1.1.7.
  5. PIL is the Python Imaging Library by Fredrik Lundh and contributors.
  6. Copyright (c) 1999 by Secret Labs AB.
  7. Use PIL.__version__ for this Pillow version.
  8. ;-)
  9. """
  10. from __future__ import annotations
  11. from . import _version
  12. # VERSION was removed in Pillow 6.0.0.
  13. # PILLOW_VERSION was removed in Pillow 9.0.0.
  14. # Use __version__ instead.
  15. __version__ = _version.__version__
  16. del _version
  17. _plugins = [
  18. "AvifImagePlugin",
  19. "BlpImagePlugin",
  20. "BmpImagePlugin",
  21. "BufrStubImagePlugin",
  22. "CurImagePlugin",
  23. "DcxImagePlugin",
  24. "DdsImagePlugin",
  25. "EpsImagePlugin",
  26. "FitsImagePlugin",
  27. "FliImagePlugin",
  28. "FpxImagePlugin",
  29. "FtexImagePlugin",
  30. "GbrImagePlugin",
  31. "GifImagePlugin",
  32. "GribStubImagePlugin",
  33. "Hdf5StubImagePlugin",
  34. "IcnsImagePlugin",
  35. "IcoImagePlugin",
  36. "ImImagePlugin",
  37. "ImtImagePlugin",
  38. "IptcImagePlugin",
  39. "JpegImagePlugin",
  40. "Jpeg2KImagePlugin",
  41. "McIdasImagePlugin",
  42. "MicImagePlugin",
  43. "MpegImagePlugin",
  44. "MpoImagePlugin",
  45. "MspImagePlugin",
  46. "PalmImagePlugin",
  47. "PcdImagePlugin",
  48. "PcxImagePlugin",
  49. "PdfImagePlugin",
  50. "PixarImagePlugin",
  51. "PngImagePlugin",
  52. "PpmImagePlugin",
  53. "PsdImagePlugin",
  54. "QoiImagePlugin",
  55. "SgiImagePlugin",
  56. "SpiderImagePlugin",
  57. "SunImagePlugin",
  58. "TgaImagePlugin",
  59. "TiffImagePlugin",
  60. "WebPImagePlugin",
  61. "WmfImagePlugin",
  62. "XbmImagePlugin",
  63. "XpmImagePlugin",
  64. "XVThumbImagePlugin",
  65. ]
  66. class UnidentifiedImageError(OSError):
  67. """
  68. Raised in :py:meth:`PIL.Image.open` if an image cannot be opened and identified.
  69. If a PNG image raises this error, setting :data:`.ImageFile.LOAD_TRUNCATED_IMAGES`
  70. to true may allow the image to be opened after all. The setting will ignore missing
  71. data and checksum failures.
  72. """
  73. pass