pymlp.datahandling package

Submodules

pymlp.datahandling.DataHandler module

class pymlp.datahandling.DataHandler.DataHandler(folder)[source]

Loads, filters and saves the data files.

filterFiles(f)[source]
isBinaryDataFile(filename)[source]

Returns True if the given filename is a binary numpy file.

isDataFile(filename)[source]

Returns True if the given filename is a data file as written by this library. It can be a binary, as well as a ASCII file.

isReshapedDataFile(filename)[source]

Returns True, if the filename contains information about its data’s original shape. This is the case when the filename starts normally with its name and has its shape in paranthesis before the filename ending. e.g. foo.(1, 2, 3).dat.gz.

loadData(filename)[source]

Loads and returns the data.

Parameters:
filename – the name of the file to load the data from returns – the data in the file with the name filename
saveData(filename, data, i)[source]

Writes the data into the file with the filename.

Parameters:

filename – name of the file to put the data into data – data to write i – the unique number for this run so it can be distinguished from

other runs, e.g. repeated runs for stability
binary – True if the data is supposed to be stored as a binary,
defaul: False

pymlp.datahandling.MultifolderReader module

class pymlp.datahandling.MultifolderReader.MultifolderReader(folder, folderfilter, filefilter, negativefilter=None)[source]

Reads all datasets in all subfolders of the given folder. Filter the subfolders and files and sorts the datasets and folder names.

collectData()[source]
parseParameters(line)[source]

Module contents