Update the Arbor backend to support Arbor 0.10.0 – 0.12.2#842
Merged
Conversation
Arbor 0.10.0 introduced breaking changes to its Python bindings that prevented the backend from importing/running. Update the backend and version pins accordingly: - Units at the user interface: physical quantities passed to decor.set_property/set_ion, threshold_detector, iclamp, the spike schedules and simulation.run must now be unit-typed (arbor.units). - Morphology loaders now return a bundle; use load_swc_neuron(f).segment_tree instead of the removed raw=True argument. - Probes now require a tag string and sampling is addressed by (gid, tag) instead of the removed cell_member index. Also fixes a latent frequency-unit bug in SpikeSourcePoisson: rate (Hz) was passed into Arbor's kHz frequency slot; it is now tagged with U.Hz, matching PyNN's Hz semantics and the NEURON/NEST backends.
Differences between these versions are handled in a new pyNN/arbor/_compat.py.
Arbor >= 0.10 requires the delay argument to arbor.connection to be a unit-typed quantity rather than a plain float; pass it in ms.
…tantiation MultiCompartmentNeuron.__init__ replaced the ion-channel and post-synaptic classes with instances in place, mutating the class-level dicts that hold them. A second instantiation of the same cell type then failed with "object is not callable", and setting ion_channels on the class in one test leaked instances into others.
# Conflicts: # test/system/scenarios/test_cell_types.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Arbor backend previously required Arbor 0.9.0 and no longer worked with current Arbor releases. This PR updates it to work, from a single codebase, with every Arbor version from 0.10.0 (the version currently in the EBRAINS Software Distribution) through 0.12.2, and adds additional tests.
Arbor API changes accommodated:
arbor.units) for properties, stimuli, thresholds, schedules and run/dt;cv_policy_max_extentalso gained units in 0.12. (This also fixed a latent Hz-vs-kHzSpikeSourcePoissonbug.)load_swc_neuron(...).segment_tree.decoronto thecable_cellconstructorspike_recording.local— the global callback was broken by the 0.12 MPI rework (arbor-sim/arbor#2511).iclamp→i_clamp, anddecor.place()dropped the label for current stimuli.In addition, the catalogue
.sois now keyed onarbor.__version__to avoid stale ABIs.