Skip to main content

feature_calculators.aggregate_snippets

feature_calculators.aggregate_snippets(results)

Aggregate and denoise snippets already computed by compute_snippet.

Each result’s manifest record is one row of the snippet table read by get_aggregated_raw_features (per-channel median), followed by denoise_raw_features_data and apply_waveform_remap, as in ephysatlas.aggregation.produce_output_dataframes.

Args: results (Sequence[FeatureComputationResult]): Results of compute_snippet for one recording, computed with an output_dir (the snippet files are read back).

Returns: pd.DataFrame: Aggregated and denoised features indexed by (pid, channel). Its attrs hold snippet_windows ({"pid", "t_start", "duration_ap", "duration_lf"} dicts), features_version and the ibleatools version and git commit of the code that computed the snippets; pandas saves them in parquet files.