nengo_extras.networks.MatrixMult(n_neurons, shape_left, shape_right, net=None)[source]¶Computes the matrix product A*B.
Both matrices need to be two dimensional.
See the Matrix Multiplication example for a description of the network internals.
| Parameters: | n_neurons : int
shape_left : tuple
shape_right : tuple
net : Network, optional (Default: None)
|
|---|---|
| Returns: | net : Network
|
nengo_extras.networks.Product(n_neurons, dimensions, input_magnitude=1, net=None)[source]¶Computes the element-wise product of two equally sized vectors.
nengo_extras.probe.probe_all(net, recursive=False, probe_options=None, **probe_args)[source]¶Probes all objects in a network.
| Parameters: | net : nengo.Network recursive : bool, optional (Default: False)
probe_options: dict, optional (Default: None)
|
|---|---|
| Returns: | A dictionary that maps objects and their attributes to their probes. |
Examples
Probe the decoded output and spikes in all ensembles in a network and its subnetworks:
with nengo.Network() as model:
ens1 = nengo.Ensemble(n_neurons=1, dimensions=1)
node1 = nengo.Node(output=[0])
conn = nengo.Connection(node1, ens1)
subnet = nengo.Network(label='subnet')
with subnet:
ens2 = nengo.Ensemble(n_neurons=1, dimensions=1)
node2 = nengo.Node(output=[0])
probe_options = {nengo.Ensemble: ['decoded_output', 'spikes']}
probes = probe_all(model, recursive=True, probe_options=probe_options)