Skip to content

Commit 76c4184

Browse files
authored
Prepare 0.104.8 with figpack fixes (#4633)
1 parent 575b9cf commit 76c4184

6 files changed

Lines changed: 31 additions & 14 deletions

File tree

doc/releases/0.104.8.rst

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
.. _release0.104.8:
2+
3+
SpikeInterface 0.104.8 release notes
4+
------------------------------------
5+
6+
June 30th 2026
7+
8+
Minor release with bug fixes for figpack metrics and curation
9+
10+
extractors:
11+
12+
* Figpack metrics serialization and curation args (#4632)
13+
14+
Contributors:
15+
16+
* @alejoe91

doc/whatisnew.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ Release notes
88
.. toctree::
99
:maxdepth: 1
1010

11+
releases/0.104.8.rst
1112
releases/0.104.7.rst
1213
releases/0.104.6.rst
1314
releases/0.104.5.rst
@@ -59,7 +60,7 @@ Release notes
5960
releases/0.9.9.rst
6061
releases/0.9.1.rst
6162

62-
Versions 0.104.1/7
63+
Versions 0.104.1/8
6364
==================
6465

6566
* Minor releases with bug fixes

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "spikeinterface"
3-
version = "0.104.7"
3+
version = "0.104.8"
44
authors = [
55
{ name="Alessio Buccino", email="alessiop.buccino@gmail.com" },
66
{ name="Samuel Garcia", email="sam.garcia.die@gmail.com" },

src/spikeinterface/widgets/base.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,11 @@ def set_default_plotter_backend(backend):
3232
"figtitle": "The figure title, default: None",
3333
},
3434
"figpack": {
35-
"generate_url": "If True, the figurl URL is generated and printed, default: True",
3635
"display": "If True and in jupyter notebook/lab, the widget is displayed in the cell, default: True.",
3736
"figlabel": "The figurl figure label, default: None",
3837
"inline": "If True, the widget is displayed inline in the cell, default: None",
3938
"height": "The height of the figpack View in jupyter, default: None",
39+
"wait_for_input": "If True, the widget waits for user input before continuing, default: False",
4040
},
4141
"ipywidgets": {
4242
"width_cm": "Width of the figure in cm, default: 10",
@@ -57,7 +57,7 @@ def set_default_plotter_backend(backend):
5757

5858
default_backend_kwargs = {
5959
"matplotlib": {"figure": None, "ax": None, "axes": None, "ncols": 5, "figsize": None, "figtitle": None},
60-
"figpack": {"generate_url": True, "display": True, "figlabel": None, "inline": None, "height": None},
60+
"figpack": {"display": True, "figlabel": None, "inline": None, "height": None, "wait_for_input": False},
6161
"ipywidgets": {"width_cm": 25, "height_cm": 10, "display": True, "controllers": None},
6262
"ephyviewer": {},
6363
"spikeinterface_gui": {},

src/spikeinterface/widgets/sorting_summary.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,6 @@ def plot_figpack(self, data_plot, **backend_kwargs):
140140
unit_ids=unit_ids,
141141
max_spikes_per_unit=dp.max_amplitudes_per_unit,
142142
hide_unit_selector=True,
143-
generate_url=False,
144143
display=False,
145144
backend=backend,
146145
).view
@@ -149,7 +148,6 @@ def plot_figpack(self, data_plot, **backend_kwargs):
149148
unit_ids=unit_ids,
150149
sparsity=sparsity,
151150
hide_unit_selector=True,
152-
generate_url=False,
153151
display=False,
154152
backend=backend,
155153
).view
@@ -158,7 +156,6 @@ def plot_figpack(self, data_plot, **backend_kwargs):
158156
unit_ids=unit_ids,
159157
min_similarity_for_correlograms=min_similarity_for_correlograms,
160158
hide_unit_selector=True,
161-
generate_url=False,
162159
display=False,
163160
backend=backend,
164161
).view
@@ -167,7 +164,6 @@ def plot_figpack(self, data_plot, **backend_kwargs):
167164
sorting_analyzer,
168165
unit_ids=unit_ids,
169166
hide_unit_selector=True,
170-
generate_url=False,
171167
display=False,
172168
backend=backend,
173169
).view
@@ -176,7 +172,6 @@ def plot_figpack(self, data_plot, **backend_kwargs):
176172
sorting_analyzer,
177173
unit_ids=unit_ids,
178174
immediate_plot=False,
179-
generate_url=False,
180175
display=False,
181176
backend=backend,
182177
)
@@ -202,11 +197,13 @@ def plot_figpack(self, data_plot, **backend_kwargs):
202197
if dp.curation:
203198
if use_sortingview:
204199
curation_class = vv_views.SortingCuration2
200+
curation_kwargs = {"label_choices": dp.label_choices}
205201
else:
206202
curation_class = vv_views.SortingCuration
207-
v_curation = curation_class(label_choices=dp.label_choices)
203+
curation_kwargs = {"default_label_options": dp.label_choices}
204+
v_curation = curation_class(**curation_kwargs)
208205
v1 = vv_base.Splitter(
209-
direction="vertical", item1=vv_views.LayoutItem(v_units_table), item2=vv_views.LayoutItem(v_curation)
206+
direction="vertical", item1=vv_base.LayoutItem(v_units_table), item2=vv_base.LayoutItem(v_curation)
210207
)
211208
else:
212209
v1 = v_units_table

src/spikeinterface/widgets/utils_figpack.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,11 @@ def handle_display_and_url(widget, view, **backend_kwargs):
7474
else:
7575
figlabel = backend_kwargs.get("figlabel")
7676
inline = backend_kwargs.get("inline", None)
77+
wait_for_input = backend_kwargs.get("wait_for_input", False)
7778
if inline is None and is_notebook():
7879
inline = True
7980
height = backend_kwargs.get("height", None)
80-
url = view.show(title=figlabel, inline=inline, inline_height=height)
81+
url = view.show(title=figlabel, inline=inline, inline_height=height, wait_for_input=wait_for_input)
8182
print(url)
8283

8384
return url
@@ -101,9 +102,11 @@ def generate_unit_table_view(
101102
units_tables = make_units_table_from_sorting(sorting)
102103
# analyzer = None
103104

105+
unit_ids = make_serializable(sorting.unit_ids)
106+
104107
if unit_properties is None:
105108
ut_columns = []
106-
ut_rows = [vv_views.UnitsTableRow(unit_id=u, values={}) for u in sorting.unit_ids]
109+
ut_rows = [vv_views.UnitsTableRow(unit_id=u, values={}) for u in unit_ids]
107110
else:
108111
# keep only selected columns
109112
unit_properties = np.array(unit_properties)
@@ -125,7 +128,7 @@ def generate_unit_table_view(
125128
ut_columns.append(vv_views.UnitsTableColumn(key=col, label=col, dtype=txt_dtype))
126129

127130
ut_rows = []
128-
for unit_index, unit_id in enumerate(sorting.unit_ids):
131+
for unit_index, unit_id in enumerate(unit_ids):
129132
row_values = {}
130133
for col in unit_properties:
131134
values = units_tables[col].to_numpy()

0 commit comments

Comments
 (0)