class UnlabeledVideoDatasetIngestor(UnlabeledVideoDatasetImporter, VideoIngestor): (source)
Constructor: UnlabeledVideoDatasetIngestor(dataset_dir, samples, sample_parser, max_samples)
Dataset importer that ingests unlabeled videos into the provided dataset_dir during import.
The source videos are parsed from the provided samples using the
provided fiftyone.utils.data.parsers.UnlabeledVideoSampleParser
.
The source videos are directly copied from their source locations into dataset_dir, maintaining the original filenames, unless a name conflict would occur, in which case an index of the form "-%d" % count is appended to the base filename.
Parameters | |
dataset | the directory where input videos will be ingested into |
samples | an iterable of samples that can be parsed by sample_parser |
sample | an
fiftyone.utils.data.parsers.UnlabeledVideoSampleParser to
use to parse the samples |
max | a maximum number of samples to import. By default, all samples are imported |
Method | __init__ |
Undocumented |
Method | __iter__ |
Undocumented |
Method | __len__ |
The total number of samples that will be imported. |
Method | __next__ |
Returns information about the next sample in the dataset. |
Method | setup |
Performs any necessary setup before importing the first sample in the dataset. |
Instance Variable | sample |
Undocumented |
Instance Variable | samples |
Undocumented |
Property | has |
Whether this importer produces a dataset info dictionary. |
Property | has |
Whether this importer produces fiftyone.core.metadata.VideoMetadata instances for each video. |
Instance Variable | _iter |
Undocumented |
Instance Variable | _num |
Undocumented |
Instance Variable | _num |
Undocumented |
Inherited from DatasetImporter
(via UnlabeledVideoDatasetImporter
):
Method | __enter__ |
Undocumented |
Method | __exit__ |
Undocumented |
Method | close |
Performs any necessary actions after the last sample has been imported. |
Method | get |
Returns the dataset info for the dataset. |
Method | _preprocess |
Internal utility that preprocesses the given list---which is presumed to be a list defining the samples that should be imported---by applying the values of the shuffle, seed, and max_samples parameters of the importer. |
Inherited from VideoIngestor
(via UnlabeledVideoDatasetImporter
, DatasetImporter
):
Method | _ingest |
Undocumented |
Method | _setup |
Undocumented |
Instance Variable | _filename |
Undocumented |
Returns information about the next sample in the dataset.
Returns | |
an(video_path, video_metadata)tuple, where |
|
Raises | |
StopIteration | if there are no more samples to import |
Performs any necessary setup before importing the first sample in the dataset.
This method is called when the importer's context manager interface is
entered, DatasetImporter.__enter__
.