Skip to content

Commit 8f94d86

Browse files
committed
Bump
1 parent 375531a commit 8f94d86

File tree

3 files changed

+10
-7
lines changed

3 files changed

+10
-7
lines changed

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ dependencies = [
1919
"polars>=0.20.26",
2020
"pyarrow>=14.0",
2121
]
22-
version = "0.1.33"
22+
version = "0.1.34"
2323
classifiers = [
2424
"Development Status :: 3 - Alpha",
2525
"Programming Language :: Python :: 3",

src/npc_ephys/spikeinterface.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -461,11 +461,9 @@ def spike_amplitudes(self, probe: str) -> tuple[npt.NDArray[np.floating], ...]:
461461
unit_indexes = self.unit_indexes(probe)
462462
spike_amplitudes_by_unit: list[npt.NDArray[np.floating]] = []
463463
for index in sorted(np.unique(unit_indexes)):
464-
spike_amplitudes_by_unit.append(
465-
spike_amplitudes[unit_indexes == index]
466-
)
464+
spike_amplitudes_by_unit.append(spike_amplitudes[unit_indexes == index])
467465
return tuple(spike_amplitudes_by_unit)
468-
466+
469467
@functools.cache
470468
def unit_locations(self, probe: str) -> npt.NDArray[np.floating]:
471469
return np.load(

src/npc_ephys/units.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -224,8 +224,13 @@ def _device_helper(
224224
[len(unit) for unit in units_x_spike_times],
225225
), "Mismatch between rows in spike_times and metrics.csv"
226226
df_device_metrics["spike_times"] = units_x_spike_times
227-
df_device_metrics["spike_amplitudes"] = spike_interface_data.spike_amplitudes(electrode_group_name)
228-
assert all(len(df_device_metrics["spike_amplitudes"].iloc[i]) == len(spike_times) for i, spike_times in enumerate(units_x_spike_times)), "Mismatch between spike_times and spike_amplitudes"
227+
df_device_metrics["spike_amplitudes"] = spike_interface_data.spike_amplitudes(
228+
electrode_group_name
229+
)
230+
assert all(
231+
len(df_device_metrics["spike_amplitudes"].iloc[i]) == len(spike_times)
232+
for i, spike_times in enumerate(units_x_spike_times)
233+
), "Mismatch between spike_times and spike_amplitudes"
229234

230235
return df_device_metrics
231236

0 commit comments

Comments
 (0)