Cephalo

Download

Docs

About


Documentation


Installation

Installation procedes as follows.

  1. Install dependencies.
  2. Install Cephalo.

Enthought Python Distribution

Before installing Cephalo, you should have some dependencies installed. Cephalo requires that you have Python and several scientific libraries installed. These are most easily acquired by installing the Enthought Python Distribution (free for academic use). EPD is available for Windows, Mac OS X, and Linux.

EPD is installed by means of an installer. This should be straightforward.

Setuptools

Setuptools makes it easy to install the other packages that Cephalo depends on. The setuptools site has detailed instructions on how to install it. Less detailed instructions are below.

Installing setuptools on Windows

On Windows, you just need to download this installer and doubleclick it.

Installing setuptools on Mac OS X

On Mac OS X, you need to download this installer script. Open Terminal, navigate to where you downloaded the script, then run the script as usual.

> sudo sh setuptools-0.6c11-py2.5.egg

Cephalo

No matter what platform you are on, you can install Cephalo by navigating to the directory where Cephalo is unzipped to and then typing:

> sudo python setup.py install

Using Cephalo

Once you have installed Cephalo and its dependencies, you can use it. There are four steps to processing your data with Cephalo.

1. Convert .sqd files to .h5 files.

> sqd2h5 *.sqd

2. Pick channels to analyze for each subject.

This should still be done with MEG160.

3. Create a configuration file.

More on configuration files below.

4. Run Cephalo.

> cephalo experiment.ceph

Creating configuration files

Below I have included a sample configuration file. Configuration files have five parts:

  1. Experiment information
  2. Triggers and conditions
  3. Recording parameters
  4. Epoch parameters
  5. Subject information
# Experiment Info
name: Ledif
experimenter: Pedro Alcocer
data_directory: data/
output_directory: output/

# Triggers and conditions
conditions:
    162: [dlif, standard]
    164: [delif, standard]
    166: [ldif, standard]
    168: [ledif, standard]
    163: [delif, deviant]
    165: [dlif, deviant]
    167: [ledif, deviant]
    169: [ldif, deviant]

# Recording Parameters
sampling_frequency: 1000
lowpass_frequency: 20

# Epoch Parameters
epoch_pre:  100
epoch_post: 600
expected_epochs: 100

# Subjects
subjects:
    R1093: [44, 79, 80, 85, 88, 90, 127, 129, 131, 137, 138]
    R1105: [45, 76, 77, 79, 80, 88, 90, 127, 130, 136]
    R1292: [48, 76, 77, 79, 80, 85, 88, 90, 130, 5]
    R1277: [43, 44, 77, 80, 82, 85, 87, 88, 90, 129]

Experiment information

This section contains metadata about your experiment. It expects four pieces of information:

  1. name: The experiment's name.
  2. experimenter: The name of the person or people doing the experiment.
  3. data_directory: The directory where your data resides relative to where you intended to run Cephalo (usually the directory where your configuration file is saved).
  4. output_directory: The directory where whatever files Cephalo creates will be stored.

Triggers and conditions

This section contains information about what trigger channels were used in the experiment and what experimental factors they are associated with. Every trigger should be on its own line. Below, 162 is the trigger channel and [dlif , standard] are two factors associated with that channel.

162: [dlif, standard]

Recording parameters

  1. sampling_frequency: The frequency at which the data was sampled.
  2. lowpass_frequency: The frequency at which a lowpass filter should be applied.

Epoch parameters

  1. epoch_pre: Number of pre-stimulus samples to take.
  2. epoch_post: Number of post-stimulus samples to take.
  3. expected_epochs: Minimum number of epochs you expect.

Subject information

Each line should have a subject ID, followed by a colon, folowed by a list of channels. The subject ID should be the name of the .h5 file minus the .h5 extension. If the file is name R1093new.h5, the subject ID should be R1093new. The channels should be channels that you want to analyze. They should be enclosed in square brackets and separated by commas.

R1093: [44, 79, 80, 85, 88, 90, 127, 129, 131, 137, 138]