diff --git a/docs/benchmark.md b/docs/benchmark.md new file mode 100644 index 0000000..f7605f2 --- /dev/null +++ b/docs/benchmark.md @@ -0,0 +1,38 @@ +# Benchmark + +OpenVector's output quality is measured with [vectorbench](https://github.com/Microck/vectorbench), +a separate repository that scores any image-to-SVG vectorizer the same way. It traces openly +licensed images with each engine at its defaults, renders every SVG in a pinned headless +Chromium, and reports ΔE00, SSIM, edge F1, coverage leak, anchors and bytes over white and black +backgrounds, with paired bootstrap intervals. + +vectorbench lives outside this repository so the yardstick stays neutral and its images and +results stay out of OpenVector's history. OpenVector's authors maintain it; its README states that +conflict of interest and the rules that keep it honest. + +## Pinned version + +Every OpenVector proof run names the exact vectorbench version it used. The current pin is +**[v0.1.1](https://github.com/Microck/vectorbench/tree/v0.1.1)**. A newer vectorbench version is a +new yardstick: results measured with different versions are not compared directly. + +## Running it against a build + +```bash +git clone --branch v0.1.1 https://github.com/Microck/vectorbench.git +cd vectorbench +npm ci +npx playwright install chromium +OPENVECTOR_BIN=/path/to/openvector OPENVECTOR_COMMIT=$(git -C /path/to/openvector rev-parse --short HEAD) npm run bench +``` + +`OPENVECTOR_BIN` points at the CLI binary to measure +(`cargo build --release --manifest-path rust/Cargo.toml -p openvector-cli` builds it at +`rust/target/release/openvector`). Without it, vectorbench uses the first +`openvector` on the `PATH`. + +## Hidden set + +vectorbench keeps part of its images out of the repository, and publishes only their hashes. +OpenVector development must never read those images, look at their per-image scores, or choose +between builds by their result. They are scored once per frozen release, as part of its proof.