gentnerlab / klusta-pipeline

data pipeline for analyzing spike2 collected data in klustakwik
BSD 3-Clause "New" or "Revised" License
4 stars 7 forks source link

write to dat instead of raw.kwd #29

Open neuromusic opened 8 years ago

neuromusic commented 8 years ago

this will be to support the latest version of klusta

expected use

add another argument to the command line, e.g. --format=dat or --format=kwd where kwd is default for backwards compatibility

expected outputs

how should we manage multiple recordings? klusta doesn't support them, so should we manually append?

neuromusic commented 8 years ago

here's the prm format


experiment_name = 'hybrid_10sec'
prb_file = '1x32_buzsaki'

traces = dict(
    raw_data_files=[experiment_name + '.dat'],
    voltage_gain=10.,
    sample_rate=20000,
    n_channels=32,
    dtype='int16',
)

spikedetekt = dict(
    filter_low=500.,  # Low pass frequency (Hz)
    filter_high_factor=0.95 * .5,
    filter_butter_order=3,  # Order of Butterworth filter.

    filter_lfp_low=0,  # LFP filter low-pass frequency
    filter_lfp_high=300,  # LFP filter high-pass frequency

    chunk_size_seconds=1,
    chunk_overlap_seconds=.015,

    n_excerpts=50,
    excerpt_size_seconds=1,
    threshold_strong_std_factor=4.5,
    threshold_weak_std_factor=2.,
    detect_spikes='negative',

    connected_component_join_size=1,

    extract_s_before=16,
    extract_s_after=16,

    n_features_per_channel=3,  # Number of features per channel.
    pca_n_waveforms_max=10000,
)

klustakwik2 = dict(
    num_starting_clusters=100,
)

note: it looks like they will take multiple dat files, so we could dump each "recording" to it's own dat? I guess? need to see how the new version of klusta is handling this

neuromusic commented 8 years ago

maybe this needs a make_dat script instead of a flag on make_kwd