Skip to main content

pixel8

Generate pixel art from images using Canny edge detection.

Overview

pixel8 is a Python package that transforms regular images into pixel art using the Canny edge detection algorithm. It's perfect for creating stylized artwork, tattoo designs, or just having fun with image processing.

Installation

pip install pixel8

Usage

Command Line Interface

# Basic usage
pixel8 input.jpg 1.5

# Save output to file
pixel8 input.jpg 2.0 --output pixel_art.png

# Don't display the result
pixel8 input.jpg 1.5 --output result.png --no-show

Python API

import pixel8

# Generate pixel art
result = pixel8.create_pixel_line_art(
    image_path="input.jpg",
    pixelation_factor=1.5,
    output_path="output.png",
    show_result=True
)

# Use individual components
from pixel8 import gaussian_kernel, conv, gradient

# Create custom edge detection pipeline
kernel = gaussian_kernel(5, 1.2)
# ... rest of your pipeline

Parameters

  • pixelation_factor (float): Controls the pixelation threshold. Higher values = fewer pixels, more stylized result

Requirements

  • Python 3.8+
  • NumPy
  • Matplotlib
  • scikit-image
  • Pillow

Development

# Clone the repository
git clone https://github.com/yourusername/pixel8.git
cd pixel8

# Install in development mode
pip install -e .

# Install development dependencies
pip install -e .[dev]

Motivation

I stumbled across some beautiful pixel art and wanted to teach myself how to make it. I am also in the process of deciding what tattoo to get next. Thought I'd put the two together and design my next tattoo in pixel art.

License

MIT License - see LICENSE file for details.

Metadata

Release files for pixel8 1.0.0

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

Source distribution (sdist)

Source distribution for pixel8 1.0.0
File Size Uploaded Provenance
pixel8-1.0.0.tar.gz 11.7 kB Without provenance Details

Built distribution (wheel)

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

Total release size: 21.6 kB

Release files / pixel8-1.0.0.tar.gz

Download URL pixel8-1.0.0.tar.gz
Size 11.7 kB
Tags Source
SHA-256 checksum
How to use checksums
32a913781b11481a80127d80664464c16d62e2262a0a58884bbefdc4acffba6d
BLAKE2b-256 checksum
How to use checksums
63a98ffcbc9def51d40ff1666bac99e6720ca779282ac1fafacd959a26c66a9c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.8

Release files / pixel8-1.0.0-py3-none-any.whl

Download URL pixel8-1.0.0-py3-none-any.whl
Size 9.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
9c686c938d340f473dd68bb1a51abbb8ac788813a7c2a593f8e94c6e4c08dada
BLAKE2b-256 checksum
How to use checksums
107b7a6a298497992c05d47970024c8304418eeb9b2dccfa96e6c4be61e61292
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.8

Security for pixel8 1.0.0

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.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files No provenance

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