class LuxonisParser(Generic[
Constructor: LuxonisParser(dataset_dir, dataset_name, save_dir, dataset_plugin, ...)
Detect a dataset format and dispatch to the matching parser.
The parser accepts local paths, remote paths supported by
LuxonisFileSystem, ZIP archives, and Roboflow dataset URLs in
roboflow://workspace/project/version/format form. If
dataset_type is omitted, parsers are tried until one validates the
dataset directory as either a full directory or a single split.
| Method | __init__ |
High-level abstraction over various parsers. |
| Method | get |
Return parser issue messages collected during the last parse. |
| Method | parse |
Parse the dataset and return it in LDF format. |
| Static Method | _download |
Undocumented |
| Static Method | _download |
Undocumented |
| Static Method | _resolve |
Undocumented |
| Method | _get |
Return parser issue messages collected during the last parse. |
| Method | _infer |
Undocumented |
| Method | _recognize |
Recognize the dataset format and parser type. |
| Instance Variable | _dataset |
Dataset instance populated by parsing. |
| Instance Variable | _dataset |
Dataset class resolved from the plugin registry, or LuxonisDataset. |
| Instance Variable | _dataset |
Local dataset directory used for parsing. |
| Instance Variable | _dataset |
Recognized or user-provided dataset type. |
| Instance Variable | _parser |
Concrete parser instance selected for dataset_type. |
| Instance Variable | _parser |
Whether dataset_dir represents a full directory or a single split. |
| Instance Variable | _parsers |
Dataset types mapped to concrete parser classes. |
str, *, dataset_name: str | None = None, save_dir: Path | str | None = None, dataset_plugin: T = None, dataset_type: DatasetType | None = None, task_name: str | dict[ str, str] | None = None, full_warnings: bool = False, **kwargs):
¶
High-level abstraction over various parsers.
Automatically recognizes the dataset format and uses the appropriate parser.
| Parameters | |
datasetstr | Dataset directory identifier. Can be one of:
|
datasetstr | None | Optional output dataset name. If omitted, the name is derived from dataset_dir. |
savePath | str | None | Optional directory used when downloading remote datasets. If omitted, the current working directory is used. |
datasetT | Optional dataset plugin registry name. If omitted, LuxonisDataset is used. |
datasetDatasetType | None | Optional dataset type. If provided, automatic format recognition is skipped. |
taskstr | dict[ | Optional task naming rule. A string is used for all records. A mapping uses class names as keys and task names as values. |
fullbool | Whether all skipped annotation warnings should be logged without truncation. |
| **kwargs | Additional arguments passed to the selected dataset constructor. |
| Raises | |
RuntimeError | If a Roboflow URL is used and ROBOFLOW_API_KEY is not configured. |
ValueError | If a Roboflow URL is malformed, its version is not an integer, or the dataset format cannot be recognized. |
Parse the dataset and return it in LDF format.
If the dataset already exists, parsing will be skipped and the existing dataset will be returned instead.
| Parameters | |
| **kwargs | Parser-specific arguments. |
| Returns | |
BaseDataset | Parsed dataset. |
| Raises | |
ValueError | If the selected parser rejects the dataset structure or split arguments. |
str, local_path: Path | None) -> tuple[ Path, str]:
¶
Undocumented
str, local_path: Path | None) -> tuple[ Path, str]:
¶
Undocumented