pillow-tools
A collection of useful tools for python pillow and ffmpy.
Install
pip install pillow-tools
Create a thumbnail
You can create a smaller version of an image (including .gif) while maintaining the aspect ratio.
from pillow_tools import OptimizeToSize
imagePath = '/dir/image.png'
thumbPath = OptimizeToSize(imagePath, maxWidth=1280, maxHeight=720)
# The thumbPath image is now in the same directory as imagePath.
# This will scale the image to a new resolution not exceeding the maxWidth/maxHeight but preserving the aspect ratio
print('thumbPath=', thumbPath)
Output
>>> thumbPath= '/dir/image_1280x720.png'
Metadata
Release files for pillow-tools 1.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pillow_tools-1.1.2.tar.gz | 4.1 kB | Without provenance | Details for pillow_tools-1.1.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pillow_tools-1.1.2-py3-none-any.whl | Python 3 | none | any | Details for pillow_tools-1.1.2-py3-none-any.whl |
Total release size: 8.1 kB
Release files / pillow_tools-1.1.2.tar.gz
| Download URL | pillow_tools-1.1.2.tar.gz |
|---|---|
| Size | 4.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c2ee8c724a00b16ed807b843e6b4c57634d8657a595a6eaeefc59a56cfdd602c
|
|
BLAKE2b-256 checksum How to use checksums |
d6aa481c8b6e6cd976af8b24dafdf2297b4d7418dedcb38f5e86944bc829e3e2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/46.4.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.8.2
|
Release files / pillow_tools-1.1.2-py3-none-any.whl
| Download URL | pillow_tools-1.1.2-py3-none-any.whl |
|---|---|
| Size | 4.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
95ac69fd4be605c121b6e0900c326ba43f975924e481271551047990ba1965da
|
|
BLAKE2b-256 checksum How to use checksums |
078f7d4c4a7b79a45dad62f8a4641c8e05293922ee3cbc49a4defe99538aae44
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/46.4.0 requests-toolbelt/0.9.1 tqdm/4.47.0 CPython/3.8.2
|
Security for pillow-tools 1.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.