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
Found and explained by @adityagilra in #12. Here is the relevant text:
In simulator.py line 185, I had to modify it to check if data is not empty:
if len(data)>0:
if data[0].shape != true_shape:
data = map(
partial(np.reshape, newshape=true_shape), data)
I was calling sim.run() multiple times in my code and on some calls, data would be empty.
I tried reproducing this in a separate small test script, but couldn't. I thought this might be if the 'sample_every' param for a probe is larger than the 'duration' in the sim.run(duration), then data might be zero length. But this worked fine in the test script. So am unsure why this happens in my script.
The text was updated successfully, but these errors were encountered:
e2crawfo
changed the title
Simulator.data object sometimes empty after simulation
Simulator.data object sometimes empty after simulation.
May 25, 2016
Found and explained by @adityagilra in #12. Here is the relevant text:
The text was updated successfully, but these errors were encountered: