Houdini 22.0 Nodes Copernicus nodes

Neural Cellular Automata Core Copernicus node

Runs a neural cellular automata model to evolve cell states.

On this page
Since 22.0

This node runs a Neural Cellular Automata (NCA) model on an input cell state, evolving it over a number of iterations. The model uses a learned neural network to simulate cellular automata rules that produce complex patterns and textures.

By default the node runs an NCA model on the incoming cells input or an empty layer, applying the model for the specified number of Model Iterations. Running the model for more iterations leads to a better convergence towards the target texture. The model can run on any aspect ratio and produces tileable results out of the box. This is achieved by wrapping the border cells around so the other side becomes their neighbor.

The NCA inference workflow is made up of the Neural Cellular Automata Core COP and the Neural Cellular Automata Decode COP. See Neural Cellular Automata for more information about these nodes, including recipes. See ML Train Neural Cellular Automata for information about how to train an NCA model.

Note

It is important to update different cells on each time step. To ensure this, the node increments and outputs a layer property called ncaiteration. This integer value is added internally to the seed leading to updates on new random cells each block iteration. Ensure this layer property does not get accidentally removed.

Parameters

Model

The NCA model preset to use. This sets the model file path and any other parameters stored in the recipe simultaneously.

Initialize Cells

Outputs an initialized cell state without running the NCA model. Use this to create the starting state for a cellular automata simulation.

Note

This parameter helps provide the correct input cable when running the model in a block.

NCA Model File

The path to an ONNX model file for the NCA.

Reload Model

Forces a reload of the ONNX model file.

Model Iterations

The number of times the NCA model is applied per cook. Higher values evolve the cell state further but take longer to compute.

Tip

When growing textures on meshes with adjacency information, use the Neural Cellular Automata Block recipe with this parameter set to a low value. Make use of the block’s own iterations or simulate over time to make sure the adjacency information is used frequently to update the solve between model iterations.

Seed

A seed value that controls the stochastic update mask.

Update Rate

The fraction of cells to update each iteration, in the range 0.1 to 0.9. Lower values update fewer cells per step, producing a more gradual evolution. Use the seed to change the random number generation, affecting which cells get updated. This can be used to generate variations of the overall pattern.

Update Mask Type

Controls how the update mask is applied to each cell.

Amplitude-Weighted

The update is scaled by the incoming 0-1 mask, but the likelihood of an update is still only controlled by the seed. This produces smoother gradual evolution.

Probabilistic

The update is always applied fully, but the 0-1 mask drives the probability of an update occurring in the first place. This creates noisier evolution, but pronounces the cell-based underlying structure.

Cell Rotation

Applies a rotation in turns to the cell perception kernel, where a value of 1 is a full rotation (360°). This is added on top of the per-cell rotation coming from the rotation input.

Cell Scale

Applies a scale to the cell perception gradient. This is multiplied with the per-cell scale coming from the scale input. The final scale is clamped to the range 0.2 to 1 to avoid exploding gradients. You can use values above 1 to multiply a small input scale mask up towards the upper bound of the valid range, but the values are limited by the internal clamping.

Adjacency

World Space Direction

When an adjacency cable is connected, this is the world space direction vector used as an up vector when computing the cell rotation adjacency information. With the default value of (0,1,0), the pattern on the geometry matches the pattern on a 2D layer in the origin when looking along the Z axis.

Advanced

Size Ref Scale

A scale factor applied to the size_ref input resolution to determine the working resolution of the NCA. Lower fractions reduce memory usage and computation time.

1/1

Full resolution.

1/2

Half resolution.

1/4

Quarter resolution.

1/8

Eighth resolution.

Execution Provider

Determines which ONNX execution provider to use for inference. By default, the node attempts to pick the best available provider and prefers to use GPU acceleration.

Automatic

Chooses the best provider for the current system. This option prioritizes CUDA if installed, DirectML/CoreML as a fallback depending on the platform, and CPU inference if no GPU provider is available.

CPU

Perform inference using on the CPU.

CUDA

Perform inference using CUDA/cuDNN. CUDA and cuDNN must be installed using the packages provided by NVIDIA.

DirectML

Only available on Windows. Performs inference using the Windows Direct Machine Learning library.

CoreML

Only available on macOS. Performs inference using Apple’s Core ML library.

Device ID

This parameter can be used to specify which GPU to use for inference when multiple GPUs are available. It has no effect when using CPU inference.

Inputs

size_ref

A representative layer that determines the size of the output image and controls the metadata.

cells

The input cell state to evolve.

updatemask

An optional mask that controls cell updates each iteration.

rotation

An optional per-cell rotation map.

scale

An optional per-cell scale map.

adjacency

An optional per-cell adjacency cable. This provides directional and scale information for the cell neighborhood to allow growing seamless textures on geometry.

Outputs

cells

The evolved cell state.

See also

Copernicus nodes