evlib.representation.voxel_grid

Voxel-grid representation.

Classes

VoxelGrid(image_shape, num_bins)

Create a voxel grid from events.

class evlib.representation.voxel_grid.VoxelGrid(image_shape, num_bins)

Create a voxel grid from events. Implementation inspired by https://github.com/uzh-rpg/rpg_e2vid.

Parameters:
  • image_shape (Tuple[int, int]) – (height, width)

  • num_bins (int) – number of bins in the temporal axis of the voxel grid

__call__(events)

Create voxel grid.

Parameters:

events (ndarray) – events: a NumPy array of size [n x d], where n is the number of events and d = 4. Every event is encoded with 4 values (y, x, t, p).

Returns:

A voxelized representation of the event data.

Return type:

ndarray