datumaro.plugins.data_formats.mnist#

Classes

MnistBase(path, *[, subset, ctx])

MnistExporter(extractor, save_dir, *[, ...])

MnistImporter()

MnistPath()

class datumaro.plugins.data_formats.mnist.MnistPath[source]#

Bases: object

TEST_LABELS_FILE = 't10k-labels-idx1-ubyte.gz'#
TEST_IMAGES_FILE = 't10k-images-idx3-ubyte.gz'#
LABELS_FILE = '-labels-idx1-ubyte.gz'#
IMAGES_FILE = '-images-idx3-ubyte.gz'#
IMAGE_SIZE = 28#
NONE_LABEL = 255#
class datumaro.plugins.data_formats.mnist.MnistBase(path: str, *, subset: str | None = None, ctx: ImportContext | None = None)[source]#

Bases: SubsetBase

class datumaro.plugins.data_formats.mnist.MnistImporter[source]#

Bases: Importer

classmethod find_sources(path)[source]#
classmethod get_file_extensions() List[str][source]#
class datumaro.plugins.data_formats.mnist.MnistExporter(extractor: IDataset, save_dir: str, *, save_media: bool | None = None, image_ext: str | None = None, default_image_ext: str | None = None, save_dataset_meta: bool = False, save_hashkey_meta: bool = False, stream: bool = False, ctx: ExportContext | None = None)[source]#

Bases: Exporter

DEFAULT_IMAGE_EXT = '.png'#
save_annotations(path, data)[source]#
save_images(path, data)[source]#
save_labels()[source]#