pptx_shrinker
Hey, I can't email this powerpoint!
I was told this. And turns out the issue had been that the images used were raw 4k images. Causing the pptx file to to be 20 MiB despite having only two images in the deck. That was where the idea emerged.
More recently, I encountered a 30 MiB pptx file with 10 images. Only two of the images were going to be shown full screen. The rest were already shrunk to be displayed in only a portion of the slide. Since the slides are 1920/1080, it does not benefit anyone to keep the larger files for display.
Requirements
ffmepg must be installed and accessible via PATH
What does it do?
shrink-pptx input_file.pptx where_to_save_result.pptx
Takes in input_file.pptx, opens it up (using a system temp directory), and examines each image file.
- If any are over 1920px wide, it downscales them to that resolution (keeping aspect ratio).
- If any file is now over 2 MiB, it is adjusted to have lower quality of image (same resolution)
- If that file is still over 2 MiB, it is discarded and the program iteratively downscales until the image is under 2 MiB.
- If any file is now larger then the original, the original is used.
The resulting image files are placed back the expected locations and the resulting slide deck is saved to where_to_save_result.pptx
Metadata
Release files for pptx-shrinker 0.1.3
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 |
|---|---|---|---|---|
| pptx_shrinker-0.1.3.tar.gz | 3.8 kB | With provenance | Details for pptx_shrinker-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pptx_shrinker-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for pptx_shrinker-0.1.3-py3-none-any.whl |
Total release size: 8.8 kB
Release files / pptx_shrinker-0.1.3.tar.gz
| Download URL | pptx_shrinker-0.1.3.tar.gz |
|---|---|
| Size | 3.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
35eb18ba8edee32970b0f45667261445170305e0c1c803a229ec6defbb1d454e
|
|
BLAKE2b-256 checksum How to use checksums |
b4f4995ce4e56e531291e7dc77074dbbde1251ffc82eb02aa2a4a4992a2bf933
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 28, 2026.
Transparency logRelease files / pptx_shrinker-0.1.3-py3-none-any.whl
| Download URL | pptx_shrinker-0.1.3-py3-none-any.whl |
|---|---|
| Size | 4.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
914a1a4f626184824ccb363641ce1b0e322d2d83eac7560602f8a1e65559a376
|
|
BLAKE2b-256 checksum How to use checksums |
2d9fbf8339d8558a9bbea30fc73b87bb62d4f3fb2a0fc537a00edd76b62893af
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 28, 2026.
Transparency logSecurity for pptx-shrinker 0.1.3
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.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for pptx_shrinker-0.1.3.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 28, 2026.
Transparency logA 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.