open3d.ml.tf.dataloaders.TFDataloader

class open3d.ml.tf.dataloaders.TFDataloader(*args, dataset=None, model=None, use_cache=True, steps_per_epoch=None, **kwargs)

Data loader for tf framework.

__init__(*args, dataset=None, model=None, use_cache=True, steps_per_epoch=None, **kwargs)

Initialize

Parameters
  • dataset – ml3d dataset class.

  • dataset – model’s preprocess method.

  • devce – model’s transform mthod.

  • use_cache – whether to use cached preprocessed data.

  • steps_per_epoch – steps per epoch. The step number will be the number of samples in the data if steps_per_epoch=None

  • kwargs

Returns

The corresponding class.

Return type

class

get_loader(batch_size=1, num_threads=3)

Construct the origianl tensorflow dataloader.

Parameters
  • batch_size – batch size.

  • num_threads – number of threads for data loading.

  • kwargs

Returns

the tensorflow dataloader and the number of steps in one epoch

read_data(index)

Returns the data at index idx.