segment_files
- ketos.data_handling.selection_table.segment_files(table, length, step=None, pad=True)[source]
Generate a selection table by stepping across the audio files, using a fixed step size (step) and fixed selection window size (length).
- Args:
- table: pandas DataFrame
File duration table.
- length: float
Selection length in seconds.
- step: float
Selection step size in seconds. If None, the step size is set equal to the selection length.
- pad: bool
If True (default), the last selection window is allowed to extend beyond the endpoint of the audio file.
- Returns:
- df: pandas DataFrame
Selection table