Skip to main content

pixiverse

Pixiverse is a versatile image processing library designed to seamlessly handle various image formats. It includes useful utility functions for efficient image manipulation and transformation.


Installation

Install Pixiverse easily using pip:

pip install pixiverse

Main Features

1. Image Reading and Writing

Pixiverse allows users to effortlessly read from and write to diverse image formats including HEIF, AVIF, WebP, PNG, JPG, among others.

Reading Images

from pixiverse import imread

img = imread("image.heic")

Writing Images

from pixiverse import imwrite

imwrite("output.avif", img)

Supported Formats:

  • HEIF/HEIC
  • AVIF
  • WebP
  • PNG
  • JPG/JPEG
  • BMP
  • PGM

2. Image Utility Functions

Pixiverse includes a set of practical functions for creating and modifying images.

Create Blank Image

from pixiverse import from_blank

blank_img = from_blank(width=500, height=500, BGR=(255, 255, 255))

Load Image from URL

from pixiverse import from_url

img = from_url("https://example.com/image.png")

PIL Image Conversion

from pixiverse import from_pil, to_pil

pil_img = to_pil(img)
opencv_img = from_pil(pil_img)

Base64 Encoding and Decoding

from pixiverse import to_base64, from_base64

b64str = to_base64(img)
img_decoded = from_base64(b64str)

Resize Images

from pixiverse import resize

resized_img = resize(img, width=200)

Overlay Images

from pixiverse import overlay

overlay_img = overlay(bg_img, fg_img_with_alpha)

Image Padding

from pixiverse import center_pad, letterbox

padded_img = center_pad(img, width=500, height=500)
letterboxed_img = letterbox(img, value=0)

Concatenate Images

from pixiverse import hconcat, vconcat

horizontal_img = hconcat(img1, img2)
vertical_img = vconcat(img1, img2)

Edge Detection

from pixiverse import canny

edges_img = canny(img)

Usage Examples

Here is an example demonstrating image loading, resizing, and saving:

from pixiverse import imread, imwrite, resize

img = imread("input.heic")
resized_img = resize(img, width=1024)
imwrite("output.png", resized_img)

Another example illustrates fetching an image from a URL and encoding it to Base64:

from pixiverse import from_url, to_base64

img = from_url("https://example.com/photo.jpg")
b64_string = to_base64(img)

Enhance your image processing workflow effortlessly with Pixiverse.

Metadata

Release files for pixiverse 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pixiverse 0.0.1
File Size Uploaded
pixiverse-0.0.1.tar.gz 6.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pixiverse 0.0.1
File Interpreter ABI Platform
pixiverse-0.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 12.9 kB

Release files / pixiverse-0.0.1.tar.gz

Download URL pixiverse-0.0.1.tar.gz
Size 6.2 kB
Tags Source
SHA-256 checksum
How to use checksums
9ba5e130daabe85da0fffdbb499396042befb8373ea2a6bc4ab8796854382f39
BLAKE2b-256 checksum
How to use checksums
76bf1126c576be64722aec8ca49cb645116f14f9962cd71d06a5e4922cfbda51
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.2

Release files / pixiverse-0.0.1-py3-none-any.whl

Download URL pixiverse-0.0.1-py3-none-any.whl
Size 6.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f6044798600ca27cb2c9f4b3cbc97795534a06e1a467907cec3fe252b716d060
BLAKE2b-256 checksum
How to use checksums
f9c44152e0ad073749acc360b89f0a39f38c01d1cb3f33a6cefa7b5e280605e8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.2

Release history Release notifications | RSS feed

This release

0.0.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page