Repository navigation
cssynth 0.6.0
cssynth compiles flat 400×300 pictures into short HTML/CSS for CSSBattle-style code golf.
Try it in the browser: https://fmindstormer.github.io/cssynth/demo/ shows three saved results at once, compiles your own picture locally with Pyodide, and lets you cancel, retry and download the generated HTML.
Install from this release
This version is not on PyPI. Install the wheel attached here:
pip install cssynth-0.6.0-py3-none-any.whl
cssynth target.pngFiles
| File | Contents |
|---|---|
cssynth-0.6.0-py3-none-any.whl, cssynth-0.6.0.tar.gz |
the package |
cssynth-0.6.0-examples.zip |
six example targets (MIT, from OmPreetham/cssbattle) and the demo's three saved results |
cssynth-0.6.0-benchmark.zip |
results.json and ablation.json: cssynth's outputs and scores on the 66 development-set targets |
SHA256SUMS |
checksums for all of the above |
What the numbers establish
On the 66 development-set targets, the targets the compiler was developed on, cssynth's code is shorter than the human solution on 56, and all 66 render at a 99%+ pixel match in Chromium. The human baseline is readable code from two public repositories, minified but not golfed. It is a baseline, not a leaderboard. Results on held-out targets are in the README.
The demo's live "estimated match" comes from cssynth's internal rasterizer; benchmark scores come from Chromium renders. The browser build uses greedy box-shadow grouping instead of OR-Tools.