Installation

MEArec is a Python package and it can be easily installed using pip:

pip install MEArec

If you want to install from sources and be updated with the latest development you can install with:

git clone https://github.com/alejoe91/MEArec
cd MEArec
python setup.py install (or develop)

Requirements

The following are the Python requirements, which are installed when running the pip installer.

  • numpy
  • click
  • pyyaml
  • matplotlib
  • neo
  • elephant
  • h5py
  • MEAutility

Additional requirements for template generatiom

Installing NEURON

The template generation requires the NEURON simulator to be installed. From MEArec version 1.7.0, NEURON version 7.8 is supported. On UNIX systems NEURON can be installed with:

pip install neuron

On Windows machines, NEURON can be downloaded and installed from this link.

Installing LFPy

LFPy is used to generate extracellular templates. It is not installed by default, but it can be easily installed with:

pip install LFPy>=2.2

Test the installation

You can test that MEArec is correctly imported in python:

import MEArec as mr

And that the CLI is working. Open a terminal and run:

mearec

You should get the list of available commands:

Usage: mearec [OPTIONS] COMMAND [ARGS]...

  MEArec: Fast and customizable simulation of extracellular recordings on
  Multi-Electrode-Arrays

Options:
  --help  Show this message and exit.

Commands:
  available-probes        Print available probes.
  default-config          Print default configurations.
  gen-recordings          Generates RECORDINGS from TEMPLATES.
  gen-templates           Generates TEMPLATES with biophysical simulation.
  set-cell-models-folder  Set default cell_models folder.
  set-recordings-folder   Set default recordings output folder.
  set-recordings-params   Set default templates output folder.
  set-templates-folder    Set default templates output folder.
  set-templates-params    Set default templates output folder.