This repository contains the codes, routines and notebooks used in the work "The Role of Potassium and Calcium Currents in the Bistable Firing Transition".
This repository has dependencies with languages C and Python (version to be defined). It is advisable to create a unique python virtual environment to use the necessary packages. If you prefer, you can use conda enviroment. This project relies on Open MPI, an open-source Message Passing Interface implementation, for parallel computing tasks. You can install Open MPI using the package manager specific to your operating system.
After creating the environment, packages can be installed in the standard way from the Python Package Index (PyPI).
You can see the individual version of each package in the requirements.txt file.
Some results are shown via Jupyter Notebook, so it's important to have it installed.
-
Create a virtual enviroment with venv python package or conda. Activate the virtual enviroment and install packages with pip:
pip install -r requirements.txt
-
For parallel computing install MPI: Quick start: Installing Open MPI
First, in the “simulations_one_cell” or “simulations_network” folder, run “nrnivmodl” in the terminal to compile the NEURON files. This must only be done once.
Open the model's Jupyter notebook
Model of regular spiking neuron with slow Potassium Current for spike-frequency adaptation,
select the kernel with the virtual environment where the python packages were installed and run all the notebook cells. This is the result shown in Figure 1(A).
To simulate neuron networks it is recommended to configure the simulation parameters in the cfg.py file and the network parameters in the netParams.py file. To run the simulation, use the python3 init.py
command.
The results are stored in the location defined in the simulation configuration file (cfg.py), by default it is in the data/v0_batch1 folder. In this folder there will be a pickle file that stores a dictionary with all the simulation information, in addition to the figures produced.
Acknowledgments