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

Multi-chip support, testing, and failure modes #197

merged 4 commits into from Apr 15, 2019


None yet
3 participants
Copy link

commented Mar 8, 2019

Abstracted two different methods of allocating resources to models:

  • OneToOne() which is the same method as before (default)
  • RoundRobin(n_chips) which cycles through chips per block / input

Ran the entire unit test suite with a manually-overwritten default of allocator=RoundRobin(n_chips=8) (on our local host; not shown) and discovered that all failed tests currently fall into one of two categories:

  1. Convolutional weights (pop[16|32]) across chips
  2. Use of SNIPS (precompute=False)

Multi-chip support is otherwise working and the user can override / customize the behaviour, with the following notes:

  • RoundRobin(n_chips) gives identical behaviour across any number of n_chips between 1 and 8 inclusive (unit-tested).
  • Each failure mode currently returns an error (unit-tested).

The current syntax for running a multi-chip simulation of the model is:

from nengo_loihi.hardware.allocators import RoundRobin  # or OneToOne

with Simulator(model, precompute=True,
               hardware_options={'allocator': RoundRobin(n_chips=8)}):


  • Is this abstraction okay for now? I realize things may change and so this is just a basic starting point that can be adapted.
  • Is this an acceptable level of exposure to the user, even if it might change in the future? Or do we have better ways of exposing advanced configuration? (Resolution: will need to rethink global simulator configuration at the level of Nengo core)
  • Are there more appropriate exceptions to raise?

@arvoelke arvoelke force-pushed the multi-chip branch from 22ca76a to 9ed809e Mar 8, 2019

@arvoelke arvoelke force-pushed the multi-chip branch from 9ed809e to 3b44ad4 Mar 8, 2019


This comment has been minimized.

Copy link
Contributor Author

commented Mar 12, 2019

Note to self: since this touches the Simulator docstring it is a natural place to simultaneously fix #147.

@arvoelke arvoelke referenced this pull request Mar 13, 2019


Better allocation #1

Show resolved Hide resolved nengo_loihi/hardware/ Outdated
Show resolved Hide resolved nengo_loihi/hardware/
Show resolved Hide resolved nengo_loihi/ Outdated
Show resolved Hide resolved nengo_loihi/ Outdated

@hunse hunse force-pushed the multi-chip branch from 3b44ad4 to 19baf3f Apr 11, 2019

@arvoelke arvoelke force-pushed the multi-chip branch from c371bd1 to cfb35b2 Apr 15, 2019

Expose hardware options on Simulator
This allows the allocator to be set by the user, since it is used
during Simulator/HardwareInterface creation and cannot be set after.

@hunse hunse force-pushed the multi-chip branch from cfb35b2 to a901208 Apr 15, 2019

arvoelke added some commits Mar 6, 2019

Add RoundRobin multi-chip allocator
- Disallow RoundRobin allocator with snips and test that error.
- Make OneToOne allocator a class.
- Unit test both allocators' data structures.
- Change some nxsdk_object methods to properties.
- Move the board validation to happen at the build level.
- Remove dead `add_axon` allocator code.
Explicitly fail for conv weights across chips
These connections are not supported by NxSDK.

@hunse hunse force-pushed the multi-chip branch from a901208 to c83acd1 Apr 15, 2019


hunse approved these changes Apr 15, 2019

@hunse hunse merged commit c83acd1 into master Apr 15, 2019

3 checks passed

Travis CI - Branch Build Passed
codecov/patch 100% of diff hit (target 100%)
codecov/project 99.29% (+<.01%) compared to d58499c

@hunse hunse deleted the multi-chip branch Apr 15, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.