API reference#

Modules#

jaxley.Compartment

A single compartment.

jaxley.Branch

A branch made up of one or multiple compartments (without branchpoints).

jaxley.Cell

A cell made up of one or multiple branches (with branchpoints).

jaxley.Network

A network made up of multiple cells, connected by synapses.

Simulation#

jaxley.integrate

Solves ODE and simulates neuron model.

jaxley.integrate.build_init_and_step_fn

Return init_fn and step_fn which initialize modules and run update steps.

Morphologies#

jaxley.read_swc

Reads SWC file into a Cell.

jaxley.morphology.distance_direct

Returns the direct distance between a root and other compartments.

jaxley.morphology.distance_pathwise

Returns the pathwise distance between a root and other compartments.

jaxley.morphology.morph_delete

Deletes part of a morphology.

jaxley.morphology.morph_connect

Combines two morphologies into a single cell.

Channels#

jaxley.channels.Channel

Channel base class.

jaxley.channels.HH

Hodgkin-Huxley channel based on Sterratt, Graham, Gillies & Einevoll.

jaxley.channels.Izhikevich

Izhikevich neuron model.

jaxley.channels.Rate

Rate-based, unit-less, neuron model.

jaxley.channels.Fire

Mechanism to reset the voltage when it crosses a threshold.

jaxley.channels.Na

Sodium channel based on Pospischil et al., 2008.

jaxley.channels.K

Potassium channel based on Pospischil et al., 2008.

jaxley.channels.Leak

Leak current based on Pospischil et al., 2008.

jaxley.channels.Km

Slow M Potassium channel based on Pospischil et al., 2008.

jaxley.channels.CaL

L-type Calcium channel based on Pospischil et al., 2008.

jaxley.channels.CaT

T-type Calcium channel based on Pospischil et al., 2008.

Pumps#

jaxley.pumps.Pump

Pump base class.

jaxley.pumps.CaFaradayConcentrationChange

Update the intracellular calcium ion concentration depending on calcium current.

jaxley.pumps.CaNernstReversal

Compute Calcium reversal from inner and outer concentration of calcium.

jaxley.pumps.CaPump

Calcium dynamics based on Destexhe et al. 1994.

Synapses#

jaxley.synapses.Synapse

Base class for a synapse.

jaxley.synapses.IonotropicSynapse

Compute synaptic current and update synapse state for a generic ionotropic synapse.

jaxley.synapses.TanhRateSynapse

Compute synaptic current for tanh synapse (no state).

jaxley.synapses.TanhConductanceSynapse

Compute synaptic current for a simple conductance synapse (no state).

Connectivity#

jaxley.connect.connect

Connect specific compartments of a network with a synapse.

jaxley.connect.connectivity_matrix_connect

Connect cells of a network with synapses via a boolean connectivity matrix.

jaxley.connect.fully_connect

Fully (densely) connect cells of a network with synapses.

jaxley.connect.sparse_connect

Sparsely connect cells of a network with synapses.

Optimization#

jaxley.optimize.transforms.SigmoidTransform

Sigmoid transformation.

jaxley.optimize.transforms.SoftplusTransform

Softplus transformation.

jaxley.optimize.transforms.NegSoftplusTransform

Negative softplus transformation.

jaxley.optimize.transforms.AffineTransform

jaxley.optimize.transforms.ChainTransform

Chaining together multiple transformations

jaxley.optimize.transforms.MaskedTransform

jaxley.optimize.transforms.CustomTransform

Custom transformation.

jaxley.optimize.optimizer.TypeOptimizer

optax wrapper which allows different argument values for different params.

Graph backend#

jaxley.io.graph.to_swc_graph

Read a SWC file and return a SWC graph via networkX.

jaxley.io.graph.build_compartment_graph

Return a networkX graph that indicates the compartment structure.

jaxley.io.graph.vis_compartment_graph

Visualize a compartment graph.

jaxley.io.graph.from_graph

Return a Jaxley module from a compartmentalized networkX graph.

jaxley.modules.base.to_graph

Export a jx.Module as a networkX compartment graph.