class documentation

Class for working with remotely-sourced datasets that are compatible with the FiftyOne Dataset Zoo.

Parameters
dataset_dirthe dataset's local directory, which must contain a valid dataset YAML file
url

the dataset's remote source, which can be:

  • a GitHub repo URL like https://github.com/<user>/<repo>
  • a GitHub ref like https://github.com/<user>/<repo>/tree/<branch> or https://github.com/<user>/<repo>/commit/<commit>
  • a GitHub ref string like <user>/<repo>[/<ref>]
  • a publicly accessible URL of an archive (eg zip or tar) file

This is explicitly provided rather than relying on the YAML file's url property in case the caller has specified a particular branch or commit

**kwargsoptional keyword arguments for the dataset's download_and_prepare() and/or load_dataset() methods
Method __init__ Undocumented
Property author Undocumented
Property description Undocumented
Property fiftyone_version Undocumented
Property is_remote Whether the dataset is remotely-sourced.
Property license Undocumented
Property metadata Undocumented
Property name The name of the dataset.
Property size_samples Undocumented
Property source Undocumented
Property supported_splits A tuple of supported splits for the dataset, or None if the dataset does not have splits.
Property supports_partial_downloads Whether the dataset supports downloading partial subsets of its splits.
Property tags A tuple of tags for the dataset.
Property url Undocumented
Property version Undocumented
Static Method _parse_tuple Undocumented
Method _download_and_prepare Internal implementation of downloading the dataset and preparing it for use in the given directory.
Method _import_module Undocumented
Method _load_dataset Undocumented
Instance Variable _author Undocumented
Instance Variable _dataset_dir Undocumented
Instance Variable _description Undocumented
Instance Variable _fiftyone_version Undocumented
Instance Variable _kwargs Undocumented
Instance Variable _license Undocumented
Instance Variable _metadata Undocumented
Instance Variable _name Undocumented
Instance Variable _size_samples Undocumented
Instance Variable _source Undocumented
Instance Variable _splits Undocumented
Instance Variable _supports_partial_downloads Undocumented
Instance Variable _tags Undocumented
Instance Variable _url Undocumented
Instance Variable _version Undocumented

Inherited from ZooDataset:

Static Method get_info_path Returns the path to the ZooDatasetInfo for the dataset.
Static Method has_info Determines whether the directory contains ZooDatasetInfo.
Static Method load_info Loads the ZooDatasetInfo from the given dataset directory.
Method download_and_prepare Downloads the dataset and prepares it for use.
Method get_split_dir Returns the directory for the given split of the dataset.
Method has_split Whether the dataset has the given split.
Method has_tag Whether the dataset has the given tag.
Property has_patches Whether the dataset has patches that may need to be applied to already downloaded files.
Property has_splits Whether the dataset has splits.
Property has_tags Whether the dataset has tags.
Property importer_kwargs A dict of default kwargs to pass to this dataset's fiftyone.utils.data.importers.DatasetImporter.
Property parameters An optional dict of parameters describing the configuration of the zoo dataset when it was downloaded.
Property requires_manual_download Whether this dataset requires some files to be manually downloaded by the user before the dataset can be loaded.
Method _get_splits_to_download Undocumented
Method _is_dataset_ready Undocumented
Method _is_split_ready Undocumented
Method _patch_if_necessary Internal method called when an already downloaded dataset may need to be patched.
def __init__(self, dataset_dir, url=None, **kwargs): (source)

Undocumented

Undocumented

@property
description = (source)

Undocumented

@property
fiftyone_version = (source)

Undocumented

Whether the dataset is remotely-sourced.

Undocumented

Undocumented

The name of the dataset.

@property
size_samples = (source)

Undocumented

Undocumented

@property
supported_splits = (source)

A tuple of supported splits for the dataset, or None if the dataset does not have splits.

@property
supports_partial_downloads = (source)

Whether the dataset supports downloading partial subsets of its splits.

A tuple of tags for the dataset.

Undocumented

Undocumented

@staticmethod
def _parse_tuple(d, key): (source)

Undocumented

def _download_and_prepare(self, dataset_dir, _, split): (source)

Internal implementation of downloading the dataset and preparing it for use in the given directory.

Parameters
dataset_dirthe directory in which to construct the dataset. If a split is provided, this is the directory for the split
_Undocumented
splitthe split to download, or None if the dataset does not have splits
scratch_dira scratch directory to use to download and prepare any required intermediate files
Returns
tuple of
  • dataset_type: the fiftyone.types.Dataset type of the dataset
  • num_samples: the number of samples in the split. For datasets that support partial downloads, this can be None, which indicates that all content was already downloaded
  • classes: an optional list of class label strings
def _import_module(self, dataset_dir): (source)

Undocumented

def _load_dataset(self, dataset, dataset_dir, split=None): (source)

Undocumented

Undocumented

_dataset_dir = (source)

Undocumented

_description = (source)

Undocumented

_fiftyone_version = (source)

Undocumented

Undocumented

_license = (source)

Undocumented

_metadata = (source)

Undocumented

Undocumented

_size_samples = (source)

Undocumented

Undocumented

Undocumented

_supports_partial_downloads = (source)

Undocumented

Undocumented

Undocumented

_version = (source)

Undocumented