Dataset Viewer
Duplicate
The dataset viewer is not available for this split.
Cannot load the dataset split (in streaming mode) to extract the first rows.
Error code:   StreamingRowsError
Exception:    ValueError
Message:      Dataset 'frame_window' has length 537 but expected 455644871
Traceback:    Traceback (most recent call last):
                File "/src/services/worker/src/worker/utils.py", line 149, in get_rows_or_raise
                  return get_rows(
                      dataset=dataset,
                  ...<4 lines>...
                      column_names=column_names,
                  )
                File "/src/libs/libcommon/src/libcommon/utils.py", line 272, in decorator
                  return func(*args, **kwargs)
                File "/src/services/worker/src/worker/utils.py", line 129, in get_rows
                  rows_plus_one = list(itertools.islice(safe_iter(ds, dataset=dataset), rows_max_number + 1))
                File "/src/services/worker/src/worker/utils.py", line 544, in safe_iter
                  yield from ds.decode(False) if ds.features else ds
                File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 3052, in __iter__
                  for key, example in ex_iterable:
                                      ^^^^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 2559, in __iter__
                  for key, pa_table in self._iter_arrow():
                                       ~~~~~~~~~~~~~~~~^^
                File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 2584, in _iter_arrow
                  for key, pa_table in self.ex_iterable._iter_arrow():
                                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
                File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 558, in _iter_arrow
                  for key, pa_table in iterator:
                                       ^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/iterable_dataset.py", line 440, in _iter_arrow
                  for key, pa_table in self.generate_tables_fn(**gen_kwags):
                                       ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^
                File "/usr/local/lib/python3.14/site-packages/datasets/packaged_modules/hdf5/hdf5.py", line 76, in _generate_tables
                  num_rows = _check_dataset_lengths(h5, self.info.features)
                File "/usr/local/lib/python3.14/site-packages/datasets/packaged_modules/hdf5/hdf5.py", line 353, in _check_dataset_lengths
                  raise ValueError(f"Dataset '{path}' has length {dset.shape[0]} but expected {num_rows}")
              ValueError: Dataset 'frame_window' has length 537 but expected 455644871

Need help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.

DSEC, converted

DSEC is a stereo event dataset recorded from a car: two Prophesee Gen3.1 event cameras (640Γ—480) and two RGB frame cameras (1440Γ—1080), with disparity and optical-flow ground truth from a lidar. The converted release keeps all of it except the semantic labels, re-encoded for fast loading: events as PODCAST, images and ground truth as compressed HDF5 arrays, and the calibration inside every file.

At a glance

train test
sequences 41 12
events, per camera events/<seq>.lcam.podcast.h5, events/<seq>.rcam.podcast.h5 same
images, both cameras images/<seq>.images.h5 same
disparity, 10 Hz gt/<seq>.disparity.h5, all 41 none (DSEC does not publish test ground truth)
optical flow, 10 Hz gt/<seq>.flow.h5, 18 sequences none

Files

<split>/                                 train or test
  events/<seq>.lcam.podcast.h5           left event camera
  events/<seq>.rcam.podcast.h5           right event camera
  images/<seq>.images.h5                 both frame cameras
  gt/<seq>.disparity.h5                  train only
  gt/<seq>.flow.h5                       train only, where DSEC has flow

<seq> is DSEC's sequence name, e.g. zurich_city_05_a.

Time

In DSEC's release everything is in microseconds on one recording clock, but events are stored relative to an offset:

DSEC file time
events/<left|right>/events.h5 events/t, uint32 Β΅s, relative to the file's t_offset (int64 Β΅s on the recording clock); the two cameras' files have different t_offsets, up to about 1 ms apart
images/timestamps.txt each image's time on the recording clock: the middle of its exposure (the mean of the two cameras' exposure midpoints)
images/<left|right>/exposure_timestamps.txt each image's exposure (start, end) on the recording clock
disparity/timestamps.txt each disparity map's time on the recording clock, equal to an image's
flow/<forward|backward>_timestamps.txt each flow map's (from, to) on the recording clock, equal to two images'

An event's time on the recording clock is t + t_offset of its file.

In the converted files the same two times are kept:

converted file time
event files event timestamps, window_edges_us and every *_us attribute are in event-file time: relative to the left camera's t_offset (an attribute), in both files, so left and right times compare directly; in the left file this is DSEC's own t
images/<seq>.images.h5 each camera's timestamps and exposure on the recording clock, as in DSEC
gt/*.h5 each group's timestamps on the recording clock (image times), and image_index, the image(s) each map is at

So on the recording clock an event is at t + t_offset, and image i at left/timestamps[i] (right/timestamps holds the same: DSEC gives one time per image pair).

Events are windowed on the images. Every image timestamp is an edge of the event windows, in both event files: each image interval (20 Hz, so about 50 ms; auto-exposure moves image times by up to about 1 ms) is cut into 5 windows of about 10 ms (9.8 to 10.2 ms), equal but for the floored microsecond. frame_window[i] is the edge index of image i:

window_edges_us[frame_window[i]]  =  left/timestamps[i] - t_offset

so the events between images i and i + 1 are windows frame_window[i] to frame_window[i + 1] - 1. The events start at the first image and end at the last; DSEC records under 1 ms of events outside them, which are dropped (see Changes).

Left and right windows are the same time span. Both event files of a sequence have the same t_offset and identical window_edges_us, so window k of the left file and window k of the right file cover physically the same time span, in every sequence, and their timestamps compare directly. DSEC's own right-camera file has its own t_offset, up to 0.8 ms from the left's; the converted right file is moved to the left camera's t_offset.

Ground truth is at image times: disparity at every second image (10 Hz), flow between images two apart (100 ms).

Cameras and views

A view is one camera's pixel grid, raw or rectified (undistorted, and rotated so that a stereo pair's rows align). Every data object (an event file's root, a camera's group in the image file, a ground-truth group) says which view it is in (view_id, view_name) and carries that view's camera model as attributes, the same names in every file:

attribute meaning
camera_model pinhole
intrinsics (fx, fy, cx, cy), px
resolution (height, width), px
is_rectified whether the pixels are rectified; their intrinsics then apply directly
distortion_model, distortion_coeffs raw views only: radtan, (k1, k2, p1, p2), OpenCV's model with k3 = 0

DSEC's views:

view name what is in it from DSEC's cam_to_cam.yaml
0 left_event_raw left events intrinsics/cam0
1 left_frame_raw nothing (DSEC ships rectified images only) β€”
2 right_frame_raw nothing β€”
3 right_event_raw right events intrinsics/cam3
4 left_event_rectified flow, disparity (event) intrinsics/camRect0
5 left_frame_rectified left images, disparity (image) intrinsics/camRect1
6 right_frame_rectified right images intrinsics/camRect2
7 right_event_rectified nothing; the target of the right rectify_map intrinsics/camRect3

Views 1 and 2 hold no data but are kept: DSEC's camera-to-camera transforms run through them.

Transforms. Every file has a group views with the rig's transforms, exactly as DSEC provides them, and the views it lists (attribute views, an array of (id, name) pairs: int64 and string). T_ab (float64, 4Γ—4, metres) maps a point from view b's camera frame to view a's, frames with x right, y down, z forward:

transform from DSEC's
T_10 left event (raw) β†’ left frame (raw) extrinsics/T_10
T_21 left frame β†’ right frame (raw) extrinsics/T_21
T_32 right frame β†’ right event (raw) extrinsics/T_32
T_40 left event raw β†’ rectified extrinsics/R_rect0, zero translation
T_51 left frame raw β†’ rectified extrinsics/R_rect1
T_62 right frame raw β†’ rectified extrinsics/R_rect2
T_73 right event raw β†’ rectified extrinsics/R_rect3

They connect all eight views, so any pair composes from them: walk the path, and invert each transform walked backwards (T_ba is the inverse of T_ab). For example, from the rectified left event view to the rectified left frame view: T_54 = T_51 Β· T_10 Β· inverse(T_40). The calibration is per sequence.

Event files

events/<seq>.lcam.podcast.h5 and events/<seq>.rcam.podcast.h5, one per event camera, in the PODCAST format: events in windows, pixel-sorted inside each. evkit reads them; the format description has the layout for writing a reader.

dataset contents storage
dcoord uint32, per event: the pixel index's delta from the previous event of its window Blosc2 lz4hc 9 with byte shuffle, chunks of 32 to 256 k events (sized per file)
pts uint8, per event: the 7-bit timestamp code, the polarity in bit 7 uncompressed, contiguous
idx uint64, per window + 1: window k is events [idx[k], idx[k + 1]) uncompressed, contiguous
window_edges_us int64, per window + 1: window k is [window_edges_us[k], window_edges_us[k + 1]), event-file time uncompressed, contiguous
frame_window int64, per image: its window edge (see Time) uncompressed, contiguous
attribute contents source
dataset_name, dataset_seq DSEC, the sequence
sensor prophesee gen3.1
total_events, t_start_us, t_end_us, duration_us the events kept, first and last time
t_offset recording-clock time of event-file time 0, Β΅s, the same in both files the left camera's events.h5 t_offset
view_id, view_name, camera model attributes view 0 or 3, raw cam_to_cam.yaml
rectify_map float32, height Γ— width Γ— 2: raw pixel (y, x) β†’ rectified (xβ€², yβ€²) rectify_map.h5
rectified_intrinsics, rectified_resolution the view rectify_map maps into (4 or 7) intrinsics/camRect0, camRect3
window_duration_us, window_origin_us the nominal 10 ms window, and the first edge
fixed_windows, lossless, polarity_bit, ts_coding, format_version how the events are coded: False, False, 7, abs, 2

Event precision. Pixel positions, polarities and the number of events are exact. Timestamps are coded with 128 steps per window and decoded at the step's centre, so a decoded timestamp is within 40 Β΅s of DSEC's.

Image files

images/<seq>.images.h5, both rectified frame cameras, a group each: left and right, carrying the attributes of views 5 and 6 (rectified, no distortion). The root carries dataset_name (DSEC) and dataset_seq.

dataset, in left/ and right/ contents storage source
images uint8, N Γ— 1080 Γ— 1440 Γ— 3 RGB, pixel-identical to DSEC's PNGs Blosc1 lz4hc 9, no shuffle, one image per chunk images/<left|right>/rectified/*.png
timestamps int64, N: each image's time, recording clock, Β΅s; DSEC gives one time per image pair, so left/ and right/ hold the same uncompressed, contiguous images/timestamps.txt
exposure int64, N Γ— 2: exposure (start, end), recording clock, Β΅s uncompressed, contiguous images/<left|right>/exposure_timestamps.txt

Ground truth

Each ground-truth file has a group per kind of map, carrying its view's attributes and holding the maps with their own timestamps. Both files' roots carry dataset_name (DSEC) and dataset_seq.

Disparity, gt/<seq>.disparity.h5, every second image (10 Hz), train only: groups event (view 4) and image (view 5).

dataset, in event/ and image/ contents storage source
disparity float32, N Γ— 480 Γ— 640 (event) or N Γ— 1080 Γ— 1440 (image): disparity in px, NaN where invalid Blosc1 lz4hc 9, no shuffle, one map per chunk disparity/<event|image>/*.png
timestamps int64, N: each map's time, recording clock, Β΅s uncompressed, contiguous disparity/timestamps.txt
image_index int64, N: the image each map is at (0, 2, 4, …) uncompressed, contiguous

Besides the view attributes, event/ and image/ carry disparity_to_depth, DSEC's 4Γ—4 reprojection matrix Q for their stereo pair (cams_03 and cams_12). Depth in metres is Q[2, 3] / (Q[3, 2] * disparity), NaN where the disparity is.

Optical flow, gt/<seq>.flow.h5, the 18 train sequences DSEC has it for, in some of them only for parts of the sequence: groups forward and backward, both view 4.

dataset, in forward/ and backward/ contents storage source
flow float32, N Γ— 480 Γ— 640 Γ— 2: (x, y) displacement in px from the map's from time to its to time, NaN where invalid Blosc1 lz4hc 9, no shuffle, one map per chunk flow/<forward|backward>/*.png
timestamps int64, N Γ— 2: (from, to), recording clock, Β΅s uncompressed, contiguous flow/<forward|backward>_timestamps.txt
image_index int64, N Γ— 2: the (from, to) images, (k, k + 2) forward and (k, k βˆ’ 2) backward uncompressed, contiguous

Everything in a sequence

zurich_city_05_a (train), every group, dataset and attribute (@). Shapes are this sequence's; values are shown where they are the same in every sequence.

events/zurich_city_05_a.lcam.podcast.h5
β”œβ”€β”€ @dataset_name = "DSEC"
β”œβ”€β”€ @dataset_seq = "zurich_city_05_a"
β”œβ”€β”€ @sensor = "prophesee gen3.1"
β”œβ”€β”€ @total_events = 925135243
β”œβ”€β”€ @t_start_us, @t_end_us, @duration_us        int64, event-file time
β”œβ”€β”€ @t_offset = 37379399960                      int64, Β΅s
β”œβ”€β”€ @view_id = 0
β”œβ”€β”€ @view_name = "left_event_raw"
β”œβ”€β”€ @camera_model = "pinhole"
β”œβ”€β”€ @intrinsics                                  float64 (4,): fx, fy, cx, cy
β”œβ”€β”€ @distortion_model = "radtan"
β”œβ”€β”€ @distortion_coeffs                           float64 (4,): k1, k2, p1, p2
β”œβ”€β”€ @resolution = (480, 640)
β”œβ”€β”€ @is_rectified = False
β”œβ”€β”€ @rectify_map                                 float32 (480, 640, 2)
β”œβ”€β”€ @rectified_intrinsics                        float64 (4,), view 4
β”œβ”€β”€ @rectified_resolution = (480, 640)
β”œβ”€β”€ @format_version = 2
β”œβ”€β”€ @window_duration_us = 10000
β”œβ”€β”€ @window_origin_us                            int64, the first image
β”œβ”€β”€ @fixed_windows = False
β”œβ”€β”€ @lossless = False
β”œβ”€β”€ @polarity_bit = 7
β”œβ”€β”€ @ts_coding = "abs"
β”œβ”€β”€ dcoord             uint32 (925135243,)       Blosc2 lz4hc 9 + shuffle, chunks of 65536
β”œβ”€β”€ pts                uint8 (925135243,)        uncompressed
β”œβ”€β”€ idx                uint64 (8761,)            uncompressed
β”œβ”€β”€ window_edges_us    int64 (8761,)             uncompressed
β”œβ”€β”€ frame_window       int64 (1753,)             uncompressed
└── views/
    β”œβ”€β”€ @views = [(0, "left_event_raw"), (1, "left_frame_raw"), (2, "right_frame_raw"),
    β”‚             (3, "right_event_raw"), (4, "left_event_rectified"),
    β”‚             (5, "left_frame_rectified"), (6, "right_frame_rectified"),
    β”‚             (7, "right_event_rectified")]
    └── @T_10, @T_21, @T_32, @T_40, @T_51, @T_62, @T_73    float64 (4, 4)

events/zurich_city_05_a.rcam.podcast.h5
β”œβ”€β”€ as the left file, with @total_events = 769122379, the same @t_offset,
β”‚   @view_id = 3, @view_name = "right_event_raw", view 3's camera model, and
β”‚   @rectified_intrinsics of view 7
β”œβ”€β”€ dcoord, pts                (769122379,)
β”œβ”€β”€ idx, window_edges_us       (8761,)
β”œβ”€β”€ frame_window               (1753,)
└── views/                     as above

images/zurich_city_05_a.images.h5
β”œβ”€β”€ @dataset_name = "DSEC"
β”œβ”€β”€ @dataset_seq = "zurich_city_05_a"
β”œβ”€β”€ left/
β”‚   β”œβ”€β”€ @view_id = 5
β”‚   β”œβ”€β”€ @view_name = "left_frame_rectified"
β”‚   β”œβ”€β”€ @camera_model = "pinhole"
β”‚   β”œβ”€β”€ @intrinsics                              float64 (4,)
β”‚   β”œβ”€β”€ @resolution = (1080, 1440)
β”‚   β”œβ”€β”€ @is_rectified = True
β”‚   β”œβ”€β”€ images         uint8 (1753, 1080, 1440, 3)   Blosc1 lz4hc 9, chunks (1, 1080, 1440, 3)
β”‚   β”œβ”€β”€ timestamps     int64 (1753,)                 uncompressed
β”‚   └── exposure       int64 (1753, 2)               uncompressed
β”œβ”€β”€ right/                                           as left/, view 6 "right_frame_rectified"
└── views/                                           as above

gt/zurich_city_05_a.disparity.h5
β”œβ”€β”€ @dataset_name = "DSEC"
β”œβ”€β”€ @dataset_seq = "zurich_city_05_a"
β”œβ”€β”€ event/
β”‚   β”œβ”€β”€ @view_id = 4, @view_name = "left_event_rectified", @camera_model,
β”‚   β”‚   @intrinsics, @resolution = (480, 640), @is_rectified = True
β”‚   β”œβ”€β”€ @disparity_to_depth                      float64 (4, 4), Q of cams_03
β”‚   β”œβ”€β”€ disparity      float32 (877, 480, 640)       Blosc1 lz4hc 9, chunks (1, 480, 640)
β”‚   β”œβ”€β”€ timestamps     int64 (877,)                  uncompressed
β”‚   └── image_index    int64 (877,)                  uncompressed
β”œβ”€β”€ image/
β”‚   β”œβ”€β”€ @view_id = 5, @view_name = "left_frame_rectified", @camera_model,
β”‚   β”‚   @intrinsics, @resolution = (1080, 1440), @is_rectified = True
β”‚   β”œβ”€β”€ @disparity_to_depth                      float64 (4, 4), Q of cams_12
β”‚   β”œβ”€β”€ disparity      float32 (877, 1080, 1440)     Blosc1 lz4hc 9, chunks (1, 1080, 1440)
β”‚   β”œβ”€β”€ timestamps     int64 (877,)                  uncompressed
β”‚   └── image_index    int64 (877,)                  uncompressed
└── views/                                           as above

gt/zurich_city_05_a.flow.h5
β”œβ”€β”€ @dataset_name = "DSEC"
β”œβ”€β”€ @dataset_seq = "zurich_city_05_a"
β”œβ”€β”€ forward/
β”‚   β”œβ”€β”€ @view_id = 4, @view_name = "left_event_rectified", @camera_model,
β”‚   β”‚   @intrinsics, @resolution = (480, 640), @is_rectified = True
β”‚   β”œβ”€β”€ flow           float32 (629, 480, 640, 2)    Blosc1 lz4hc 9, chunks (1, 480, 640, 2)
β”‚   β”œβ”€β”€ timestamps     int64 (629, 2)                uncompressed
β”‚   └── image_index    int64 (629, 2)                uncompressed
β”œβ”€β”€ backward/                                        as forward/
└── views/                                           as above

Recipes

Imports for all of them:

import h5py
import hdf5plugin  # registers the compression filters
import numpy as np

An image and its time.

with h5py.File("images/zurich_city_05_a.images.h5") as f:
    image = f["left/images"][100]        # 1080 x 1440 x 3, uint8, rectified
    t = f["left/timestamps"][100]        # recording clock, us

The events between two images. Windows frame_window[i] to frame_window[i + 1] - 1 of an event file:

with h5py.File("events/zurich_city_05_a.lcam.podcast.h5") as f:
    w0, w1 = f["frame_window"][100], f["frame_window"][101]
    # decode windows [w0, w1) with evkit

Rectified event coordinates.

with h5py.File("events/zurich_city_05_a.lcam.podcast.h5") as f:
    rectify = f.attrs["rectify_map"]     # 480 x 640 x 2
x_rect, y_rect = rectify[y, x].T         # for raw event coordinates x, y

Depth from disparity.

with h5py.File("gt/zurich_city_05_a.disparity.h5") as f:
    disparity = f["event/disparity"][10]
    Q = f["event"].attrs["disparity_to_depth"]
    image = f["event/image_index"][10]   # the image (and frame_window entry) it is at
depth = Q[2, 3] / (Q[3, 2] * disparity)  # metres, NaN where invalid

The views a file lists. h5py reads the names as bytes:

with h5py.File("events/zurich_city_05_a.lcam.podcast.h5") as f:
    names = {int(i): n.decode() for i, n in f["views"].attrs["views"]}
# {0: "left_event_raw", 1: "left_frame_raw", ..., 7: "right_event_rectified"}

A transform between two views.

with h5py.File("events/zurich_city_05_a.lcam.podcast.h5") as f:
    T = {k: f["views"].attrs[k] for k in ("T_10", "T_40", "T_51")}
T_54 = T["T_51"] @ T["T_10"] @ np.linalg.inv(T["T_40"])   # rectified event -> rectified frame

Changes from the original

what change
events Only the events from the first image to the last are kept: DSEC's files run under 1 ms beyond them (270 to 29,000 events a file, at most 0.017%). Timestamps are coded to within 40 Β΅s; everything else is exact.
event times The left camera's event-file time and t_offset are DSEC's own; the right camera's events are moved to the left's t_offset (DSEC's two differ by up to 0.8 ms), so both files' times compare directly.
images PNG re-encoded as Blosc1 lz4hc, pixel-identical.
disparity DSEC's 16-bit PNG divided by 256, with 0 (invalid) as NaN.
flow Decoded as DSEC's reference code does, (code βˆ’ 2¹⁡) / 128, with invalid pixels as NaN instead of 0 plus a mask.
calibration Copied from cam_to_cam.yaml, resolutions as (height, width). Dropped: T_cn_cnm1, a copy of T_10, T_21, T_32, and cam_to_lidar.yaml, as no lidar data ships.
not included DSEC-Semantic labels.

Source and licence

Converted from DSEC's own release, train and test: events, images, disparity, optical flow and calibration, as downloaded from https://dsec.ifi.uzh.ch.

DSEC is released under the Creative Commons Attribution-ShareAlike 4.0 International licence (CC BY-SA 4.0), whose ShareAlike term requires derived work to use the same licence. The converted files are therefore released under CC BY-SA 4.0 too.

Downloads last month
105