Skip to main content

GUI for spikeinterface objects

Project description

spikeinterface-gui

GUI for spikeinterface objects without data copy.

This is a cross platform interactive viewer to inspect the final results and quality of any spike sorter supported by spikeinterface (kilosort, spykingcircus, tridesclous, moutainssort, yass, ironclust, herdinspikes, hdsort, klusta...)

This interactive GUI offer several views that dynamically refresh other views. This allow to very quickly check strenght and wikness of a sorter otuput.

Contrary to other viewers (like phy), this viewer skip the tedious and long step of copying and reformating the entire dataset (filetred signal + waveform + PCA) to a particular format or folder organisation. This gui is built on top of spike interface objects (Recording, Sorting, WaveformExtractor) Theses objects are "lazy" and retrieve data on the fly (no copy!). And contrary to phy, this is a view only tool : no manual curation at the moment (split/merge/trash have to be done outside).

This viewer internally use Qt (with PySide6, PyQT6 or PyQt5) and pyqtgraph. And so, this viewer is local desktop app (old school!!). There is a web based viewer work-in-progres here.

screenshot

Launch

You will need this viewer only and only if you known a bit of spikeinterface

Step 1 : extract waveforms

You first need to "extract waveform" with spikeinterface See help here

Note that:

  • not all waveforms snipet are extracted (See max_spikes_per_unit) only some of then
  • this step is cached to a folder (and can be reloaded)
  • this step can be run in parralel (and so quite fast)
  • optionaly PCa can be compute and displayed

Example:

from spikeinetrface.full as si
recording = si.read_XXXX('/path/to/my/recording')
recording_filtered = si.bandpass_filter(recording)
sorting = si.run_sorter('YYYYY', recording_filtered)
waveform_forlder = '/path/for/my/waveforms'
we = si.extract_waveforms(
    recording_filtered, sorting, waveform_folder,
    max_spikes_per_unit=500,
    ms_before=1.5, ms_after=2.5,
    n_jobs=10, total_memory='500M',
    progress_bar=True,
)
# and optionally compute principal component
pc = compute_principal_components(we,
    n_components=5,
    mode='by_channel_local',
    whiten=True)

Step 2 : open the GUI

With python:

import spikeinterface_gui
# This cerate a Qt app
app = spikeinterface_gui.mkQApp() 
# reload the waveform folder
we = WaveformExtractor.load_from_folder(waveform_forlder)
# create the mainwindow and show
win = spikeinterface_gui.MainWindow(we)
win.show()
# run the main Qt6 loop
app.exec_()

With the commend line

sigui /path/for/my/waveforms

Install

You need first to install one of this 3 packages (by order of preference):

  • pip install PySide6
  • pip install PyQt6
  • pip install PyQt5

From pypi:

pip install spikeinterface-gui

From sources:

git clone https://github.com/SpikeInterface/spikeinterface-gui.git
cd spikeinterface-gui
pip install .

Author

Samuel Garcia, CNRS, Lyon, France

This work is a port of the old tridesclous.gui submodule of top of spikeinterface.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

spikeinterface-gui-0.1.0.tar.gz (34.7 kB view details)

Uploaded Source

Built Distribution

spikeinterface_gui-0.1.0-py3-none-any.whl (44.1 kB view details)

Uploaded Python 3

File details

Details for the file spikeinterface-gui-0.1.0.tar.gz.

File metadata

  • Download URL: spikeinterface-gui-0.1.0.tar.gz
  • Upload date:
  • Size: 34.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.8.10

File hashes

Hashes for spikeinterface-gui-0.1.0.tar.gz
Algorithm Hash digest
SHA256 02421a25e7ad61dd6d9c7bd0b0bc7d5e4523e93745477de3b19ae4fe714b4493
MD5 5b14386d72e7d8c8ed960e42c6d63a3b
BLAKE2b-256 0136ce948385611dc8b4f216fb782c5cd9a178869e61b76a5454410cf20bcada

See more details on using hashes here.

File details

Details for the file spikeinterface_gui-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: spikeinterface_gui-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 44.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.8.10

File hashes

Hashes for spikeinterface_gui-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fe3a1a528f55fa58ebfd4c53c659f0ac648b3965512fd51fef5902b6c4aa3979
MD5 01ac28d1b985785a4f67ad6fc78d85a8
BLAKE2b-256 541a19063bcae5b380fcb9016e0e5613444780837d54545d4d8dae8c35791c2e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page