Update README.md
Browse files
README.md
CHANGED
|
@@ -6,10 +6,34 @@ license: mit
|
|
| 6 |
|
| 7 |
A toy model, trained on toy data generated from spikeinterface.
|
| 8 |
|
| 9 |
-
|
| 10 |
|
| 11 |
Used to try out the download features of hugging face hub.
|
| 12 |
|
| 13 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
|
| 15 |
Chris Halcrow
|
|
|
|
| 6 |
|
| 7 |
A toy model, trained on toy data generated from spikeinterface.
|
| 8 |
|
| 9 |
+
# Intended use
|
| 10 |
|
| 11 |
Used to try out the download features of hugging face hub.
|
| 12 |
|
| 13 |
+
# How to Get Started with the Model
|
| 14 |
+
|
| 15 |
+
This can be used to automatically label a sorting in spikeinterface. Provided you have a `sorting_analyzer`, it is used as follows
|
| 16 |
+
|
| 17 |
+
``` python
|
| 18 |
+
from huggingface_hub import hf_hub_download
|
| 19 |
+
import skops.io as skio
|
| 20 |
+
from spikeinterface.curation import auto_label_units
|
| 21 |
+
|
| 22 |
+
new_model_path = hf_hub_download(repo_id="chrishalcrow/toy_data_model", filename="best_model.skops")
|
| 23 |
+
pipeline = skio.load(new_model_path, trusted='numpy.dtype')
|
| 24 |
+
|
| 25 |
+
auto_label_units(sorting_analyzer = sorting_analyzer, pipeline = pipeline)
|
| 26 |
+
```
|
| 27 |
+
|
| 28 |
+
or you can download the entire repositry to `a_folder_for_a_pipeline`, and use
|
| 29 |
+
|
| 30 |
+
``` python
|
| 31 |
+
from spikeinterface.curation import auto_label_units, load_pipeline
|
| 32 |
+
|
| 33 |
+
pipeline = load_pipeline('a_folder_for_a_pipeline')
|
| 34 |
+
auto_label_units(sorting_analyzer = sorting_analyzer, pipeline = pipeline)
|
| 35 |
+
```
|
| 36 |
+
|
| 37 |
+
# Authors
|
| 38 |
|
| 39 |
Chris Halcrow
|