https://github.com/wanadev/pyguetzli
Python bindings for Google's Guetzli, a JPEG encoder that optimises JPEG compression
https://github.com/wanadev/pyguetzli
binding guetzli jpeg jpeg-encoder python
Last synced: 29 days ago
JSON representation
Python bindings for Google's Guetzli, a JPEG encoder that optimises JPEG compression
- Host: GitHub
- URL: https://github.com/wanadev/pyguetzli
- Owner: wanadev
- License: apache-2.0
- Created: 2017-05-03T17:46:37.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2025-03-17T12:42:48.000Z (about 2 months ago)
- Last Synced: 2025-03-30T07:11:12.478Z (about 1 month ago)
- Topics: binding, guetzli, jpeg, jpeg-encoder, python
- Language: C++
- Homepage: https://wanadev.github.io/pyguetzli/
- Size: 6.54 MB
- Stars: 43
- Watchers: 6
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- Contributing: docs/contributing.rst
- License: LICENSE
Awesome Lists containing this project
README
PyGuetzli
=========|Github| |Discord| |PYPI Version| |Build Status| |License|
**PyGuetzli** is a Python binding for Google’s
`Guetzli `__ library.Description of **Guetzli** from official’s repo:
Guetzli is a JPEG encoder that aims for excellent compression density
at high visual quality. Guetzli-generated images are typically 20-30%
smaller than images of equivalent quality generated by libjpeg.
Guetzli generates only sequential (nonprogressive) JPEGs due to
faster decompression speeds they offer.Documentation
-------------* `Installation `_
* `Guetzli Python Module `_
* `Using with PIL / Pillow images `_
* `Contributing / Reporting a bug `_More topics at https://wanadev.github.io/pyguetzli/
Usage Example
-------------.. code-block:: python
import pyguetzli
input_jpeg = open("./test/image.jpg", "rb").read()
optimized_jpeg = pyguetzli.process_jpeg_bytes(input_jpeg)output = open("./optimized.jpg", "wb")
output.write(optimized_jpeg)Changelog
---------* **[NEXT]** (changes on ``master`` but not released yet):
* Nothing yet ;)
* **v1.0.17:**
* misc(deps): Only pin setuptools version on required platforms (@flozz)
* **v1.0.16:**
* misc: Added Python 3.13 support (@flozz)
* misc!: Removed Python 3.8 support (@flozz)* **v1.0.15:**
* misc: Added Python 3.12 support (@flozz)
* misc!: Removed Python 3.7 support (@flozz)* **v1.0.14:**
* Guetzli: Apply a better patch to fix the crash caused by a bad access to
a vector revealed when compiled with "-D_GLIBCXX_ASSERTIONS" (David Odin)* **v1.0.13:**
* Added Python 3.11 support
* **v1.0.12:**
* Guetzli: Fixed a crash caused by a bad access to a vector revealed when
compiled with "-D_GLIBCXX_ASSERTIONS" (David Odin)* **v1.0.11:**
* ``arm64`` and ``universal2`` wheels for macOS
* ``x86`` and ``x68_64`` wheels for musl-based Linux distro (Alpine,...)
* ``win32`` wheels for Windows (``x86_64`` were already available)* **v1.0.10:** Python 3.10 support and wheels
* **v1.0.9:** Provides prebuilt wheel packages
* **v1.0.8:** Updates Guetzli and python dependencies
* **v1.0.7:** Fixes unicode issue when installing pyguetzli (#4)
* **v1.0.6:** Fixes a typo in compilator options on unix
* **v1.0.5:** Adds optimization flags when compiling Guetzli
* **v1.0.4:** MS Windows support
* **v1.0.3:** Updates Guetzli library
* **v1.0.2**: PIL Images: fixes crash with non RGB/RGBA images
(grayscale, indexed,…)
* **v1.0.1**: Adds ``--std=c++11`` flag when building Guetzli
* **v1.0.0**:* New and simpler API
* Built-in function to deal with PIL / Pillow Images
* Documentation (Sphinx)
* Guetzli update* **v0.9.0**: Initial release
.. |Github| image:: https://img.shields.io/github/stars/wanadev/pyguetzli?label=Github&logo=github
:target: https://github.com/wanadev/pyguetzli
.. |Discord| image:: https://img.shields.io/badge/chat-Discord-8c9eff?logo=discord&logoColor=ffffff
:target: https://discord.gg/BmUkEdMuFp
.. |PYPI Version| image:: https://img.shields.io/pypi/v/pyguetzli.svg
:target: https://pypi.python.org/pypi/pyguetzli
.. |Build Status| image:: https://github.com/wanadev/pyguetzli/actions/workflows/python-ci.yml/badge.svg
:target: https://github.com/wanadev/pyguetzli/actions
.. |License| image:: https://img.shields.io/pypi/l/pyguetzli.svg
:target: https://github.com/wanadev/pyguetzli/blob/master/LICENSE