Skip to content

Commit 058bce4

Browse files
authored
Merge branch 'master' into fixate_plexon2_streams
2 parents 6b62f9d + 0aa596e commit 058bce4

File tree

5 files changed

+8
-8
lines changed

5 files changed

+8
-8
lines changed

neo/rawio/medrawio.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ def _get_analogsignal_chunk(self, block_index, seg_index, i_start, i_stop, strea
240240
self.sess.set_channel_active(self._stream_info[stream_index]["raw_chans"])
241241
num_channels = len(self._stream_info[stream_index]["raw_chans"])
242242
self.sess.set_reference_channel(self._stream_info[stream_index]["raw_chans"][0])
243-
243+
244244
# in the case we have a slice or we give an ArrayLike we need to iterate through the channels
245245
# in order to activate them.
246246
else:

neo/rawio/plexon2rawio/plexon2rawio.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ def _parse_header(self):
166166
for channel_index in range(self.pl2reader.pl2_file_info.m_TotalNumberOfAnalogChannels):
167167
achannel_info = self.pl2reader.pl2_get_analog_channel_info(channel_index)
168168
# only consider active channels
169-
if not achannel_info.m_ChannelEnabled:
169+
if not (achannel_info.m_ChannelEnabled and achannel_info.m_ChannelRecordingEnabled):
170170
continue
171171

172172
# assign to matching stream or create new stream based on signal characteristics
@@ -228,7 +228,7 @@ def _parse_header(self):
228228
schannel_info = self.pl2reader.pl2_get_spike_channel_info(c)
229229

230230
# only consider active channels
231-
if not schannel_info.m_ChannelEnabled:
231+
if not (schannel_info.m_ChannelEnabled and schannel_info.m_ChannelRecordingEnabled):
232232
continue
233233

234234
for channel_unit_id in range(schannel_info.m_NumberOfUnits):
@@ -252,7 +252,7 @@ def _parse_header(self):
252252
echannel_info = self.pl2reader.pl2_get_digital_channel_info(i)
253253

254254
# only consider active channels
255-
if not echannel_info.m_ChannelEnabled:
255+
if not (echannel_info.m_ChannelEnabled and echannel_info.m_ChannelRecordingEnabled):
256256
continue
257257

258258
# event channels are characterized by (name, id, type), with type in ['event', 'epoch']

neo/test/iotest/test_plexonio.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class TestPlexonIO(
1818
"plexon/File_plexon_1.plx",
1919
"plexon/File_plexon_2.plx",
2020
"plexon/File_plexon_3.plx",
21-
"plexon/4chDemoPLX.plx"
21+
"plexon/4chDemoPLX.plx",
2222
]
2323

2424

neo/test/rawiotest/rawio_compliance.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -224,15 +224,15 @@ def read_analogsignals(reader):
224224
i_start=i_start,
225225
i_stop=i_stop,
226226
stream_index=stream_index,
227-
channel_indexes=slice(None)
227+
channel_indexes=slice(None),
228228
)
229229
raw_chunk_channel_indexes = reader.get_analogsignal_chunk(
230230
block_index=block_index,
231231
seg_index=seg_index,
232232
i_start=i_start,
233233
i_stop=i_stop,
234234
stream_index=stream_index,
235-
channel_indexes=channel_indexes
235+
channel_indexes=channel_indexes,
236236
)
237237

238238
np.testing.assert_array_equal(raw_chunk_slice_none, raw_chunk_channel_indexes)

neo/test/rawiotest/test_plexonrawio.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ class TestPlexonRawIO(
1515
"plexon/File_plexon_1.plx",
1616
"plexon/File_plexon_2.plx",
1717
"plexon/File_plexon_3.plx",
18-
"plexon/4chDemoPLX.plx"
18+
"plexon/4chDemoPLX.plx",
1919
]
2020

2121

0 commit comments

Comments
 (0)