Skip to content

🐍 Geometric Computer Vision Library for Spatial AI

docs+bench: auto-generated benchmark results page from checked-in JSONs, --contribute flow, llms digest (#3918)

Dmytro Mishkinbfa5a21d3301
diff --git a/.claude/skills/kornia-developer/SKILL.md b/.claude/skills/kornia-developer/SKILL.md
index c0fb44bb7..f56b96de8 100644
--- a/.claude/skills/kornia-developer/SKILL.md
+++ b/.claude/skills/kornia-developer/SKILL.md
@@ -63,6 +63,8 @@ The fix must run the **same code path** in eager and compile.
**Benchmark against every other library β€” kornia's numbers are meaningless in isolation.** Use the harnesses, don't hand-roll: `benchmarks/augmentation/flagship.py` (each library's random-transform class API, parameter sampling included: kornia eager+compiled vs torchvision v2, albumentations, OpenCV, PIL; `--json` export), `cross_library.py` (focused three-way), `pipeline.py` (end-to-end), plus `benchmarks/filters/flagship.py` and `benchmarks/geometry/flagship.py` for the functional ops. Read `benchmarks/augmentation/README.md` first β€” it documents the regimes and the standing improvement list, and it is where durable results and the honest interpretation live (update it when you move a number). Read the columns honestly and state the regime: **OpenCV / kornia-rs win CPU/uint8/single-image**, **torchvision v2 wins raw float-tensor throughput**, **kornia's regime is GPU-batched + differentiable + compiled** β€” the only one where differentiable, on-device augmentation exists at all.
+ Durable, citable numbers live in benchmarks/results/ and render at docs get-started/performance β€” refresh the llms digest with python docs/generate_benchmarks.py --refresh-llms when adding results.
+
**The moonshot is 10Γ— vs albumentations** for the augmentation package β€” frame every perf fix against that target. Today kornia trails on CPU; the levers that close then invert the gap: (a) `torch.compile` (the fix you just made β€” ~2–3Γ—), (b) a **uint8 fast path** (albumentations' whole edge is uint8 + OpenCV; kornia upcasts to float32), (c) pushing the hot op into **`kornia-rs`** (the Rust backend albumentations can't match). A compile fix that only reaches parity is a step toward 10Γ—, not the destination β€” say in the PR which lever is still on the table.
5. **Lock it in.** Add/confirm a `test_dynamo` for the op that exercises the **real path** β€” compile the full forward (`torch.compile(op, fullgraph=True)(x)` with no pre-generated `params`), not just `apply_transform` with params fed in, so parameter generation is covered too. A PR-time `dynamo` CI job now runs the compile-clean core under `inductor` on the CI torch version (`.github/workflows/pr_test_cpu.yml`), so a fullgraph regression is caught at PR time on the *real* torch β€” but locally you must still run with `KORNIA_TEST_OPTIMIZER=inductor` (the default matrix sets it empty and deselects these tests). If you add an op to a scoped-core dir, the CI job will exercise it; confirm it passes there, not only on your local torch.
diff --git a/.gitignore b/.gitignore
index 936a7d325..ac77a1bc4 100644
--- a/.gitignore
+++ b/.gitignore
@@ -21,6 +21,7 @@ kornia.egg-info/
docs/source/_static/*jpg
docs/source/_static/img/*jpg
docs/source/_static/scripts/*
+docs/source/get-started/performance.rst
*DS_Store
*jpg
diff --git a/benchmarks/README.md b/benchmarks/README.md
index 3b5181873..83105e071 100644
--- a/benchmarks/README.md
+++ b/benchmarks/README.md
@@ -89,6 +89,21 @@ One file per run:
4. Missing optional libraries must degrade to a skip note, never a crash.
5. Document the regimes in the module docstring; keep the honest framing.
+## Contributing results (any machine)
+
+1. Check out the release tag you are measuring.
+2. Quiet the machine: close other applications, mains power, let it cool. Only aggregate load
+ numbers (load average, memory) are recorded in the file - never process or app names.
+3. Run each suite with `--contribute`:
+
+ python benchmarks/augmentation/flagship.py --device cuda --contribute benchmarks/results
+
+ The run lands at `benchmarks/results/<kornia-version>/<suite>--<machine>--<device>.json`
+ (override the machine name with `--machine-slug`).
+4. Commit the file and open a PR. CI validates the schema (`benchmarks/results_schema.py`);
+ the docs page and the llms digest regenerate from it automatically at the next docs build
+ (`python docs/generate_benchmarks.py --refresh-llms` refreshes the committed digest).
+
## Sample results β€” geometry flagship ops
Directional numbers only β€” reproduce on your own hardware for anything you cite. Measured
diff --git a/benchmarks/augmentation/flagship.py b/benchmarks/augmentation/flagship.py
index c65323362..458dbc7f1 100644
--- a/benchmarks/augmentation/flagship.py
+++ b/benchmarks/augmentation/flagship.py
@@ -65,7 +65,16 @@ import numpy as np
import torch
sys.path.insert(0, str(Path(__file__).resolve().parents[1]))
-from common import run_batch_sweep, run_metadata, save_json, versions_line
+from common import (
+ add_contribute_args,
+ collect_load_metrics,
+ contribute_result,
+ print_preflight,
+ run_batch_sweep,
+ run_metadata,
+ save_json,
+ versions_line,
+)
import kornia.augmentation as KA
@@ -206,6 +215,7 @@ def main() -> None:
help="comma-separated op names to keep eager-only (workaround for faulting compiled kernels)",
)
parser.add_argument("--json", type=str, default=None, help="write machine-readable results to this path")
+ add_contribute_args(parser)
args = parser.parse_args()
skip_compile = frozenset(s.strip() for s in args.skip_compile_ops.split(",") if s.strip())
@@ -235,6 +245,9 @@ def main() -> None:
pil = None
meta = run_metadata(device)
+ meta["load"] = collect_load_metrics()
+ if args.contribute:
+ print_preflight(meta["load"])
print(f"# flagship augmentation benchmark β€” commit {meta['git_commit']} β€” {platform.platform()}")
print(versions_line(meta))
if device.type == "cuda":
@@ -262,6 +275,8 @@ def main() -> None:
if args.json:
out = save_json(args.json, meta, results)
print(f"# results written to {out}")
+ if args.contribute:
+ contribute_result(args.contribute, "augmentation", meta, results, slug_override=args.machine_slug)
if __name__ == "__main__":
diff --git a/benchmarks/common.py b/benchmarks/common.py
index 467ffa30c..d48e102c9 100644
--- a/benchmarks/common.py
+++ b/benchmarks/common.py
@@ -26,9 +26,12 @@ machine-readable JSON export so every run is comparable and citable.
from __future__ import annotations
+import argparse
import json
import math
+import os
import platform
+import re
import subprocess
import sys
from datetime import UTC, datetime
@@ -109,11 +112,14 @@ def _sanitize(obj: Any) -> Any:
def save_json(path: str | Path, metadata: dict[str, Any], results: list[dict[str, Any]]) -> Path:
- """Write one run as strict-valid JSON ``{"metadata": ..., "results": [...]}`` (non-finite β†’ null)."""
+ """Write one run as strict-valid JSON ``{"metadata": ..., "results": [...]}`` (non-finite β†’ null).
+
+ Keys are sorted so committed result files satisfy the ``pretty-format-json`` pre-commit hook.
+ """
out = Path(path)
out.parent.mkdir(parents=True, exist_ok=True)
payload = _sanitize({"metadata": metadata, "results": results})
- out.write_text(json.dumps(payload, indent=2, allow_nan=False) + "\n")
+ out.write_text(json.dumps(payload, indent=2, allow_nan=False, sort_keys=True) + "\n")
return out
@@ -123,6 +129,108 @@ def versions_line(meta: dict[str, Any]) -> str:
return "# " + ", ".join(f"{k} {meta.get(k) or '-'}" for k in keys)
+def collect_load_metrics() -> dict[str, Any]:
+ """Aggregate system-load snapshot for run metadata.
+
+ Privacy-preserving by design: numbers only (load averages, memory totals, CPU count) β€”
+ never process or application names.
+ """
+ metrics: dict[str, Any] = {
+ "load_avg_1m": None,
+ "load_avg_5m": None,
+ "load_avg_15m": None,
+ "cpu_count": os.cpu_count(),
+ "mem_total_bytes": None,
+ "mem_available_bytes": None,
+ }
+ try:
+ one, five, fifteen = os.getloadavg()
+ metrics.update(load_avg_1m=one, load_avg_5m=five, load_avg_15m=fifteen)
+ except (OSError, AttributeError):
+ pass
+ try:
+ import psutil # optional; aggregate numbers only
+
+ vm = psutil.virtual_memory()
+ metrics.update(mem_total_bytes=int(vm.total), mem_available_bytes=int(vm.available))
+ except Exception: # noqa: S110
+ pass
+ return metrics
+
+
+def machine_slug(meta: dict[str, Any], override: Optional[str] = None) -> str:
+ """Stable, human-readable machine identifier for result filenames."""
+ if override:
+ return re.sub(r"-+", "-", re.sub(r"[^a-z0-9]+", "-", override.lower())).strip("-")
+ name = meta.get("cuda_device")
+ if not name:
+ if sys.platform == "darwin":
+ try:
+ name = subprocess.check_output(
+ ["sysctl", "-n", "machdep.cpu.brand_string"], # noqa: S607
+ text=True,
+ ).strip()
+ except Exception:
+ name = None
+ elif sys.platform.startswith("linux"):
+ try:
+ for line in Path("/proc/cpuinfo").read_text().splitlines():
+ if line.lower().startswith("model name"):
+ name = line.split(":", 1)[1].strip()
+ break
+ except Exception:
+ name = None
+ if not name:
+ name = str(meta.get("machine", "unknown"))
+ return re.sub(r"-+", "-", re.sub(r"[^a-z0-9]+", "-", name.lower())).strip("-")
+
+
+def canonical_result_name(meta: dict[str, Any], suite: str, slug_override: Optional[str] = None) -> str:
+ """Filename for a contributed run: <suite>--<machine-slug>--<device-type>.json."""
+ device_type = str(meta["device"]).split(":")[0]
+ return f"{suite}--{machine_slug(meta, slug_override)}--{device_type}.json"
+
+
+def add_contribute_args(parser: argparse.ArgumentParser) -> None:
+ """CLI options shared by every flagship suite for contributing canonical result files."""
+ parser.add_argument(
+ "--contribute",
+ type=str,
+ default=None,
+ help="write this run to DIR/<kornia-version>/<suite>--<machine>--<device>.json for committing",
+ )
+ parser.add_argument(
+ "--machine-slug", type=str, default=None, help="override the auto-detected machine name in the filename"
+ )
+
+
+def print_preflight(metrics: dict[str, Any]) -> None:
+ """Measurement-hygiene notice. Advisory only; records nothing beyond aggregate numbers."""
+ print("# preflight: close other applications, use mains power, let the machine cool before contributing.")
+ load1, ncpu = metrics.get("load_avg_1m"), metrics.get("cpu_count")
+ if load1 is not None and ncpu and load1 > ncpu:
+ print(f"# preflight WARNING: load average {load1:.1f} exceeds {ncpu} CPUs - numbers will be noisy.")
+ total, avail = metrics.get("mem_total_bytes"), metrics.get("mem_available_bytes")
+ if total and avail is not None and avail < 0.1 * total:
+ print("# preflight WARNING: less than 10% memory available - numbers will be noisy.")
+
+
+def contribute_result(
+ results_dir: str | Path,
+ suite: str,
+ metadata: dict[str, Any],
+ results: list[dict[str, Any]],
+ slug_override: Optional[str] = None,
+) -> Path:
+ """Write one run under the canonical results layout and print the git line to commit it."""
+ version = str(metadata.get("kornia", "unknown"))
+ out = Path(results_dir) / version / canonical_result_name(metadata, suite, slug_override)
+ save_json(out, metadata, results)
+ print(f"# contributed: {out}")
+ print(f"# commit it with: git add {out}")
+ return out
+
+
def run_batch_sweep(
batches: list[int],
build_ops: Callable[[int], tuple[dict[str, dict[str, Optional[Callable[[], object]]]], dict[str, str]]],
diff --git a/benchmarks/common_test.py b/benchmarks/common_test.py
index 9ac3f16fa..dd8756f41 100644
--- a/benchmarks/common_test.py
+++ b/benchmarks/common_test.py
@@ -27,6 +27,7 @@ from pathlib import Path
import torch
sys.path.insert(0, str(Path(__file__).resolve().parent))
+import common
from common import git_commit, run_batch_sweep, run_metadata, save_json, time_us, versions_line
@@ -134,3 +135,60 @@ def test_run_batch_sweep_reports_warmup_failures(capsys): # 'compile' in a test
run_batch_sweep([1], build, ["fast"], row_fields=lambda b: {}, min_run_time=0.05)
assert "torch.compile warmup failed" in capsys.readouterr().out
+
+
+def test_collect_load_metrics_aggregate_only() -> None:
+ from common import collect_load_metrics
+
+ m = collect_load_metrics()
+ assert set(m) == {
+ "load_avg_1m",
+ "load_avg_5m",
+ "load_avg_15m",
+ "cpu_count",
+ "mem_total_bytes",
+ "mem_available_bytes",
+ }
+ # privacy: values are numbers or None β€” never strings that could carry process names
+ assert all(v is None or isinstance(v, (int, float)) for v in m.values())
+
+
+def test_machine_slug_prefers_cuda_device() -> None:
+ from common import machine_slug
+
+ assert machine_slug({"cuda_device": "NVIDIA GeForce RTX 4080", "machine": "x86_64"}) == ("nvidia-geforce-rtx-4080")
+
+
+def test_machine_slug_override_wins() -> None:
+ from common import machine_slug
+
+ assert machine_slug({"cuda_device": "NVIDIA L4"}, override="box-a") == "box-a"
+
+
+def test_canonical_result_name() -> None:
+ from common import canonical_result_name
+
+ meta = {"cuda_device": "NVIDIA L4", "device": "cuda:0", "machine": "x86_64"}
+ assert canonical_result_name(meta, "augmentation") == "augmentation--nvidia-l4--cuda.json"
+
+
+def test_contribute_result_writes_canonical_path(tmp_path) -> None:
+ meta = {"kornia": "0.9.0rc1", "device": "cpu", "machine": "arm64", "load": {"load_avg_1m": 1.0}}
+ out = common.contribute_result(tmp_path, "filters", meta, [{"op": "sobel", "batch": 1}], slug_override="test-box")
+ assert out == tmp_path / "0.9.0rc1" / "filters--test-box--cpu.json"
+ payload = json.loads(out.read_text())
+ assert payload["metadata"]["load"]["load_avg_1m"] == 1.0
+ assert payload["results"][0]["op"] == "sobel"
+
+
+def test_print_preflight_warns_on_high_load(capsys) -> None:
+ common.print_preflight({"load_avg_1m": 64.0, "cpu_count": 8, "mem_total_bytes": 100, "mem_available_bytes": 5})
+ outp = capsys.readouterr().out
+ assert "close other applications" in outp
+ assert "WARNING" in outp # load1 > cpu_count and available < 10% both trip it
+
+
+def test_machine_slug_override_is_slugified() -> None:
+ from common import machine_slug
+
+ assert machine_slug({"machine": "x86_64"}, override="My Box! #2") == "my-box-2"
diff --git a/benchmarks/filters/flagship.py b/benchmarks/filters/flagship.py
index 1f8767ca6..dcef7a2ff 100644
--- a/benchmarks/filters/flagship.py
+++ b/benchmarks/filters/flagship.py
@@ -61,7 +61,16 @@ import numpy as np
import torch
sys.path.insert(0, str(Path(__file__).resolve().parents[1]))
-from common import run_batch_sweep, run_metadata, save_json, versions_line
+from common import (
+ add_contribute_args,
+ collect_load_metrics,
+ contribute_result,
+ print_preflight,
+ run_batch_sweep,
+ run_metadata,
+ save_json,
+ versions_line,
+)
import kornia.filters as KF
@@ -209,6 +218,7 @@ def main() -> None:
help="comma-separated op names to keep eager-only (workaround for faulting compiled kernels)",
)
parser.add_argument("--json", type=str, default=None, help="write machine-readable results to this path")
+ add_contribute_args(parser)
args = parser.parse_args()
skip_compile = frozenset(s.strip() for s in args.skip_compile_ops.split(",") if s.strip())
@@ -238,6 +248,9 @@ def main() -> None:
pilf = None
meta = run_metadata(device)
+ meta["load"] = collect_load_metrics()
+ if args.contribute:
+ print_preflight(meta["load"])
print(f"# flagship filters benchmark β€” commit {meta['git_commit']} β€” {platform.platform()}")
print(versions_line(meta))
if device.type == "cuda":
@@ -270,6 +283,8 @@ def main() -> None:
if args.json:
out = save_json(args.json, meta, results)
print(f"# results written to {out}")
+ if args.contribute:
+ contribute_result(args.contribute, "filters", meta, results, slug_override=args.machine_slug)
if __name__ == "__main__":
diff --git a/benchmarks/geometry/flagship.py b/benchmarks/geometry/flagship.py
index e70da8dcd..e587a1530 100644
--- a/benchmarks/geometry/flagship.py
+++ b/benchmarks/geometry/flagship.py
@@ -54,7 +54,16 @@ import numpy as np
import torch
sys.path.insert(0, str(Path(__file__).resolve().parents[1]))
-from common import run_batch_sweep, run_metadata, save_json, versions_line
+from common import (
+ add_contribute_args,
+ collect_load_metrics,
+ contribute_result,
+ print_preflight,
+ run_batch_sweep,
+ run_metadata,
+ save_json,
+ versions_line,
+)
import kornia.geometry as KG
@@ -182,6 +191,7 @@ def main() -> None:
help="comma-separated op names to keep eager-only (workaround for faulting compiled kernels)",
)
parser.add_argument("--json", type=str, default=None, help="write machine-readable results to this path")
+ add_contribute_args(parser)
args = parser.parse_args()
skip_compile = frozenset(s.strip() for s in args.skip_compile_ops.split(",") if s.strip())
@@ -201,6 +211,9 @@ def main() -> None:
tvf = None
meta = run_metadata(device)
+ meta["load"] = collect_load_metrics()
+ if args.contribute:
+ print_preflight(meta["load"])
print(f"# flagship geometry benchmark β€” commit {meta['git_commit']} β€” {platform.platform()}")
print(versions_line(meta))
if device.type == "cuda":
@@ -224,6 +237,8 @@ def main() -> None:
if args.json:
out = save_json(args.json, meta, results)
print(f"# results written to {out}")
+ if args.contribute:
+ contribute_result(args.contribute, "geometry", meta, results, slug_override=args.machine_slug)
if __name__ == "__main__":
diff --git a/benchmarks/results/0.9.0rc1/augmentation--apple-m1--cpu.json b/benchmarks/results/0.9.0rc1/augmentation--apple-m1--cpu.json
new file mode 100644
index 000000000..9aaeabff7
--- /dev/null
+++ b/benchmarks/results/0.9.0rc1/augmentation--apple-m1--cpu.json
@@ -0,0 +1,953 @@
+{
+ "metadata": {
+ "albumentations": "2.0.8",
+ "device": "cpu",
+ "git_commit": "83725c6b",
+ "kornia": "0.9.0rc1",
+ "kornia_rs": "0.1.10",
+ "load": {
+ "cpu_count": 8,
+ "load_avg_15m": 3.5673828125,
+ "load_avg_1m": 2.54150390625,
+ "load_avg_5m": 3.86865234375,
+ "mem_available_bytes": null,
+ "mem_total_bytes": null
+ },
+ "machine": "arm64",
+ "numpy": "2.4.0",
+ "opencv": "5.0.0",
+ "pillow": "12.3.0",
+ "platform": "macOS-26.5.1-arm64-arm-64bit",
+ "python": "3.11.0",
+ "timestamp_utc": "2026-08-08T11:55:58+00:00",
+ "torch": "2.9.1",
+ "torch_num_threads": 4,
+ "torchvision": "0.24.1"
+ },
+ "results": [
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.3332924970891291,
+ "median_us": 37.95870799513068,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 26344.416151579222,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.22318750416161243,
+ "median_us": 29.32041700114496,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 34105.92693688327,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.027958500140812668,
+ "median_us": 7.4221670074621215,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 134731.54120550197,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.02119784985552449,
+ "median_us": 5.5385667001246475,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 180552.12731797463,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.13821743777953738,
+ "median_us": 61.03728999732995,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 16383.427246585565,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 19.1938001080417,
+ "median_us": 1205.166599538643,
+ "op": "RandomAffine",
+ "throughput_per_s": 829.7607985342574,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 44.77707443584222,
+ "median_us": 944.5791496546009,
+ "op": "RandomAffine",
+ "throughput_per_s": 1058.6725319584543,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 6.445937542594039,
+ "median_us": 138.81999999284744,
+ "op": "RandomAffine",
+ "throughput_per_s": 7203.5729725653655,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 41.91665066173296,
+ "median_us": 1213.3833995903842,
+ "op": "RandomPerspective",
+ "throughput_per_s": 824.1418172834584,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 48.72949284617789,
+ "median_us": 1587.9165002843365,
+ "op": "RandomPerspective",
+ "throughput_per_s": 629.7560355477995,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 6.34957756119546,
+ "median_us": 121.92396003229076,
+ "op": "RandomPerspective",
+ "throughput_per_s": 8201.833337230488,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 47.66699566971511,
+ "median_us": 402.4580121040344,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 2484.7312512727476,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 9.069170191651223,
+ "median_us": 223.3654199517332,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 4476.9687278186975,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.29295899730641484,
+ "median_us": 34.999791998416185,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 28571.598369648942,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 236.04198941029608,
+ "median_us": 4662.583000026643,
+ "op": "ColorJiggle",
+ "throughput_per_s": 214.47339382361358,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 89.48022441472841,
+ "median_us": 2950.9667001548223,
+ "op": "ColorJiggle",
+ "throughput_per_s": 338.8720041969755,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 28.405309967638427,
+ "median_us": 381.8499999761116,
+ "op": "ColorJiggle",
+ "throughput_per_s": 2618.8293834295137,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 100.1662494672928,
+ "median_us": 639.4999945769086,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 1563.721670805638,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 56.960425717988855,
+ "median_us": 1716.4208496978972,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 582.6076979757077,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1.4672875477117475,
+ "median_us": 157.1035449887859,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 6365.228741791793,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.6218724593054503,
+ "median_us": 88.05916499113664,
+ "op": "RandomBrightness",
+ "throughput_per_s": 11356.001389527739,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.4941699444316273,
+ "median_us": 70.87291000061668,
+ "op": "RandomBrightness",
+ "throughput_per_s": 14109.763518829674,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.2593750068626859,
+ "median_us": 31.397541504702527,
+ "op": "RandomBrightness",
+ "throughput_per_s": 31849.627457303504,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3.0214650905691087,
+ "median_us": 106.17749998345971,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 9418.191237840218,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.3127812487946333,
+ "median_us": 42.83218750060769,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 23346.92805465078,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.06462500459747232,
+ "median_us": 17.118124989792705,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 58417.61294512605,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.04170899046585093,
+ "median_us": 9.888500004308298,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 101127.57238856371,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 22.46137501788325,
+ "median_us": 62.95366700214799,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 15884.69818550649,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 11.441670067142724,
+ "median_us": 483.54082988225855,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 16544.62147891004,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 6.480000010924427,
+ "median_us": 473.931669985177,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 16880.070496766366,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 24.97614252206404,
+ "median_us": 59.66042001091409,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 134092.25075077423,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 5.67374987440416,
+ "median_us": 71.59938002587296,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 111732.81105379881,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 75.5957997171209,
+ "median_us": 570.2124995877966,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 14029.857300187481,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 121.56299635535106,
+ "median_us": 8826.771001622546,
+ "op": "RandomAffine",
+ "throughput_per_s": 906.3336976261684,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 339.16674146894366,
+ "median_us": 5742.687499150634,
+ "op": "RandomAffine",
+ "throughput_per_s": 1393.0759772638214,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 56.34995031869052,
+ "median_us": 1209.87919945037,
+ "op": "RandomAffine",
+ "throughput_per_s": 6612.230381044885,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 258.18724316195585,
+ "median_us": 9251.416500774212,
+ "op": "RandomPerspective",
+ "throughput_per_s": 864.7324438728398,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 229.83300368650816,
+ "median_us": 7940.687493828591,
+ "op": "RandomPerspective",
+ "throughput_per_s": 1007.4694421884133,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 66.07910036109392,
+ "median_us": 1121.2083001737483,
+ "op": "RandomPerspective",
+ "throughput_per_s": 7135.159451424216,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 301.3760495377939,
+ "median_us": 2171.7375500884373,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 3683.686364254385,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 179.4458003132604,
+ "median_us": 1824.2417005239986,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 4385.383799582076,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 13.45895499980541,
+ "median_us": 324.23750002635643,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 24673.27190516119,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 925.3534954041243,
+ "median_us": 45057.33300175052,
+ "op": "ColorJiggle",
+ "throughput_per_s": 177.55156523998417,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 606.9062546885107,
+ "median_us": 28341.60399652319,
+ "op": "ColorJiggle",
+ "throughput_per_s": 282.2705447786724,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 437.40415057982307,
+ "median_us": 3241.604099457618,
+ "op": "ColorJiggle",
+ "throughput_per_s": 2467.913956963021,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 30.341600358952356,
+ "median_us": 6084.074999671429,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 1314.9081824980856,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 445.2499924809672,
+ "median_us": 25650.24999785237,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 311.88779839065194,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 131.54374901205293,
+ "median_us": 1380.462499218993,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 5795.159234333465,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 26.2969006143976,
+ "median_us": 1316.281200706726,
+ "op": "RandomBrightness",
+ "throughput_per_s": 6077.728676596393,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 5.4937252571107384,
+ "median_us": 650.0167000922374,
+ "op": "RandomBrightness",
+ "throughput_per_s": 12307.376101052172,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2.21416499698537,
+ "median_us": 281.9750001071952,
+ "op": "RandomBrightness",
+ "throughput_per_s": 28371.30950246912,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 22.866700601298405,
+ "median_us": 1161.9666998740286,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 6884.878887550994,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 4.795830027433108,
+ "median_us": 307.6745900034439,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 26001.497230923276,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 25.363330059917637,
+ "median_us": 161.79500002181157,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 49445.28569437572,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 152.4387500830926,
+ "median_us": 90.03874991321936,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 88850.63384054661,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 127.89374988642521,
+ "median_us": 464.1841600823682,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 17234.538978194392,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 93.27817424491539,
+ "median_us": 3194.658349821111,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 10016.720567879154,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 36.11145002651011,
+ "median_us": 3178.12915018294,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 10068.816743384394,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 157.00834956078324,
+ "median_us": 1119.9541499081533,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 28572.59826451315,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 350.5978496832539,
+ "median_us": 949.6958497038576,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 33694.998256524465,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 80.42182380449967,
+ "median_us": 3336.045800097054,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 9592.194447411075,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 385.62399276997894,
+ "median_us": 35183.66700154729,
+ "op": "RandomAffine",
+ "throughput_per_s": 909.5129282173094,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1444.708243070636,
+ "median_us": 22754.33301110752,
+ "op": "RandomAffine",
+ "throughput_per_s": 1406.3255549779997,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 518.9267503737938,
+ "median_us": 5661.916497047059,
+ "op": "RandomAffine",
+ "throughput_per_s": 5651.796528028879,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 521.9785016379319,
+ "median_us": 37524.04199622106,
+ "op": "RandomPerspective",
+ "throughput_per_s": 852.7865948775623,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 840.3329993598163,
+ "median_us": 29317.58300110232,
+ "op": "RandomPerspective",
+ "throughput_per_s": 1091.4951617531644,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 192.831250387826,
+ "median_us": 5047.112450120039,
+ "op": "RandomPerspective",
+ "throughput_per_s": 6340.25897307656,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 4511.61449382198,
+ "median_us": 10576.145999948494,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 3025.67683919604,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1974.9165076063946,
+ "median_us": 8336.145998327993,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 3838.7043612741836,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 91.56665037153306,
+ "median_us": 1485.2083499135915,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 21545.79860924007,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 5569.125001784414,
+ "median_us": 203262.37499830313,
+ "op": "ColorJiggle",
+ "throughput_per_s": 157.43198907455027,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2170.5419931095093,
+ "median_us": 117306.12500105053,
+ "op": "ColorJiggle",
+ "throughput_per_s": 272.79052990381723,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 926.3749961974099,
+ "median_us": 14468.12500944361,
+ "op": "ColorJiggle",
+ "throughput_per_s": 2211.7586058395964,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1818.1249979534186,
+ "median_us": 28479.66700210236,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 1123.6086432344089,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 286.6045033442788,
+ "median_us": 32314.208991010673,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 990.2764449193826,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 260.45849881484173,
+ "median_us": 5987.249998725019,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 5344.690802424214,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 175.45937625982384,
+ "median_us": 5039.347949787043,
+ "op": "RandomBrightness",
+ "throughput_per_s": 6350.027884332195,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 113.2416000473313,
+ "median_us": 3459.012499661185,
+ "op": "RandomBrightness",
+ "throughput_per_s": 9251.19524810461,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 55.56039977818719,
+ "median_us": 2202.0666001481004,
+ "op": "RandomBrightness",
+ "throughput_per_s": 14531.803896325313,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 161.41044943651738,
+ "median_us": 5858.941649785265,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 5461.737274883566,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 15.933300164760979,
+ "median_us": 1324.9374998849817,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 24152.082647504452,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 420.3374002827332,
+ "median_us": 1539.641700219363,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 20784.056443418456,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 563.5958252241834,
+ "median_us": 905.6291506567504,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 35334.55165041234,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 232.5729503354524,
+ "median_us": 1708.0624995287508,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 18734.677454032688,
+ "width": 256
+ }
+ ]
+}
diff --git a/benchmarks/results/0.9.0rc1/augmentation--apple-m1--mps.json b/benchmarks/results/0.9.0rc1/augmentation--apple-m1--mps.json
new file mode 100644
index 000000000..79751c3ac
--- /dev/null
+++ b/benchmarks/results/0.9.0rc1/augmentation--apple-m1--mps.json
@@ -0,0 +1,953 @@
+{
+ "metadata": {
+ "albumentations": "2.0.8",
+ "device": "mps",
+ "git_commit": "83725c6b",
+ "kornia": "0.9.0rc1",
+ "kornia_rs": "0.1.10",
+ "load": {
+ "cpu_count": 8,
+ "load_avg_15m": 3.48974609375,
+ "load_avg_1m": 2.7998046875,
+ "load_avg_5m": 3.60009765625,
+ "mem_available_bytes": null,
+ "mem_total_bytes": null
+ },
+ "machine": "arm64",
+ "numpy": "2.4.0",
+ "opencv": "5.0.0",
+ "pillow": "12.3.0",
+ "platform": "macOS-26.5.1-arm64-arm-64bit",
+ "python": "3.11.0",
+ "timestamp_utc": "2026-08-08T11:57:32+00:00",
+ "torch": "2.9.1",
+ "torch_num_threads": 4,
+ "torchvision": "0.24.1"
+ },
+ "results": [
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 69.48998634470627,
+ "median_us": 544.2705005407333,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 1837.3216975869516,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 38.487917408929235,
+ "median_us": 499.2572899936931,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 2002.9752595352838,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.04718232521554479,
+ "median_us": 7.583041699399473,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 131873.20334519504,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.009079201481655001,
+ "median_us": 5.566035400261172,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 179661.09233747912,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.18530758097768155,
+ "median_us": 61.178335090517066,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 16345.655672395125,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2112.89599610609,
+ "median_us": 8579.354507673997,
+ "op": "RandomAffine",
+ "throughput_per_s": 116.55888553218396,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 944.7807497053873,
+ "median_us": 4141.334000451025,
+ "op": "RandomAffine",
+ "throughput_per_s": 241.46808730981175,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2.118593743944075,
+ "median_us": 140.96164600050543,
+ "op": "RandomAffine",
+ "throughput_per_s": 7094.128285054323,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1331.6357544681523,
+ "median_us": 5540.541496884543,
+ "op": "RandomPerspective",
+ "throughput_per_s": 180.48777372433756,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 163.56870073650464,
+ "median_us": 6591.53959932155,
+ "op": "RandomPerspective",
+ "throughput_per_s": 151.70962488079834,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2.4996659922180706,
+ "median_us": 122.88100000296254,
+ "op": "RandomPerspective",
+ "throughput_per_s": 8137.954606293008,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 608.1659957999364,
+ "median_us": 3058.8340014219284,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 326.92195769209457,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 38.49665998131965,
+ "median_us": 444.24416992114857,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 2251.0143468568103,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.3916249988833461,
+ "median_us": 35.18062499642838,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 28424.73662993544,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1357.3640026152134,
+ "median_us": 10963.625492877327,
+ "op": "ColorJiggle",
+ "throughput_per_s": 91.21070403669516,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 399.6660088887438,
+ "median_us": 2749.6250113472342,
+ "op": "ColorJiggle",
+ "throughput_per_s": 363.6859556751085,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2.0541650883387557,
+ "median_us": 373.42708004871383,
+ "op": "ColorJiggle",
+ "throughput_per_s": 2677.8989886581053,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 551.6657402040437,
+ "median_us": 2579.0830040932633,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 387.73470974485883,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 114.12501044105738,
+ "median_us": 1088.4170042118058,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 918.7655063549523,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1.3932375441072737,
+ "median_us": 156.768335000379,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 6378.839196050544,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 225.45617612195207,
+ "median_us": 1451.1124507407658,
+ "op": "RandomBrightness",
+ "throughput_per_s": 689.1264694817543,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 123.47728748864041,
+ "median_us": 724.7952150646597,
+ "op": "RandomBrightness",
+ "throughput_per_s": 1379.700057637369,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.24923899400164226,
+ "median_us": 31.645646005927123,
+ "op": "RandomBrightness",
+ "throughput_per_s": 31599.923724505526,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 160.68750119302422,
+ "median_us": 1152.1660053404048,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 867.9304851600376,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 32.41198257455838,
+ "median_us": 503.2181300339289,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 1987.209800911935,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.14390624346560754,
+ "median_us": 17.248771000595298,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 57975.14500977998,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.045958004193379934,
+ "median_us": 9.88916699134279,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 101120.7517150255,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.19607275680755315,
+ "median_us": 50.50762450264301,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 19798.99094141066,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 252.60375696234405,
+ "median_us": 778.6880014464259,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 10273.691112666264,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 144.56666991463857,
+ "median_us": 744.1429200116545,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 10750.623011873455,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.3131249977741436,
+ "median_us": 60.22100000700448,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 132844.02449427106,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.3736662547453281,
+ "median_us": 43.864334002137184,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 182380.51897950209,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 62.74709005083424,
+ "median_us": 549.9091699311975,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 14547.857059741209,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3113.082999334438,
+ "median_us": 17448.416503611952,
+ "op": "RandomAffine",
+ "throughput_per_s": 458.49432802936246,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 824.7079967986792,
+ "median_us": 5706.541996914893,
+ "op": "RandomAffine",
+ "throughput_per_s": 1401.8997852508594,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 54.90420080604967,
+ "median_us": 1144.7749988292344,
+ "op": "RandomAffine",
+ "throughput_per_s": 6988.272811846547,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3456.6455069580115,
+ "median_us": 14601.584000047296,
+ "op": "RandomPerspective",
+ "throughput_per_s": 547.8857636249661,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1611.1669974634424,
+ "median_us": 11652.458008029498,
+ "op": "RandomPerspective",
+ "throughput_per_s": 686.5504251967564,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 60.93750125728552,
+ "median_us": 1021.3625006144865,
+ "op": "RandomPerspective",
+ "throughput_per_s": 7832.6744864697175,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 891.7499944800511,
+ "median_us": 4438.58299695421,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 1802.3770211100393,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 27.31542001129124,
+ "median_us": 781.8991699605249,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 10231.498263905165,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 6.166664970805899,
+ "median_us": 293.56500002904795,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 27251.205011525246,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1874.3124965112656,
+ "median_us": 29425.87499273941,
+ "op": "ColorJiggle",
+ "throughput_per_s": 271.8695706405989,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 306.22850317740813,
+ "median_us": 14800.999997532926,
+ "op": "ColorJiggle",
+ "throughput_per_s": 540.5040200887415,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 64.51250083046051,
+ "median_us": 3015.449999656994,
+ "op": "ColorJiggle",
+ "throughput_per_s": 2653.0036979256815,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1384.5312532794196,
+ "median_us": 4350.353992776945,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 1838.9308119023642,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 471.9589887827169,
+ "median_us": 3440.291497099679,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 2325.384348025265,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 23.541600967291743,
+ "median_us": 1280.345898703672,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 6248.3114977756095,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 535.752100404352,
+ "median_us": 3874.6103993617,
+ "op": "RandomBrightness",
+ "throughput_per_s": 2064.723720691483,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 166.3166498474312,
+ "median_us": 1971.508300630376,
+ "op": "RandomBrightness",
+ "throughput_per_s": 4057.8069072506855,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 14.963952598918691,
+ "median_us": 257.78083501791116,
+ "op": "RandomBrightness",
+ "throughput_per_s": 31034.11469453943,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 983.7285033427179,
+ "median_us": 2295.792000950314,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 3484.6362373806082,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 36.271848875913186,
+ "median_us": 2538.8166999618984,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 3151.074278076106,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2.2064575750846602,
+ "median_us": 140.0337499944726,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 57129.0849549896,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1.8716701015364439,
+ "median_us": 89.95957992738113,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 88928.82788534486,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 6.777809976483637,
+ "median_us": 419.2339549626922,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 19082.423800123546,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 586.7069849045947,
+ "median_us": 1607.040991075337,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 19912.37322365218,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 155.90937495289845,
+ "median_us": 1486.4141699217726,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 21528.3200655199,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 22.831259993836316,
+ "median_us": 466.18791500804946,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 68641.8479969552,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 44.721672529703916,
+ "median_us": 402.9249949962832,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 79419.24774434802,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 100.96667465404582,
+ "median_us": 2322.1853996801656,
+ "op": "RandomHorizontalFlip",
+ "throughput_per_s": 13780.122812074937,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3428.1667503819335,
+ "median_us": 19345.29149730224,
+ "op": "RandomAffine",
+ "throughput_per_s": 1654.1492799145722,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1069.5204910007305,
+ "median_us": 11182.041998836212,
+ "op": "RandomAffine",
+ "throughput_per_s": 2861.7313370250668,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 71.99990068329498,
+ "median_us": 4856.062500039116,
+ "op": "RandomAffine",
+ "throughput_per_s": 6589.701018004245,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2809.187506500166,
+ "median_us": 19541.916495654732,
+ "op": "RandomPerspective",
+ "throughput_per_s": 1637.5057178816317,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 160.54785010055812,
+ "median_us": 14800.354199542198,
+ "op": "RandomPerspective",
+ "throughput_per_s": 2162.1104176675594,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 110.26772481272963,
+ "median_us": 4261.99585053837,
+ "op": "RandomPerspective",
+ "throughput_per_s": 7508.219416956448,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 990.7184830808546,
+ "median_us": 8276.14599984372,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 3866.5340124019394,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 29.547187405114425,
+ "median_us": 1771.6245849442203,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 18062.517461061045,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 28.20522568072184,
+ "median_us": 1212.9146001825575,
+ "op": "RandomResizedCrop",
+ "throughput_per_s": 26382.731311160438,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1288.5209944215603,
+ "median_us": 98807.33300815336,
+ "op": "ColorJiggle",
+ "throughput_per_s": 323.86260235725047,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 396.37524241697975,
+ "median_us": 58391.18749281624,
+ "op": "ColorJiggle",
+ "throughput_per_s": 548.0279023942936,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 122.84475815249607,
+ "median_us": 12309.312500292435,
+ "op": "ColorJiggle",
+ "throughput_per_s": 2599.6577793633696,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2129.4795005815104,
+ "median_us": 10149.541005375795,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 3152.8519351811983,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 290.3562744904775,
+ "median_us": 8471.827099856455,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 3777.225340274261,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 79.37705013318953,
+ "median_us": 5293.16669999389,
+ "op": "RandomGaussianBlur",
+ "throughput_per_s": 6045.53036276695,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3439.166259340709,
+ "median_us": 6974.978998186998,
+ "op": "RandomBrightness",
+ "throughput_per_s": 4587.827434077972,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 510.03339904127614,
+ "median_us": 3689.9124999763444,
+ "op": "RandomBrightness",
+ "throughput_per_s": 8672.29236471194,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 45.47500066109933,
+ "median_us": 1242.566600558348,
+ "op": "RandomBrightness",
+ "throughput_per_s": 25753.146741285967,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1971.792007680051,
+ "median_us": 5850.292000104673,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 5469.812446870594,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 36.71728991321271,
+ "median_us": 2801.128960054484,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 11423.965285546,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 38.30792004009707,
+ "median_us": 777.8474999940954,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 41139.169310491976,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 20.72947248962011,
+ "median_us": 404.89479499228764,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 79032.87568962088,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 27.745899569708897,
+ "median_us": 1732.1249993983656,
+ "op": "RandomGrayscale",
+ "throughput_per_s": 18474.417268450514,
+ "width": 256
+ }
+ ]
+}
diff --git a/benchmarks/results/0.9.0rc1/filters--apple-m1--cpu.json b/benchmarks/results/0.9.0rc1/filters--apple-m1--cpu.json
new file mode 100644
index 000000000..01fa9d198
--- /dev/null
+++ b/benchmarks/results/0.9.0rc1/filters--apple-m1--cpu.json
@@ -0,0 +1,656 @@
+{
+ "metadata": {
+ "albumentations": "2.0.8",
+ "device": "cpu",
+ "git_commit": "83725c6b",
+ "kornia": "0.9.0rc1",
+ "kornia_rs": "0.1.10",
+ "load": {
+ "cpu_count": 8,
+ "load_avg_15m": 3.4248046875,
+ "load_avg_1m": 2.72216796875,
+ "load_avg_5m": 3.39794921875,
+ "mem_available_bytes": null,
+ "mem_total_bytes": null
+ },
+ "machine": "arm64",
+ "numpy": "2.4.0",
+ "opencv": "5.0.0",
+ "pillow": "12.3.0",
+ "platform": "macOS-26.5.1-arm64-arm-64bit",
+ "python": "3.11.0",
+ "timestamp_utc": "2026-08-08T11:59:10+00:00",
+ "torch": "2.9.1",
+ "torch_num_threads": 4,
+ "torchvision": "0.24.1"
+ },
+ "results": [
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 17.06594011920972,
+ "median_us": 574.1322950052563,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 1741.7588397302136,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 49.144825607072605,
+ "median_us": 1798.1750002945773,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 556.1193987438263,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.5543699808185736,
+ "median_us": 160.810829984257,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 6218.486653528856,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 5.612710083369166,
+ "median_us": 84.25082996836863,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 11869.319274070567,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 11.570849528652746,
+ "median_us": 1144.2207993241027,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 873.9571947920414,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 57.9936997382902,
+ "median_us": 1029.0707999956794,
+ "op": "sobel",
+ "throughput_per_s": 971.7504373889519,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3.7836524643353684,
+ "median_us": 281.5327099960996,
+ "op": "sobel",
+ "throughput_per_s": 3551.9851317236075,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 46.10414980561468,
+ "median_us": 1816.8541006161831,
+ "op": "laplacian",
+ "throughput_per_s": 550.4019280694315,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 6.390932430804224,
+ "median_us": 285.7912499894155,
+ "op": "laplacian",
+ "throughput_per_s": 3499.057441531313,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 320.16600016504526,
+ "median_us": 80229.79099769145,
+ "op": "median_blur",
+ "throughput_per_s": 12.464197993844634,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 7.839372483431351,
+ "median_us": 135.6154149834765,
+ "op": "median_blur",
+ "throughput_per_s": 7373.79301697997,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 6.482604985649234,
+ "median_us": 128.44521006627474,
+ "op": "median_blur",
+ "throughput_per_s": 7785.420721286712,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 237.49998945277184,
+ "median_us": 48775.957999168895,
+ "op": "median_blur",
+ "throughput_per_s": 20.501903827640643,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 112.25930029468145,
+ "median_us": 1796.1582998395897,
+ "op": "box_blur",
+ "throughput_per_s": 556.743801528689,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.29958398954477,
+ "median_us": 49.62412500753999,
+ "op": "box_blur",
+ "throughput_per_s": 20151.48881412132,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.385145998734509,
+ "median_us": 44.5992919994751,
+ "op": "box_blur",
+ "throughput_per_s": 22421.8805987272,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3.972704944317257,
+ "median_us": 452.84416002687067,
+ "op": "box_blur",
+ "throughput_per_s": 2208.2652008599657,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 116.74975030473433,
+ "median_us": 13848.375005181879,
+ "op": "canny",
+ "throughput_per_s": 72.21063840528677,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 12.713120086118591,
+ "median_us": 373.4545900078956,
+ "op": "canny",
+ "throughput_per_s": 2677.7017253392387,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 210.85425760247745,
+ "median_us": 11411.625004257075,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 701.0395098871214,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 256.7490009823814,
+ "median_us": 26097.12499543093,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 306.5471771852507,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 35.41254991432639,
+ "median_us": 1352.3500005248934,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 5915.628348352813,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 48.95937563560433,
+ "median_us": 693.395849521039,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 11537.421237127357,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 74.3752570997458,
+ "median_us": 9236.95850360673,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 866.0859520886949,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 176.06250185053796,
+ "median_us": 10115.249999216758,
+ "op": "sobel",
+ "throughput_per_s": 790.8850498622827,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 51.96037491259639,
+ "median_us": 2516.968749841908,
+ "op": "sobel",
+ "throughput_per_s": 3178.4264308019256,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 318.1770007358864,
+ "median_us": 26307.958505640272,
+ "op": "laplacian",
+ "throughput_per_s": 304.0904902706475,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 392.64160150196415,
+ "median_us": 2639.954100595787,
+ "op": "laplacian",
+ "throughput_per_s": 3030.355716485583,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 172.54149861400947,
+ "median_us": 672357.3755079997,
+ "op": "median_blur",
+ "throughput_per_s": 11.898434212840455,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 80.36240033106891,
+ "median_us": 1123.2499993639067,
+ "op": "median_blur",
+ "throughput_per_s": 7122.190077480861,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 58.79064992768694,
+ "median_us": 1064.7041992342565,
+ "op": "median_blur",
+ "throughput_per_s": 7513.824032772352,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 529.4579968904145,
+ "median_us": 391607.6250025071,
+ "op": "median_blur",
+ "throughput_per_s": 20.42861141927148,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1028.3754963893443,
+ "median_us": 26113.95900021307,
+ "op": "box_blur",
+ "throughput_per_s": 306.3495657603937,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 12.803119971067618,
+ "median_us": 449.24166999408044,
+ "op": "box_blur",
+ "throughput_per_s": 17807.787065045446,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 44.610420009121285,
+ "median_us": 399.8000000137836,
+ "op": "box_blur",
+ "throughput_per_s": 20010.005001811383,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 62.78744913288401,
+ "median_us": 3673.0834006448276,
+ "op": "box_blur",
+ "throughput_per_s": 2178.0066302321266,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3253.6462458665483,
+ "median_us": 170063.29201103654,
+ "op": "canny",
+ "throughput_per_s": 47.04130977001684,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 177.9250007530207,
+ "median_us": 3154.0562005829997,
+ "op": "canny",
+ "throughput_per_s": 2536.4164400498858,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 225.12549185194075,
+ "median_us": 52574.12500213832,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 608.6644332872584,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 651.9374910567421,
+ "median_us": 32118.437004100997,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 996.3124916668306,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 526.9169960229192,
+ "median_us": 5903.39600603329,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 5420.608742374033,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 130.3270491916919,
+ "median_us": 3428.1520995136816,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 9334.474979841043,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 553.0410126084462,
+ "median_us": 40431.54200189747,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 791.4612803661613,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 829.9162509501912,
+ "median_us": 39894.583002023865,
+ "op": "sobel",
+ "throughput_per_s": 802.1139110133481,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 581.4989854115993,
+ "median_us": 10670.666000805795,
+ "op": "sobel",
+ "throughput_per_s": 2998.8756088498617,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 470.2709957200568,
+ "median_us": 31956.250008079223,
+ "op": "laplacian",
+ "throughput_per_s": 1001.3690590075405,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 437.43773494497873,
+ "median_us": 12317.89599842159,
+ "op": "laplacian",
+ "throughput_per_s": 2597.846255894713,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.0,
+ "median_us": 2865248.041009181,
+ "op": "median_blur",
+ "throughput_per_s": 11.168317556454605,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 484.85449224244803,
+ "median_us": 4918.749509670306,
+ "op": "median_blur",
+ "throughput_per_s": 6505.718564665208,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 119.77710055361985,
+ "median_us": 4617.368750041351,
+ "op": "median_blur",
+ "throughput_per_s": 6930.354002961844,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.0,
+ "median_us": 1622766.6670019971,
+ "op": "median_blur",
+ "throughput_per_s": 19.71940923529003,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1426.4574929256923,
+ "median_us": 32758.79198918119,
+ "op": "box_blur",
+ "throughput_per_s": 976.8369972423957,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 108.3041992387731,
+ "median_us": 2174.7958002379164,
+ "op": "box_blur",
+ "throughput_per_s": 14714.025103643888,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 91.67500102194018,
+ "median_us": 2081.670799816493,
+ "op": "box_blur",
+ "throughput_per_s": 15372.26731662899,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 537.9164831538219,
+ "median_us": 16656.39550628839,
+ "op": "box_blur",
+ "throughput_per_s": 1921.18396731867,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 440.9795074025169,
+ "median_us": 915891.5625012014,
+ "op": "canny",
+ "throughput_per_s": 34.938633906192386,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2401.979494607076,
+ "median_us": 16265.04200976342,
+ "op": "canny",
+ "throughput_per_s": 1967.4096126398786,
+ "width": 256
+ }
+ ]
+}
diff --git a/benchmarks/results/0.9.0rc1/filters--apple-m1--mps.json b/benchmarks/results/0.9.0rc1/filters--apple-m1--mps.json
new file mode 100644
index 000000000..1910d2ce0
--- /dev/null
+++ b/benchmarks/results/0.9.0rc1/filters--apple-m1--mps.json
@@ -0,0 +1,656 @@
+{
+ "metadata": {
+ "albumentations": "2.0.8",
+ "device": "mps",
+ "git_commit": "83725c6b",
+ "kornia": "0.9.0rc1",
+ "kornia_rs": "0.1.10",
+ "load": {
+ "cpu_count": 8,
+ "load_avg_15m": 3.474609375,
+ "load_avg_1m": 3.59912109375,
+ "load_avg_5m": 3.53955078125,
+ "mem_available_bytes": null,
+ "mem_total_bytes": null
+ },
+ "machine": "arm64",
+ "numpy": "2.4.0",
+ "opencv": "5.0.0",
+ "pillow": "12.3.0",
+ "platform": "macOS-26.5.1-arm64-arm-64bit",
+ "python": "3.11.0",
+ "timestamp_utc": "2026-08-08T12:00:27+00:00",
+ "torch": "2.9.1",
+ "torch_num_threads": 4,
+ "torchvision": "0.24.1"
+ },
+ "results": [
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 57.8339968342334,
+ "median_us": 1915.0410080328584,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 522.1820294215037,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 12.582997442223132,
+ "median_us": 801.1659956537187,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 1248.1807832895365,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 10.530010040383777,
+ "median_us": 173.80000004777685,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 5753.739929373444,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 4.5012599730398435,
+ "median_us": 81.64750004652888,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 12247.772429408433,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 51.99375045776816,
+ "median_us": 1157.716700254241,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 863.7691758099322,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 742.3017559631262,
+ "median_us": 1578.62499327166,
+ "op": "sobel",
+ "throughput_per_s": 633.4626679940785,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 4.98312503623312,
+ "median_us": 290.1691698934883,
+ "op": "sobel",
+ "throughput_per_s": 3446.265502179531,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 45.51050005829893,
+ "median_us": 750.9580027544871,
+ "op": "laplacian",
+ "throughput_per_s": 1331.6323900032169,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 16.309892416757023,
+ "median_us": 319.7947899752762,
+ "op": "laplacian",
+ "throughput_per_s": 3127.005290102792,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.0,
+ "median_us": 1683151.0420015547,
+ "op": "median_blur",
+ "throughput_per_s": 0.5941237447180193,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2.6224999965051934,
+ "median_us": 143.04289600113407,
+ "op": "median_blur",
+ "throughput_per_s": 6990.909915526821,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 8.07292497484013,
+ "median_us": 135.50520496210086,
+ "op": "median_blur",
+ "throughput_per_s": 7379.790320819689,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1145.1042482804041,
+ "median_us": 50176.54200491961,
+ "op": "median_blur",
+ "throughput_per_s": 19.929631657397874,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 48.20419853786002,
+ "median_us": 769.6500004385598,
+ "op": "box_blur",
+ "throughput_per_s": 1299.2918851818135,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 5.077802754385628,
+ "median_us": 58.076937501027714,
+ "op": "box_blur",
+ "throughput_per_s": 17218.538769925744,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2.147583014448173,
+ "median_us": 49.6594160067616,
+ "op": "box_blur",
+ "throughput_per_s": 20137.167941399886,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 21.58583010896108,
+ "median_us": 474.51207996346056,
+ "op": "box_blur",
+ "throughput_per_s": 2107.427908003953,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 357.0420012692921,
+ "median_us": 12526.416991022415,
+ "op": "canny",
+ "throughput_per_s": 79.8312878069357,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 7.418329987558575,
+ "median_us": 380.43333013774827,
+ "op": "canny",
+ "throughput_per_s": 2628.581464294723,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1153.7499958649278,
+ "median_us": 3695.916006108746,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 2164.5513552735792,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 693.1229505426016,
+ "median_us": 3552.145849971567,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 2252.159775495715,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 52.758960009668954,
+ "median_us": 1432.4366700020619,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 5584.889138581243,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 42.291625140933235,
+ "median_us": 714.8791504732799,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 11190.702644920706,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1040.5942557554226,
+ "median_us": 9800.562504096888,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 816.2796774833887,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3011.958491697442,
+ "median_us": 5221.165993134491,
+ "op": "sobel",
+ "throughput_per_s": 1532.224796246567,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 15.427910111611657,
+ "median_us": 2317.2654199879616,
+ "op": "sobel",
+ "throughput_per_s": 3452.345135345592,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1123.0937496293338,
+ "median_us": 3000.675000657793,
+ "op": "laplacian",
+ "throughput_per_s": 2666.0668010518566,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 189.99587482539928,
+ "median_us": 2687.8124997892883,
+ "op": "laplacian",
+ "throughput_per_s": 2976.398093478307,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.0,
+ "median_us": 13473142.290997203,
+ "op": "median_blur",
+ "throughput_per_s": 0.5937738819358885,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 74.89474955946207,
+ "median_us": 1142.05209974898,
+ "op": "median_blur",
+ "throughput_per_s": 7004.934364866873,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 79.48855054564787,
+ "median_us": 1091.6645507677456,
+ "op": "median_blur",
+ "throughput_per_s": 7328.258478645076,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2132.458503183443,
+ "median_us": 390550.5420116242,
+ "op": "median_blur",
+ "throughput_per_s": 20.483904487224834,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1083.1250037881546,
+ "median_us": 2907.6250066282228,
+ "op": "box_blur",
+ "throughput_per_s": 2751.386434551635,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 38.0590624990873,
+ "median_us": 461.51791502779815,
+ "op": "box_blur",
+ "throughput_per_s": 17334.105003308796,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 19.082910002907735,
+ "median_us": 411.80833999533206,
+ "op": "box_blur",
+ "throughput_per_s": 19426.512828979332,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 267.34580023912713,
+ "median_us": 3727.07910137251,
+ "op": "box_blur",
+ "throughput_per_s": 2146.452968238311,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 8512.02049307176,
+ "median_us": 46325.43799380073,
+ "op": "canny",
+ "throughput_per_s": 172.69129762077068,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 68.02290008636226,
+ "median_us": 3292.5000006798655,
+ "op": "canny",
+ "throughput_per_s": 2429.7646160510517,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2325.208992260741,
+ "median_us": 9689.895996416453,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 3302.40902604469,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1228.5792006878194,
+ "median_us": 8396.050000737887,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 3811.316035181744,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 373.24026197893545,
+ "median_us": 6247.750003240071,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 5121.8438611347865,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 44.81670039240254,
+ "median_us": 2735.579200088978,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 11697.70555316372,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2904.0730005363002,
+ "median_us": 38491.312006954104,
+ "op": "gaussian_blur2d",
+ "throughput_per_s": 831.356436855638,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 662.1772517974023,
+ "median_us": 11775.333507102914,
+ "op": "sobel",
+ "throughput_per_s": 2717.5451107773306,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 365.08955090539496,
+ "median_us": 9374.054099316709,
+ "op": "sobel",
+ "throughput_per_s": 3413.6777600134114,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 4420.207744260551,
+ "median_us": 4498.875503486488,
+ "op": "laplacian",
+ "throughput_per_s": 7112.888537413627,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 531.4209003699933,
+ "median_us": 12052.887499157805,
+ "op": "laplacian",
+ "throughput_per_s": 2654.965459707145,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.0,
+ "median_us": 53974843.91600301,
+ "op": "median_blur",
+ "throughput_per_s": 0.5928687825350489,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 609.1659961384721,
+ "median_us": 5070.792001788504,
+ "op": "median_blur",
+ "throughput_per_s": 6310.651272762395,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 131.4854504016697,
+ "median_us": 5011.339599877828,
+ "op": "median_blur",
+ "throughput_per_s": 6385.51815582008,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.0,
+ "median_us": 1574099.2500068387,
+ "op": "median_blur",
+ "throughput_per_s": 20.32908661881452,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3429.3227436137386,
+ "median_us": 4640.625505999196,
+ "op": "box_blur",
+ "throughput_per_s": 6895.622143745883,
+ "width": 256
+ },
+ {
+ "backend": "albumentations",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 57.80457999208025,
+ "median_us": 2392.9404199589044,
+ "op": "box_blur",
+ "throughput_per_s": 13372.668927774459,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 207.27500086650244,
+ "median_us": 2236.7666009813547,
+ "op": "box_blur",
+ "throughput_per_s": 14306.365262231822,
+ "width": 256
+ },
+ {
+ "backend": "PIL",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 927.5935008190572,
+ "median_us": 18456.812504155096,
+ "op": "box_blur",
+ "throughput_per_s": 1733.7771618363674,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3859.249991364777,
+ "median_us": 168291.4580014767,
+ "op": "canny",
+ "throughput_per_s": 190.14631152413693,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 151.41254989430377,
+ "median_us": 15349.683401291259,
+ "op": "canny",
+ "throughput_per_s": 2084.7335520489023,
+ "width": 256
+ }
+ ]
+}
diff --git a/benchmarks/results/0.9.0rc1/geometry--apple-m1--cpu.json b/benchmarks/results/0.9.0rc1/geometry--apple-m1--cpu.json
new file mode 100644
index 000000000..e645a93d9
--- /dev/null
+++ b/benchmarks/results/0.9.0rc1/geometry--apple-m1--cpu.json
@@ -0,0 +1,425 @@
+{
+ "metadata": {
+ "albumentations": "2.0.8",
+ "device": "cpu",
+ "git_commit": "83725c6b",
+ "kornia": "0.9.0rc1",
+ "kornia_rs": "0.1.10",
+ "load": {
+ "cpu_count": 8,
+ "load_avg_15m": 3.673828125,
+ "load_avg_1m": 2.36083984375,
+ "load_avg_5m": 4.302734375,
+ "mem_available_bytes": null,
+ "mem_total_bytes": null
+ },
+ "machine": "arm64",
+ "numpy": "2.4.0",
+ "opencv": "5.0.0",
+ "pillow": "12.3.0",
+ "platform": "macOS-26.5.1-arm64-arm-64bit",
+ "python": "3.11.0",
+ "timestamp_utc": "2026-08-08T11:54:29+00:00",
+ "torch": "2.9.1",
+ "torch_num_threads": 4,
+ "torchvision": "0.24.1"
+ },
+ "results": [
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 34.787500044331125,
+ "median_us": 1029.812499473337,
+ "op": "warp_perspective",
+ "throughput_per_s": 971.0505558161475,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 13.291995855979621,
+ "median_us": 78.0830014264211,
+ "op": "warp_perspective",
+ "throughput_per_s": 12806.884747409671,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 18.65415033535094,
+ "median_us": 936.1040996736847,
+ "op": "warp_affine",
+ "throughput_per_s": 1068.2572593674024,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 9.617082359909542,
+ "median_us": 84.96562499203719,
+ "op": "warp_affine",
+ "throughput_per_s": 11769.465593805942,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 10.543700045673134,
+ "median_us": 1050.1416996703483,
+ "op": "rotate",
+ "throughput_per_s": 952.2524439453377,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 23.04149529663846,
+ "median_us": 621.7079935595393,
+ "op": "rotate",
+ "throughput_per_s": 1608.4721611420503,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 7.051252541714359,
+ "median_us": 86.42583503387868,
+ "op": "rotate",
+ "throughput_per_s": 11570.614268384017,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 7.844484971428726,
+ "median_us": 235.77708503580652,
+ "op": "resize",
+ "throughput_per_s": 4241.294271019315,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 14.11042001564058,
+ "median_us": 242.07499998738058,
+ "op": "resize",
+ "throughput_per_s": 4130.951151717981,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.5566664985963167,
+ "median_us": 21.40208298806101,
+ "op": "resize",
+ "throughput_per_s": 46724.423999189356,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1.6980125292320833,
+ "median_us": 113.69000494596548,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 8795.847976920042,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.011319751138216688,
+ "median_us": 2.2144021000713106,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 451589.16710194456,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 178.95801283884794,
+ "median_us": 9207.08299963735,
+ "op": "warp_perspective",
+ "throughput_per_s": 868.8962617492538,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 72.022950189421,
+ "median_us": 719.454200589098,
+ "op": "warp_perspective",
+ "throughput_per_s": 11119.54033133659,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 148.3650048612617,
+ "median_us": 8241.52100540232,
+ "op": "warp_affine",
+ "throughput_per_s": 970.6946077982448,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 85.58330082451002,
+ "median_us": 728.8541994057596,
+ "op": "warp_affine",
+ "throughput_per_s": 10976.132135237009,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 234.70800078939646,
+ "median_us": 8488.209001370706,
+ "op": "rotate",
+ "throughput_per_s": 942.4838618733506,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 128.268725529779,
+ "median_us": 2529.3416496424466,
+ "op": "rotate",
+ "throughput_per_s": 3162.8783723744473,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 75.8395501179621,
+ "median_us": 718.612500349991,
+ "op": "rotate",
+ "throughput_per_s": 11132.564485176228,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 46.421849401667544,
+ "median_us": 2303.0875498079695,
+ "op": "resize",
+ "throughput_per_s": 3473.597866771082,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 34.237549698445946,
+ "median_us": 2373.6875009490177,
+ "op": "resize",
+ "throughput_per_s": 3370.2835764191964,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 3.9749950519763213,
+ "median_us": 182.35916999401525,
+ "op": "resize",
+ "throughput_per_s": 43869.46924721443,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.6881225999677392,
+ "median_us": 123.07583492656704,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 65000.5746844877,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.08553150109946972,
+ "median_us": 16.177624995179944,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 494510.1646492342,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 431.13474384881556,
+ "median_us": 38046.97949817637,
+ "op": "warp_perspective",
+ "throughput_per_s": 841.0654517669082,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 157.76039945194532,
+ "median_us": 3303.0874998075888,
+ "op": "warp_perspective",
+ "throughput_per_s": 9687.905634308527,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 568.6670083377976,
+ "median_us": 33763.64549330901,
+ "op": "warp_affine",
+ "throughput_per_s": 947.7649564334362,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 218.1114497943784,
+ "median_us": 3554.4562997529283,
+ "op": "warp_affine",
+ "throughput_per_s": 9002.783351767283,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 311.30274510360323,
+ "median_us": 33601.68750077719,
+ "op": "rotate",
+ "throughput_per_s": 952.3331231284101,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 289.76075191167183,
+ "median_us": 8980.041500763036,
+ "op": "rotate",
+ "throughput_per_s": 3563.4579191288763,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 292.7666006144135,
+ "median_us": 3554.9250009353273,
+ "op": "rotate",
+ "throughput_per_s": 9001.596374489072,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 83.1875076983124,
+ "median_us": 10250.354003801476,
+ "op": "resize",
+ "throughput_per_s": 3121.8434005432773,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 232.97849111258984,
+ "median_us": 10219.083007541485,
+ "op": "resize",
+ "throughput_per_s": 3131.396425333332,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 60.21455010341015,
+ "median_us": 899.3375005957205,
+ "op": "resize",
+ "throughput_per_s": 35581.74765180283,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.4981350139133059,
+ "median_us": 125.61562500195578,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 254745.37900441745,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1.0304200986866001,
+ "median_us": 63.85625005350448,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 501125.5746021343,
+ "width": 256
+ }
+ ]
+}
diff --git a/benchmarks/results/0.9.0rc1/geometry--apple-m1--mps.json b/benchmarks/results/0.9.0rc1/geometry--apple-m1--mps.json
new file mode 100644
index 000000000..44756c0fe
--- /dev/null
+++ b/benchmarks/results/0.9.0rc1/geometry--apple-m1--mps.json
@@ -0,0 +1,425 @@
+{
+ "metadata": {
+ "albumentations": "2.0.8",
+ "device": "mps",
+ "git_commit": "83725c6b",
+ "kornia": "0.9.0rc1",
+ "kornia_rs": "0.1.10",
+ "load": {
+ "cpu_count": 8,
+ "load_avg_15m": 3.607421875,
+ "load_avg_1m": 2.279296875,
+ "load_avg_5m": 4.0341796875,
+ "mem_available_bytes": null,
+ "mem_total_bytes": null
+ },
+ "machine": "arm64",
+ "numpy": "2.4.0",
+ "opencv": "5.0.0",
+ "pillow": "12.3.0",
+ "platform": "macOS-26.5.1-arm64-arm-64bit",
+ "python": "3.11.0",
+ "timestamp_utc": "2026-08-08T11:55:12+00:00",
+ "torch": "2.9.1",
+ "torch_num_threads": 4,
+ "torchvision": "0.24.1"
+ },
+ "results": [
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 312.95801454689354,
+ "median_us": 2871.290998882614,
+ "op": "warp_perspective",
+ "throughput_per_s": 348.2753926331946,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1.4775632625969641,
+ "median_us": 83.52627050044248,
+ "op": "warp_perspective",
+ "throughput_per_s": 11972.281223722332,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 400.2919886261225,
+ "median_us": 2751.208987319842,
+ "op": "warp_affine",
+ "throughput_per_s": 363.47656779580916,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1.609833747352236,
+ "median_us": 85.47212500707246,
+ "op": "warp_affine",
+ "throughput_per_s": 11699.720814443941,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1419.524975426612,
+ "median_us": 4595.38130016881,
+ "op": "rotate",
+ "throughput_per_s": 217.60979876974852,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 837.2909942409024,
+ "median_us": 3284.1669890331104,
+ "op": "rotate",
+ "throughput_per_s": 304.4912159885053,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2.3971567570697654,
+ "median_us": 85.9176669982844,
+ "op": "rotate",
+ "throughput_per_s": 11639.049743051892,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 30.36832000361759,
+ "median_us": 362.0283299824223,
+ "op": "resize",
+ "throughput_per_s": 2762.214769348447,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 50.74000000604428,
+ "median_us": 392.80917000724,
+ "op": "resize",
+ "throughput_per_s": 2545.765415765545,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.6166885068523666,
+ "median_us": 21.498290996532887,
+ "op": "resize",
+ "throughput_per_s": 46515.325341966665,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 365.198998770211,
+ "median_us": 1992.7646004362032,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 501.815417526539,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 1,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.026737600273918295,
+ "median_us": 2.2311416003503837,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 448201.04642527294,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 2164.5834895025473,
+ "median_us": 10322.166497644503,
+ "op": "warp_perspective",
+ "throughput_per_s": 775.0310946665686,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 18.84344754216733,
+ "median_us": 737.7975049894304,
+ "op": "warp_perspective",
+ "throughput_per_s": 10843.083564120494,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1887.6247449952643,
+ "median_us": 10215.979498752858,
+ "op": "warp_affine",
+ "throughput_per_s": 783.086927785693,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 19.477812420518504,
+ "median_us": 714.383544982411,
+ "op": "warp_affine",
+ "throughput_per_s": 11198.466224746218,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1788.5000124806538,
+ "median_us": 13306.332999491133,
+ "op": "rotate",
+ "throughput_per_s": 601.2174804512964,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 715.8708740462316,
+ "median_us": 4192.306250479305,
+ "op": "rotate",
+ "throughput_per_s": 1908.2575370263953,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 18.53520006989129,
+ "median_us": 720.4447899857769,
+ "op": "rotate",
+ "throughput_per_s": 11104.25130586056,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 67.69082741811886,
+ "median_us": 614.4183300057193,
+ "op": "resize",
+ "throughput_per_s": 13020.44488146298,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 75.07437010644924,
+ "median_us": 712.7304200548679,
+ "op": "resize",
+ "throughput_per_s": 11224.440229987853,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 5.15062005433721,
+ "median_us": 194.06458501180168,
+ "op": "resize",
+ "throughput_per_s": 41223.38962316847,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 704.1604003461546,
+ "median_us": 2153.8687506108545,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 3714.2467468043887,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 8,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.05233300908003032,
+ "median_us": 16.29983300517779,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 490802.5743244565,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 857.3960076319054,
+ "median_us": 15325.791988288984,
+ "op": "warp_perspective",
+ "throughput_per_s": 2087.9834480627433,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 155.7708004838788,
+ "median_us": 3013.216699764598,
+ "op": "warp_perspective",
+ "throughput_per_s": 10619.880077825117,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 740.3432464343496,
+ "median_us": 13063.833495834842,
+ "op": "warp_affine",
+ "throughput_per_s": 2449.5107052767166,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 115.31454983924016,
+ "median_us": 3131.5125001128763,
+ "op": "warp_affine",
+ "throughput_per_s": 10218.704220036341,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 1239.8740072967485,
+ "median_us": 15752.374994917773,
+ "op": "rotate",
+ "throughput_per_s": 2031.4397041921766,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 791.9750503788239,
+ "median_us": 5921.170899819117,
+ "op": "rotate",
+ "throughput_per_s": 5404.336497191384,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 179.48329914361247,
+ "median_us": 3077.125000709202,
+ "op": "rotate",
+ "throughput_per_s": 10399.317542389335,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 376.91701436415315,
+ "median_us": 1431.2080020317808,
+ "op": "resize",
+ "throughput_per_s": 22358.734687461187,
+ "width": 256
+ },
+ {
+ "backend": "torchvision v2",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 57.99979000585152,
+ "median_us": 1557.5708299002144,
+ "op": "resize",
+ "throughput_per_s": 20544.81207897947,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 8.822499949019376,
+ "median_us": 790.2954101155046,
+ "op": "resize",
+ "throughput_per_s": 40491.18796643787,
+ "width": 256
+ },
+ {
+ "backend": "kornia (eager)",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 376.4937500818637,
+ "median_us": 2230.57705006795,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 14346.063499140362,
+ "width": 256
+ },
+ {
+ "backend": "opencv",
+ "batch": 32,
+ "dtype": "float32",
+ "height": 256,
+ "iqr_us": 0.9009792556753498,
+ "median_us": 65.23212500178488,
+ "op": "get_perspective_transform",
+ "throughput_per_s": 490555.8419126224,
+ "width": 256
+ }
+ ]
+}
diff --git a/benchmarks/results_schema.py b/benchmarks/results_schema.py
new file mode 100644
index 000000000..3b7ab16b9
--- /dev/null
+++ b/benchmarks/results_schema.py
@@ -0,0 +1,73 @@
+# LICENSE HEADER MANAGED BY add-license-header
+#
+# Copyright 2018 Kornia Team
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+"""Schema validation for committed benchmark result JSON files."""
+
+from __future__ import annotations
+
+import json
+from pathlib import Path
+
+REQUIRED_METADATA = ("timestamp_utc", "git_commit", "platform", "python", "torch", "kornia", "device", "load")
+
+
+def validate_result(path: Path) -> list[str]:
+ """Return a list of problems with a committed result file; empty list means valid."""
+ errors: list[str] = []
+ try:
+ payload = json.loads(Path(path).read_text())
+ except (OSError, json.JSONDecodeError) as exc:
+ return [f"unreadable JSON: {exc}"]
+ if not isinstance(payload, dict) or set(payload) != {"metadata", "results"}:
+ return [f"top level must be an object with keys metadata/results, got {type(payload).__name__}"]
+ meta, results = payload["metadata"], payload["results"]
+ if not isinstance(meta, dict):
+ return [f"metadata must be an object, got {type(meta).__name__}"]
+ for key in REQUIRED_METADATA:
+ if key not in meta:
+ errors.append(f"metadata missing '{key}'")
+ load = meta.get("load", {})
+ if not isinstance(load, dict) or not all(v is None or isinstance(v, (int, float)) for v in load.values()):
+ errors.append("metadata.load must contain only numeric aggregates or null (privacy rule)")
+ if not isinstance(results, list) or not results:
+ errors.append("results must be a non-empty list")
+ else:
+ for i, row in enumerate(results):
+ if not isinstance(row, dict):
+ errors.append(f"results[{i}] must be an object, got {type(row).__name__}")
+ continue
+ for key, types in (("op", str), ("backend", str), ("batch", int)):
+ if not isinstance(row.get(key), types) or isinstance(row.get(key), bool):
+ errors.append(f"results[{i}].{key} missing or wrong type")
+ for key in ("median_us", "throughput_per_s"):
+ if (
+ key not in row
+ or isinstance(row[key], bool)
+ or (row[key] is not None and not isinstance(row[key], (int, float)))
+ ):
+ errors.append(f"results[{i}].{key} missing or wrong type")
+ name = Path(path).name
+ parts = name[: -len(".json")].split("--") if name.endswith(".json") else []
+ if len(parts) != 3:
+ errors.append("filename must be <suite>--<machine-slug>--<device>.json")
+ else:
+ device_type = str(meta.get("device", "")).split(":")[0]
+ if parts[2] != device_type:
+ errors.append(f"filename device '{parts[2]}' != metadata device '{device_type}'")
+ if "kornia" in meta and Path(path).parent.name != str(meta["kornia"]):
+ errors.append(f"version dir '{Path(path).parent.name}' != metadata kornia '{meta['kornia']}'")
+ return errors
diff --git a/benchmarks/results_schema_test.py b/benchmarks/results_schema_test.py
new file mode 100644
index 000000000..a40dff495
--- /dev/null
+++ b/benchmarks/results_schema_test.py
@@ -0,0 +1,112 @@
+# LICENSE HEADER MANAGED BY add-license-header
+#
+# Copyright 2018 Kornia Team
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+"""Unit tests for the benchmark result file schema validator."""
+
+from __future__ import annotations
+
+import json
+import sys
+from pathlib import Path
+
+sys.path.insert(0, str(Path(__file__).resolve().parent))
+import results_schema
+
+
+def _valid_payload() -> dict:
+ return {
+ "metadata": {
+ "timestamp_utc": "2026-08-08T12:00:00+00:00",
+ "git_commit": "c670e2ab",
+ "platform": "macOS-26.5.1-arm64-arm-64bit",
+ "python": "3.11.0",
+ "torch": "2.9.1",
+ "kornia": "0.9.0rc1",
+ "device": "cpu",
+ "load": {"load_avg_1m": 2.0, "cpu_count": 8},
+ },
+ "results": [
+ {"op": "sobel", "backend": "kornia (eager)", "batch": 1, "median_us": 10.0, "throughput_per_s": 1e5}
+ ],
+ }
+
+
+def test_valid_file_passes(tmp_path) -> None:
+ p = tmp_path / "0.9.0rc1" / "filters--test-box--cpu.json"
+ p.parent.mkdir()
+ p.write_text(json.dumps(_valid_payload()))
+ assert results_schema.validate_result(p) == []
+
+
+def test_device_mismatch_flagged(tmp_path) -> None:
+ p = tmp_path / "0.9.0rc1" / "filters--test-box--cuda.json"
+ p.parent.mkdir()
+ p.write_text(json.dumps(_valid_payload())) # metadata says cpu
+ assert any("device" in e for e in results_schema.validate_result(p))
+
+
+def test_version_dir_mismatch_flagged(tmp_path) -> None:
+ p = tmp_path / "9.9.9" / "filters--test-box--cpu.json"
+ p.parent.mkdir()
+ p.write_text(json.dumps(_valid_payload()))
+ assert any("version" in e for e in results_schema.validate_result(p))
+
+
+def test_missing_metric_fields_flagged(tmp_path) -> None:
+ p = tmp_path / "0.9.0rc1" / "filters--test-box--cpu.json"
+ p.parent.mkdir()
+ payload = _valid_payload()
+ # Remove required metric fields
+ payload["results"][0].pop("median_us", None)
+ p.write_text(json.dumps(payload))
+ assert any("median_us" in e for e in results_schema.validate_result(p))
+ # Also test missing throughput_per_s
+ payload = _valid_payload()
+ payload["results"][0].pop("throughput_per_s", None)
+ p.write_text(json.dumps(payload))
+ assert any("throughput_per_s" in e for e in results_schema.validate_result(p))
+
+
+def test_all_committed_results_are_valid() -> None:
+ results_root = Path(__file__).parent / "results"
+ for path in sorted(results_root.rglob("*.json")):
+ assert results_schema.validate_result(path) == [], f"{path} invalid"
+
+
+def test_non_object_payload_rejected(tmp_path) -> None:
+ p = tmp_path / "0.9.0rc1" / "filters--test-box--cpu.json"
+ p.parent.mkdir()
+ p.write_text(json.dumps(["metadata", "results"]))
+ errors = results_schema.validate_result(p)
+ assert errors and "object" in errors[0]
+
+
+def test_non_object_metadata_rejected(tmp_path) -> None:
+ p = tmp_path / "0.9.0rc1" / "filters--test-box--cpu.json"
+ p.parent.mkdir()
+ p.write_text(json.dumps({"metadata": "oops", "results": []}))
+ errors = results_schema.validate_result(p)
+ assert errors and "metadata must be an object" in errors[0]
+
+
+def test_bool_batch_rejected(tmp_path) -> None:
+ p = tmp_path / "0.9.0rc1" / "filters--test-box--cpu.json"
+ p.parent.mkdir()
+ payload = _valid_payload()
+ payload["results"][0]["batch"] = True
+ p.write_text(json.dumps(payload))
+ assert any("batch" in e for e in results_schema.validate_result(p))
diff --git a/docs/generate_benchmarks.py b/docs/generate_benchmarks.py
new file mode 100644
index 000000000..f2f036ba8
--- /dev/null
+++ b/docs/generate_benchmarks.py
@@ -0,0 +1,154 @@
+# LICENSE HEADER MANAGED BY add-license-header
+#
+# Copyright 2018 Kornia Team
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+"""Render docs/source/get-started/performance.rst from benchmarks/results/**.json."""
+
+from __future__ import annotations
+
+import json
+import re
+import sys
+from pathlib import Path
+
+REPO = Path(__file__).resolve().parents[1]
+RESULTS = REPO / "benchmarks" / "results"
+OUT = REPO / "docs" / "source" / "get-started" / "performance.rst"
+LLMS_FULL = REPO / "docs" / "source" / "_extra" / "llms-full.txt"
+
+BEGIN, END = "<!-- BENCH:BEGIN -->", "<!-- BENCH:END -->"
+
+INTRO = """\
+Performance
+===========
+
+Numbers below are generated at docs-build time from the committed benchmark result files in
+``benchmarks/results/`` β€” median wall clock over repeated runs with device synchronization and
+recorded hardware/software metadata (see ``benchmarks/README.md`` for methodology). Kornia's
+regime is batched float tensors on an accelerator, differentiable end-to-end; OpenCV and
+albumentations win the single-image uint8 CPU regime and we publish those losses too.
+
+.. warning::
+
+ Each table is a snapshot of one machine. Before contributing a run: close other applications,
+ use mains power, and let the machine cool. Expect run-to-run variance (about Β±5% on CPU and
+ up to Β±30% on MPS). Never compare numbers across machines β€” only across columns of one table.
+ Only aggregate load metrics (load average, memory) are recorded, never process names.
+
+Reproduce or contribute a machine with::
+
+ python benchmarks/<suite>/flagship.py --device <cpu|cuda|mps> --contribute benchmarks/results
+
+"""
+
+
+def load_results(results_root: Path) -> dict[str, dict[str, dict]]:
+ out: dict[str, dict[str, dict]] = {}
+ for path in sorted(Path(results_root).rglob("*.json")):
+ out.setdefault(path.parent.name, {})[path.name] = json.loads(path.read_text())
+ return out
+
+
+def _version_key(v: str) -> tuple:
+ # pad to three numeric parts so digit-less dirs (e.g. "unknown") stay comparable
+ nums = ([int(x) for x in re.findall(r"\d+", v)[:3]] + [0, 0, 0])[:3]
+ is_final = not re.search(r"(rc|a|b|dev)\d*$", v)
+ return (*nums, is_final, v)
+
+
+def latest_version(versions: list[str]) -> str:
+ return max(versions, key=_version_key)
+
+
+def _table(payload: dict) -> str:
+ rows = payload["results"]
+ backends = list(dict.fromkeys(r["backend"] for r in rows))
+ lines = [".. list-table::", " :header-rows: 1", "", " * - op @ batch"]
+ lines += [f" - {b}" for b in backends]
+ cells = {(r["op"], r["batch"], r["backend"]): r.get("throughput_per_s") for r in rows}
+ for op, batch in dict.fromkeys((r["op"], r["batch"]) for r in rows):
+ lines.append(f" * - {op} @ {batch}")
+ for b in backends:
+ v = cells.get((op, batch, b))
+ lines.append(f" - {v:.0f}" if isinstance(v, (int, float)) else " - β€”")
+ return "\n".join(lines) + "\n"
+
+
+def render_page(results_root: Path) -> str:
+ data = load_results(results_root)
+ if not data:
+ return INTRO + "\nNo benchmark results are committed yet.\n"
+ version = latest_version(list(data))
+ parts = [INTRO, f"Results for kornia {version}\n{'-' * (20 + len(version))}\n"]
+ for fname, payload in sorted(data[version].items()):
+ suite, slug, device = fname[:-5].split("--")
+ meta = payload["metadata"]
+ parts.append(f"\n{suite} β€” {slug} ({device})\n{'^' * (len(suite) + len(slug) + len(device) + 6)}\n")
+ parts.append(
+ f"``{meta['platform']}`` β€” torch {meta['torch']}, kornia {meta['kornia']}, "
+ f"commit ``{meta['git_commit']}``, {meta['timestamp_utc'][:10]}, throughput in items/s\n\n"
+ )
+ parts.append(_table(payload))
+ older = sorted(set(data) - {version})
+ if older:
+ parts.append("\nOlder result sets in git: " + ", ".join(f"``benchmarks/results/{v}/``" for v in older) + "\n")
+ return "\n".join(parts)
+
+
+def _digest(results_root: Path) -> str:
+ data = load_results(results_root)
+ if not data:
+ return "- No committed benchmark results yet.\n"
+ version = latest_version(list(data))
+ lines = [f"- Result set: kornia {version}, committed in `benchmarks/results/{version}/` (per-machine"]
+ lines += [" snapshots; reproduce with `python benchmarks/<suite>/flagship.py --contribute benchmarks/results`)."]
+ for fname, payload in sorted(data[version].items()):
+ suite, slug, device = fname[:-5].split("--")
+ meta = payload["metadata"]
+ rows = [r for r in payload["results"] if isinstance(r.get("throughput_per_s"), (int, float))]
+ if not rows:
+ continue
+ best = max(rows, key=lambda r: r["throughput_per_s"])
+ kornia_rows = [r for r in rows if r["backend"].startswith("kornia")]
+ worst = min(kornia_rows, key=lambda r: r["throughput_per_s"]) if kornia_rows else None
+ line = (
+ f"- {suite} on {slug}/{device} ({meta['timestamp_utc'][:10]}): fastest overall "
+ f"{best['backend']} {best['op']}@{best['batch']} at {best['throughput_per_s']:.0f} items/s"
+ )
+ if worst is not None:
+ line += f"; slowest kornia op {worst['op']}@{worst['batch']} at {worst['throughput_per_s']:.0f} items/s"
+ lines.append(line + ".")
+ return "\n".join(lines) + "\n"
+
+
+def refresh_llms(llms_path: Path, results_root: Path) -> None:
+ text = Path(llms_path).read_text()
+ if BEGIN not in text or END not in text or text.index(BEGIN) > text.index(END):
+ raise RuntimeError(f"markers {BEGIN}/{END} not found (in order) in {llms_path}")
+ head, rest = text.split(BEGIN, 1)
+ _, tail = rest.split(END, 1)
+ Path(llms_path).write_text(f"{head}{BEGIN}\n{_digest(results_root)}{END}{tail}")
+
+
+def main() -> None:
+ OUT.write_text(render_page(RESULTS))
+
+
+if __name__ == "__main__":
+ if "--refresh-llms" in sys.argv:
+ refresh_llms(LLMS_FULL, RESULTS)
+ else:
+ main()
diff --git a/docs/source/_extra/llms-full.txt b/docs/source/_extra/llms-full.txt
index 47a04c0ef..0a20450fd 100644
--- a/docs/source/_extra/llms-full.txt
+++ b/docs/source/_extra/llms-full.txt
@@ -156,16 +156,29 @@ img = img[None] # most ops want (B, C, H, W)
13. Expecting hue in `[0, 360]` or `[0, 1]` β€” `rgb_to_hsv` returns radians `[0, 2Ο€)`.
14. Wrong `data_keys` box format β€” `"bbox"` means 4-corner `(B, 4, 2)`; coordinate formats are `"bbox_xyxy"` / `"bbox_xywh"`.
-## Performance (measured 2026-08-07)
+## Performance (auto-refreshed from benchmarks/results)
From the in-repo benchmark harness (`benchmarks/` in the GitHub repo β€” warmup + repeats, median wall clock, device sync, recorded hardware metadata; see `benchmarks/README.md`). Guidance for choosing a backend, not marketing; numbers vary by hardware β€” reproduce with `python benchmarks/geometry/flagship.py --json out.json` before citing:
+Durable findings from earlier CUDA runs (2026-08-07, see benchmarks/README.md):
+
- Kornia's regime is batched float tensors on an accelerator, differentiable end-to-end. At batch 32, 256Γ—256 fp32, `warp_perspective` under `torch.compile` reached ~57k img/s on an NVIDIA L4 and ~232k img/s on an RTX PRO 6000 β€” roughly 45–72Γ— OpenCV's per-image uint8 CPU loop on the same hosts.
- OpenCV wins the CPU single-image uint8 regime on image warps and resize β€” use OpenCV or kornia-rs for per-image CPU data loading; use Kornia for batched / GPU / differentiable pipelines.
- Batched `get_perspective_transform` beats OpenCV's per-pair solver even on CPU once batched: crossover around batch 32, ~13Γ— (3.5M solves/s, compiled) at batch 128 on an AMD Turin CPU.
- Known weak spot (as of 2026-08): `rotate` on GPU trails torchvision v2 by ~1.7–2Γ—.
- `torch.compile` speeds most of these ops 1.3–7Γ—, but regressed `resize` at batch ≀ 32 on L4 β€” measure your own shapes before assuming compile helps.
+<!-- BENCH:BEGIN -->
+- Result set: kornia 0.9.0rc1, committed in `benchmarks/results/0.9.0rc1/` (per-machine
+ snapshots; reproduce with `python benchmarks/<suite>/flagship.py --contribute benchmarks/results`).
+- augmentation on apple-m1/cpu (2026-08-08): fastest overall opencv RandomHorizontalFlip@1 at 180552 items/s; slowest kornia op ColorJiggle@32 at 157 items/s.
+- augmentation on apple-m1/mps (2026-08-08): fastest overall opencv RandomHorizontalFlip@8 at 182381 items/s; slowest kornia op ColorJiggle@1 at 91 items/s.
+- filters on apple-m1/cpu (2026-08-08): fastest overall opencv box_blur@1 at 22422 items/s; slowest kornia op median_blur@32 at 11 items/s.
+- filters on apple-m1/mps (2026-08-08): fastest overall opencv box_blur@1 at 20137 items/s; slowest kornia op median_blur@32 at 1 items/s.
+- geometry on apple-m1/cpu (2026-08-08): fastest overall opencv get_perspective_transform@32 at 501126 items/s; slowest kornia op warp_perspective@32 at 841 items/s.
+- geometry on apple-m1/mps (2026-08-08): fastest overall opencv get_perspective_transform@8 at 490803 items/s; slowest kornia op rotate@1 at 218 items/s.
+<!-- BENCH:END -->
+
## Links
- Docs: <https://kornia.readthedocs.io/en/latest/>
diff --git a/docs/source/conf.py b/docs/source/conf.py
index c4ee72273..3f450101a 100644
--- a/docs/source/conf.py
+++ b/docs/source/conf.py
@@ -70,6 +70,13 @@ spec.loader.exec_module(generate_examples)
# Pre-generate the example images
generate_examples.main()
+spec = importlib.util.spec_from_file_location("generate_benchmarks", "../generate_benchmarks.py")
+generate_benchmarks = importlib.util.module_from_spec(spec)
+spec.loader.exec_module(generate_benchmarks)
+
+# Pre-generate the benchmark results page
+generate_benchmarks.main()
+
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
diff --git a/docs/source/index.rst b/docs/source/index.rst
index b1c802ebc..91215ef67 100644
--- a/docs/source/index.rst
+++ b/docs/source/index.rst
@@ -102,6 +102,7 @@ Join the community
get-started/highlights
get-started/conventions
get-started/stability
+ get-started/performance
get-started/installation
get-started/precision
get-started/about
diff --git a/tests/test_benchmark_results.py b/tests/test_benchmark_results.py
new file mode 100644
index 000000000..64cd4e528
--- /dev/null
+++ b/tests/test_benchmark_results.py
@@ -0,0 +1,36 @@
+# LICENSE HEADER MANAGED BY add-license-header
+#
+# Copyright 2018 Kornia Team
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+"""CI shim for benchmark result schema validation (collected by CI via tests/ directory)."""
+
+from __future__ import annotations
+
+import importlib.util
+from pathlib import Path
+
+REPO_ROOT = Path(__file__).resolve().parent.parent
+
+_spec = importlib.util.spec_from_file_location("results_schema", REPO_ROOT / "benchmarks" / "results_schema.py")
+results_schema = importlib.util.module_from_spec(_spec)
+_spec.loader.exec_module(results_schema)
+
+
+def test_all_committed_results_are_valid() -> None:
+ """Every committed benchmark result JSON must pass schema validation."""
+ results_root = REPO_ROOT / "benchmarks" / "results"
+ for path in sorted(results_root.rglob("*.json")):
+ assert results_schema.validate_result(path) == [], f"{path} invalid"
diff --git a/tests/test_generate_benchmarks.py b/tests/test_generate_benchmarks.py
new file mode 100644
index 000000000..b1ca8ecbf
--- /dev/null
+++ b/tests/test_generate_benchmarks.py
@@ -0,0 +1,127 @@
+# LICENSE HEADER MANAGED BY add-license-header
+#
+# Copyright 2018 Kornia Team
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+
+import importlib.util
+import json
+from pathlib import Path
+
+import pytest
+
+_spec = importlib.util.spec_from_file_location(
+ "generate_benchmarks", Path(__file__).parents[1] / "docs" / "generate_benchmarks.py"
+)
+generate_benchmarks = importlib.util.module_from_spec(_spec)
+_spec.loader.exec_module(generate_benchmarks)
+
+
+def _seed(tmp_path: Path) -> Path:
+ payload = {
+ "metadata": {
+ "timestamp_utc": "2026-08-08T12:00:00+00:00",
+ "git_commit": "c670e2ab",
+ "platform": "macOS-26.5.1-arm64-arm-64bit",
+ "python": "3.11.0",
+ "torch": "2.9.1",
+ "kornia": "0.9.0rc1",
+ "device": "mps",
+ "load": {"load_avg_1m": 2.0},
+ },
+ "results": [
+ {"op": "ColorJiggle", "backend": "kornia (eager)", "batch": 32, "throughput_per_s": 317.0},
+ {"op": "ColorJiggle", "backend": "albumentations", "batch": 32, "throughput_per_s": 2526.0},
+ ],
+ }
+ d = tmp_path / "0.9.0rc1"
+ d.mkdir(exist_ok=True)
+ (d / "augmentation--apple-m3--mps.json").write_text(json.dumps(payload))
+ return tmp_path
+
+
+def test_render_page_contains_table_and_metadata(tmp_path: Path) -> None:
+ rst = generate_benchmarks.render_page(_seed(tmp_path))
+ assert "Performance" in rst and "ColorJiggle" in rst
+ assert "317" in rst and "2526" in rst # numbers from the JSON, not hand-written
+ assert "apple-m3" in rst and "2026-08-08" in rst # machine + date disclosed
+ assert "close other applications" in rst # hygiene box present
+
+
+def test_latest_version_orders_rc_before_final() -> None:
+ assert generate_benchmarks.latest_version(["0.9.0rc1", "0.9.0", "0.8.3"]) == "0.9.0"
+
+
+def test_render_page_empty_results_dir(tmp_path: Path) -> None:
+ rst = generate_benchmarks.render_page(tmp_path)
+ assert "No benchmark results" in rst # page still builds, honestly empty
+
+
+def test_refresh_llms_replaces_only_marker_block(tmp_path: Path) -> None:
+ llms = tmp_path / "llms-full.txt"
+ llms.write_text("before\n<!-- BENCH:BEGIN -->\nold\n<!-- BENCH:END -->\nafter\n")
+ generate_benchmarks.refresh_llms(llms, _seed(tmp_path))
+ text = llms.read_text()
+ assert text.startswith("before\n") and text.endswith("after\n")
+ assert "old" not in text # marker block content was replaced, not appended to
+ # digest is one headline line per result file, naming the actual op/batch that was
+ # fastest/slowest so the numbers can't be misread as a blanket per-backend gap
+ digest_lines = [ln for ln in text.splitlines() if ln.startswith("- augmentation")]
+ assert len(digest_lines) == 1
+ assert "ColorJiggle@32" in digest_lines[0]
+ assert "0.9.0rc1" in text and "apple-m3" in text
+
+
+def test_refresh_llms_idempotent(tmp_path: Path) -> None:
+ llms = tmp_path / "llms-full.txt"
+ llms.write_text("x\n<!-- BENCH:BEGIN -->\n<!-- BENCH:END -->\ny\n")
+ generate_benchmarks.refresh_llms(llms, _seed(tmp_path))
+ first = llms.read_text()
+ generate_benchmarks.refresh_llms(llms, _seed(tmp_path))
+ assert llms.read_text() == first
+
+
+def test_refresh_llms_missing_markers_raises(tmp_path: Path) -> None:
+ llms = tmp_path / "llms-full.txt"
+ llms.write_text("no markers here\n")
+ with pytest.raises(RuntimeError):
+ generate_benchmarks.refresh_llms(llms, _seed(tmp_path))
+
+
+def test_refresh_llms_swapped_markers_raises(tmp_path: Path) -> None:
+ llms = tmp_path / "llms-full.txt"
+ llms.write_text("before\n<!-- BENCH:END -->\nold\n<!-- BENCH:BEGIN -->\nafter\n")
+ with pytest.raises(RuntimeError):
+ generate_benchmarks.refresh_llms(llms, _seed(tmp_path))
+
+
+def test_committed_digest_is_fresh(tmp_path: Path) -> None:
+ """The committed llms-full.txt digest must already match committed results.
+
+ Guards against the committed benchmark digest going stale relative to committed
+ results: if this fails, re-run `python docs/generate_benchmarks.py --refresh-llms`
+ and commit the result.
+ """
+ results_root = generate_benchmarks.RESULTS
+ if not any(results_root.rglob("*.json")):
+ pytest.skip("no committed benchmark results")
+ committed = generate_benchmarks.LLMS_FULL
+ copy = tmp_path / "llms-full.txt"
+ copy.write_text(committed.read_text())
+ generate_benchmarks.refresh_llms(copy, results_root)
+ assert copy.read_bytes() == committed.read_bytes()
+
+
+def test_latest_version_tolerates_digitless_dirs() -> None:
+ assert generate_benchmarks.latest_version(["unknown", "0.9.0rc1"]) == "0.9.0rc1"