mirror of
https://github.com/bitcoinresearchkit/brk.git
synced 2026-04-23 22:29:59 -07:00
brk_bencher_visualizer
SVG chart generation for benchmark visualization.
What It Enables
Turn benchmark CSV data into publication-ready SVG charts showing disk usage, memory (current/peak), progress, and I/O over time. Compare multiple runs side-by-side with automatic color coding.
Key Features
- Multi-run comparison: Overlay multiple benchmark runs with distinct colors
- Dual-axis charts: Memory charts show both current and peak usage (solid vs dashed lines)
- Smart scaling: Automatic unit conversion for bytes (KB/MB/GB) and time (seconds/minutes/hours)
- Per-run trimming: Aligns data by progress cutoffs for fair comparison
- Dark theme: Clean, readable charts with monospace fonts
Core API
let viz = Visualizer::from_cargo_env()?;
viz.generate_all_charts()?; // Process all crates in benches/
Chart Types
disk.svg- Storage consumption over timememory.svg- Current + peak memory usageprogress.svg- Processing progress (e.g., blocks indexed)io_read.svg/io_write.svg- I/O throughput
Input Format
Reads CSV files from benches/<crate>/<run_id>/:
disk.csv,memory.csv,progress.csv,io.csv