Skip to content

Commit c42b5eb

Browse files
committed
resolve conflicts
2 parents e5a62a0 + 376a7ba commit c42b5eb

2 files changed

Lines changed: 5 additions & 3 deletions

File tree

mne/io/bci2k/bci2k.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,9 @@ def _parse_bci2k_header(fname):
8282
left, right = line.split("=", 1)
8383
left_tokens = left.strip().split()
8484
name = left_tokens[-1]
85-
param_type = left_tokens[-2].lower() if len(left_tokens) >= 2 else ""
85+
param_type = (
86+
left_tokens[-2].lower() if len(left_tokens) >= 2 else ""
87+
)
8688
rhs = right.split("//", 1)[0].strip()
8789
rhs_tokens = rhs.split()
8890
if not rhs_tokens:
@@ -182,7 +184,7 @@ def _read_bci2k_data(fname, info_dict):
182184
raise ValueError(
183185
"Expected SourceChOffset and SourceChGain lengths to match SourceCh."
184186
)
185-
offsets_arr = np.array([float(val) for val in offsets])
187+
offsets_arr = np.array([_parse_value_with_unit(val)[0] for val in offsets])
186188
gain_parsed = [_parse_value_with_unit(val, unit_scale=_VOLT_SCALE) for val in gains]
187189
gains_arr = np.array([val for val, _ in gain_parsed])
188190
gain_scales = np.array([scale for _, scale in gain_parsed])

mne/io/bci2k/tests/test_bci2k.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def test_read_raw_bci2k():
2929
assert events.ndim == 2
3030
assert events.shape[1] == 3
3131
assert "RawBCI2k" in repr(raw)
32-
32+
3333
info_dict = _parse_bci2k_header(bci2k_fname)
3434
assert info_dict["params"]["SourceChOffset"] == ["0", "0"]
3535
assert info_dict["params"]["SourceChGain"] == ["0.1muV", "0.1muV"]

0 commit comments

Comments
 (0)