gifing
A lightweight python tool for creating GIF
Quick start
Let's make a GIF with these images:
from gifing import GIF
path = "tests/img/image"
path_to_files = [f"{path}1.jpg", f"{path}2.jpg", f"{path}3.jpg",]
gif = GIF(
path_to_files,
frame_duration=500, # in ms
n_repeat_last_frame=3, # 500x3
)
gif.set_background_color("red")
gif.set_size((900, 700), scale=1.2)
gif.make("img/output.gif")
This package offers:
- a streamlined approach to creating GIF
- automatic image resizing
- ability to set a background color during resizing
It's a basic prototype of the functionality I envision for this tool. The API is still unstable.
Installation
Install directly via pip (requires Python >=3.9):
pip install gifing
Usage
Import the GIF class and provide a list of image file paths:
from gifing import GIF
path = "tests/img"
gif = GIF(
[f"{path}/image{i}.jpg" for i in range(1, 4)],
frame_duration=800, # Duration per frame (in milliseconds)
n_repeat_last_frame=3, # Repeat last frame 3x longer
)
You can set a background color, which is useful if your images have varying sizes:
gif.set_background_color("black")
You can also set a custom size for your GIF. The set_size method allows you to specify a target size and scale factor:
gif.set_size((300, 800), scale=2) # (600px, 1600px)
Finally, call the make() method to generate the GIF:
gif.make("path/to/output/file.gif")
If not specified, by default, the GIF will be saved as output.gif.
Metadata
Release files for gifing 0.1.1
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 |
|---|---|---|---|---|
| gifing-0.1.1.tar.gz | 5.4 MB | With provenance | Details for gifing-0.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| gifing-0.1.1-py3-none-any.whl | Python 3 | none | any | Details for gifing-0.1.1-py3-none-any.whl |
Total release size: 5.4 MB
Release files / gifing-0.1.1.tar.gz
| Download URL | gifing-0.1.1.tar.gz |
|---|---|
| Size | 5.4 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4d9aec2bd033f913c81a2cc34acd778f8ddb151cc48f6f6fb7c110508178fb5d
|
|
BLAKE2b-256 checksum How to use checksums |
990fcec460def26d663e624efb117a10478adbd01edd889d1f5e704b530db394
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
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 May 24, 2025.
Transparency logRelease files / gifing-0.1.1-py3-none-any.whl
| Download URL | gifing-0.1.1-py3-none-any.whl |
|---|---|
| Size | 5.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7eca76587dfcfc2ff449b4a56c5f663b3a389c1d67afc43aceceb4b803931c0f
|
|
BLAKE2b-256 checksum How to use checksums |
7be312bc273cbe9001c355514040a00e7842fad112f55f95737b5f691b70df3b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
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 May 24, 2025.
Transparency logSecurity for gifing 0.1.1
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 gifing-0.1.1.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 May 24, 2025.
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.