Class VOCDataset
Defined in File datasets.h
Inheritance Relationships
Base Type
public mindspore::dataset::Dataset
(Class Dataset)
Class Documentation
-
class VOCDataset : public mindspore::dataset::Dataset
A source dataset for reading and parsing VOC dataset.
Public Functions
Constructor of VOCDataset.
- Parameters
dataset_dir – [in] Path to the root directory that contains the dataset.
task – [in] Set the task type of reading voc data, now only support “Segmentation” or “Detection”.
usage – [in] The type of data list text file to be read (default = “train”).
class_indexing – [in] A str-to-int mapping from label name to index, only valid in “Detection” task.
decode – [in] Decode the images after reading.
sampler – [in] Shared pointer to a sampler object used to choose samples from the dataset. If sampler is not given, a
RandomSampler
will be used to randomly iterate the entire dataset (default = RandomSampler()).cache – [in] Tensor cache to use (default=nullptr which means no cache is used).
extra_metadata – [in] Flag to add extra meta-data to row (default=false).
Constructor of VOCDataset.
- Parameters
dataset_dir – [in] Path to the root directory that contains the dataset.
task – [in] Set the task type of reading voc data, now only support “Segmentation” or “Detection”.
usage – [in] The type of data list text file to be read.
class_indexing – [in] A str-to-int mapping from label name to index, only valid in “Detection” task.
decode – [in] Decode the images after reading.
sampler – [in] Raw pointer to a sampler object used to choose samples from the dataset.
cache – [in] Tensor cache to use (default=nullptr which means no cache is used).
extra_metadata – [in] Flag to add extra meta-data to row (default=false).
Constructor of VOCDataset.
- Parameters
dataset_dir – [in] Path to the root directory that contains the dataset.
task – [in] Set the task type of reading voc data, now only support “Segmentation” or “Detection”.
usage – [in] The type of data list text file to be read.
class_indexing – [in] A str-to-int mapping from label name to index, only valid in “Detection” task.
decode – [in] Decode the images after reading.
sampler – [in] Raw pointer to a sampler object used to choose samples from the dataset.
cache – [in] Tensor cache to use (default=nullptr which means no cache is used).
extra_metadata – [in] Flag to add extra meta-data to row (default=false).
-
~VOCDataset() override = default
Destructor of VOCDataset.