Skip to content

Commit 930fb42

Browse files
authored
Merge pull request #1850 from NeuralEnsemble/black-formatting
Black formatting
2 parents 07cd3ea + 6691030 commit 930fb42

2 files changed

Lines changed: 3 additions & 10 deletions

File tree

neo/rawio/spikegadgetsrawio.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -177,10 +177,7 @@ def _intan_hwchans_in_binary_order(self, sconf, num_ephy_channels, num_ephy_chan
177177
intan_chans_per_chip = int(sconf.attrib.get("chanPerChip", 32)) # RHD2132 default for legacy files
178178
hw_chans_in_xml = [int(schan.attrib["hwChan"]) for trode in sconf for schan in trode]
179179

180-
channels_fit_chip_layout = (
181-
intan_chans_per_chip > 0
182-
and num_ephy_channels % intan_chans_per_chip == 0
183-
)
180+
channels_fit_chip_layout = intan_chans_per_chip > 0 and num_ephy_channels % intan_chans_per_chip == 0
184181
if not channels_fit_chip_layout:
185182
return hw_chans_in_xml
186183

@@ -357,9 +354,7 @@ def _parse_header(self):
357354
else:
358355
chan_id = str(hw_chan)
359356
name = f"trode{parent_trode.attrib['id']}chan{hw_chan}"
360-
signal_channels.append(
361-
(name, chan_id, self._sampling_rate, "int16", units, gain, 0.0, stream_id, "")
362-
)
357+
signal_channels.append((name, chan_id, self._sampling_rate, "int16", units, gain, 0.0, stream_id, ""))
363358

364359
num_bytes = packet_size - 2 * num_ephy_channels + 2 * binary_index
365360
chan_mask = np.zeros(packet_size, dtype="bool")

neo/test/rawiotest/test_spikegadgetsrawio.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,7 @@ def test_neuropixels_uses_hwchan_ids(self):
6060
# where i is the channel index in the trodes stream (which equals the hwChan
6161
# the firmware writes at that byte position, since the SpikeGadgets MCU emits
6262
# Neuropixels samples in hwChan ascending order).
63-
file_path = Path(
64-
self.get_local_path("spikegadgets/SpikeGadgets_test_data_2xNpix1.0_20240318_173658.rec")
65-
)
63+
file_path = Path(self.get_local_path("spikegadgets/SpikeGadgets_test_data_2xNpix1.0_20240318_173658.rec"))
6664
reader = SpikeGadgetsRawIO(filename=file_path)
6765
reader.parse_header()
6866

0 commit comments

Comments
 (0)