Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add "event-based" processing mode #1665

Open
hunse opened this issue Jan 20, 2021 · 0 comments
Open

Add "event-based" processing mode #1665

hunse opened this issue Jan 20, 2021 · 0 comments

Comments

@hunse
Copy link
Collaborator

hunse commented Jan 20, 2021

Is your feature request related to a problem? Please describe.

When we're dealing with spikes, we currently spend a lot of computation multiplying by zeros or (in the case where neurons can only spike once per timestep) values of a fixed size (i.e. 1 / dt).

These problems also appear for any spike-based nodes (e.g. DVS output).

Describe the solution you'd like

  1. Represent spikes sparsely, so we're not multiplying by zeros. @arvoelke has already done this in the NengoNumba backend: https://gl.appliedbrainresearch.com/arvoelke/nengo
  2. Represent spikes without amplitude, so that we can sum weights when applying them to spikes, rather than multiplying.

The second improvement is not necessary to get the benefits of the first (i.e. we could do the first but not the second), and it's unclear how much advantage each one would have. (@arvoelke has done some benchmarking of the first improvement, but it's been in the context of NengoNumba, so it might not be directly translatable. Nevertheless, sparse ensembles provide about a 1.25x speedup for NengoNumba on the Nengo test suite.)

I see this as a feature that we can turn on or off at the Simulator level. It would also be something for the reference simulator only (of course, backends are free to do the same or similar if they want, but are certainly not required).

Describe alternatives you've considered

Improvement 1 can be done just by making signals representing spikes sparse, and then having operators act on those signals appropriately. Improvement 2 is a bit more complicated, because multiple spikes per timestep would have to be handled differently (e.g. if we're sending a list of indices to indicate which neurons spiked, you could repeat an index to indicate multiple spikes), and neuron amplitudes and the default 1 / dt spike scaling would have to be folded into connection weights, rather than scaling the spikes. So we can decide whether to do Improvement 2 or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant