squarepix
squarepix is a simple Python tool that prepares images for computer vision and deep learning projects. Instead of just resizing an image (which can stretch and distort it), squarepix first crops it evenly from the center to make it a perfect square, then resizes it smoothly. This is useful when you're building datasets for image classification, object detection, or image segmentation, where images need to be the same size without looking stretched or squished. You can process a whole folder of images with one command, or use it directly in your own Python code.
Install
pip install squarepix
Usage (command line)
squarepix "D:\InputImages" "D:\OutputImages"
squarepix "D:\InputImages" "D:\OutputImages" --size 512 512
Usage (Python)
from squarepix import process_folder
process_folder("D:/InputImages", "D:/OutputImages", output_size=(640, 640))
Supported formats
.jpg .jpeg .png .bmp .tif .tiff .webp
Metadata
Release files for squarepix 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 |
|---|---|---|---|---|
| squarepix-0.1.3.tar.gz | 4.1 kB | Without provenance | Details for squarepix-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| squarepix-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for squarepix-0.1.3-py3-none-any.whl |
Total release size: 8.8 kB
Release files / squarepix-0.1.3.tar.gz
| Download URL | squarepix-0.1.3.tar.gz |
|---|---|
| Size | 4.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f07863889df742e2f86892c1d16ec3d500453d12103250e503e198ec2ecb5f42
|
|
BLAKE2b-256 checksum How to use checksums |
3fd1135d1cc652682dc7366ee586ae013292dab9c25632765cbf4f5ccccad2ac
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.4
|
Release files / squarepix-0.1.3-py3-none-any.whl
| Download URL | squarepix-0.1.3-py3-none-any.whl |
|---|---|
| Size | 4.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a5b0274e12909fa3a24158f77d5fd8a3fcf3434b05590ea03e7c438e2ab866bb
|
|
BLAKE2b-256 checksum How to use checksums |
68023c564912576a2ce71dcdbc6c0b14cf557a553155f744fe10154385a70385
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.4
|
Security for squarepix 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.
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.