Repository navigation
feat(schema): load 0.x vehicle states and traffic light links, backfill source LiDARs and capture time - #308
Merged
Merged
Conversation
jacoblambert
force-pushed
the
v1/convert-v0-core
branch
from
October 14, 2026 11:10
1a84b24 to
ae084bb
Compare
jacoblambert
force-pushed
the
v1/convert-v0-rest
branch
from
October 14, 2026 11:10
d3188fc to
3598a11
Compare
jacoblambert
force-pushed
the
v1/convert-v0-core
branch
from
October 15, 2026 03:36
ae084bb to
2066304
Compare
jacoblambert
force-pushed
the
v1/convert-v0-rest
branch
3 times, most recently
from
October 15, 2026 05:40
58bb6a9 to
5f1bc5c
Compare
jacoblambert
marked this pull request as ready for review
October 15, 2026 06:17
jacoblambert
force-pushed
the
v1/convert-v0-core
branch
from
October 15, 2026 08:26
630bd8b to
7013b16
Compare
jacoblambert
force-pushed
the
v1/convert-v0-rest
branch
from
October 15, 2026 08:26
5f1bc5c to
5812b7f
Compare
jacoblambert
force-pushed
the
v1/convert-v0-core
branch
from
October 15, 2026 10:37
7013b16 to
db0ace5
Compare
jacoblambert
force-pushed
the
v1/convert-v0-rest
branch
from
October 15, 2026 10:37
5812b7f to
5d2cfee
Compare
ktro2828
self-requested a review
October 16, 2026 08:53
jacoblambert
force-pushed
the
v1/convert-v0-rest
branch
from
October 21, 2026 01:31
5d2cfee to
df1c63a
Compare
jacoblambert
force-pushed
the
v1/convert-v0-core
branch
from
October 21, 2026 01:31
db0ace5 to
2524cd7
Compare
ktro2828
approved these changes
Oct 21, 2026
jacoblambert
force-pushed
the
v1/convert-v0-core
branch
from
October 22, 2026 09:52
2524cd7 to
1df166c
Compare
jacoblambert
force-pushed
the
v1/convert-v0-rest
branch
from
October 22, 2026 09:53
df1c63a to
bd6c15a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Completes the 0.x → 1.0 conversion from #307:
vehicle_state, traffic-light links, source LiDARs, capture time and placeholder masks. Every local 0.x dataset loads (16 datasets: 10 j6gen2, 4 annotation datasets, 2 traffic-light autolabel datasets).vehicle_state
sourceisvehicle_interface: a fact, not a placeholder (tier4_perception_dataset reads/vehicle/status/*).FORWARDandHIGHbecomeDRIVE(the 0.x converter writesDRIVE, but the 0.x devkit enum and the sample use the other two).additional_info.speedis dropped: it isnorm(longitudinal, lateral), unsigned, so it can't fill the 1.0 velocities. Velocities andheading_ratearenull.Traffic-light links →
instance.map_elementtraffic_lighttable (feat(schema): add new traffic light schema for object detection #288) links a lamp instance to the lanelet2 way of that lamp (type=traffic_light, what the REF014 check verifies). It has no states, so it becomes the instance'smap_element(id=primitive_idas int,type: way), and the 1.0traffic_lighttable (states per regulatory element) stays empty.traffic_light_instance_map(traffic_light_linestring_id), from the unmerged branchfeat/traffic-light-instance-map, which real autolabel datasets already use. It is read too and wins when both list a lamp.traffic_lightrows withoutprimitive_idare skipped with a warning, since no 0.x devkit reads them either.map/folder. Changing the map means regenerating the dataset or making a new version of it.Source LiDARs
The LiDARs merged into a concatenated channel have
sensorrows but no frames of their own in 0.x. They are now filled from the concatenated channel's.infofiles, instead of the default 5-field.binlayout with 0 frames:fields: the concatenated channel's (their points sit in its files, with the same layout);frame_count: the number of concatenated frames that list points from them.On real data: every source in all 171 frames of one dataset (7 fields); 554/554 frames in another, except one LiDAR missing from 2 frames. The
.infofiles are read once per channel (0.1 s for 554 frames). Points are still split the 0.x.binway until the.bin→ Parquet migration.Capture time
log.data_capturedis""in every local 0.x dataset, but 1.0 requires an ISO 8601 time. An empty one is filled with the log's first sample time in UTC (on one dataset, this matches the capture time in its README).2D boxes and masks
mask: null. One real dataset has the same empty placeholder mask on all 395 box labels, written by hand withsize(width, height) instead of pycocotools' (height, width).Category index
0.x categories without
indexget their position incategory.json, which is how the 0.xT4Devkitreads them (fix_category_table): all unset → positions, a mix of set and unset → error. Of the local datasets, only the semantic segmentation one setsindexitself (to the positions); all others leave it unset. 1.0 datasets keepnullwhen there is no index.Known issues and unknowns
Not fixed here:
automatic_annotation, so both 0.x and 1.0 read them as manual. The converter does not guess provenance; datasets must set the flag.red,red_right,crosswalk_red,red_straight_left,red_circle,green_arrow,unknown, ...) and attributes (light_status.on/off,traffic_light_color.*), with no fixed vocabulary to map to 1.0 color / shape / status. This needs an agreed mapping. A lamp shared by several regulatory elements is normal (one signal head serves several lanes): a state read from it gives one row per regulatory element.map_id/version_idstayunknown: 0.xmap.jsonhas no ids.orientation: no local dataset has the 0.xorientationfield, so its conversion is untested on real data.painting2d.py) end at the last pixel, not the edge. Existing 0.x boxes are not re-derived.SurfaceAnn.bboxbug: it swaps x and y (np.wherereturns rows, cols) and ends at the last pixel. The conversion doesn't use it; worth a separate 0.x fix.surface_annrows, non-emptyvehicle_state(every realvehicle_state.jsonis empty).Tests
tests/schema/v1/test_convert_v0.py, on the 0.x sample dataset with small edits:DRIVEand sourcevehicle_interface.data_capturedbecomes the first sample time.traffic_light(primitive_id) ortraffic_light_instance_map(traffic_light_linestring_id) sets the instance'smap_element; the 1.0traffic_lighttable stays empty.nulland the box is kept.surface_annbox matches its decoded mask pixels.