mirror of
https://github.com/godotengine/godot-benchmarks.git
synced 2025-12-31 09:49:13 +03:00
- Always use relative values to display benchmarks (actual values are platform dependent and meaningless). - Use the median of the last 10 values as middle, such that new benchmarks are always on the graph. - Don't round values in the data aggregator, round them on visualization instead. - Use toolbar in detail charts. - Don't use shared tooltip.
Web interface for benchmark results
This website is built with the Hugo static site generator.
It's designed to work exclusively with the run-benchmarks.sh script,
which runs benchmarks on a dedicated server with various GPU models.
How it works
- Using the
run-benchmarks.shscript, benchmark data is collected and saved to a single JSON file for each engine commit, with 4 runs:- CPU (debug template)
- CPU (release template)
- GPU (AMD, release template)
- GPU (Intel, release template)
- GPU (NVIDIA, release template)
- The produced results (as .json or .md) should be copied into the
src-data/benchmarksfolder. - The ./generate-content.py script produces
.mdfiles in thecontentfolder, so that web pages can be generated for each graph and each benchmark. - Hugo is used to create a homepage listing recent benchmarked commits, plus a single page per engine commit. This allows linking to individual benchmarked commit in a future-proof way.
- ApexCharts is used to draw graphs on the homepage.
- Water.css is used to provide styling, including automatic dark theme support.
Building
Development
- Create JSON data or fetch existing JSON data from the live website,
and copy the JSON files into the
src-data/benchmarksfolder. Files should be named using formatYYYY-MM-DD_hash.jsonwherehashis a 9-character Git commit hash of the Godot build used (truncated from a full commit hash). The files can also have the.mdextension (for backward compatibility), but they should still be JSON inside. - Run ./generate-content.py. This should create
.mdpages in both thecontent/benchmarkand thecontent/graphfolders. - Run
hugo server.
Production
- Follow the same steps as in the Development section above.
- Run
hugo --minify.