User Tools

Site Tools


ephys_pipeline:1_pipeline_overview

This is an old revision of the document!


Ephys pipeline overview

Folder structure

  • Y:\Data\TDTtanks\Monkey_phys contains the Raw TDT data
  • Y:\Data\Sortcodes\Monkey_phys contains sorting related files
  • Y:\Data\Monkey contains the behavioral data
  • Y:\Data\Monkey_phys_mat_from_TDT contains recorded data, arranged in the same trial structure as the behavioral data
  • Y:\Data\Monkey_phys_combined_monkeypsych_TDT contains trial structures with combined behavioral and ephys data
  • Y:\Data\All_phys_preprocessing_log\Monkey_phys contains automatically created log files of all preprocessing performed
  • \Dropbox\DAG\phys\Monkey_phys_dpz contains
    1. Electrode_depths matfile
    2. Same_cells matfile
    3. plx files excel table
    4. Sorted_neurons excel table

General Workflow

  • Update Electrode depths matfile. Only block/channel combinations defined here will be processed (?)
  • (Optional - Synapse only) Reformat Synapse tank folder format to match previous conventions
  • (Optional - WC only) Run waveclus automatic sorting (Channels with electrodes in the same depth across blocks will be combined across blocks)
  • (Optional - WC only) manually refine WC sorting
  • (Optional - Plexon only) Create Plexon sortcodes
  • (Optional - Plexon only) Manual Plexon sorting
  • Update plx files excel table
  • Combine TDT and behavioral data
    1. Create TDT trial structure
    2. Combine
  • Update Same_cells matfile
  • Update sorted_neurons excel table

Most of the steps above are automatized, check out phys_gui page for details.

Synchronization

  • TDT data is stored as a continuous data (starting from start of recording)
  • behavioral data is stored per trial (starting from first trial)

For combining both, we first convert TDT data to trial format (function TDT_trial_struct.m) preferentially using epocs store (Tnum and SVal) information.
Note: There is a flag for using the continous state information stream (stream_state_info), but it is permanently turned off, as the epoc information is already extracted from the continuous state information within the TDT circuit.
Importantly, trial start reference is STATE 2 (fixation acquisition). Trial end is STATE 2 of the next trial.
Therefore, ITI between trial 1 and 2 as well as STATE 1 (initiation) of trial 2 are found at the end of trial 1.
This also means that data recorded before 1st trial's state 2 can not be stored in the trial structure and is saved in a separate variable (First_trial_INI) instead.

Associated code

ephys_pipeline/1_pipeline_overview.1639495076.txt.gz · Last modified: 2022/12/29 07:15 (external edit)