Introducing The Sweep: OX’s New Live Security Research Series
Register Now
Breaking: The 2026 Vulnpocalypse Hits PHP: Four Critical RCEs, but How Dangerous Are They?
Read the Report
Are you exposed? Connect your apps in minutes.
Scan your apps free

blazediff

Latest version: v8.1.2

Overview

Last scanned
27 Nov 2026
Published
27 Nov 2026
PyPI package Publisher: teimurjan
358 Stars
6 Forks
6 Versions
1.4K Downloads
Rust Repo language

Scan summary

blazediff was last scanned on 27 Nov 2026 at version 8.1.2. Risk score 0 of 100. No malicious behavior was detected.

  • Releases: 6 versions; the latest was published on 27 Nov 2026.
  • Findings: No rules fired in version 8.1.2.
  • Downloads: 1,356 downloads.

Versions

6 versions published
Versions and the rules that fired in each
VersionPublishedStatus
8.1.2 LATEST 27 Nov 2026 No rules fired
8.1.1 19 Nov 2026 No rules fired
8.1.0 16 Nov 2026 No rules fired
8.0.0 13 Nov 2026 Not shown
7.0.0 5 Nov 2026 Not shown

No rules fired in 8.1.2

Findings

Findings for v8.1.2. The score is a capped sum of the weights of the rules that fired — not CVSS, not exploitability, and not a probability. It is not comparable across packages with different scan coverage.

The score describes 8.1.2; other versions have their own rules, not their own score.

README

The publisher’s own README, as collected from the registry.

blazediff

High-performance image diffing with block-based optimization and SIMD acceleration.

Crates.io npm PyPI License: MIT

Features

  • Block-based optimization - Skip identical regions for massive speedups on similar images
  • SIMD acceleration - Native SSE4.1 (x86) and NEON (ARM) implementations
  • Multiple formats - PNG, JPEG, and QOI support, via blazediff-shared
  • Perceptual diffing - YIQ-based color difference with antialiasing detection
  • In-house PNG codec - optional blazediff_png, faster than spng on every fixture, with byte-exact decode parity; opt-in via BLAZEDIFF_PNG_ENABLED
  • Cross-platform - Linux, macOS, and Windows support
  • Multi-language - Native Rust crate, Node.js (N-API), and Python (PyO3) bindings - all sharing the same core

Installation

Rust (CLI + library)
cargo install blazediff
Node.js - @blazediff/core-native
npm install @blazediff/core-native

N-API bindings shipped as pre-built .node binaries for macOS, Linux, and Windows (arm64 + x64). Built from this crate's napi Cargo feature.

import { diff } from "@blazediff/core-native";

const result = await diff("expected.png", "actual.png", {
  output: "diff.png",
  threshold: 0.1,
});
if (result.kind === "compared" && !result.identical) {
  console.log(`${result.count} pixels differ`);
}
Python - blazediff
pip install blazediff

PyO3 bindings shipped as abi3-py38 wheels for CPython ≥ 3.8 (macOS, Linux manylinux, Windows; arm64 + x86_64). Built from this crate's python Cargo feature.

from blazediff import diff

result = diff("expected.png", "actual.png", "diff.png", threshold=0.1)
if result.kind == "compared" and not result.identical:
    print(f"{result.count} pixels differ ({result.percentage:.2f}%)")

diff(a, b, output=None, *, threshold=0.1, antialiasing=True, metric="yiq", mask=None, window=None, alpha=0.1, diff_color=None, diff_color_alt=None, aa_color=None, background="faded", compression=0, quality=90) takes file paths or encoded bytes. The result has a kind:

kind Fields
"compared" count, percentage, identical, and window (x, y, count) when window is set
"dimension-mismatch" a and b, each with width and height
"io-error" path (when known) and message

Invalid options raise ValueError.

CLI Usage

# Basic diff
blazediff image1.png image2.png -o diff.png

# With custom threshold (0.0 - 1.0)
blazediff image1.png image2.png -o diff.png -t 0.1

# pixelmatch 8 metric, a mask, and the busiest 16×16 window, as JSON
blazediff image1.png image2.png --metric oklab --mask mask.png --window 16 --json
Flag Meaning
-o, --output <path> Write the diff image (only when the images differ)
-t, --threshold <n> Color difference threshold (0-1). Default: 0.1
--antialiasing, --no-antialiasing Detect anti-aliased pixels and leave them out of the count. Default: on
--metric <yiq\|oklab> Color metric. oklab is pixelmatch 8's. Default: yiq
--mask <path> Image the size of the inputs; its non-black pixels are skipped
--window <n> Also report the N×N window with the most diff pixels
-a, --alpha <n> Opacity of the faded background. Default: 0.1
--diff-color, --diff-color-alt, --aa-color <r,g,b> Output colors
--background <faded\|transparent> What the diff image shows under the diff. Default: faded
-c, --compression <0-9>, -q, --quality <1-100> PNG and JPEG encoder settings
--json Print the result object as JSON

Exit codes: 0 identical, 1 the images differ or their dimensions do not match, 2 error. With --json, a result prints to stdout ({"kind":"compared","count":..,"percentage":..,"identical":..}, or {"kind":"dimension-mismatch","a":{..},"b":{..}}) and an error prints to stderr ({"kind":"io-error","path":..,"message":..}).

Library Usage

use blazediff::{diff, load_png, save_png, DiffOptions, DiffResult, Image, Metric};

let a = load_png("image1.png")?;
let b = load_png("image2.png")?;
let mut output = Image::new(a.width, a.height);
let options = DiffOptions {
    threshold: 0.1,
    metric: Metric::Oklab,
    window: Some(16),
    ..Default::default()
};

match diff(&a, &b, Some(&mut output), &options)? {
    DiffResult::Compared { count, window, .. } => {
        println!("Different pixels: {count}, busiest window: {window:?}");
        save_png(&output, "diff.png")?;
    }
    DiffResult::DimensionMismatch { a, b } => println!("Sizes differ: {a:?} vs {b:?}"),
}

DiffOptions holds threshold, antialiasing (default true), metric (Yiq or Oklab), mask (one byte per pixel, non-zero is skipped), window, and render (alpha, diff_color, diff_color_alt, aa_color, background). diff returns Err only for buffers that do not match their size and masks of the wrong length.

Structural similarity

This crate is a pixel diff: it answers where two images differ. For how alike they look — SSIM, MS-SSIM, Hitchhiker's SSIM — use blazediff-ssim, which stands alone and shares nothing with this crate but the blazediff-shared primitives. It is also what @blazediff/ssim-native wraps.

Interpret

Structured region analysis that produces human-readable change descriptions. It is not part of this crate: it lives in blazediff-interpret, which consumes what diff returns, with its own blazediff-interpret CLI.

The classifier is independent of whatever found the regions. Anything that can say where something changed can drive it: blazediff-ssim by thresholding a score map, or a caller passing boxes directly. Coarse boxes are fine — each is refined against the source pixels before any statistic is computed, so the analysis stays per-pixel.

See INTERPRET.md for the full algorithm documentation - pipeline stages, formulas, classification rules, and output format.

Performance

5.1-5.9x faster than odiff, 8x faster than pixelmatch on 4K images.

Image I/O lives in blazediff-shared, shared with the other crates; load_png, save_jpeg and friends are re-exported here unchanged. PNG encode uses the in-house blazediff_png codec. A diff image has few colors, so it is written as a palette PNG: the decoded pixels are the same and the file is about 4x smaller. PNG decode defaults to spng. Setting BLAZEDIFF_PNG_ENABLED=1 routes decode through blazediff_png too, which is faster than spng on every fixture.

License

MIT

OX Radar and Response Center

Find threats in your stack.

OX Radar can check high-priority threats, like critical package CVEs, against your context.

Each incident is marked Detected or Not Detected with a remediation plan and proof all tracked in the Response Center.

Where it’s listed

The probe returned only these fields for this server — auth requirement, protocol and tool list weren’t observed, so they’re not shown (never guessed).

  • pypi-releases blazediff

References

The publisher’s own links, as the registry reports them. These are not sources for the assessment on this page.

Powered by Read the latest findings

Scan your whole stack

Group 1261154050 1
Group 1261154050
 

From OX Research Newsroom

Ethersphere Hijacked With Crypto Stealing Malware (1)
npm

Ethersphere Hijacked With Crypto Stealing Malware Via Github & npm

Plug and Pray: Your AI Agents Are Taking Orders From Strangers
Research

Plug and Pray: Your AI Agents Are Taking Orders From Strangers

Vulnerability Insights

Compromised Claude Code extensions (versions 2.1.312 & 2.1.313) in Cursor try to install a backdoor

Frame 2085668439 (1)
Group 1261154229