imageZIP
This is a small python package to archive (encrypt) files and directories into a single image file.
This project is made just for fun, it has no practical use, output "ZIP" image will always have the same or greater file size than it's content. Also, this is not easy-to-scan like QR codes.
Algorithm is pretty easy. If folder to zip is chosen, it will iterate through all folders and files inside it. If folder is found, it will write relative path of folder in bytes and add special folder delimiter at the end. If file is found, it will write it's relative path and name in bytes, add special file delimiter and then write all it's content in bytes with additional second file delimiter. When bytes array is ready to go, it will build an image, where individual pixels representing particular byte number.
Example
This is an "imageZIP archive", containing this whole "imageZIP" repository.
It was created with imageZIP.zip("some path/imageZIP/", scale=4).
You can actually download this image and unzip it with imageZIP.unzip("some path/demo_zip.png", scale=4), it will create "imageZIP" folder with all repository files.
How to use
To download this package, you can use pip install imageZIP.
Then go to python terminal and write import imageZIP.
Then you can use 2 available functions:
imageZIP.zip(path: str, scale: int = 1, color_mode: str = 'heat');imageZIP.unzip(path: str, scale: int = 1, color_mode: str = 'heat').
Where:
path- path (str) to a single file or whole directory to "zip", or image file to "unzip";scale* - scale (int) of input or output image file. Default:1;color_mode* - color mode (str) of input or output image file. Default:"heat".
*not necessary attributes, which can be omitted.
Notes:
- For
zipandunzipyou have to provide samescaleandcolor_modesettings; - Available
color_modes are:bw,heat,heat_toxic,rainbow,red,blue; scaleis have to beint >= 1;pathcan be absolute or relative;- If a good rectangle image can't be created, output image will be a square with some empty pixels at the end.
Metadata
Release files for imageZIP 3.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 |
|---|---|---|---|---|
| imageZIP-3.1.tar.gz | 6.2 kB | Without provenance | Details for imageZIP-3.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| imageZIP-3.1-py3-none-any.whl | Python 3 | none | any | Details for imageZIP-3.1-py3-none-any.whl |
Total release size: 12.5 kB
Release files / imageZIP-3.1.tar.gz
| Download URL | imageZIP-3.1.tar.gz |
|---|---|
| Size | 6.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6815b864ab99235ff3c88c24c868d5e0af8d29719bb3a6d379764b697818ae78
|
|
BLAKE2b-256 checksum How to use checksums |
24a3a668e54beabf241f734977c7bc9ec73059c41173caa547b5add1974f905e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.54.0 CPython/3.8.6
|
Release files / imageZIP-3.1-py3-none-any.whl
| Download URL | imageZIP-3.1-py3-none-any.whl |
|---|---|
| Size | 6.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f5304669e05ed456d24bbdd69dc837bee896fd0f48ae5c50bb8523ca1c22a929
|
|
BLAKE2b-256 checksum How to use checksums |
de26b6f75053f4e8865d20598debc0d6e09354d257608760a4daccc2ee4183f1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.6.1 requests/2.25.0 setuptools/49.2.1 requests-toolbelt/0.9.1 tqdm/4.54.0 CPython/3.8.6
|
Security for imageZIP 3.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.
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.