Datasets:

Formats:
json
ArXiv:
License:
Xuweiyi commited on
Commit
bfe1d58
·
verified ·
1 Parent(s): f446e03

TrackingBench: 2,000 queries, ground truth, images of 10 sources, evaluator, rebuild script for 3 TAPVid-3D sources

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. README.md +298 -1
  2. SHA256SUMS +0 -0
  3. evaluate.py +82 -0
  4. images/drivtap/Day_Bridge/f00005.png +3 -0
  5. images/drivtap/Day_Bridge/f00010.png +3 -0
  6. images/drivtap/Day_Bridge/f00014.png +3 -0
  7. images/drivtap/Day_Bridge/f00015.png +3 -0
  8. images/drivtap/Day_Bridge/f00018.png +3 -0
  9. images/drivtap/Day_Bridge/f00019.png +3 -0
  10. images/drivtap/Day_Bridge/f00034.png +3 -0
  11. images/drivtap/Day_Bridge/f00049.png +3 -0
  12. images/drivtap/Day_Bridge/f00054.png +3 -0
  13. images/drivtap/Day_Bridge/f00055.png +3 -0
  14. images/drivtap/Day_Bridge/f00060.png +3 -0
  15. images/drivtap/Day_Bridge/f00070.png +3 -0
  16. images/drivtap/Day_Bridge/f00081.png +3 -0
  17. images/drivtap/Day_Bridge/f00084.png +3 -0
  18. images/drivtap/Day_Bridge/f00092.png +3 -0
  19. images/drivtap/Day_Bridge/f00093.png +3 -0
  20. images/drivtap/Day_Bridge/p0002_ref00000.jpg +3 -0
  21. images/drivtap/Day_Bridge/p0002_ref00078.jpg +3 -0
  22. images/drivtap/Day_Bridge/p0003_ref00000.jpg +3 -0
  23. images/drivtap/Day_Bridge/p0003_ref00027.jpg +3 -0
  24. images/drivtap/Day_Bridge/p0004_ref00000.jpg +3 -0
  25. images/drivtap/Day_Bridge/p0004_ref00007.jpg +3 -0
  26. images/drivtap/Day_Bridge/p0006_ref00001.jpg +3 -0
  27. images/drivtap/Day_Bridge/p0007_ref00027.jpg +3 -0
  28. images/drivtap/Day_Bridge/p0008_ref00000.jpg +3 -0
  29. images/drivtap/Day_Bridge/p0008_ref00014.jpg +3 -0
  30. images/drivtap/Day_Bridge/p0009_ref00039.jpg +3 -0
  31. images/drivtap/Day_Bridge/p0010_ref00026.jpg +3 -0
  32. images/drivtap/Day_Bridge/p0011_ref00000.jpg +3 -0
  33. images/drivtap/Day_Bridge/p0011_ref00064.jpg +3 -0
  34. images/drivtap/Day_Fast/f00006.png +3 -0
  35. images/drivtap/Day_Fast/f00007.png +3 -0
  36. images/drivtap/Day_Fast/f00016.png +3 -0
  37. images/drivtap/Day_Fast/f00023.png +3 -0
  38. images/drivtap/Day_Fast/f00024.png +3 -0
  39. images/drivtap/Day_Fast/f00026.png +3 -0
  40. images/drivtap/Day_Fast/f00030.png +3 -0
  41. images/drivtap/Day_Fast/f00036.png +3 -0
  42. images/drivtap/Day_Fast/f00041.png +3 -0
  43. images/drivtap/Day_Fast/f00045.png +3 -0
  44. images/drivtap/Day_Fast/f00046.png +3 -0
  45. images/drivtap/Day_Fast/f00048.png +3 -0
  46. images/drivtap/Day_Fast/f00049.png +3 -0
  47. images/drivtap/Day_Fast/p0000_ref00030.jpg +3 -0
  48. images/drivtap/Day_Fast/p0005_ref00000.jpg +3 -0
  49. images/drivtap/Day_Fast/p0006_ref00000.jpg +3 -0
  50. images/drivtap/Day_Fast/p0006_ref00006.jpg +3 -0
README.md CHANGED
@@ -1,3 +1,300 @@
1
  ---
2
- license: mit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ license: other
3
+ license_name: source-dataset-terms
4
+ license_link: https://huggingface.co/datasets/uva-cv-lab/TrackingBench#terms-of-use
5
+ pretty_name: TrackingBench
6
+ size_categories:
7
+ - 1K<n<10K
8
+ tags:
9
+ - point-tracking
10
+ - tracking-any-point
11
+ - correspondence
12
+ - vision-language-models
13
+ - benchmark
14
+ configs:
15
+ - config_name: default
16
+ data_files:
17
+ - split: test
18
+ path: queries.jsonl
19
  ---
20
+
21
+ # TrackingBench
22
+
23
+ TrackingBench asks one question of a model: given a marked point on a surface in one frame of a video, where is that
24
+ same surface point in another frame, and is it visible? It has 2,000 queries on 272 real-video clips from 13 existing
25
+ point-tracking benchmarks, across six domains. It is the benchmark of
26
+ [Tracking Any Point with Agentic Visual Reasoning](https://agentap.cs.virginia.edu/).
27
+
28
+ | | |
29
+ | --- | --- |
30
+ | Queries | 2,000 (1,579 with a visible target, 421 with an occluded one) |
31
+ | Clips | 272 real videos from 13 source benchmarks |
32
+ | Domains | Everyday activities, sports and performances, robotic manipulation, driving and street scenes, animals and nature, biomedical scenes |
33
+ | Input per query | A reference frame with one marked point, and a target frame |
34
+ | Answer per query | The point's pixel position in the target frame, or "occluded" |
35
+
36
+ ## One task, three protocols
37
+
38
+ A system gets a reference image with one marked surface point and a target image from the same video. It answers where
39
+ that point is and whether it is visible. All three protocols use the same 2,000 queries.
40
+
41
+ - **Direct.** The model sees the two images and answers once. It tests what the model can locate by looking.
42
+ - **Agentic with tools.** The same model works as an agent. It can zoom in, compare regions and check its own answer
43
+ before it commits. It tests what reasoning with tools adds.
44
+ - **AgenTAP.** The full method. The agent reasons as above, and expert vision models add candidate points as
45
+ hypotheses. The agent verifies them and may accept, refine or reject each one. It tests reasoning with expert
46
+ hypotheses to verify.
47
+
48
+ ## Files
49
+
50
+ | File | Content |
51
+ | --- | --- |
52
+ | `queries.jsonl` | The 2,000 queries, one JSON object per line |
53
+ | `truth.jsonl` | The ground truth of each query |
54
+ | `images/<source>/<clip>/` | The reference images (`p<point>_ref<frame>.jpg`, with the marker and inset drawn in) and the target frames (`f<frame>.jpg` or `.png`), for 10 of the 13 sources |
55
+ | `rebuild/` | The script that builds the images of the other three sources from their original files (see [Images of three TAPVid-3D sources](#images-of-three-tapvid-3d-sources)) |
56
+ | `prompt_template.txt` | The template of the prompt stored in every query |
57
+ | `evaluate.py` | The scoring script, with no dependencies beyond Python 3 |
58
+ | `SHA256SUMS` | Checksums of every file |
59
+
60
+ A query:
61
+
62
+ | Field | Meaning |
63
+ | --- | --- |
64
+ | `id` | Query id, `<source>/<clip>/p<point>/r<reference frame>/f<target frame>` |
65
+ | `source`, `clip` | The source benchmark and the clip |
66
+ | `domain` | One of the six domains |
67
+ | `point` | The point's index in the clip's source annotation |
68
+ | `reference_frame`, `target_frame`, `frame_gap` | Frame indices and their distance |
69
+ | `reference_x`, `reference_y` | The marked point's position in the reference frame, in pixels |
70
+ | `reference_image` | The reference frame with a red crosshair labelled A on the queried point and a magnified inset of the region around it |
71
+ | `target_image` | The target frame, unmarked |
72
+ | `width`, `height` | Size of both images in pixels |
73
+ | `prompt` | The text prompt used for the Direct protocol |
74
+
75
+ A ground-truth record has `id`, `x`, `y` (pixels in the target image, origin at the top-left corner), `occluded`,
76
+ `width` and `height`.
77
+
78
+ ## Quick start
79
+
80
+ ```python
81
+ import json
82
+ from huggingface_hub import snapshot_download
83
+ from PIL import Image
84
+
85
+ root = snapshot_download("uva-cv-lab/TrackingBench", repo_type="dataset")
86
+ queries = [json.loads(line) for line in open(f"{root}/queries.jsonl")]
87
+
88
+ with open("predictions.jsonl", "w") as out:
89
+ for q in queries:
90
+ reference = Image.open(f"{root}/{q['reference_image']}")
91
+ target = Image.open(f"{root}/{q['target_image']}")
92
+ x, y, occluded = my_model(reference, target, q["prompt"]) # your system
93
+ out.write(json.dumps({"id": q["id"], "x": x, "y": y, "occluded": occluded}) + "\n")
94
+ ```
95
+
96
+ ```bash
97
+ python evaluate.py predictions.jsonl
98
+ ```
99
+
100
+ Build the images of the three TAPVid-3D sources first (next section). Without them, 595 queries have no images.
101
+
102
+ ## Images of three TAPVid-3D sources
103
+
104
+ The licences of Aria Digital Twin, CMU Panoptic Studio and the Waymo Open Dataset do not allow us to redistribute
105
+ their frames. The 595 queries of TAPVid-3D Aria Digital Twin, TAPVid-3D Panoptic Studio and DriveTrack (58 clips,
106
+ 1,084 images) therefore come without images. Their queries and ground truth are included. Build the images once:
107
+
108
+ 1. Accept the licence of each source:
109
+ [Aria Digital Twin](https://www.projectaria.com/datasets/adt/license/),
110
+ [CMU Panoptic Studio](http://domedb.perception.cs.cmu.edu/) and
111
+ [Waymo Open Dataset](https://waymo.com/open/terms/).
112
+ 2. Generate the TAPVid-3D files of the three subsets with TAPVid-3D's own scripts, as its
113
+ [instructions](https://github.com/google-deepmind/tapnet/tree/main/tapnet/tapvid3d) describe. For Aria Digital
114
+ Twin, first download the recordings from Project Aria Explorer with `aria_dataset_downloader`.
115
+
116
+ ```bash
117
+ pip install "git+https://github.com/google-deepmind/tapnet.git"[tapvid3d_eval,tapvid3d_generation]
118
+ python3 -m tapnet.tapvid3d.annotation_generation.generate_adt --help
119
+ python3 -m tapnet.tapvid3d.annotation_generation.generate_pstudio --help
120
+ python3 -m tapnet.tapvid3d.annotation_generation.generate_drivetrack --help
121
+ ```
122
+
123
+ TrackingBench needs only the 58 files listed in `rebuild/restricted_clips.txt` (17 Aria Digital Twin, 8 Panoptic
124
+ Studio, 33 DriveTrack), with their frames (`images_jpeg_bytes`).
125
+ 3. Put them in one folder per subset and run the script:
126
+
127
+ ```
128
+ <dir>/adt/<clip>.npz
129
+ <dir>/pstudio/<clip>.npz
130
+ <dir>/drivetrack/<clip>.npz
131
+ ```
132
+
133
+ ```bash
134
+ pip install -r rebuild/requirements.txt
135
+ python rebuild/build_restricted_images.py --tapvid3d <dir>
136
+ ```
137
+
138
+ The script writes each target frame as stored in the TAPVid-3D file and draws each reference image the way the
139
+ benchmark did. It then checks every file against `rebuild/SHA256SUMS.restricted`. With the TAPVid-3D files we used
140
+ and the versions in `rebuild/requirements.txt`, all 1,084 images match the originals byte for byte. Aria Digital Twin
141
+ frames are decoded from the recordings, so another JPEG encoder can change their bytes slightly. The script lists any
142
+ file that differs.
143
+
144
+ ## Evaluation
145
+
146
+ `evaluate.py` scores all 2,000 queries. A query without a readable answer counts as wrong. Positions are compared at
147
+ the TAP-Vid 256 x 256 scale.
148
+
149
+ | Metric | Meaning |
150
+ | --- | --- |
151
+ | AJ | Average Jaccard over the thresholds 1, 2, 4, 8 and 16 px. It scores position and visibility together, and it is the ranking metric |
152
+ | APD | Average share of visible targets that are predicted visible and within each threshold |
153
+ | OA | Occlusion accuracy: the share of queries with the right visible or occluded call |
154
+ | EPE | Mean end-point error over visible targets in pixels, capped at 32 |
155
+
156
+ The script also reports every metric by domain and by source.
157
+
158
+ ## Terms of use
159
+
160
+ TrackingBench reuses video frames and point annotations of the benchmarks listed below. Each source keeps its own
161
+ licence and terms, which continue to apply to its part of this dataset, and several allow non-commercial use only. No
162
+ new licence is granted for the source material. Use each source's frames only as its terms allow. The frames of three
163
+ sources are not included because their licences do not allow redistribution (see
164
+ [Images of three TAPVid-3D sources](#images-of-three-tapvid-3d-sources)). The query selection, the prompts and the code
165
+ (`evaluate.py` and `rebuild/`) are released under the MIT licence.
166
+
167
+ ## Sources and citation
168
+
169
+ If you use TrackingBench, please cite our paper and the benchmarks it is built from.
170
+
171
+ | Source | Clips | Queries | Images included | Licence or terms | Reference |
172
+ | --- | ---: | ---: | :---: | --- | --- |
173
+ | Perception Test | 18 | 207 | yes | CC BY 4.0 | Pătrăucean et al., 2023 |
174
+ | TAPVid-3D Panoptic Studio | 8 | 204 | no | Annotations CC BY 4.0 (TAPVid-3D). Frames: CMU Panoptic Studio terms | Koppula et al., 2024 |
175
+ | ITTO | 16 | 202 | yes | ITTO terms, non-commercial research (MOSE part CC BY-NC-SA 4.0) | Demler et al., 2025 |
176
+ | DriveTrack | 33 | 199 | no | Annotations CC BY 4.0 (TAPVid-3D). Frames: Waymo Open Dataset licence | Balasingam et al., 2024, and Koppula et al., 2024 |
177
+ | TAPVid-3D Aria Digital Twin | 17 | 192 | no | Annotations CC BY 4.0 (TAPVid-3D). Frames: Aria Digital Twin licence | Koppula et al., 2024 |
178
+ | TAP-Vid Kinetics | 69 | 189 | yes | Annotations CC BY 4.0. Videos: the licence of each YouTube video | Doersch et al., 2022 |
179
+ | RoboTAP | 10 | 179 | yes | CC BY 4.0 | Vecerik et al., 2024 |
180
+ | RoboTrack Real | 27 | 178 | yes | RoboTrack Real release terms | RoboTrack24, 2026 |
181
+ | TAP-Vid DAVIS | 13 | 175 | yes | Annotations CC BY 4.0. Videos: DAVIS terms | Doersch et al., 2022 |
182
+ | EgoPoints | 35 | 122 | yes | Frames from EPIC-KITCHENS, CC BY-NC 4.0 | Darkhalil et al., 2025 |
183
+ | DrivTAP | 5 | 79 | yes | TAPFormer release terms | Liu et al., 2026 |
184
+ | VOTSp2026 | 14 | 57 | yes | VOTS2026 challenge terms | VOT Challenge, 2026 |
185
+ | VL-SurgPT | 7 | 17 | yes | VL-SurgPT terms, non-commercial | Zhou et al., 2026 |
186
+ | Total | 272 | 2,000 | | | |
187
+
188
+ ```bibtex
189
+ @misc{chen2026tracking,
190
+ title = {Tracking Any Point with Agentic Visual Reasoning},
191
+ author = {Chen, Xuweiyi and Yao, Jin and Mou, Linzhan and Gong, Lei and Liu, Di and Zhang, Cheng and Ma, Ziqiao and Xu, Sihan and Harley, Adam W. and Qian, Shengyi and Cheng, Zezhou},
192
+ year = {2026},
193
+ }
194
+
195
+ @inproceedings{tapvid,
196
+ title = {{TAP-Vid}: A Benchmark for Tracking Any Point in a Video},
197
+ author = {Doersch, Carl and Gupta, Ankush and Markeeva, Larisa and Recasens, Adri{\`a} and Smaira, Lucas and Aytar, Yusuf and Carreira, Jo{\~a}o and Zisserman, Andrew and Yang, Yi},
198
+ booktitle = {Advances in Neural Information Processing Systems, Datasets and Benchmarks Track},
199
+ volume = {35},
200
+ pages = {13610--13626},
201
+ year = {2022},
202
+ url = {https://arxiv.org/abs/2211.03726}
203
+ }
204
+
205
+ @inproceedings{tapvid3d,
206
+ title = {{TAPVid-3D}: A Benchmark for Tracking Any Point in {3D}},
207
+ author = {Koppula, Skanda and Rocco, Ignacio and Yang, Yi and Heyward, Joe and Carreira, Jo{\~a}o and Zisserman, Andrew and Brostow, Gabriel and Doersch, Carl},
208
+ booktitle = {Advances in Neural Information Processing Systems, Datasets and Benchmarks Track},
209
+ volume = {37},
210
+ pages = {82149--82165},
211
+ year = {2024},
212
+ url = {https://arxiv.org/abs/2407.05921}
213
+ }
214
+
215
+ @inproceedings{drivetrack,
216
+ title = {{DriveTrack}: A Benchmark for Long-Range Point Tracking in Real-World Videos},
217
+ author = {Balasingam, Arjun and Chandler, Joseph and Li, Chenning and Zhang, Zhoutong and Balakrishnan, Hari},
218
+ booktitle = {Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition},
219
+ pages = {22488--22497},
220
+ year = {2024},
221
+ url = {https://arxiv.org/abs/2312.09523}
222
+ }
223
+
224
+ @inproceedings{perceptiontest,
225
+ title = {{Perception Test}: A Diagnostic Benchmark for Multimodal Video Models},
226
+ author = {P{\u{a}}tr{\u{a}}ucean, Viorica and Smaira, Lucas and Gupta, Ankush and {Recasens Continente}, Adri{\`a} and Markeeva, Larisa and Banarse, Dylan and Koppula, Skanda and Heyward, Joseph and Malinowski, Mateusz and Yang, Yi and others},
227
+ booktitle = {Advances in Neural Information Processing Systems, Datasets and Benchmarks Track},
228
+ volume = {36},
229
+ pages = {42748--42761},
230
+ year = {2023},
231
+ url = {https://arxiv.org/abs/2305.13786}
232
+ }
233
+
234
+ @inproceedings{itto,
235
+ title = {Is This Tracker On? {A} Benchmark Protocol for Dynamic Tracking},
236
+ author = {Demler, Ilona and Chauhan, Saumya and Gkioxari, Georgia},
237
+ booktitle = {Advances in Neural Information Processing Systems, Datasets and Benchmarks Track},
238
+ volume = {38},
239
+ pages = {18469--18498},
240
+ year = {2025},
241
+ url = {https://arxiv.org/abs/2510.19819}
242
+ }
243
+
244
+ @inproceedings{robotap,
245
+ title = {{RoboTAP}: Tracking Arbitrary Points for Few-Shot Visual Imitation},
246
+ author = {Vecerik, Mel and Doersch, Carl and Yang, Yi and Davchev, Todor and Aytar, Yusuf and Zhou, Guangyao and Hadsell, Raia and Agapito, Lourdes and Scholz, Jon},
247
+ booktitle = {IEEE International Conference on Robotics and Automation},
248
+ pages = {5397--5403},
249
+ year = {2024},
250
+ doi = {10.1109/ICRA57147.2024.10611409},
251
+ url = {https://arxiv.org/abs/2308.15975}
252
+ }
253
+
254
+ @misc{robotrack,
255
+ title = {{RoboTrack Real v3}},
256
+ author = {{RoboTrack24}},
257
+ howpublished = {Hugging Face dataset. \url{https://huggingface.co/datasets/RoboTrack24/RoboTrack-Real-Expanded}},
258
+ year = {2026},
259
+ url = {https://huggingface.co/datasets/RoboTrack24/RoboTrack-Real-Expanded},
260
+ note = {Accessed September 2026}
261
+ }
262
+
263
+ @inproceedings{egopoints,
264
+ title = {{EgoPoints}: Advancing Point Tracking for Egocentric Videos},
265
+ author = {Darkhalil, Ahmad and Guerrier, Rhodri and Harley, Adam W. and Damen, Dima},
266
+ booktitle = {Proceedings of the IEEE/CVF Winter Conference on Applications of Computer Vision},
267
+ pages = {8545--8554},
268
+ year = {2025},
269
+ url = {https://arxiv.org/abs/2412.04592}
270
+ }
271
+
272
+ @inproceedings{tapformer,
273
+ title = {{TAPFormer}: Robust Arbitrary Point Tracking via Transient Asynchronous Fusion of Frames and Events},
274
+ author = {Liu, Jiaxiong and Tan, Zhen and Zhang, Jinpu and Zhou, Yi and Shen, Hui and Chen, Xieyuanli and Hu, Dewen},
275
+ booktitle = {Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition},
276
+ pages = {37053--37062},
277
+ year = {2026},
278
+ url = {https://arxiv.org/abs/2603.04989}
279
+ }
280
+
281
+ @misc{votsp2026,
282
+ title = {{{VOTSp2026}: Point-Tracking Subchallenge of the {VOTS2026} Visual Object Tracking and Segmentation Challenge}},
283
+ author = {{VOT Challenge}},
284
+ howpublished = {Official challenge website. \url{https://www.votchallenge.net/vots2026/}},
285
+ year = {2026},
286
+ url = {https://www.votchallenge.net/vots2026/},
287
+ note = {Accessed September 2026}
288
+ }
289
+
290
+ @inproceedings{vlsurgpt,
291
+ title = {Bridging Vision and Language for Robust Context-Aware Surgical Point Tracking: The {VL-SurgPT} Dataset and Benchmark},
292
+ author = {Zhou, Rulin and He, Wenlong and Wang, An and Zhang, Jianhang and Zeng, Xuanhui and Zhang, Xi and Zhu, Chaowei and Hu, Haijun and Ren, Hongliang},
293
+ booktitle = {Proceedings of the AAAI Conference on Artificial Intelligence},
294
+ volume = {40},
295
+ pages = {13755--13763},
296
+ year = {2026},
297
+ doi = {10.1609/aaai.v40i16.38383},
298
+ url = {https://arxiv.org/abs/2511.12026}
299
+ }
300
+ ```
SHA256SUMS ADDED
The diff for this file is too large to render. See raw diff
 
evaluate.py ADDED
@@ -0,0 +1,82 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/env python3
2
+ """Score predictions on TrackingBench.
3
+
4
+ python evaluate.py predictions.jsonl [--truth truth.jsonl] [--queries queries.jsonl]
5
+
6
+ predictions.jsonl has one JSON object per line: {"id": <query id>, "x": <float>, "y": <float>, "occluded": <bool>}.
7
+ x and y are pixels in the target image, with the origin at the top-left corner. An answer of occluded needs no x and y.
8
+
9
+ All 2,000 queries are scored. A query with no answer, or with an answer that cannot be read, counts as wrong everywhere.
10
+ Positions are compared at the TAP-Vid 256 x 256 scale: a pixel offset is multiplied by 255 / (size - 1).
11
+
12
+ AJ average Jaccard over the thresholds 1, 2, 4, 8 and 16 px (position and visibility together)
13
+ APD average share of visible targets predicted visible and within each threshold
14
+ OA occlusion accuracy: the share of queries with the right visible / occluded call
15
+ EPE mean end-point error over visible targets, capped at 32 px (a visible target answered occluded counts 32)
16
+ """
17
+ import argparse
18
+ import json
19
+ import math
20
+ from collections import defaultdict
21
+ from pathlib import Path
22
+
23
+ THRESHOLDS = (1, 2, 4, 8, 16)
24
+ EPE_CAP = 32.0
25
+
26
+
27
+ def read(path):
28
+ with open(path) as stream:
29
+ return [json.loads(line) for line in stream if line.strip()]
30
+
31
+
32
+ def score(truths, answers):
33
+ by_id = {a["id"]: a for a in answers}
34
+ rows = [] # (truth visible, predicted visible, distance, answer missing)
35
+ for truth in truths:
36
+ answer = by_id.get(truth["id"])
37
+ readable = answer is not None and isinstance(answer.get("occluded"), bool) and (
38
+ answer["occluded"] or (answer.get("x") is not None and answer.get("y") is not None))
39
+ hidden = bool(answer["occluded"]) if readable else False
40
+ distance = math.inf
41
+ if readable and not hidden and not truth["occluded"]:
42
+ sx, sy = 255.0 / (truth["width"] - 1), 255.0 / (truth["height"] - 1)
43
+ distance = math.hypot((float(answer["x"]) - truth["x"]) * sx, (float(answer["y"]) - truth["y"]) * sy)
44
+ rows.append((not truth["occluded"], readable and not hidden, distance, not readable))
45
+ visible = [r for r in rows if r[0]]
46
+ out = {"queries": len(rows), "answered": sum(not r[3] for r in rows), "visible_queries": len(visible)}
47
+ within, jaccard = [], []
48
+ for t in THRESHOLDS:
49
+ within.append(sum(r[2] < t for r in visible) / len(visible) if visible else float("nan"))
50
+ true_pos = sum(r[0] and r[1] and r[2] < t for r in rows)
51
+ false_pos = sum(r[1] and (not r[0] or not r[2] < t) for r in rows) + sum(r[3] and not r[0] for r in rows)
52
+ false_neg = sum(r[0] and not (r[1] and r[2] < t) for r in rows)
53
+ jaccard.append(true_pos / max(true_pos + false_pos + false_neg, 1))
54
+ out[f"d_{t}"] = round(100 * within[-1], 2)
55
+ out["apd"] = round(100 * sum(within) / len(within), 2)
56
+ out["aj"] = round(100 * sum(jaccard) / len(jaccard), 2)
57
+ out["oa"] = round(100 * sum(r[0] == r[1] and not r[3] for r in rows) / len(rows), 2)
58
+ out["epe"] = round(sum(min(r[2], EPE_CAP) for r in visible) / len(visible), 2) if visible else float("nan")
59
+ return out
60
+
61
+
62
+ def main():
63
+ here = Path(__file__).resolve().parent
64
+ parser = argparse.ArgumentParser(description=__doc__, formatter_class=argparse.RawDescriptionHelpFormatter)
65
+ parser.add_argument("predictions")
66
+ parser.add_argument("--truth", default=here / "truth.jsonl")
67
+ parser.add_argument("--queries", default=here / "queries.jsonl", help="adds scores by domain and by source")
68
+ args = parser.parse_args()
69
+ truths, answers = read(args.truth), read(args.predictions)
70
+ result = {"overall": score(truths, answers)}
71
+ if Path(args.queries).exists():
72
+ queries = {q["id"]: q for q in read(args.queries)}
73
+ for key in ("domain", "source"):
74
+ groups = defaultdict(list)
75
+ for truth in truths:
76
+ groups[queries[truth["id"]][key]].append(truth)
77
+ result[f"by_{key}"] = {name: score(group, answers) for name, group in sorted(groups.items())}
78
+ print(json.dumps(result, indent=1))
79
+
80
+
81
+ if __name__ == "__main__":
82
+ main()
images/drivtap/Day_Bridge/f00005.png ADDED

Git LFS Details

  • SHA256: f585d036ce97b408795b85e1fb5fb8e79a32449d12056658fee643d4961dd25d
  • Pointer size: 132 Bytes
  • Size of remote file: 1.41 MB
images/drivtap/Day_Bridge/f00010.png ADDED

Git LFS Details

  • SHA256: a4ea0c596d4875cf86b9e91ca8927af8c17f0ebfeb600756edd2541ecc6a9767
  • Pointer size: 132 Bytes
  • Size of remote file: 1.42 MB
images/drivtap/Day_Bridge/f00014.png ADDED

Git LFS Details

  • SHA256: 216f4d4f04286812cb007e7626a3665f674ecb0f5baa4f2c89a454f0c325686b
  • Pointer size: 132 Bytes
  • Size of remote file: 1.43 MB
images/drivtap/Day_Bridge/f00015.png ADDED

Git LFS Details

  • SHA256: bc9b3dd1dbfe7fa07940b57959a17265d3735926e8a061dbd636442abf3d67ea
  • Pointer size: 132 Bytes
  • Size of remote file: 1.44 MB
images/drivtap/Day_Bridge/f00018.png ADDED

Git LFS Details

  • SHA256: eab3b1cf3963e0ed6c3d0a2686903cdf12ee6cc32dce063837b0d618c174a7a5
  • Pointer size: 132 Bytes
  • Size of remote file: 1.44 MB
images/drivtap/Day_Bridge/f00019.png ADDED

Git LFS Details

  • SHA256: 5a36b5b682efa5f5d9d705fe836a8c810ace79cf06fc632fa7def22f090350ca
  • Pointer size: 132 Bytes
  • Size of remote file: 1.45 MB
images/drivtap/Day_Bridge/f00034.png ADDED

Git LFS Details

  • SHA256: 859bc61f9db8ca19e62c1eeb4b86807684d2093aa28be71b6141527947f74d2e
  • Pointer size: 132 Bytes
  • Size of remote file: 1.37 MB
images/drivtap/Day_Bridge/f00049.png ADDED

Git LFS Details

  • SHA256: b1374db7f793132b39a553ec831be6af2b03d1b17eefb4ca2a55bcd060227267
  • Pointer size: 132 Bytes
  • Size of remote file: 1.35 MB
images/drivtap/Day_Bridge/f00054.png ADDED

Git LFS Details

  • SHA256: 7f81ac9ef5d61944a5ccfef7b190eaf634c02d3c607ed08be63d970b5aec75f4
  • Pointer size: 132 Bytes
  • Size of remote file: 1.34 MB
images/drivtap/Day_Bridge/f00055.png ADDED

Git LFS Details

  • SHA256: 2be2ac4e267611ac04704c56d5a38971bf9d18240f76a102664389e6d7837fac
  • Pointer size: 132 Bytes
  • Size of remote file: 1.34 MB
images/drivtap/Day_Bridge/f00060.png ADDED

Git LFS Details

  • SHA256: b7fa51bf261dce01a47137e92917cd0f78ad6b94253afc4d89c35d4669536f99
  • Pointer size: 132 Bytes
  • Size of remote file: 1.33 MB
images/drivtap/Day_Bridge/f00070.png ADDED

Git LFS Details

  • SHA256: ec77aac0493a67b611bc63cfadfa65f73d1057dcd05fabb675d2d6c2e01b4375
  • Pointer size: 132 Bytes
  • Size of remote file: 1.35 MB
images/drivtap/Day_Bridge/f00081.png ADDED

Git LFS Details

  • SHA256: eb14a6ae612ab2660f2b93e97abf76d29a091b2f6929fe2977700916a38cab57
  • Pointer size: 132 Bytes
  • Size of remote file: 1.36 MB
images/drivtap/Day_Bridge/f00084.png ADDED

Git LFS Details

  • SHA256: c9bf7bf66b175cef6749f49fdfe1b7baf406b5e50c6ef3980c9d36f3c51984a9
  • Pointer size: 132 Bytes
  • Size of remote file: 1.35 MB
images/drivtap/Day_Bridge/f00092.png ADDED

Git LFS Details

  • SHA256: 9c4aeaafec556639491b4969fb303ccca656553a15085522b0b5a71cca5de919
  • Pointer size: 132 Bytes
  • Size of remote file: 1.38 MB
images/drivtap/Day_Bridge/f00093.png ADDED

Git LFS Details

  • SHA256: 0ccd0ef049e81c5b7a71f88357e0bb15e55c1fdb2934e6279946caa74cfa050e
  • Pointer size: 132 Bytes
  • Size of remote file: 1.34 MB
images/drivtap/Day_Bridge/p0002_ref00000.jpg ADDED

Git LFS Details

  • SHA256: 96f8d3543642d897cf25c668c16f667c08b583c34ee03edce48beb2cf8ac3b30
  • Pointer size: 131 Bytes
  • Size of remote file: 255 kB
images/drivtap/Day_Bridge/p0002_ref00078.jpg ADDED

Git LFS Details

  • SHA256: 937b02f0b4f098455446ff09fb3516db84fd29dd5f5b34e1c6db1b89dc248028
  • Pointer size: 131 Bytes
  • Size of remote file: 258 kB
images/drivtap/Day_Bridge/p0003_ref00000.jpg ADDED

Git LFS Details

  • SHA256: ad00ced72dfbf44eac0e4f0830e8cbf90d69d894e11c5c90a2b79bef3755597c
  • Pointer size: 131 Bytes
  • Size of remote file: 253 kB
images/drivtap/Day_Bridge/p0003_ref00027.jpg ADDED

Git LFS Details

  • SHA256: a3a3281e5deef9356aedda83344b373bfc13253aff147953bf3facb5966de3a8
  • Pointer size: 131 Bytes
  • Size of remote file: 253 kB
images/drivtap/Day_Bridge/p0004_ref00000.jpg ADDED

Git LFS Details

  • SHA256: 1a903f80b149d0ef56815ceee973b4d0c08218c418a64b5c39012f4eab57504c
  • Pointer size: 131 Bytes
  • Size of remote file: 253 kB
images/drivtap/Day_Bridge/p0004_ref00007.jpg ADDED

Git LFS Details

  • SHA256: c1d90ac810c4be2ae92e13c953aa1183a278835fae5d5b23f90b519a6e26be7a
  • Pointer size: 131 Bytes
  • Size of remote file: 254 kB
images/drivtap/Day_Bridge/p0006_ref00001.jpg ADDED

Git LFS Details

  • SHA256: e487115fe7ea6c1d0c356b4ec2f52ed87e94803e4f6890ee9e37b31723124730
  • Pointer size: 131 Bytes
  • Size of remote file: 262 kB
images/drivtap/Day_Bridge/p0007_ref00027.jpg ADDED

Git LFS Details

  • SHA256: f5a16bee224abd1394009b0b4365bd8b77246214963ea489cfa2f05309871cc3
  • Pointer size: 131 Bytes
  • Size of remote file: 258 kB
images/drivtap/Day_Bridge/p0008_ref00000.jpg ADDED

Git LFS Details

  • SHA256: 95575f08a21c317015f5268c353e1e2996b32a302ce9e721cc1fc0c21570420b
  • Pointer size: 131 Bytes
  • Size of remote file: 251 kB
images/drivtap/Day_Bridge/p0008_ref00014.jpg ADDED

Git LFS Details

  • SHA256: 2647107b837a4a074ca1a57c48604c6b2cf87030cc3fddc7f5d042a09342197c
  • Pointer size: 131 Bytes
  • Size of remote file: 247 kB
images/drivtap/Day_Bridge/p0009_ref00039.jpg ADDED

Git LFS Details

  • SHA256: 735de67457aefe9bb55d464342dae16c2973adf3e9cd851c2b6b3d352c564130
  • Pointer size: 131 Bytes
  • Size of remote file: 208 kB
images/drivtap/Day_Bridge/p0010_ref00026.jpg ADDED

Git LFS Details

  • SHA256: 9d619f356ff9030dd77f31b0cf1a5c9385babab0a39e0ae271aa58ff996472ac
  • Pointer size: 131 Bytes
  • Size of remote file: 209 kB
images/drivtap/Day_Bridge/p0011_ref00000.jpg ADDED

Git LFS Details

  • SHA256: 1791a6843d86c48d654bcc9c210092cc33720c24e49cd58b52717ea3bfac0cf4
  • Pointer size: 131 Bytes
  • Size of remote file: 256 kB
images/drivtap/Day_Bridge/p0011_ref00064.jpg ADDED

Git LFS Details

  • SHA256: ad52b26e3e012b2c556d4bef5d9bb3ca08fe39123e53f498dacf5ca8c83b798d
  • Pointer size: 131 Bytes
  • Size of remote file: 263 kB
images/drivtap/Day_Fast/f00006.png ADDED

Git LFS Details

  • SHA256: d22899f7fda889037ed19f49406aef06cb628296ff20d6eda7b9bfabfa5e1fe5
  • Pointer size: 132 Bytes
  • Size of remote file: 1.69 MB
images/drivtap/Day_Fast/f00007.png ADDED

Git LFS Details

  • SHA256: 24534451f78b10f719bf7c6785e43567a872d06d89338e3de4ef6f44ac8163c5
  • Pointer size: 132 Bytes
  • Size of remote file: 1.6 MB
images/drivtap/Day_Fast/f00016.png ADDED

Git LFS Details

  • SHA256: f0751ebff67ede1ffa333490b2652997785c3b02abca701f8279a612ebfd869c
  • Pointer size: 132 Bytes
  • Size of remote file: 1.68 MB
images/drivtap/Day_Fast/f00023.png ADDED

Git LFS Details

  • SHA256: 4f255a29ac39717593dd8169b8c3b4df4077adbcd792e919caa4d6fc616b5565
  • Pointer size: 132 Bytes
  • Size of remote file: 1.71 MB
images/drivtap/Day_Fast/f00024.png ADDED

Git LFS Details

  • SHA256: 7139c5f81adf4fe3550053d59c333093981f1d5a09c4c1ff3fa99f056c55a1e3
  • Pointer size: 132 Bytes
  • Size of remote file: 1.66 MB
images/drivtap/Day_Fast/f00026.png ADDED

Git LFS Details

  • SHA256: a2948bf9dc8bcca8d6b6d4fab7dfb69f52a177ff4a9f439abf162a56ecd08be3
  • Pointer size: 132 Bytes
  • Size of remote file: 1.62 MB
images/drivtap/Day_Fast/f00030.png ADDED

Git LFS Details

  • SHA256: 79c4a81f62caf7846ceac62a1f157b0a8c23db5376ba48df1e2de8299adf6a64
  • Pointer size: 132 Bytes
  • Size of remote file: 1.45 MB
images/drivtap/Day_Fast/f00036.png ADDED

Git LFS Details

  • SHA256: 424d38f21c44cb7e710a0a92aa3ae4dff54b7570bf85eba4b49af4bc4b2af61c
  • Pointer size: 132 Bytes
  • Size of remote file: 1.66 MB
images/drivtap/Day_Fast/f00041.png ADDED

Git LFS Details

  • SHA256: 7dc55ca99173ce5dabfb53e076e5600c1059ee961962d559eea39a7169974f70
  • Pointer size: 132 Bytes
  • Size of remote file: 1.7 MB
images/drivtap/Day_Fast/f00045.png ADDED

Git LFS Details

  • SHA256: 50e68d1b4a7698bf895c49eaace56bdeb4ce77e43d018fbcdfa52a8cc789b788
  • Pointer size: 132 Bytes
  • Size of remote file: 1.66 MB
images/drivtap/Day_Fast/f00046.png ADDED

Git LFS Details

  • SHA256: bd837f3e4e646aca08da6ff99be54284c1e2fbb59be0caf49c1d598532b9b83a
  • Pointer size: 132 Bytes
  • Size of remote file: 1.6 MB
images/drivtap/Day_Fast/f00048.png ADDED

Git LFS Details

  • SHA256: e9e7cf0dcd1a85601f5272f08462a5274d6547d38cf4306b3cd4704aaf24fce0
  • Pointer size: 132 Bytes
  • Size of remote file: 1.72 MB
images/drivtap/Day_Fast/f00049.png ADDED

Git LFS Details

  • SHA256: 13169ea533534484497811976fc1c2ff88e9f8aefc0d2565f542223944b7aaf9
  • Pointer size: 132 Bytes
  • Size of remote file: 1.54 MB
images/drivtap/Day_Fast/p0000_ref00030.jpg ADDED

Git LFS Details

  • SHA256: cf8a04dae132c4c1388a7735351a5d92c091b8806ff3b1292ddfd9a653cb4748
  • Pointer size: 131 Bytes
  • Size of remote file: 230 kB
images/drivtap/Day_Fast/p0005_ref00000.jpg ADDED

Git LFS Details

  • SHA256: 8b70b3b64d9618fac01f280989657404f85d5643dec182801f5a5bd62bea34b6
  • Pointer size: 131 Bytes
  • Size of remote file: 298 kB
images/drivtap/Day_Fast/p0006_ref00000.jpg ADDED

Git LFS Details

  • SHA256: 6e30a0135bedf732d8d6736bf2633a93d32e9aea303dacb4426e647eb149ed48
  • Pointer size: 131 Bytes
  • Size of remote file: 303 kB
images/drivtap/Day_Fast/p0006_ref00006.jpg ADDED

Git LFS Details

  • SHA256: 62b767609f59fe45616f852d7c621fa555bf667704bfe65a0ddeb647b886b831
  • Pointer size: 131 Bytes
  • Size of remote file: 331 kB