py123detection.taxonomy¶
Mapping 123D box labels onto the class_names tuple of an mmdet3d config.
A Taxonomy turns a 123D label into one of its class names, or drops the box. Lookups go
from most to least specific:
native_mapby qualified enum member ("AV2SensorBoxDetectionLabel.BICYCLIST"), for when the same member name exists in several datasets and only one should be overridden;native_mapby bare member name ("VEHICLE_CAR");default_mapbyDefaultBoxDetectionLabelmember ("VEHICLE"). Every 123D dataset implementsto_default(), so a default-level taxonomy works for all of them, which is what cross-dataset merges rely on.
Labels that resolve to VOID, or to nothing, are dropped.
Module Attributes
Target class name that drops a label. |
|
The standard nuScenes 10-class benchmark, in mmdet3d's class order. |
|
Cross-dataset vehicle / pedestrian / cyclist over the default labels. |
|
CoIn3D's unified classes, spelled with nuScenes names on purpose: the devkit's DetectionBox only accepts the ten nuScenes detection names, and reusing three of them lets any dataset be scored with the unmodified metric code. |
|
A single |
|
Identity over DefaultBoxDetectionLabel, minus EGO. |
|
The values accepted by --taxonomy. |
Functions
|
Classes
|
An ordered class list plus the rules mapping 123D labels onto it. |
- py123detection.taxonomy.VOID = 'void'¶
Target class name that drops a label.
- class py123detection.taxonomy.Taxonomy(name, class_names, native_map=<factory>, default_map=<factory>)[source]¶
Bases:
objectAn ordered class list plus the rules mapping 123D labels onto it.
- class_names: Tuple[str, ...]¶
Ordered class names. The index of a name is its label id in the mmdet3d config.
- native_map: Mapping[str, str]¶
Dataset-native (optionally qualified) enum member name -> class name or
VOID.
- py123detection.taxonomy.NUSCENES_DETECTION = Taxonomy(name='nuscenes_detection_10cls')¶
The standard nuScenes 10-class benchmark, in mmdet3d’s class order. Native-level only, so any other dataset exported with it drops every box.
- py123detection.taxonomy.GENERAL_3CLS = Taxonomy(name='general_3cls')¶
Cross-dataset vehicle / pedestrian / cyclist over the default labels.
- py123detection.taxonomy.COIN3D_3CLS = Taxonomy(name='coin3d_3cls')¶
CoIn3D’s unified classes, spelled with nuScenes names on purpose: the devkit’s DetectionBox only accepts the ten nuScenes detection names, and reusing three of them lets any dataset be scored with the unmodified metric code. CoIn3D’s mapping (data_preprocess/README.md): nuScenes car/truck/trailer/bus/construction_vehicle -> car, pedestrian -> pedestrian, bicycle/motorcycle -> motorcycle; Lyft car/truck/bus/emergency_vehicle/other_vehicle -> car; Waymo VEHICLE/PEDESTRIAN/CYCLIST.
- py123detection.taxonomy.VEHICLE_1CLS = Taxonomy(name='vehicle_1cls')¶
A single
vehicleclass over the default labels (VEHICLEandTRAIN).
- py123detection.taxonomy.DEFAULT_123D = Taxonomy(name='default_123d')¶
Identity over DefaultBoxDetectionLabel, minus EGO.
- py123detection.taxonomy.TAXONOMIES: Dict[str, Taxonomy] = {'coin3d_3cls': Taxonomy(name='coin3d_3cls'), 'default_123d': Taxonomy(name='default_123d'), 'general_3cls': Taxonomy(name='general_3cls'), 'nuscenes_detection_10cls': Taxonomy(name='nuscenes_detection_10cls'), 'vehicle_1cls': Taxonomy(name='vehicle_1cls')}¶
The values accepted by –taxonomy.