GIRC.dev

Three commands, and the codec is on your machine.

Everything is in one repository and every command below is the one the documentation and the CI both use. There is no package to install and no hosted-only feature: the code the service runs is the code here.

Build and test

git clone https://github.com/devansh0703/girc
cd girc
cargo build --release --workspace
cargo test --workspace

The test suite checks the integer transforms against Fraunhofer HHI's VVenC bit for bit, across all twelve transform and size combinations, and checks the chroma quantization parameter mapping against the same reference implementation for every quantization parameter. It needs the reference implementation:

git clone --depth 1 --branch v1.14.0 \
    https://github.com/fraunhoferhhi/vvenc.git data/tools/vvenc-src
cmake -S data/tools/vvenc-src -B data/tools/vvenc-src/build \
    -DCMAKE_BUILD_TYPE=Release
cmake --build data/tools/vvenc-src/build --config Release -j "$(nproc)"
./tools/generate_transform_oracle.sh
./tools/generate_chroma_qp_oracle.sh
cargo test -p girc-core transform
cargo test -p girc-core chroma_qp

The reference encoders' oracles are generated from VVenC's own kernels rather than from the standard's text, so the check is against the implementation a codec team would actually build against.

The command line

./target/release/girc-cli encode input.y4m --output out.girc --qp 27
./target/release/girc-cli decode out.girc --output out.y4m
./target/release/girc-cli inspect out.girc

The --inferred flag selects the signalling mode. Without it the encoder writes the explicit mode, which is the clean rate-distortion optimum the inferred mode is measured against.

The two syntaxes, and what each costs crates/girc-core/src/bitstream.rs, ITU-T H.266 clause 7.3.9
plain DCT-II 1 1 bin DST-VII / DST-VII 1 0 2 bins DCT-VIII / DST-VII 1 0 0 3 bins DST-VII / DCT-VIII 1 0 0 0 4 bins DCT-VIII / DCT-VIII 1 0 0 0 4 bins 1 bin: was the prediction right? and if not, 2 bins select between the four the prediction ruled out an override never costs more than the signalling it replaces the naive form spent a bin on the correction and then the full type again the inferred mode codes the correction relative to the prediction the explicit mode is the standard's own mts_idx
How the prediction works: the window, the block, and the single correction bit crates/girc-core/src/geometry.rs, crates/girc-core/src/bitstream.rs
the block being coded already reconstructed, already known to both sides the encoder's rate-distortion search the decoder's prediction, from the window one bin: was the prediction right? if it was wrong, two bins pick between the rest the decoder reads its own window it predicts the mode, at no cost it reads the one bin right: take the prediction. wrong: read two more one bitstream, one flag in the header

Measure it on your own content

source tools/benchmark_env.sh

./target/release/girc-bench \
    --sequence data/seq/foreman_cif.y4m \
    --qps 22,27,32,37 \
    --model models/girc-predictor.json \
    --margin 50 \
    --anchors x265,svt-av1,vvenc \
    --margin-sweep 0,2,5,10,20,50,100,500 \
    --report bench-out/report.json

The report records the tool versions it ran against, so a number can be traced to the state that produced it. Point --sequence at your own material and the comparison runs on your content rather than only on the twelve CIF sequences the published figures come from.

The measurement apparatus: one variable, everything else held constant crates/girc-bench/src/main.rs
twelve CIF sequences four quantization parameters ten frames each the explicit mode the same search, the same quantizer the inferred mode the same search, plus a margin the only difference how the transform mode reaches the decoder every other stage is shared by both the anchors are coded the same way, on the same frames, with the same PSNR code the benchmark decodes what it encodes, and refuses a result if the two pictures differ

Fit your own predictor

pip install -r python/girc-train/requirements.txt
export PYTHONPATH=python/girc-train

python3 -m girc_train collect --sequences data/seq/*.y4m \
    --output bench-out/training.jsonl
python3 -m girc_train fit --input bench-out/training.jsonl \
    --output models/girc-predictor.json

The collection pass runs the encoder itself, so the training set is the encoder's actual behaviour and not a proxy for it, and the features are taken from the reconstructed neighbourhood exactly as the decoder will see them. The fit runs on the GPU when one is present and on the CPU when it is not, and the two agree on the result: the same data gives 50.17% test accuracy on the GPU and 50.18% on the CPU.

uv pip install --python .venv/bin/python \
    -r python/girc-train/requirements-gpu.txt

The model records which backend produced it, in training.estimator_backend, so a fit is attributable. The predictability ceiling is a gradient-boosted tree, which stays on the CPU because cuML has no histogram gradient boosting.

The pipeline: where each artifact comes from, and where it is used the repository layout
crates/girc-core VVC-exact integer transforms intra and inter prediction the geometry predictor the entropy coder python/girc-train collect: the encoder's decisions fit: one model over five modes the predictability ceiling a frozen, versioned artifact crates/girc-bench both modes, same content the margin sweep the anchor codecs the Bjontegaard implementation models/girc-predictor.json — produced by the middle, read by both sides of the codec one product: the codec, the training pipeline, the benchmark, and the portal that evaluates it

Regenerate the site's figures

Every figure on this site is generated from a committed artifact by one script, so you can check that a figure you are looking at is the one your run produces:

.venv/bin/python tools/generate_figures.py
.venv/bin/python tools/assemble_site.py
.venv/bin/python tools/verify_benchmark_numbers.py \
    research/benchmark/report-v9-joint.json

The third command is the one that matters most: it reads the benchmark report and checks that every figure the documents quote is the one the report holds. It has caught a number changed in one place and not in the others, which is exactly the drift a project whose value is checkable claims cannot afford.

What the encoder actually chose: the plain DCT-II, and four modes that split the rest models/girc-predictor.json · class_distribution
50.1% DCT-II 14.2% DST-VII DST-VII 12.3% DCT-VIII DST-VII 12.4% DST-VII DCT-VIII 10.9% DCT-VIII DCT-VIII 570,240 blocks, the encoder's own rate-distortion choices the majority class is 50.10% the four other modes are 49.90%