Model of peripheral nerve with ephaptic coupling (Capllonch-Juan & Sepulveda 2020)

 Download zip file 
Help downloading and running models
Accession:263988
We built a computational model of a peripheral nerve trunk in which the interstitial space between the fibers and the tissues is modelled using a resistor network, thus enabling distance-dependent ephaptic coupling between myelinated axons and between fascicles as well. We used the model to simulate a) the stimulation of a nerve trunk model with a cuff electrode, and b) the propagation of action potentials along the axons. Results were used to investigate the effect of ephaptic interactions on recruitment and selectivity stemming from artificial (i.e., neural implant) stimulation and on the relative timing between action potentials during propagation.
Reference:
1 . Capllonch-Juan M, Sepulveda F (2020) Modelling the effects of ephaptic coupling on selectivity and response patterns during artificial stimulation of peripheral nerves. PLoS Comput Biol 16:e1007826 [PubMed]
Model Information (Click on a link to find other models with that property)
Model Type: Extracellular; Axon;
Brain Region(s)/Organism:
Cell Type(s): Myelinated neuron;
Channel(s):
Gap Junctions:
Receptor(s):
Gene(s):
Transmitter(s):
Simulation Environment: NEURON; Python;
Model Concept(s): Ephaptic coupling; Stimulus selectivity;
Implementer(s):
/
publication_data
dataset_02__stimulation
noec
code
README.md
algebra.py *
create_folders.py
extstim.csv
geometry.py *
get_stim_results.py
modify_files_all.sh *
recruitment_data.txt
run_all_simulations.sh *
run_all_simulations_specific.sh *
stim_results_current_00200nA_noEC.json
stim_results_current_00400nA_noEC.json
stim_results_current_00600nA_noEC.json
stim_results_current_00800nA_noEC.json
stim_results_current_01000nA_noEC.json
stim_results_current_01200nA_noEC.json
stim_results_current_01400nA_noEC.json
stim_results_current_01600nA_noEC.json
stim_results_current_01800nA_noEC.json
stim_results_current_02000nA_noEC.json
stim_results_current_02200nA_noEC.json
stim_results_current_02400nA_noEC.json
stim_results_current_02600nA_noEC.json
stim_results_current_02800nA_noEC.json
stim_results_current_03000nA_noEC.json
stim_results_current_03200nA_noEC.json
stim_results_current_03400nA_noEC.json
stim_results_current_03600nA_noEC.json
stim_results_current_03800nA_noEC.json
stim_results_current_04000nA_noEC.json
tools.py *
workspace.py *
                            
"""
This is just a module containing handy tools for lists, dictionaries, etc.
"""

import os
import numpy as np

import workspace as ws



def flattenlist(l):
	""" Flatten a list of lists """
	return [item for sublist in l for item in sublist]

def list_to_number(l):
	""" Given a list or a list of lists with ONLY ONE NUMBER INSIDE, 
	retrieve that number.
	If there's more than one number, yield an error and quit """


	# Check if it's a list or a number
	try:
		ll = len(l)
	except TypeError:
		# It's probably a number, so just return it as it is
		return float(l)

	l = np.array(l).flatten()
	if len(l) != 1:
		msg = 'ERROR: tools.list_to_number got a list with more than one number'
		ws.log(msg)
		ws.terminate()

	return float(l[0])

def append_items(d, k, items):
	""" Append a list of items to a list which is a value of a dictionary 
	entry and create the entry if it does not exist yet """
	try:
		d[k].append(items[0])
	except KeyError:
		# Create entry
		d[k] = items[:]
	else:
		d[k] = d[k] + items[1:]
	return d

def arrtonum(x):
	""" Meant only for arrays with one size 1. 
	Return the element as a float """
	try:
		a = x.mean()
	except AttributeError:
		a = x
	return a

def str2bool(s):
	""" Very simple tool to parse the strings 'True' or 'False' into
	their corresponding booleans """
	str2booldict = {
		"True": True, 
		"False": False
	}
	try:
		return str2booldict[s]
	except KeyError:
		return s

def explore_folder(path):
	""" List all the items of a folder and return its sub-folders """
	items = []
	dirs = []
	for item in os.listdir(path):
		items.append(item)
		if os.path.isdir(item):
			dirs.append(item)
	return items, dirs

Loading data, please wait...