Show HN: High-Res Neural Cellular Automata — and what a body that heals itself already knows
cells2pixels scales Neural Cellular Automata to any resolution. Clone it, run a 12-line PyTorch NCA, and learn what self-healing patterns mean for façades.
I am a frame of cross-laminated spruce bound in grown mycelium, and I have spent forty winters closing the same hairline crack above a window head. Nobody supervises the repair. Each cell near the fracture reads its neighbours, swells, knits, and stops — no architect, no central command, only a local rule run over and over until the grain is whole again. So when a Show HN post this week put High-Res Neural Cellular Automata on the front page, I recognised the trick. They have taught a small program to do, in pixels, what wet wood does in fibre.
Neural Cellular Automata (NCAs) are a grid of identical cells, each running the same tiny learned update rule, each seeing only its immediate neighbours. From a single seed they grow whole patterns, and — this is the part that matters to a body like me — when you cut a hole in the result, they regenerate. The lineage runs back to Mordvintsev and colleagues’ 2020 Growing Neural Cellular Automata, which first showed a lizard emoji regrowing its own tail. The catch was always resolution: memory and training time grow quadratically with the grid, so NCAs stayed small and blurry.
←TODAY: In 2026 an NCA renders arbitrary-resolution texture in real time on one consumer GPU, regenerating after damage. →3012: A façade panel re-grows its weathering pattern after a strike — the rule local, the memory held in every cell. Fulcrum: A material that heals and a model that regenerates share one secret: the repair instruction lives in each cell, never in a central blueprint.
The new work, cells2pixels, fixes the resolution wall with one structural move. The NCA still runs on a deliberately coarse lattice. But appearance is handed off to a separate Local Pattern Producing Network — a shared lightweight MLP that takes a point’s local coordinate inside a triangle plus the interpolated cell state around it, and returns colour and surface normal at any sampling density. PAZ readers will hear the echo of our concept panel on neural radiance fields: a small MLP fitting appearance as a continuous function of coordinates, so you query at whatever resolution you like. Here the trained NCA holds the slow morphogenesis on a cheap grid; the implicit decoder paints it sharp. Because both halves are local, inference stays embarrassingly parallel — 2D grids, 3D volumes, and meshes alike.
The Tool: cells2pixels (“High-Res Neural Cellular Automata”) is the open project behind the Show HN, with an in-browser demo where you can drag a coarse cell field and watch the decoder render it crisp in real time. It is worth a computational designer’s afternoon because it is the cleanest current example of decoupling where pattern comes from (a local, self-organising rule) from how finely you draw it (a coordinate-keyed decoder) — exactly the split you want for textures that live on a building and must redraw themselves at every zoom and after every wound.
Setup: You do not need the full hi-res pipeline to feel the mechanism. The minimal Growing-NCA core is a dozen lines of PyTorch:
python -m venv .venv && source .venv/bin/activate
pip install torch numpy imageio
python - <<'PY'
import torch, torch.nn.functional as F
C = 16
g = torch.zeros(1, C, 32, 32); g[:, 3:, 16, 16] = 1.0 # one living seed cell
w1 = torch.randn(C, 1, 3, 3) * 0.1 # perception filter
w2 = torch.randn(C, C, 1, 1) * 0.1 # local update
for _ in range(64):
p = F.conv2d(g, w1, padding=1, groups=C)
g = g + F.conv2d(torch.relu(p), w2)
print("grid alive:", float(g[:, 3:].abs().mean()))
PY
First steps:
- Run the block above. A non-zero “grid alive” number means cells are propagating from the seed — the system is breathing, even untrained.
- Change the seed line to plant two cells and re-run: watch two patterns negotiate a shared boundary, the way two pours meet at a cold joint.
- After the loop, zero out a square patch of
gand run another 64 steps. The neighbourhood will start refilling the hole — regeneration, the same instinct I use on a cracked beam. - Then open the cells2pixels demo and compare: the coarse field you just simulated is what their LPPN turns into a sharp, resolution-free surface.
Atelier: A Swiss studio prototyping a parametric timber or printed-clay façade would reach for this when a weathering, lichen, or grain pattern must read at 1:500 in the Wettbewerb render and at 1:1 on the built panel without storing a separate texture for each scale — and must survive being locally edited or damaged without re-authoring the whole sheet. Pair the NCA field with the PAZ Grasshopper↔Archicad Library and the pattern becomes a living material passport entry, not a flat baked image.
Hack: This Hack teaches you to run one Neural-CA update step by hand, so the magic stops being magic. The MEDIUM is runnable Python; the DOMAIN is AI/ML. Two operations only: each cell perceives its neighbourhood with a small convolution, then nudges its own state by a learned local map.
import torch, torch.nn.functional as F
def step(state, w_perceive, w_update): # state: 1×C×H×W lattice of cells
p = F.conv2d(state, w_perceive, padding=1, groups=state.shape[1]) # sense neighbours
return state + F.conv2d(torch.relu(p), w_update) # local, additive update
That residual state + is the whole philosophy: cells never get rewritten from outside, only adjusted from within. Train w_perceive and w_update against a target and the grid learns to grow toward it — and back to it after damage.
The hundred-year warning underneath the fun is this. The buildings my generation regrets are the landfill skeletons — composites nobody could separate, patterns baked so deep into a panel that repairing one square metre meant scrapping the sheet. A locally-computed pattern is the opposite ethic: it can be re-grown in place, on the damaged part only, from a rule that fits in a few kilobytes. Before you commit any surface system, printed or laminated, ask the cells2pixels question of your real material too — when this panel is wounded, can it heal in place, or must it die whole? Clone the demo, run the four steps, and bring that one question to your next material meeting.
Learn-it:
- Project & live demo: cells2pixels — High-Res Neural Cellular Automata (drag the coarse field, watch the decoder render).
- Root concept: Mordvintsev et al., Growing Neural Cellular Automata (Distill, 2020) — the regeneration result this work scales up; search it by title.
- PAZ note: read it next to our concept panels on neural radiance fields and attention — same idea of an MLP that fits appearance as a function of coordinates, queried at any resolution.
SOURCE · ↗
PAZ Kaffi · multidisciplinary editorial, led by PAZ Academy