Skip to content

Commit

Permalink
Merge pull request #2677 from alejoe91/preprare_0.100.5
Browse files Browse the repository at this point in the history
Preprare 0.100.5
  • Loading branch information
alejoe91 authored Apr 6, 2024
2 parents 7d0e1da + bb88a49 commit 7c2656c
Show file tree
Hide file tree
Showing 8 changed files with 32 additions and 11 deletions.
1 change: 1 addition & 0 deletions .github/workflows/core-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
types: [synchronize, opened, reopened]
branches:
- main
- 0.100-bug-fixes

concurrency: # Cancel previous workflows on the same pull request
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/full-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
types: [synchronize, opened, reopened]
branches:
- main
- 0.100-bug-fixes

concurrency: # Cancel previous workflows on the same pull request
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down
12 changes: 12 additions & 0 deletions doc/releases/0.100.5.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
.. _release0.100.5:

SpikeInterface 0.100.5 release notes
------------------------------------

6th April 2024

Minor release with bug fixes

* Open Ephys: Use discovered recording ids to load sync timestamps (#2655)
* Fix channel gains in NwbRecordingExtractor with backend (#2661)
* Fix depth location in spikes on traces map (#2676)
6 changes: 6 additions & 0 deletions doc/whatisnew.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ Release notes
.. toctree::
:maxdepth: 1

releases/0.100.5.rst
releases/0.100.4.rst
releases/0.100.3.rst
releases/0.100.2.rst
Expand Down Expand Up @@ -38,6 +39,11 @@ Release notes
releases/0.9.1.rst


Version 0.100.5
===============

* Minor release with bug fixes

Version 0.100.4
===============

Expand Down
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "spikeinterface"
version = "0.100.4"
version = "0.100.5"
authors = [
{ name="Alessio Buccino", email="[email protected]" },
{ name="Samuel Garcia", email="[email protected]" },
Expand Down Expand Up @@ -59,7 +59,7 @@ changelog = "https://spikeinterface.readthedocs.io/en/latest/whatisnew.html"

extractors = [
"MEArec>=1.8",
"pynwb>=2.3.0",
"pynwb>=2.6.0",
"hdmf-zarr>=0.5.0",
"pyedflib>=0.1.30",
"sonpy;python_version<'3.10'",
Expand All @@ -80,7 +80,7 @@ streaming_extractors = [
"fsspec",
"aiohttp",
"requests",
"pynwb>=2.3.0",
"pynwb>=2.6.0",
"hdmf-zarr>=0.5.0",
"remfile",
"s3fs"
Expand Down
11 changes: 6 additions & 5 deletions src/spikeinterface/extractors/neoextractors/openephys.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,9 @@ def __init__(
exp_id = exp_ids[0]
else:
exp_id = exp_ids[block_index]
rec_ids = sorted(
list(self.neo_reader.folder_structure[record_node]["experiments"][exp_id]["recordings"].keys())
)

# do not load probe for NIDQ stream or if load_sync_channel is True
if "NI-DAQmx" not in stream_name and not load_sync_channel:
Expand Down Expand Up @@ -229,10 +232,8 @@ def __init__(
# load synchronized timestamps and set_times to recording
recording_folder = Path(folder_path) / record_node
stream_folders = []
for segment_index in range(self.get_num_segments()):
stream_folder = (
recording_folder / f"experiment{exp_id}" / f"recording{segment_index+1}" / "continuous" / oe_stream
)
for segment_index, rec_id in enumerate(rec_ids):
stream_folder = recording_folder / f"experiment{exp_id}" / f"recording{rec_id}" / "continuous" / oe_stream
stream_folders.append(stream_folder)
if load_sync_timestamps:
if (stream_folder / "sample_numbers.npy").is_file():
Expand All @@ -245,7 +246,7 @@ def __init__(
sync_times = None
try:
self.set_times(times=sync_times, segment_index=segment_index, with_warning=False)
except AssertionError:
except:
warnings.warn(f"Could not load synchronized timestamps for {stream_name}")

self._stream_folders = stream_folders
Expand Down
3 changes: 2 additions & 1 deletion src/spikeinterface/extractors/nwbextractors.py
Original file line number Diff line number Diff line change
Expand Up @@ -842,7 +842,8 @@ def _fetch_main_properties_backend(self):
data_attributes = self.electrical_series["data"].attrs
electrical_series_conversion = data_attributes["conversion"]
gains = electrical_series_conversion * 1e6
if "channel_conversion" in data_attributes:
channel_conversion = self.electrical_series.get("channel_conversion", None)
if channel_conversion:
gains *= self.electrical_series["channel_conversion"][:]

# Channel offsets
Expand Down
3 changes: 1 addition & 2 deletions src/spikeinterface/widgets/spikes_on_traces.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,7 @@ def plot_matplotlib(self, data_plot, **backend_kwargs):
spike_times_to_plot = sorting.get_unit_spike_train(
unit, segment_index=segment_index, return_times=True
)[spike_start:spike_end]
unit_y_loc = min_y + max_y - dp.unit_locations[unit][1]
# markers = np.ones_like(spike_frames_to_plot) * (min_y + max_y - dp.unit_locations[unit][1])
unit_y_loc = dp.unit_locations[unit][1]
width = 2 * 1e-3
ellipse_kwargs = dict(width=width, height=10, fc="none", ec=dp.unit_colors[unit], lw=2)
patches = [Ellipse((s, unit_y_loc), **ellipse_kwargs) for s in spike_times_to_plot]
Expand Down

0 comments on commit 7c2656c

Please sign in to comment.