feat: Add support for ADAS project in labeling and export processes
- Implemented class name loading for ADAS campaigns in `_class_names_for_campaign`. - Enhanced annotation parsing to support cuboid and 2D rectangle labels in `_parse_ls_annotations`. - Updated catalog building to include ADAS packs and batches in `build_catalog_signature`. - Added ADAS cuboid promotion logic in `adas_cuboid.py`, supporting both quaternion_json and YOLO HBB formats. - Introduced validation for ADAS batches to check for YOLO HBB labels in `adas_cuboid.py`. - Modified delivery scanning to include ADAS project deliveries in `scan.py`. - Extended job execution to handle ADAS exports for YOLO format in `runner.py`. - Updated labeling export logic to accommodate ADAS project in `export_cuboid_batch.py`. - Enhanced format conversion to support rectangle labels in `format_converter.py`. - Improved CVAT task handling in `service.py` to ensure task ID updates on each labeling job. - Updated web API endpoints to reflect ADAS project changes in `hsap-api.ts`. - Added ADAS catalog types and UI components for displaying ADAS packs and batches in `dmsCatalog.ts`, `CatalogPage.tsx`, and `ExportPage.tsx`. - Adjusted workflow registry to align with new ADAS project structure.
This commit is contained in:
@@ -238,10 +238,14 @@ def cvat_shapes_to_export_regions(
|
||||
}
|
||||
|
||||
if stype == "rectangle":
|
||||
xtl = float(shape.get("xtl", 0))
|
||||
ytl = float(shape.get("ytl", 0))
|
||||
xbr = float(shape.get("xbr", 0))
|
||||
ybr = float(shape.get("ybr", 0))
|
||||
pts = shape.get("points") or []
|
||||
if len(pts) >= 4:
|
||||
xtl, ytl, xbr, ybr = float(pts[0]), float(pts[1]), float(pts[2]), float(pts[3])
|
||||
else:
|
||||
xtl = float(shape.get("xtl", 0))
|
||||
ytl = float(shape.get("ytl", 0))
|
||||
xbr = float(shape.get("xbr", 0))
|
||||
ybr = float(shape.get("ybr", 0))
|
||||
regions.append({
|
||||
**base,
|
||||
"type": "rectanglelabels",
|
||||
|
||||
Reference in New Issue
Block a user