Pin of JAX version
Installing Jaxley
will no longer install the newest version of JAX
. We realized that, on CPU, with version jax==0.4.32
or newer, simulation time in Jaxley
is 10x slower and gradient time is 5x slower as compared to older versions of JAX. Newer versions of JAX
can be made equally fast as older versions by setting os.environ['XLA_FLAGS'] = '--xla_cpu_use_thunk_runtime=false'
at the beginning of your jupyter notebook (#570, @michaeldeistler).
New Features
net.record("i_IonotropicSynapse")
- refactor plotting (#539, @jnsbck).
- rm networkx dependency
- add
Network.arrange_in_layers
- disentangle moving of cells and plotting in
Network.vis
. To get the same asnet.vis(layers=[3,3])
, one now has to do:
net.arrange_in_layers([3,3])
net.vis()
-
Allow parameter sharing for groups of different sizes, i.e. due to inhomogenous numbers of compartments or for synapses with the same (pre-)synaptic parameters but different numbers of post-synaptic partners. (#514, @jnsbck)
-
Add
jaxley.io.graph
for exporting and importing of jaxley modules to and fromnetworkx
graph objects (#355, @jnsbck).- Adds a new (and improved) SWC reader, which is more flexible and should also be easier to extend in the future.
from jaxley.io.graph import swc_to_graph, from_graph graph = swc_to_graph(fname) # do something to the swc graph, i.e. prune it pruned_graph = do_something_to_graph(graph) cell = from_graph(pruned_graph, ncomp=4)
- Adds a new
to_graph
method for jaxley modules, which exports a module to anetworkX
graph. This allows to seamlessly work withnetworkX
's graph manipulation or visualization functions. "graph"
can now also be selected as a backend in theread_swc
.- See the improved SWC reader tutorial for more details.
Code Health
-
Add regression tests and supporting workflows for maintaining baselines (#475, #546, @jnsbck).
- Regression tests can be triggered by commenting "/test_regression" on a PR.
- Regression tests can be done locally by running
NEW_BASELINE=1 pytest -m regression
i.e. onmain
and thenpytest -m regression
onfeature
, which will produce a test report (printed to the console and saved to .txt).
-
Allow inspecting the version via
import jaxley as jx; print(jx.__version__)
(#577, @michaeldeistler).
Bug fixes
- Fixed inconsistency with type assertions arising due to
numpy
functions returning differentdtypes
on platforms like Windows (#567, @Kartik-Sama)