You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is very minor but it's a difference between nengo and nengo_dl that might crop up in rare/special circumstances (discovered when looping and resetting probes inside of the simulator context).
In Nengo an empty probe array is a NumPy ndarray. But in NengoDL it is a Python list. I'd expect the behaviour to be the same with the NengoDL simulator since it is a drop-in replacement.
A minimal example:
import nengo
import nengo_dl
with nengo.Network() as model:
p = nengo.Probe(nengo.Node(0))
with nengo_dl.Simulator(model) as sim:
# sim.step()
print(sim.data[p].shape)
Raises: AttributeError: 'list' object has no attribute 'shape'.
Switching nengo_dl.Simulator to nengo.Simulator instead outputs the shape: (0,).
Likewise, uncommenting the sim.step() (with either simulator) outputs the shape: (1, 1).
The text was updated successfully, but these errors were encountered:
This is very minor but it's a difference between
nengo
andnengo_dl
that might crop up in rare/special circumstances (discovered when looping and resetting probes inside of the simulator context).In Nengo an empty probe array is a NumPy ndarray. But in NengoDL it is a Python list. I'd expect the behaviour to be the same with the NengoDL simulator since it is a drop-in replacement.
A minimal example:
Raises:
AttributeError: 'list' object has no attribute 'shape'
.Switching
nengo_dl.Simulator
tonengo.Simulator
instead outputs the shape:(0,)
.Likewise, uncommenting the
sim.step()
(with either simulator) outputs the shape:(1, 1)
.The text was updated successfully, but these errors were encountered: