Downloads · 30 days
0
themantralab/gol-emergence-pipeline
gol-emergence-pipeline is a machine learning model from themantralab. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for pytorch. The card lists the license as mit.
A convolutional autoencoder trained to reconstruct Conway's Game of Life frames near-exactly: 128×128 binary grid → z ∈ ℝ¹⁰²⁴ → 128×128 logits.
Downloads · 30 days
0
Access
Public
Updated Aug 2, 2026
Repo size
269 MB
Likes
0
Public
Click a slice to open those files.
.pt269 MB · 100%
From the Hugging Face model README
A convolutional autoencoder trained to reconstruct Conway's Game of Life frames
near-exactly: 128×128 binary grid → z ∈ ℝ¹⁰²⁴ → 128×128 logits.
alive-F1 0.9169 (dead-F1 0.9997) on the full validation set at threshold 0.5; round-trip cosine 0.999 on real frames.
This checkpoint exists so the accompanying study can be independently verified. The point of that study is that reconstruction fidelity like the above does not imply a latent you can predict, plan, or sample in — see Known limitations.
The architecture lives in model.py in the GitHub repository — it is not
duplicated here, so there is one definition rather than two that can drift.
git clone https://github.com/themantralab/gol-emergence-pipeline.git
cd gol-emergence-pipeline
pip install -r requirements.txt
import torch
from huggingface_hub import hf_hub_download
from model import Encoder, Decoder
path = hf_hub_download("themantralab/gol-emergence-pipeline", "best.pt")
ckpt = torch.load(path, map_location="cpu", weights_only=False)
print(ckpt["step"], ckpt["metrics"]) # 148500, alive_f1 0.916896
enc, dec = Encoder(), Decoder(kernel_size=1)
enc.load_state_dict(ckpt["encoder"]); enc.eval()
dec.load_state_dict(ckpt["decoder"]); dec.eval()
import engine, numpy as np
grid = engine.embed_seeds(np.random.randint(0, 2, (1, 16, 16), dtype=np.uint8))
x = torch.from_numpy(grid.astype(np.float32)).unsqueeze(1)
with torch.no_grad():
z = enc(x) # (1, 1024)
recon = torch.sigmoid(dec(z)).squeeze() > 0.5
Place checkpoints/best.pt in the repository root to run the diagnostics
unmodified — they all load that path.
Checkpoint contents: encoder, decoder (state dicts), step, metrics,
per_q (per-lifespan-quartile validation metrics).
269,139,477 bytes, SHA-256 b2a2ca4b9e19c9e24070b347d45ccf9ec72261a74ae43a62dccb84dfc9247243.
67,281,873 parameters, CPU-only training, 150,000 steps (~30 h).
kernel=2, stride=2 downsample stages with
1×1 channel-mixing refines, then a linear projection to ℝ¹⁰²⁴. Each of the
16×16 trunk positions sees exactly one disjoint 8×8 input tile — no
overlapping receptive fields. python3 model.py verifies this: flip one input
pixel and exactly 1 of 256 trunk positions changes, while ~988 of the 1024
latent dimensions do.PixelShuffle 2× upsamples
with kernel=1 convolutions, final 1×1 conv. No layer mixes signal between
adjacent output pixels, so the decoder cannot paint a probability halo around
true cells — which is what makes near-exact cell placement possible.Trained with four losses (reconstruction, a smoothness term matching latent
cosine to frame IoU, a soft norm bound, and angular uniformity) under three
schedules that are required for convergence. Details in
design/03_final_architecture.md.
Reproducing and extending the measurements in the linked repository. This is a research artifact for studying representation properties, not a component to build on — the limitations below are the finding, not bugs to work around.
These are measured, with the producing script named. Full tables in RESULTS.md.
z_t → z_{t+1} predictor
collapses under closed-loop rollout — F1 0.344 ± 0.011 at horizon 1 to
0.009 ± 0.003 at horizon 60 — while the teacher-forced ceiling stays flat at
0.929–0.946. Predicting no change beats it at every horizon.
(dynamics_probe.py, persistence_baseline.py)probe_behavior_class.py)n4_offset_curve.py)border_test.py)world_model_readiness.py)1.5M random 16×16 seeds simulated under B3/S23 on a 128×128 grid, embedded at centre-biased random offsets. Trajectories are generated on the fly by the reference simulator rather than stored. See the dataset.
@misc{koegler2026golae,
author = {Koegler, Maxwell},
title = {{Game of Life autoencoder (step 148,500)}},
year = {2026},
publisher = {Mantra Labs},
url = {https://huggingface.co/themantralab/gol-emergence-pipeline}
}