Python API Reference¶
||Encapsulates the data loader library and exposes an API to iterate over generic data (images, video or audio given in compressed form).|
Encapsulates the data loader library and exposes an API to iterate over generic data (images, video or audio given in compressed form). An index file that maps the data examples to their targets is expected to be provided in CSV format.
- config (dict) – All configuration information needed for defining the type of extraction, transforming, and loading of targets, as well as where source files come from, where the files should be cached locally, etc.
- backend (object) – This is an instance of an object which knows how to create tensors it needs for processing, and how to transfer host information to those tensors
Note that if the epoch is not evenly divisible by the minibatch size, there will be one minibatch per epoch (or so) which contains data from two epochs.
Number of items in the dataset.
returns the minibatch_index that epoch_index starts with
Returns the number of minibatches in this dataset in this epoch.
Sometimes the number of minibatches per epoch changes since items from the next epoch will be used to fill the last minibatch of an epoch if it doesn’t line up with the end of the epoch.
returns the number of minibatches which will be in epoch # epoch_index
return one minibatch in a (data, targets) tuple
Restart data from index 0.
C api wrapper with exception handling
The starting item offset for epoch # epoch_index
assumes 0 indexed epochs
never ending iterator over dataset.