Data handling

Data handling module within the ketos library

This module provides utilities to load and handle data files.

rel_path_unix(path[, start])

Return a relative unix filepath to path either from the current directory or from an optional start directory.

parse_datetime(to_parse[, fmt, replace_spaces])

Parse date-time data from string.

find_files(path, substr[, return_path, ...])

Find all files in the specified directory containing the specified substring in their file name

find_wave_files(path[, return_path, ...])

Find all wave files in the specified directory

read_wave(file[, channel, start, stop])

Read a wave file in either mono or stereo mode.

create_dir(dir)

Create a new directory if it does not exist

to1hot(value, depth)

Converts the binary label to one hot format

from1hot(value)

Converts the one hot label to binary format

check_data_sanity(images, labels)

Check that all images have same size, all labels have values,