feature_calculators.SpikeGLXFileFeatureCalculator
feature_calculators.SpikeGLXFileFeatureCalculator(
ap_file=None,
lf_file=None,
name=None,
neuropixel_version=1,
traj_dict=None,
)Feature calculator for local SpikeGLX AP/LF files.
Args: ap_file (str | Path, optional): AP-band .bin or .cbin file. lf_file (str | Path, optional): LF-band .bin or .cbin file. name (str, optional): Recording identifier used as the OOP pid in outputs. Defaults to the AP file stem, LF file stem, or "probe". neuropixel_version (int): Neuropixels version passed to destriping. traj_dict (dict, optional): Optional trajectory dictionary used to add target coordinates to channel metadata.
Raises: ValueError: If neither AP nor LF file is supplied.
Note: Readers are opened lazily so importing and constructing this class does not touch the filesystem until data are requested.
Methods
| Name | Description |
|---|---|
| enrich_channel_metadata | Add probe metadata and optional trajectory target coordinates. |
| load_channel_metadata | Build channel metadata from SpikeGLX geometry. |
enrich_channel_metadata
feature_calculators.SpikeGLXFileFeatureCalculator.enrich_channel_metadata(
channels,
options,
)Add probe metadata and optional trajectory target coordinates.
Args: channels (pd.DataFrame): Channel metadata. options (FeatureComputationOptions): Current computation options.
Returns: pd.DataFrame: Channel metadata with probe_model and referencing_scheme columns, plus optional x_target, y_target, and z_target columns.
Raises: ValueError: If trajectory metadata are required but missing.
load_channel_metadata
feature_calculators.SpikeGLXFileFeatureCalculator.load_channel_metadata()Build channel metadata from SpikeGLX geometry.
Returns: pd.DataFrame: Columns channel, rawInd, axial_um, lateral_um, and shank (shank feeds the physical-site channel merge in the base class).