Skip to content
@elixir-image

Elixir Image

Image processing libraries for Elixir including intelligent image serving for Plug-based apps, heex components and color management.

Image processing for Elixir.

This organization hosts a family of related libraries built around the image package — a fast, memory-efficient wrapper over libvips (via vix) — together with peripheral packages for colour science, lens correction, ML-driven vision, OCR, and QR codes. The packages share conventions, work cleanly together, and each can also be used on its own.

Where to start

You want to … Reach for
Open, transform, draw on, or composite images image
Build palettes, convert between colour spaces, or work with CSS Color 4 / 5 color
Detect objects or faces, segment, classify, describe, or match images with ML image_vision
Encode or decode QR codes image_qrcode
Correct camera-lens distortion, vignetting, or chromatic aberration image_lens_correction
Run OCR over image content image_ocr
Serve images over HTTP with on-the-fly transforms image_plug (coming soon)
Render :image content in Phoenix LiveView / HEEx image_components (coming soon)

Packages

image   Hex  Docs

The flagship library. A high-level, idiomatic Elixir wrapper around libvips for image manipulation, drawing, text rendering with full Pango markup, EXIF / XMP metadata, video frame extraction (via Xav / FFmpeg), blurhash, perceptual hashing, dominant-colour and palette extraction, K-means clustering, histogram operations, and pixel-level colour management. Roughly 2–3× faster than Mogrify at ~5× less memory in resize benchmarks.

color   Hex  Docs

A comprehensive colour library with no runtime dependencies. Covers 20+ colour spaces (CIE, Oklab / Oklch, JzAzBz, ICtCp, IPT, CAM16-UCS, the standard RGB working spaces, HSL / HSV / HSLuv, CMYK, YCbCr), chromatic adaptation, ΔE difference metrics, WCAG / APCA contrast, gamut checking and CSS Color 4 perceptual gamut mapping, mixing and gradients, harmonies, colour temperature, blend modes, full CSS Color 4 / 5 parser and serialiser, an ICC matrix-profile reader, and palette generation (tonal scales, Material 3 themes, Adobe Leonardo style contrast palettes, Ström-Awn contrast-constrained scales, sort & summarize transforms, plus a Plug-based web visualizer).

Opinionated, defaults-first computer vision for :image. Answers the common "what's in this image?" questions — image classification and embeddings, object detection, face detection with landmarks, promptable and panoptic segmentation, background removal, natural-language captioning, and zero-shot label matching — with strong defaults so callers don't need ML expertise. Built on Bumblebee, Ortex, and Nx over ONNX and Hugging Face models.

Corrections for the four most common camera-lens defects — radial (barrel / pincushion) distortion, vignetting, lateral chromatic aberration, and geometric projection — driven by the Lensfun project's community-maintained calibration database (1,000+ camera bodies, 1,400+ lenses, bundled as a compact ~5 MB Erlang term file).

QR-code encoding (via Nayuki's QR-Code-generator) and decoding (via quirc) for :image. Produces and consumes Vix.Vips.Image structs directly so QR codes flow through the rest of the :image pipeline (overlay, embed, scale, recolour) without temporary files. Both encoder and decoder run on dirty CPU schedulers, with precompiled NIF artefacts for Linux (gnu/musl × x86_64/aarch64/armv7), macOS (x86_64/arm64) and Windows (x86_64).

image_ocr   Hex  Docs

Idiomatic Elixir interface to Tesseract 5 via a NIF over the C++ API. Accepts Vix.Vips.Image structs, file paths, or in-memory binaries, with auto-normalisation of pixel format before recognition. Returns plain text or per-word results with confidence and bounding boxes. Locale handling accepts ISO 639-1, BCP-47, native Tesseract codes, and +-joined combinations. Includes a NimblePool-backed pool for true parallel recognition across schedulers.

image_plug   (coming soon — not yet published)

A Plug for serving images backed by :image. Aimed at the use case of "expose a URL that returns a transformed image" — query-string-driven resize, crop, format conversion, quality, and metadata stripping — without writing per-route controller code. Designed to drop straight into a Phoenix or plain Plug pipeline.

image_components   (coming soon — not yet published)

Phoenix LiveView / HEEx components for rendering :image content in web UIs. Targets common patterns — responsive srcset, lazy loading, blurhash placeholders, art-direction with <picture> — backed by :image for the underlying transforms.

Built on

Contributing

Issues, PRs, and discussions on each package's repository are welcome. For cross-cutting design questions, open a discussion on whichever repo is most affected — there's no umbrella discussion forum.

Licence

Each package is released under the Apache-2.0 license. Bundled upstream data — Lensfun's calibration database, Tesseract trained models — is redistributed under its own licence; see the relevant package README.

Popular repositories Loading

  1. image image Public

    Image processing for Elixir

    Elixir 447 50

  2. color color Public

    Color definitions, conversions and math

    Elixir 23

  3. image_plug image_plug Public

    Image server for Plug applications for streaming image transformations

    Elixir 12 2

  4. image_vision image_vision Public

    Image object detection for Elixir using Axon and the Yolo V8 model

    Elixir 1 1

  5. image_lens_correction image_lens_correction Public

    Radial distortion and vignette correction add-on for Image

    Elixir 1

  6. vix vix Public

    Forked from akash-akya/vix

    Elixir extension for libvips

    Elixir

Repositories

Showing 10 of 13 repositories

People

This organization has no public members. You must be a member to see who’s a part of this organization.

Top languages

Loading…

Most used topics

Loading…