diff --git a/neo/rawio/neuralynxrawio/ncssections.py b/neo/rawio/neuralynxrawio/ncssections.py index a9bc47c7d..1b57338b7 100644 --- a/neo/rawio/neuralynxrawio/ncssections.py +++ b/neo/rawio/neuralynxrawio/ncssections.py @@ -33,6 +33,7 @@ The challenge addressed by the NcsSectionsFactory of this module is to separate those intended gaps from those introduced by a quirk of the hardware, recording software, or file format. """ + import math import numpy as np @@ -87,12 +88,12 @@ class NcsSection: _RECORD_SIZE = 512 # nb sample per signal record def __init__(self, startRec, startTime, endRec, endTime, n_samples): - self.startRec = startRec # index of starting record - self.startTime = startTime # starttime of first record - self.endRec = endRec # index of last record (inclusive) - self.endTime = endTime # end time of last record, that is, the end time of the last - # sampling period contained in the last record of the section - self.n_samples = n_samples # number of samples in record which are valid + self.startRec = startRec # index of starting record + self.startTime = startTime # starttime of first record + self.endRec = endRec # index of last record (inclusive) + self.endTime = endTime # end time of last record, that is, the end time of the last + # sampling period contained in the last record of the section + self.n_samples = n_samples # number of samples in record which are valid def __eq__(self, other): return ( diff --git a/neo/rawio/neuralynxrawio/neuralynxrawio.py b/neo/rawio/neuralynxrawio/neuralynxrawio.py index 5d4fb316a..16ee1860e 100644 --- a/neo/rawio/neuralynxrawio/neuralynxrawio.py +++ b/neo/rawio/neuralynxrawio/neuralynxrawio.py @@ -326,7 +326,7 @@ def _parse_header(self): internal_ids = [] else: data = self._get_file_map(filename) - if data.shape[0] == 0: # empty file + if data.shape[0] == 0: # empty file self._empty_nse_ntt.append(filename) internal_ids = np.unique(data[["event_id", "ttl_input"]]).tolist() for internal_event_id in internal_ids: diff --git a/neo/rawio/neuralynxrawio/nlxheader.py b/neo/rawio/neuralynxrawio/nlxheader.py index baf343c00..8d1de1ca2 100644 --- a/neo/rawio/neuralynxrawio/nlxheader.py +++ b/neo/rawio/neuralynxrawio/nlxheader.py @@ -81,52 +81,53 @@ def _to_bool(txt): "bml": dict( datetime1_regex=r"## Time Opened: \(m/d/y\): (?P\S+)" r" At Time: (?P