I’m trying to understand why the PES implementation in NengoDL requires redefining the build function [link].
This seems to be done to “avoid slicing encoders along an axis > 0” but I’m not sure what’s meant by this or why it would be a technical problem.
What’s the problem with doing the equivalent to error = dot(encoders, error)
inside SimPESBuilder
?
The build_pes
function in Nengo Core has encoder slicing along axis > 0 at line 726 in learning_rules.py
. Nengo-DL does not support this slicing along an axis > 0 and therefore it is required to have a custom build function.
The error = dot(encoders, error)
is effectively the same.
Thanks!
What does that slicing actually do? In my topology:
pre = nengo.Ensemble( n_neurons, dimensions=dimensions, seed=seed ) post = nengo.Ensemble( n_neurons, dimensions=dimensions, seed=seed ) conn = nengo.Connection( pre.neurons, post.neurons, transform=np.zeros( (post.n_neurons, pre.n_neurons) ) )
I see that conn.post_slice
is always None
, so local_error=error
without any padding.
When would the problematic slicing come into effect?
It would come into effect if there is slicing of the post synaptic object like the following
conn = nengo.Connection(
pre.neurons,
post.neurons[:5],
transform=np.zeros( (5, pre.n_neurons) )
)
ther would be a not None conn.post_slice
.