DatasetFactory

class paddle.fluid.dataset.DatasetFactory[source]

DatasetFactory is a factory which create dataset by its name, you can create “QueueDataset” or “InMemoryDataset”, or “FileInstantDataset”, the default is “QueueDataset”.

Example

import paddle.fluid as fluid
dataset = fluid.DatasetFactory().create_dataset("InMemoryDataset")
create_dataset(datafeed_class='QueueDataset')

Create “QueueDataset” or “InMemoryDataset”, or “FileInstantDataset”, the default is “QueueDataset”.

Parameters

datafeed_class (str) – datafeed class name, QueueDataset or InMemoryDataset. Default is QueueDataset.

Examples

import paddle.fluid as fluid
dataset = fluid.DatasetFactory().create_dataset()