Skip to content

Commit 580abca

Browse files
Add support for BioCAM files recorded with BrainWave 6 (#458)
* BRW6 * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent a173778 commit 580abca

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

src/probeinterface/io.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -567,7 +567,10 @@ def read_3brain(file: str | Path, mea_pitch: float = None, electrode_width: floa
567567
num_channels = None
568568
for key in rf:
569569
if key.startswith("Well_"):
570-
num_channels = len(rf[key]["StoredChIdxs"])
570+
if "ExperimentSettings" in rf: # BRW5
571+
num_channels = len(rf[key]["StoredChIdxs"])
572+
elif "ExperimentInfo" in rf: # BRW6
573+
num_channels = max(rf[key]["NoisePlateElIdxs"]) + 1
571574
break
572575
assert num_channels is not None, "No Well found in the file"
573576

0 commit comments

Comments
 (0)