Manuscript Offprint
arXiv:2610.08479MetaLearnNCA: Few-Shot Offline Meta-Learning via Interacting Neural Cellular Automata
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
Abstract
Few-shot meta-learning traditionally formulates task adaptation either as analytical gradient descent through unrolled computational graphs or as metric-based distance comparisons over flattened 1D feature vectors, which either incur costly test-time backpropagation or discard native 2D spatial geometry. In this work, we propose METALEARNNCA, a decentralized framework that achieves few-shot adaptation through the dynamical interaction of coupled Neural Cellular Automata (NCAs) without computing analytical gradients during inference. METALEARNNCA decomposes task adaptation into an Active-NCA, which executes task inference conditioned on a continuous 2D spatial memory grid termed the spatial program, and a learned Meta-NCA, which acts as a decentralized cellular optimizer by diffusing spatial error residuals across local neighborhoods to dynamically update this program. METALEARNNCA is competitive against canonical meta-learners in-distribution (96.12% on Omniglot) with Out-Of-Distribution transfer gains on MNIST, KMNIST, and Fashion-MNIST transfer across 10 independent testing seeds across 1-, 5-, and 10-shot regimes (e.g., surpassing Prototypical Networks by +10.54% on 10-shot MNIST and a +3.87% gain on 10-shot Fashion-MNIST over FOMAML). Our results establish that robust, gradient-free learning-to-learn can emerge from decentralized cellular dynamics on non-von Neumann substrates.
1 Introduction
Few-shot meta-learning seeks to equip computational systems with the ability to acquire novel concepts rapidly from minimal supervision [Hospedales et al., 2021, Vinyals et al., 2016]. In biological organisms, this learning-to-learn capacity emerges not from monolithic, centralized gradient updates across billions of parameters, but through coordinated, decentralized cellular processes operating under strict physical and energetic constraints [Levin, 2019]. Recently, Neural Cellular Automata (NCAs) [Mordvintsev et al., 2020] have emerged as a compelling paradigm of decentralized computing. Characterized by uniform local transition rules, translational invariance, and extreme parameter efficiency, NCAs have demonstrated remarkable prowess across morphogenesis [Mordvintsev et al., 2020], robust functional regeneration, texture synthesis [Niklasson et al., 2021], and spatial reasoning tasks—often utilizing orders of magnitude fewer parameters than conventional deep architectures.
Crucially, recent investigations reveal that the representational capacity of NCAs extends beyond static pattern formation. Studies have demonstrated that NCAs organize their latent, non-observable channels into structured functional representations [Guichard and Nichele, 2026, Montero et al., 2026, Randazzo et al., 2020]. For instance, NCAs can learn reusable functional primitives in hidden state channels that are subsequently recombined to execute hierarchical, multi-stage behaviors [Guichard et al., 2025b, Montero et al., 2026]. Furthermore, partitioning NCA states into private, immutable channels enables universal cellular computation, where distinct sub-channels act as isolated memory registers or programmable routing mechanisms [Béna et al., 2025]. In discriminative settings, NCAs have been shown to encode orthogonal, task-relevant representations within their latent channels; remarkably, features distilled from one NCA can bootstrap another to achieve competitive one-shot recognition [Guichard and Nichele, 2026]. This body of evidence points toward an unexplored frontier: the localized, recurrent hidden channels of NCAs provide a natural substrate for decentralized, gradient-free meta-learning.
In contrast, current deep meta-learning paradigms suffer from fundamental trade-offs: gradient-based approaches [Finn et al., 2017, Nichol et al., 2018] require unrolling computational graphs and executing costly backpropagation during test-time inference, while black-box and in-context methods [Santoro et al., 2016, Brown et al., 2020] avoid test-time gradients only at the expense of massive parameter footprints ( parameters), quadratic sequence complexity, and an absence of native 2D spatial inductive biases.
To bridge this divide, we propose MetaLearnNCA, a decentralized framework that achieves few-shot offline adaptation without computing gradients at test time. MetaLearnNCA decomposes task adaptation into the dynamical interaction of two localized cellular systems:
• An Active-NCA, which executes the primary task (e.g., visual character classification) conditioned on a localized, spatial memory grid termed the spatial program
• A Meta-NCA, which functions as a decentralized, learned cellular optimizer. Rather than calculating explicit gradients via chain-rule backpropagation, the Meta-NCA receives spatial residual error maps computed on the support set. Over a sequence of localized homogeneous transition functions, the Meta-NCA processes these residual errors and writes updated steering signals directly into the spatial program.
During adaptation, the Active-NCA and Meta-NCA communicate iteratively in a closed feedback loop: task inference produces residual errors, and cellular dynamics refines the spatial program. Once adaptation on the support set concludes, the resulting spatial program is frozen and broadcast across query instances. The query predictions are then computed purely through forward cellular unrolling—demanding zero gradient computation at adaptation or inference time.
Contributions. (1) We introduce METALEARNNCA, an offline meta-learning framework realizing few-shot adaptation via coupled NCAs that eliminates test-time backpropagation while maintaining a compact < 120k parameter footprint; (2) we formulate a spatially distributed conditioning mechanism where a learned Meta-NCA translates pixel-wise residual errors into persistent pre-activation program channels; and (3) we demonstrate good empirical performance, with competitive performance on in-distribution (96.12% on Omniglot) with Out-Of-Distribution transfer gains on MNIST, KMNIST, and Fashion-MNIST.
2.1 Few-Shot Meta-Learning and Test-Time Adaptation
Existing approaches in Few-shot Meta-Learning broadly divide into three paradigms: Gradient-Based Meta-Learning, Black-Box and Memory-Augmented Meta-Learning, and Metric-Based Learning.
Optimization-centric algorithms, such as FOMAML [Finn et al., 2017] and Reptile [Nichol et al., 2018], Meta-SGD [Li et al., 2017], and implicit formulations [Rajeswaran et al., 2019], formalize meta-learning as optimizing a shared parameter initialization that adapts via inner-loop gradient descent on support examples. Although expressive, these methods suffer from computational issues: calculating second-order meta-gradients is memory-prohibitive, and test-time adaptation mandates analytical backpropagation through unrolled graphs.
Memory-augmented architectures, such as MANN [Santoro et al., 2016] and SNAIL [Mishra et al., 2018], replace gradient descent with recurrent dynamics, accumulating task representations directly in episodic memory. Specifically, MANN utilizes an external memory matrix with content-based addressing to dynamically store and recall class bindings, while SNAIL combines temporal causal convolutions with attention mechanisms to pinpoint past exemplars across an episode. However, both approaches flatten inputs into 1D feature vectors—discarding native 2D spatial geometry—and rely on centralized memory controllers or attention operations that scale poorly with episode length and introduce artificial order dependence into unordered support sets. In modern regimes, large language and vision models exhibit emergent in-context learning [Brown et al., 2020, Garg et al., 2022, von Oswald et al., 2023]. However, in-context inference typically requires massive parameter footprints ( ), exhibits quadratic attention complexity, and lacks spatial locality priors.
Methods such as Matching Networks [Vinyals et al., 2016], Prototypical Networks [Snell et al., 2017], and Relation Networks [Sung et al., 2018] map inputs into metric feature spaces where classification reduces to nearest-neighbor or prototype distance comparisons.
2.2 Neural Cellular Automata: From Morphogenesis to General Computation
Neural Cellular Automata (NCAs) integrate classical cellular automata [von Neumann and Burks, 1966, Wolfram, 2002] with end-to-end differentiable neural components. Initially introduced to model biological morphogenesis, self-repair, and homeostatic pattern maintenance [Mordvintsev et al., 2020, Niklasson et al., 2021], NCAs demonstrate how uniform, strictly localized update rules can coordinate globally stable anatomical structures.
Beyond generative morphology, recent work has explored discriminative and computational NCA formulations. Randazzo et al. [2020] demonstrated that NCAs can achieve global agreement for digit classification (Self-classifying MNIST), proving that local message passing can perform perceptual classification without centralized pooling. Concurrently, efforts toward general and universal cellular computation [Variengien et al., 2021, Béna et al., 2025] have shown that continuous NCA state spaces can emulate discrete logic, matrix arithmetic, and routing operations.
To bridge low-level morphogenesis with high-level cognitive behavior, recent architectures have introduced modular memory and developmental hierarchies [Guichard et al., 2025b, Béna et al., 2025, Pande and Grattarola, 2023]. These architectures partition the hidden channel into mutable and immutable states, with the development of said states being decoupled from each other. Building upon this, NCAs have applied developmental cellular dynamics to the Abstraction and Reasoning Corpus (ARC-AGI) [Guichard et al., 2025a, Xu and Miikkulainen, 2025], demonstrating that localized state-refinement dynamics are well-suited for abstract grid transformations. METALEARNNCA advances this trajectory by formulating a dual-NCA interaction loop where an Active-NCA is modulated by a learned Meta-NCA that translates task-level residual signals into spatial program fields.
2.3 Decentralized and Biologically Plausible Credit Assignment
Standard deep learning relies on global backpropagation, which exhibits well-documented biological implausibilities, including the weight-transport problem, non-local gradient flow, and global backward phases [Crick, 1989, Lillicrap et al., 2020]. Biologically plausible alternatives—such as Feedback Alignment [Lillicrap et al., 2016], Direct Feedback Alignment (DFA) [Nøkland, 2016], Predictive Coding [Whittington and Bogacz, 2019], and Equilibrium Propagation [Scellier and Bengio, 2017]—substitute exact backward transpose operations with local error projections or energy-relaxation phases.
3 Model Architecture
The MetaLearnNCA architecture performs few-shot spatial reasoning tasks through the dynamical coupling of two NCAs: an Active-NCA ( ), which executes task inference conditioned on a spatial program, and a Meta-NCA ( ), which iteratively infers and updates this spatial program by reading residual error signals. Both networks build upon the standard Neural Cellular Automata (NCA) formulation [Mordvintsev et al., 2020] and conditioned routing mechanisms [Guichard et al., 2025b, Béna et al., 2025].
3.1 Base NCA Formulation
Both models share a common local transition backbone (BaseNCA). Let denote the cellular grid state at discrete time-step . The local state transition comprises a fixed spatial perception operation followed by a point-wise Multi-Layer Perceptron (MLP):
Perception Phase: Each channel of the state grid is padded with circular boundary conditions and convolved with four fixed differential filters , computing identity, directional Sobel gradients, and discrete Laplacian operators (exact filter matrices are given in Appendix A.1). Applying across all channels yields a perceived feature representation .
Update Phase: The perceived vector per cell is mapped to a state differential ds through a two-layer convolutional network:
where , (with ), and is initialized to zero without bias ( ) to ensure stable identity transitions at initialization.
To simulate asynchronous biological cellular behavior, cell updates are modulated by a stochastic dropout mask:
3.2 Active NCA
The Active-NCA maps visual inputs to task solutions conditioned on a persistent spatial program S. Its total state is partitioned into three functional sets ( channels): (i) Observation
Channel ( ), the normalized input image ; (ii) Static Program Channels ( ), the read-only spatial memory written by the Meta-NCA; and (iii) Dynamic Reasoning Channels ( ), the read-write state , where channels represent class logits maps and channels serve as internal recurrent reasoning memory.
Concatenating the static program grid S with the dynamic state prior to perception allows the program channels to serve as spatially distributed pre-activation biases on upstream convolutional neurons. Because each cell computes local state differentials based on its immediate neighborhood, this continuous spatial bias directly routes the flow of information across the grid during inference without requiring centralized routing circuitry (see Appendix A.2 and Figure 5 for a detailed schematic of this conditioning mechanism).
3.3 Meta-NCA
The Meta-NCA acts as a decentralized optimizer. Rather than utilizing explicit gradient backpropagation during few-shot adaptation, it receives a spatial residual tensor defined by:
where is the one-hot target tensor broadcast spatially across all pixels, and is a binary foreground mask that isolates character strokes and prevents background pixels from generating penalizing error signals. The masking is also used during training when computing class logits, as in Randazzo et al. [2020].
The Meta-NCA state combines with its internal dynamic memory ( channels). Over internal recurrence steps, the Meta-NCA diffuses local error feedback across neighboring cells to update . The updated task program is extracted directly from the first dynamic channels.
3.4 Ensemble Interaction Loop
The full MetaLearnNCA framework coordinates the two models within a nested interaction loop (Figure 1; formal algorithmic outline provided in Appendix A.3, Algorithm 1):
-
Initialization: A shared spatial program grid is initialized randomly: , and the meta dynamic state is cleared ( ).
-
Support Adaptation (K iterations): For each interaction step :
(a) Broadcast across the support batch: .
(b) Execute Active-NCA for 2N steps: .
(c) Compute the residual over the support set.
(d) Execute Meta-NCA for N steps: .
(e) Aggregate support programs via batch mean-pooling: .
- Query Inference: The adapted program is frozen and broadcast to the query set: . The Active-NCA then executes inference on for 2N steps to produce the final predictions .

Figure 1: The MetaLearnNCA interaction loop: Active-NCA computes forward task predictions on the support set, while Meta-NCA translates the residual error maps into an updated spatial program .
Hypothetical Mechanics of Distributed Memory Superposition. Unlike metric meta-learners that store isolated 1D prototype vectors, METALEARNNCA encodes the full multi-class task representation within a single, superposed spatial memory manifold . In high-dimensional cellular lattices ( ), class-specific steering fields written by the Meta-NCA could occupy quasi-orthogonal subspaces. Batch mean-pooling in step (e) could acts as an additive holographic superposition. This was not empirically tested but could explain why batch mean pooling does not destructively interfere with class specific artifacts.
4 Training Methodology
The parameters of both the Active-NCA and Meta-NCA are optimized concurrently through the unrolled adaptation trajectory (Algorithm 1, Appendix A.3), heavily inspired by FOMAML [Finn et al., 2017].
Meta-Objective Formulation: The query loss is computed as a stroke-masked spatial Cross-Entropy loss. For each query instance , raw logit maps are supervised by the scalar ground-truth label broadcast spatially across all grid coordinates belonging to the active stroke mask :
During discrete test-time evaluation, predictions are extracted by globally average pooling logits across all active stroke pixels:
Temporal Jittering for Robustness: To prevent the cellular dynamics from overfitting to exact unroll lengths, we apply random step-length jittering during meta-training ( and ). The total effective minimal interaction steps ( ) substantially exceed the canvas diameter ( , grid diagonal ), ensuring sufficient time for information to propagate across NCAs (with kernels of size 3, the speed of light within an NCA is 1 pixel per step).
5 Experiments
We evaluate MetaLearnNCA on few-shot character recognition using the Omniglot dataset (964 background classes) for training. All images are resized to , inverted such that background pixels equal 0.0 and character strokes equal 1.0, and normalized to .
Episode Sampling: In each meta-training iteration, we randomly sample a 10-way, 1-support, 5-query task ( , ). True Omniglot class IDs are mapped dynamically to surrogate class indices .
Optimization Details: The joint model is trained for meta-epochs with a meta-batch size of tasks using AdamW ( , weight decay = ). Gradients are clipped to a maximum norm of 1.0.
6 Results
We evaluate METALEARNNCA along three dimensions: (i) few-shot out-of-distribution (OOD) cross-dataset transfer, (ii) spatial fault tolerance and damage resilience, and (iii) qualitative visual inspection of the learned spatial program fields. We present further results and analysis in Appendices D, E, F, G, H I.
6.1 Out Of Distribution Offline Learning
To evaluate whether the learned cellular optimizer (META-NCA) acquires a generalizable error-diffusion dynamic rather than memorizing in-distribution character templates, we evaluate models meta-trained solely on Omniglot across five completely unseen out-of-distribution visual domains: MNIST, USPS, KMNIST, Fashion-MNIST, and MedMNIST Organ (referred to as MedMNIST). Full testing algorithm can be found in Appendix B.
Table 1 evaluates METALEARNNCA against canonical metric- and optimization-based baselines across 1-shot, 5-shot, and 10-shot adaptation regimes over 10 independent test splits (1 random checkpoint, 10 testing seeds). While FOMAML and ProtoNet maintain a marginal lead in-domain on Omniglot ( )
Table 1: Few-shot adaptation performance (Accuracy % ± 95% CI) across 1-shot, 5-shot, and 10-shot regimes on in-domain Omniglot and cross-domain out-of-distribution transfer benchmarks. All models (except ours) employ the canonical Conv4 backbone on 28 × 28 inputs.
| Dataset | Gradient-Free Baselines | Gradient-Based FOMAML | Ours MetaLearnNCA | |||
|---|---|---|---|---|---|---|
| Shot | MatchingNet | RelationNet | ProtoNet | |||
| Omniglot (In-Dist) | 1 | 63.47 ± 7.79 | 84.84 ± 3.74 | 92.26 ± 3.15 | 87.84 ± 3.67 | 87.95 ± 4.16 |
| 5 | 75.47 ± 4.54 | 92.73 ± 3.09 | 96.40 ± 3.09 | 96.93 ± 1.41 | 95.20 ± 2.13 | |
| 10 | 77.40 ± 6.37 | 93.20 ± 2.65 | 97.40 ± 1.27 | 98.80 ± 0.94 | 96.12 ± 0.70 | |
| MNIST | 1 | 44.79 ± 4.93 | 51.17 ± 2.66 | 55.32 ± 1.87 | 48.16 ± 2.98 | 65.02 ± 3.07 |
| 5 | 58.93 ± 1.34 | 63.74 ± 1.39 | 75.17 ± 1.56 | 70.80 ± 1.72 | 84.12 ± 1.57 | |
| 10 | 58.66 ± 1.15 | 67.30 ± 0.66 | 79.17 ± 1.48 | 72.37 ± 2.01 | 89.71 ± 0.43 | |
| USPS | 1 | 30.23 ± 3.33 | 24.14 ± 3.46 | 35.50 ± 3.74 | 42.40 ± 4.62 | 53.26 ± 5.99 |
| 5 | 34.39 ± 3.03 | 35.41 ± 2.69 | 51.07 ± 2.04 | 64.91 ± 2.13 | 57.10 ± 4.26 | |
| 10 | 36.58 ± 3.02 | 38.81 ± 1.19 | 55.54 ± 1.89 | 69.75 ± 2.16 | 65.02 ± 3.10 | |
| Fashion-MNIST | 1 | 25.24 ± 2.84 | 20.82 ± 2.59 | 22.26 ± 1.75 | 31.39 ± 3.21 | 40.43 ± 3.11 |
| 5 | 31.68 ± 0.82 | 25.43 ± 0.75 | 29.66 ± 0.91 | 47.41 ± 1.88 | 51.34 ± 2.67 | |
| 10 | 32.99 ± 0.75 | 25.91 ± 1.58 | 31.63 ± 1.29 | 50.53 ± 1.82 | 54.40 ± 1.22 | |
| KMNIST | 1 | 17.15 ± 1.46 | 20.04 ± 1.96 | 22.57 ± 2.35 | 22.76 ± 2.01 | 30.28 ± 3.14 |
| 5 | 23.15 ± 1.03 | 26.06 ± 1.60 | 30.09 ± 2.05 | 33.66 ± 1.66 | 41.65 ± 1.86 | |
| 10 | 25.61 ± 1.38 | 29.40 ± 1.13 | 35.42 ± 1.42 | 36.23 ± 1.18 | 51.26 ± 1.27 | |
| MedMNIST | 1 | 17.47 ± 3.00 | 10.79 ± 3.83 | 20.86 ± 2.66 | 22.82 ± 4.74 | 18.54 ± 2.16 |
| 5 | 26.61 ± 3.19 | 12.24 ± 3.51 | 24.85 ± 2.34 | 35.91 ± 2.30 | 19.76 ± 3.86 | |
| 10 | 27.88 ± 2.80 | 11.86 ± 4.70 | 25.99 ± 2.14 | 34.24 ± 1.31 | 26.43 ± 2.22 | |
| Test-Time Gradients? Parameters | No ≈ 115k | No ≈ 225k | No ≈ 115k | Yes (5 steps) ≈ 115k | No ≈ 118k | |
at 10-shot). In contrast, METALEARNNCA demonstrates somewhat better cross-domain transfer: it outperforms all baselines across all shot counts on MNIST (reaching 89.71% at 10-shot, +10.54% over ProtoNet), cursive KMNIST (51.26%, +15.03% over FOMAML), and Fashion-MNIST (54.40%, +3.87% over FOMAML). Furthermore, in a 1-shot domain setting, METALEARNNCA achieves the highest accuracy across 4 of 5 unseen target domains (including 53.26% on USPS, beating FOMAML by +10.86%). FOMAML outperformed MetaLearnNCA across all shots on MedMNIST (+4.28%, +16.51%, +7.81%) and on 1- and 5- shot on USPS (+7.81%, +4.72%). Crucially, METALEARNNCA achieves this transfer purely through forward cellular dynamics.
To measure end-to-end (training and testing) variability, Figure 2 plots test-time adaptation trajectories across offline cellular optimization repeats () in the 10-shot regime, aggregated across 42 independent meta-training runs and 42 independent testing seeds (One random test seed per random training seed). Crucially, the 95% confidence interval bands demonstrate that METALEARNNCA converges consistently regardless of the training or testing seed. Across all domains, the coupled cellular dynamics display an emergent two-phase behavior: remaining flat at chance level () at and , followed by a sharp transition at , and plateauing stably between and without diverging under extended recurrence (except for USPS).
MetaNCA OOD Few-Shot Performance vs. Optimization Repeats (k)

Figure 2: Few-shot offline 10-shot adaptation trajectories of METALEARNNCA evaluated on out-of-distribution character datasets across offline cellular optimization repeats ( ). Solid curves depict mean accuracy across 42 independent meta-training runs and 42 independent testing seeds, with shaded regions denoting 95% confidence intervals.
6.2 Program Damage
A defining characteristic of biological cellular ensembles is structural fault tolerance. We evaluate whether the continuous spatial representation retains this physical property under severe localized damage.
Following support adaptation, we corrupt the spatial program grid by injecting circular patches of random noise of radius pixels ( , spanning of the total grid area per circle across all 24 channels). We evaluate test classification accuracy as a function of the number of damaged patches ( ).
As depicted in Figure 3, with a single localized circular puncture (d = 1), METALEARNNCA retains 93.4% classification accuracy (a marginal 4.6% drop relative to the uncorrupted 98.0% baseline). Even when subjected to two non-overlapping punctures (d = 2, destroying over 12% of the spatial memory footprint), performance remains resilient at an average 81.8%. Variance between runs, however, increases greatly. Performance degrades smoothly as damage scales (d 3), dropping toward chance only when larger fractions of the grid are physically destroyed.
6.3 Hidden Channel and Program Field Visualizations
We visualize a small section of the hidden channels and program on the MNIST dataset. We chose to visualize MNIST as the characters are easier to recognize.
Figure 4 illustrates representative hidden reasoning channels from the Active-NCA and program channels from the Meta-NCA during inference on Mnist. The dynamic reasoning channels exhibit chaotic behavior, possibly representing a higher-order feature of the classification task. The program channels demonstrate functional specializations such as: Spot attention (channel 5), positive general shape matching (channel 13),
OMNIGLOT: Spatial Noise Circle Damage Resilience

Figure 3: Resilience of MetaLearnNCA to physical spatial damage: test accuracy as a function of circular noise patches ( ) injected into the static program grid .
MNIST: Compressed Feature Representation [Left: 4 Active Hidden Channels | Right: 4 Spatial Program Channels]

Figure 4: Representative spatial and program channels during MNIST inference. (see Appendix C for the complete 46-channel atlas).
negative shape matching (channel 21), and more complex compound features (channel 23). See Appendix C for the complete 46-channel atlas.
7 Discussion
Beyond eliminating test time gradients, METALEARNNCA shifts the representational paradigm of few-shot learning by encoding task knowledge as a continuous, spatially structured dynamical field rather than parametric weight perturbations or global 1D vector embeddings. Crucially, our framework embodies a decentralized realization of localized credit assignment that bypasses the non-local weight-transport requirements of backpropagation. Instead of back-propagating errors through analytical layer inversion, task adaptation modifies the spatial states used by the networks during forward computation, while the weights remain fixed. This demonstrates how effective task adaptation can emerge on non-Von Neumann substrates with explicit aggregation operations.
From a neurobiological perspective, METALEARNNCA can be viewed as a speculative spatially grounded abstraction of biological cortical dynamics. Each cell on the lattice functions analogously to an individual neuron or cortical microcolumn, with a local perception that models the recurrent connectivity among local neurons. Within this microcircuit, dynamic reasoning channels emulate fast-timescale electrophysio-logical variables such as membrane potentials and intracellular signaling cascades, while the persistent spatial program channels (S) operate as slow neuromodulatory fields or synaptic trace maps that alter upstream neural excitability without modifying structural weights. In this view, the Meta-NCA acts as a feedback or subcortical neuromodulatory network that detects sensory prediction errors and broadcasts chemical or electrical signals throughout the tissue, thereby regulating the attractor dynamics of the primary network entirely through recurrent activations.
Several limitations of this study highlight important avenues for future work. First, our evaluation relies on character and silhouette benchmarks where visual concepts exhibit a strong spatial center bias, which naturally aids coordinate-dependent steering; extending this formulation to unconstrained scenes with translation, scale variance, and background clutter remains to be demonstrated. Second, our core architectural hyperparameters—including channel partitions ( , ), MLP hidden widths ( ), inner steps ( ), and outer test repeats ( )—were selected heuristically rather than through systematic optimization sweeps. Third, while test-time adaptation is gradient-free and activation memory is independent of unroll length during inference, unrolling recurrent trajectories makes meta-training computationally demanding in wall-clock time and backpropagation memory. The mechanism for modulation (appending the program channels to the NCA) remains limited in functional expressivity. Scaling directly to higher-resolution RGB canvases is constrained by the cellular speed of light. Finally, the experiments do not isolate the benefits of the cellular updater, spatial memory, and foreground masking, or establish a runtime advantage. Future work will investigate Graph Neural Cellular Automata (GNCAs) over flexible topological graphs, developing methods for more expressive programs, and apply interacting NCAs to abstract program induction on the Abstraction and Reasoning Corpus (ARC-AGI).
8 Conclusion
We introduced MetaLearnNCA, an offline meta-learning framework that achieves few-shot adaptation through the dynamical interaction of coupled Neural Cellular Automata without test-time backpropagation. By formulating task representations as continuous 2D spatial memory fields and computing credit assignment via localized updates to a residual error map, METALEARNNCA bridges the gap between gradient-free meta-learning and decentralized cellular self-organization. Our framework matches established baselines in-distribution while achieving gains on some OOD transfer tasks. METALEARNNCA demonstrates that gradient-free learning-to-learn can emerge from decentralized cellular dynamics on non-von Neumann computing substrates.
AI use statement
In this work, generative AI assistance was used for LaTeX syntax restructuring, template formatting, and phrasing refinement. All theoretical derivations, algorithmic designs, experimental implementations, and conclusions were conceived, verified, and validated by the author(s).
Reproducibility Statement
Complete PyTorch code, training scripts, and evaluation routines for both METALEARNNCA and all baselines are open-sourced via an anonymous repository at: https://github.com/etimush/MetaLearnNCA.
Acknowledgment
This work was supported by MishMash - Research Council of Norway, GrantId: 357438.
References
Gabriel Béna, Maxence Faldor, Dan F. M. Goodman, and Antoine Cully. A path to universal neural cellular automata, 2025. URL https://arxiv.org/abs/2505.13058.
Tom Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared D Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. Language models are few-shot learners. In Advances in Neural Information Processing Systems (NeurIPS), volume 33, pages 1877–1901, 2020.
Francis Crick. The recent excitement about neural networks. Nature, 337(6203):129–132, 1989.
Chelsea Finn, Pieter Abbeel, and Sergey Levine. Model-agnostic meta-learning for fast adaptation of deep networks. In International Conference on Machine Learning (ICML), pages 1126–1135, 2017.
Shivam Garg, Dimitris Tsipras, Percy S Liang, and Gregory Valiant. What can transformers learn in-context? a case study of simple function classes. In Advances in Neural Information Processing Systems (NeurIPS), volume 35, pages 30583–30598, 2022.
Etienne Guichard and Stefano Nichele. Neural cellular automata learn general features in their hidden channels, 2026. URL https://arxiv.org/abs/2609.21870.
Etienne Guichard et al. Arc-nca: Towards developmental solutions to the abstraction and reasoning corpus. arXiv preprint, 2025a.
Etienne Guichard et al. Engramnca: a neural cellular automaton model of memory transfer. arXiv preprint, 2025b.
Timothy Hospedales, Antreas Antoniou, Paul Micaelli, and Amos Storkey. Meta-learning in neural networks: A survey. IEEE Transactions on Pattern Analysis and Machine Intelligence, 44(9):5149–5169, 2021.
Michael Levin. The computational boundary of a “self”: developmental bioelectricity drives multicellularity and scale-free cognition. Frontiers in Psychology, 10:2688, 2019.
Zhenguo Li, Fengwei Zhou, Fei Chen, and Hang Li. Meta-sgd: Learning to learn quickly for few-shot learning. 2017.
Timothy P Lillicrap, Daniel Cownden, Douglas B Tweed, and Colin J Akerman. Random synaptic feedback weights support error backpropagation for deep learning. Nature Communications, 7(1):11140, 2016.
Timothy P Lillicrap, Adam Santoro, Luke Marris, Colin J Akerman, and Geoffrey Hinton. Backpropagation and the brain. Nature Reviews Neuroscience, 21(6):335–346, 2020.
Nikhil Mishra, Mostafa Rohaninejad, Xi Chen, and Pieter Abbeel. A simple neural attentive meta-learner. In International Conference on Learning Representations (ICLR), 2018.
Milton L. Montero, Elias Najarro, Jakob Schauser, and Sebastian Risi. Learning developmental scaffoldings to guide self-organisation, 2026. URL https://arxiv.org/abs/2605.14998.
Alexander Mordvintsev, Ettore Randazzo, Eyvind Niklasson, and Michael Levin. Growing neural cellular automata. Distill, 5(2):e23, 2020.
Alex Nichol, Joshua Achiam, and John Schulman. On first-order meta-learning algorithms. arXiv preprint arXiv:1803.02999, 2018.
Eyvind Niklasson, Alexander Mordvintsev, Ettore Randazzo, and Michael Levin. Self-organising textures. Distill, 6(2):e00027, 2021.
Arild Nøkland. Direct feedback alignment provides learning in deep neural networks. In Advances in Neural Information Processing Systems (NeurIPS), volume 29, 2016.
Ritu Pande and Daniele Grattarola. Hierarchical neural cellular automata. In ALIFE 2023: Ghost in the Machine: Proceedings of the 2023 Artificial Life Conference, page 20, 07 2023. doi: 10.1162/isal_a_00601. URL https://doi.org/10.1162/isal_a_00601.
Aravind Rajeswaran, Chelsea Finn, Sham M Kakade, and Sergey Levine. Meta-learning with implicit gradients. In Advances in Neural Information Processing Systems (NeurIPS), volume 32, 2019.
Ettore Randazzo, Alexander Mordvintsev, Eyvind Niklasson, Michael Levin, and Sam Greydanus. Self-classifying mnist digits: Achieving distributed coordination with neural cellular automata. Distill, 5(8): e27, 2020.
Adam Santoro, Sergey Bartunov, Matthew Botvinick, Daan Wierstra, and Timothy Lillicrap. Meta-learning with memory-augmented neural networks. In International Conference on Machine Learning (ICML), pages 1842–1850, 2016.
Benjamin Scellier and Yoshua Bengio. Equilibrium propagation: Comparing gradient-descent and biologically plausible neural networks. Frontiers in Computational Neuroscience, 11:24, 2017.
Jake Snell, Kevin Swersky, and Richard Zemel. Prototypical networks for few-shot learning. In Advances in Neural Information Processing Systems (NeurIPS), volume 30, 2017.
Flood Sung, Yongxin Yang, Li Zhang, Tao Xiang, Philip HS Torr, and Timothy M Hospedales. Learning to compare: Relation network for few-shot learning. In IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pages 1199–1208, 2018.
Alexandre Variengien, Stefano Nichele, Tom Glover, and Sidney Pontes-Filho. Towards self-organized control: Using neural cellular automata to robustly control a cart-pole agent, 2021. URL https://arxiv.org/abs/2106.15240.
Oriol Vinyals, Charles Blundell, Timothy Lillicrap, Daan Wierstra, et al. Matching networks for one shot learning. In Advances in Neural Information Processing Systems (NeurIPS), volume 29, 2016.
John von Neumann and Arthur W Burks. Theory of self-reproducing automata. University of Illinois Press Urbana, 1966.
Johannes von Oswald, Eyvind Niklasson, Ettore Randazzo, João Sacramento, Alexander Mordvintsev, Andrey Zhmoginov, and Julian Zilly. Transformers learn in-context by gradient descent. In International Conference on Machine Learning (ICML), pages 35151–35174, 2023.
James CR Whittington and Rafal Bogacz. Theories of error back-propagation in the brain. Trends in Cognitive Sciences, 23(3):235–250, 2019.
Stephen Wolfram. A new kind of science, volume 5. Wolfram media Champaign, IL, 2002.
Kevin Xu and Risto Miikkulainen. Neural cellular automata for arc-agi, 2025. URL https://arxiv.org/abs/2506.15746.
A Extended Architectural and Algorithmic Details
A.1 Explicit Perception Filter Matrices
The four fixed differential filters used in the perception phase (Section 3.1) are defined as:
A.2 Single-Cell Conditioning Schematic
Inside a single Active NCA Cell

Figure 5: Theoretical overview of the conditioning mechanism: the static spatial program S acts as a localized pre-activation bias, dynamically modulating information flow through the Active-NCA transition operator.
A.3 Meta-NCA Meta-Training Algorithm
Algorithm 1 Meta-NCA Meta-Training Loop
Require: Dataset D, Meta-batch size B, Epochs E, Base Inner iterations K = 3, Base inner steps N = 16, Learning rate
1: Initialize Active-NCA and Meta-NCA
2: Initialize AdamW optimizer for joint parameters
3: for epoch = 1 to E do
4:
5: for task b = 1 to B do
6: Sample episode
7: Initialize program and meta-state
8: Sample randomized step horizons:
// Inner Adaptation Loop (Support Set)
9: for k = 1 to do
10:
11:
12:
13:
14:
15: end for
// Query Evaluation & Meta-Loss
16:
17:
18: ,
19: Compute masked spatial Cross-Entropy:
20: Accumulate task meta-gradient:
21: end for
22: Clip gradients: ,
23: Update parameters:
24: end for
25: return Optimized parameters ,
B Testing Algorithm
Algorithm 2 METALEARNNCA Few-Shot Offline Inference and Testing Loop
Require: Optimized Active-NCA parameters , Meta-NCA parameters Require: Target test dataset , Number of classes , Support shot Require: Base recurrence steps , Optimization repeats Require: Optional test-time program spatial displacement (default: 0) 1: Sample test episode: 2: Compute foreground stroke masks: 3: 4: Initialize random spatial program grid: 5: 6: 7: 8: 9:
10: for to do // 1. Forward Task Inference on Support Set (Active-NCA) 11: 12: Forward unroll without gradients // 2. Signed Residual Error Calculation 13: Construct spatial one-hot targets from 14: // 3. Cellular Optimization via Error Diffusion (Meta-NCA) 15: // 4. Cross-Class Spatial Program Superposition 16: // 5. Query Set Evaluation (Gradient-Free Inference) 17: Optional coordinate shift test 18: 19: 20: 21: 22: end for 23: return Adaptation trajectory and adapted program
C Complete Channel Atlases
MNIST: Complete Active-NCA Hidden Reasoning Channels (10-31)

Figure 6: Complete atlas of Active-NCA dynamic reasoning channels (Channels 10 through 31) during MNIST inference.
MNIST: Complete Spatial Program Field S_task (All 24 Channels)

Figure 7: Complete atlas of static spatial program channels ( , Channels 0 through 23) written by the Meta-NCA following support adaptation.

(a) Active-NCA Dynamic Reasoning Channels

(b) Meta-NCA Static Program Channels
Figure 8: Ablation analysis on Omniglot: (a) test accuracy under Gaussian noise injection across dynamic reasoning channels (10 ... 31), and (b) test accuracy when individual static program channels (0 ... 23) are ablated to zero.
D Hidden Channel and Spatial Program Ablation
To understand how task representations and decision-making are distributed across the cellular state channels, we conduct targeted channel ablation experiments on the Omniglot test set.
Active-NCA Dynamic Reasoning Channels (Figure 8a): We inject independent Gaussian noise ( ) into individual dynamic reasoning channels ( ) throughout test-time execution while keeping all other channels intact. As shown in Figure 8a, the unablated baseline achieves 98.0% accuracy. Ablating individual reasoning channels results in graceful degradation: the majority of channels maintain accuracy above 94%, with only specific channels (e.g., channels 20, 22, and 26) causing moderate drops to . Accuracy is relatively insensitive to individual channel ablation. The higher baseline accuracy compared to the reported main results is due to testing variance, as these results are only tested on one seed.
Meta-NCA Spatial Program Channels (Figure 8b): Similarly, we ablate each of the static spatial program channels ( ) by setting them to zero following support adaptation. Figure 8b reveals that the baseline (97.0%) drops by at most 1.5%–3.0% when any single program channel is ablated. This demonstrates that the Meta-NCA generates redundant, multi-channel spatial pre-activation codes.
E Flexible Program
MNIST: Program Channel Divergence
Accuracies: Seed 42 = 91.92% | Seed 43 = 91.93% | Global Mean Absolute Difference (MAD): 0.2034

Figure 9: Difference in across 2 independent testing runs on the same training seed
Solution Manifold and Functional Degeneracy. To inspect the stability and uniqueness of the learned spatial programs, we evaluate a single trained model checkpoint (Seed 0) across two independent test-time evaluation runs (Seed 42 vs. Seed 43) on the MNIST benchmark. In this setting, the model parameters remain identical, but the evaluation runs differ across three stochastic dimensions: (i) each run samples an independent 10-shot support set with differing handwriting styles, (ii) the static program grid is initialized from distinct random noise , and (iii) cellular unrolling is driven by independent stochastic update masks .
As visualized in Figure 9, both runs achieve near identical downstream test accuracy across all 10,000 MNIST test samples (91.92% vs. 91.93%). Subtracting the two adapted programs channel-by-channel ( ) reveals a global Mean Absolute Difference of MAD = 0.2034, with localized regions differing by up to . This divergence is not random high-frequency static; rather, it manifests as smooth, spatially continuous dipoles and phase shifts. This behavior highlights two core dynamical properties:
Support-Exemplar Adaptation without Overfitting: The localized variations in reflect local adjustments to the specific stylistic traits (stroke thickness, slant) of the respective support sets, while remaining constrained enough to preserve macro-level class separability across the entire test set.
Functional Degeneracy: The presence of non-trivial spatial divergence alongside identical functional performance demonstrates that the Meta-NCA optimization landscape does not collapse to an isolated, fragile minimum. This Mirrors biological degeneracy, where distinct cellular micro-states reliably execute equivalent computational phenotypes.
F Simulated spatial-memory corruption
MNIST: Program Resilience to Additive Spatial Noise

Figure 10: MetaLearnNCA performance on MNIST under different levels of additive random noise to .
MNIST: Spatial Program Resilience Under 100% Additive Noise
[Top Row: Clean (0% Noise) | Bottom Row: Perturbed (100% Additive Noise, )]

Figure 11: MetaLearnNCA under different levels of noise.
Visualizing Additive Noise Robustness. To provide intuitive grounding for the noise resilience curve in Figure 10, Figure 11 compares the clean spatial program grid against a grid corrupted by additive Gaussian noise ( ) across 100% of spatial coordinates. As visible in the bottom row, this perturbation severely degrades local pixel fidelity, simulating high-amplitude thermal or transmission noise in physical analog substrates. Crucially, the global low-frequency modes of the program remain somewhat structurally coherent.
G Dataset to Dataset Transfer
MetaNCA Cross-Domain Transfer Matrix (Full Test Set) (Mean ± 95% CI across 50 Evaluation Seeds)

Evaluated On (Target Domain)
Figure 12: Cross dataset transfer, each model is trained on one dataset and tested on all the other ones. 50 repeats per dataset with 95% CI intervals.
H K-repeats and K-shot meta-learning surface
MetaNCA Few-Shot Generalization Landscape: Accuracy vs. Support Shots & Optimization Repeats (k) (Evaluated using Omniglot-Trained Dual-NCA Model)



FASHION (Out-of-Distribution Transfer)
USPS (Out-of-Distribution Transfer)
MEDMNIST (Out-of-Distribution Transfer)



Figure 13: Dataset surfaces for seed 0, trained on OMNIGLOT across a combination of K-repeats and K-shots.
I Spatial Translation and Coordinate Invariance Robustness
A core design characteristic of METALEARNNCA is that task knowledge is encoded as a continuous 2D spatial field ( ) rather than a global 1D latent vector. While this inductive bias provides localized routing mechanisms for stroke- and shape-based reasoning, it introduces a natural question: does the coupled cellular dynamics rely on rigid pixel-to-pixel coordinate alignment, or does it exhibit translational elasticity under spatial displacement?
I. 1 Experimental Setup
To quantify spatial coordinate robustness, we evaluate a model meta-trained on Omniglot (Seed 0) in a standard 5-shot, 10-way evaluation setting across all six benchmark domains. Following support-set adaptation on canonical images, we apply independent discrete 2D spatial translations to all query instances:
with displacement thresholds pixels, using circular padding to preserve canvas dimensions ( ). We evaluate classification accuracy across 5 independent evaluation runs per displacement setting, and report sample means with 95% confidence intervals.
I. 2 Results and Dynamical Elasticity
As summarized in Table 2, METALEARNNCA displays graceful, non-catastrophic degradation across all evaluated visual domains:
Table 2: Robustness of METALEARNNCA to discrete spatial coordinate shifts ( pixels) in the 5-shot, 10-way transfer regime. Results report mean classification accuracy confidence intervals evaluated over 5 independent testing runs on full test splits.
| Dataset | Shift = 1 px | Shift = 2 px | Shift = 3 px | Shift = 4 px |
|---|---|---|---|---|
| Omniglot (In-Dist) | ||||
| MNIST | ||||
| USPS | ||||
| Fashion-MNIST | ||||
| KMNIST | ||||
| MedMNIST |
-
Near-Invariance at Local Offsets ( px): For local shifts of pixel, accuracy remains virtually indistinguishable from clean unshifted baselines (e.g., MNIST achieves , and Omniglot attains ). At pixels, degradation remains minimal, with MNIST dropping by only () when compared to and in-distribution Omniglot retaining mean accuracy.
-
Degradation under Larger Offsets ( px): When images are perturbed by pixels, representing a larger displacement exceeding of the total canvas width (), the model retains some task structure. On MNIST, the model achieves , which is nearly higher than the random-guess baseline. Similarly, Omniglot retains .
Mechanistic Basis of Elasticity. This shows that does not solely function as an overfitted, static pixel mask. Rather, some degree of translational elasticity is an emergent consequence of the Active-NCA's recurrent message-passing dynamics. Because each update step convolves differential operators (, ) across a neighborhood, information propagates outwards at 1 pixel per step. Across forward inference steps, each cell integrates context over an effective receptive field spanning the entire canvas. This recurrent diffusion acts as an intrinsic spatial regularizer: local gradients dynamically warp and re-route displaced stroke trajectories into the attractor basin defined by , buffering the system against some coordinate misalignment.
J Baseline Hyperparameters and Dataset Preprocessing
All canonical baselines share a standard Conv4-64 encoder (4 conv blocks with 64 channels, ReLU, max-pooling, and global average pooling yielding a 64D feature vector). All models are meta-trained for 5,000 epochs on Omniglot with AdamW (, weight decay , gradient clipping at 1.0). Full source code and configuration files are available in our anonymous repository.
https://github.com/etimush/MetaLearnNCA
Table 3: Architectural and optimization hyperparameters for canonical baselines.
| Hyperparameter | ProtoNet | MatchingNet | RelationNet | FOMAML |
|---|---|---|---|---|
| Backbone | Conv4-64 | Conv4-64 | Conv4-64 | Conv4-64 |
| Parameters | ||||
| Output Head | Metric Centroid | Cosine Attention | Relation MLP | Linear (64 10) |
| BatchNorm Stats | Frozen Running | Frozen Running | Frozen Running | Shuffled Mini-Batch |
| Meta-Loss | Cross-Entropy | Neg. Log-Likelihood | Mean Squared Error | Cross-Entropy |
| Inner Steps () | - | - | - | 3 / 5 |
| Inner LR () | - | - | - | 0.1 (clip = 1.0) |
| In-Domain Inner LR () | - | - | - | 0.2 ( 5-shot), 0.1 (10-shot) |
| OOD Inner LR () | - | - | - | 0.1 (1s), 0.05 (5s), 0.03 (10s) |
| Higher-Order Gradients | - | - | - | First-Order (FOMAML) |
Table 4: Dataset preprocessing and normalization pipelines (28 × 28 grayscale).
| Dataset | Domain | Transform Pipeline |
|---|---|---|
| Omniglot | Sparse Characters (In-Dist) | Resize(28) ToTensor() Invert (1.0 - x) Normalize(0.5, 0.5) |
| MNIST / KMNIST / USPS | Digits / Calligraphy (OOD) | Resize(28) ToTensor() Normalize(0.5, 0.5) |
| Fashion / MedMNIST | Silhouettes / CT Organs (OOD) | Resize(28()) ToTensor() Normalize(0.5, 0.5) |