cogpy.io.ecephys_io

BIDS ECEPHYS reader for electrophysiology .dat files.

Note

Lab-internal module. Assumes the Bhatt Lab BIDS-ECEPHYS directory layout and sidecar conventions. Not part of the stable public API — external users should prefer cogpy.io.converters.

Functions

load_ecephys_metadata

Load metadata from BIDS sidecar files.

from_file

Create an xarray.DataArray from a .dat file.

Example

from cogpy.io import ecephys_io
da = ecephys_io.from_file('sub-01_ses-01_task-free_ecephys.lfp')

Functions

from_file(dat_file[, sidecars, as_float])

Creates a memory-mapped (dask) array from a .dat file, reshaped to (num_channels, num_samples).

load_ecephys_metadata(lfp_path[, sidecars])

Read BIDS JSON, channels.tsv, and electrodes.tsv.

resolve_ecephys_sidecars(lfp_path)

Resolve BIDS sidecar paths for an ecephys LFP file.