Histo3D Format

Histo3D format accumulates event-data received during an integration period or until reaching an event rate threshold, and represent it in framed form.

Note

The sample metavision_event_frame_generation sample can be used to emulate those two mechanism to accumulate events using the command line options --period and --nevents.

Histo3D format accumulates event spikes to the histogram location (x,y) for each positive and negative polarity event with two separated counters, one for each polarity. Every incoming event will increase the corresponding counter by 1 (one). If data addition exceeds the maximum size configured, the counter will be set to the maximum value.

Bit Splitting

The Histo3D format depends on a bit splitting parameter that configures the number of bits allocated for each histogram channel counter.

Here are some possible configurations examples:

  • 4 bits positive, 4 bits negative

  • 6 bits positive, 2 bits negative

  • 4 bits positive, 2 bits negative

  • 6 bits positive, 0 bits negative

The sum of those 2 numbers can not exceed 8, which is the maximum number of bits allocated to store those information. Note also that the organisation of data is always aligned on 8 bits as shown in the Data Format section below where we illustrate the format for those 4 configurations.

Padding and Packing

The Histo3D format allows to set a padding for positive and negative counters representation so that each value is aligned on 8 bits. For example, if the bit splitting (see above) is set to “4 bits positive, 4 bits negative”, the “padded mode” will align any polarity container on 8 bits making it easily loadable in register and then avoiding a costly software shift and mask. Data arrangement in padded and non-padded mode can be seen in the next section on Data Format.

Note that when the data is not padded for 8-bit alignment, it is also referred to as “packed” (and conversely, padded mode is referred to as “unpacked”).

Data Format

In non-padded mode, each 32 bits word contains the information for 4 pixels (4 values for negative events and 4 values for positive events) as shown in the figure below using various Bit Splitting configurations:

Histo3D format in non-padded mode

In padded mode, each 32 bits word contains the information for 2 pixels (2 values for negative events and 2 values for positive events) Here are some example with various Bit Splitting configurations:

Histo3D format in padded mode

RAW file header

When Histo3D data is stored in a RAW files, some specific keys are used to store the information about Bit Splitting and Padding:

  • Bit Splitting is stored in pixellayout in the form of 4p/4n for “4 bits positive, 4 bits negative”

  • Padding information is stored in pixelbytes that describes how many bytes should occupy the data for one pixel (hence, value will be 1 if there is no padding and 2 if there is padding).

For example, here is an extract of a RAW file header for an Histo3D file:

% format HISTO3D
% geometry 320x320
% pixellayout 6p/2n
% pixelbytes 2
% (...)