--- license: other task_categories: - object-detection - image-segmentation tags: - traffic - aerial - drone - roadside - multi-view - coco - instance-segmentation size_categories: - 10K/*.jpg (34 subdirs, 18015 images) valid/ _annotations.coco.json + *.jpg (5892 images) test/ _annotations.coco.json + *.jpg (5880 images) ``` | split | images | instances | source runs | |---|---|---|---| | train | 18,015 | 375,926 | 34 | | valid | 5,892 | 104,024 | 24 | | test | 5,880 | 105,952 | 24 | | **total** | **29,787** | **585,902** | 58 | `train/` images are grouped into one subdirectory per source run because the Hub caps a directory at 10,000 files. This is transparent to loaders: COCO `file_name` is a relative path, so `os.path.join(split_dir, file_name)` resolves correctly in all three splits. ## Classes | id | name | instances | |---|---|---| | 0 | person | 0 | | 1 | bicycle | 0 | | 2 | car | 528,354 | | 3 | motorcycle | 16,048 | | 4 | bus | 3,202 | | 5 | truck | 12,549 | | 6 | van | 25,749 | `person` and `bicycle` are kept for COCO id compatibility but carry **no annotations** — the prompt set targets vehicles only. `van` is id 6 so the standard COCO ids 0–5 stay stable. Traffic is overwhelmingly cars (90%); `bus` is rare (0.5%). This is a long-tailed vehicle dataset, not a balanced one. ## Format Standard COCO. Detection and instance segmentation share one file — masks are compressed RLE in `segmentation`. ```jsonc { "id": 1, "image_id": 0, "category_id": 2, "bbox": [x, y, w, h], // xywh, pixels "area": 3896, // == mask pixel count, not bbox area "iscrowd": 0, "segmentation": {"size": [h, w], "counts": "..."}, // full-frame RLE "score": 0.96, // detection confidence "track_id": 1474, // stable within its source run "global_id": "sb_pos3_drone_0001_1474" } ``` Loads with `pycocotools`; RLE round-trips (`area == mask.sum()` verified on every split). `global_id` is **clip-scoped** (`"_"`) — it identifies a vehicle within one camera, not across cameras. Image file names are `_.jpg`, so every image is traceable to its source video and frame. ```python import os from pycocotools.coco import COCO split = "train" coco = COCO(f"{split}/_annotations.coco.json") img = coco.loadImgs(coco.getImgIds()[0])[0] path = os.path.join(split, img["file_name"]) # works for every split anns = coco.loadAnns(coco.getAnnIds(imgIds=img["id"])) mask = coco.annToMask(anns[0]) # HxW binary ``` ## Splits Split **by position**, then a frame-level cut — not a random shuffle. Randomly splitting video frames leaks near-identical neighbours across splits and inflates scores. - **train** positions are exclusive: their frames never appear in valid/test. - **eval** positions feed both valid and test, cut temporally (first part → valid, remainder → test). valid and test may share a position; neither shares one with train. Frames are selected with a gap + min-vehicle rule rather than a fixed stride: keep a frame only if it has ≥3 annotations and is ≥25 source frames (~1 s) after the last kept one, which drops near-duplicate consecutive frames. Verified: **0 source-run overlap between train and eval**. ### Caveat — Tostmannplatz At Tostmannplatz the split is per *camera*: `tp_pos1`'s drone and `cam_3_100` are in eval while its `cam_48_101`/`cam_48_106` are in train. Those cameras observe **the same intersection at the same instant** from different viewpoints, so the same traffic appears on both sides of the split, seen from different angles. Exclude the `tp_pos1_*` runs from train if you need a strictly scene-disjoint evaluation. ## Notes - Strongly class-imbalanced (90% car). - `person`/`bicycle` are empty by construction. - Frames within a split are temporally correlated (~1 s apart within a run). - Three sites only; limited weather and lighting diversity. Contact: Javi Borau — `jborau@caos.uc3m.es`