During the compiler’s validate pass, it found that layer N expects expected input features, but layer N-1 produces got output features. The two layers cannot be connected.
The most common cause: you changed the size of one layer but forgot to update the adjacent layer.For example:
# Bug: Dense(512, 20) can't connect to LIF that was set up for 256 outputsmodel = snn.Sequential( snn.Dense(700, 256), # outputs 256 snn.LIF(tau_mem=20.0, threshold=0.3), snn.Dense(512, 20), # expects 512 but gets 256 snn.LIF(tau_mem=20.0, threshold=0.3),)