dau_core.records

Byte layouts of the rows and records the row, grouped and bar tiles exchange with the host.

A layout is a tuple of (field, kind) pairs in wire order, little-endian, with kind a numpy-style code (i4, u4, i8, u8). The tiles’ registry entries declare the same records in 64-bit words (record_words and output_record_words), and the suite checks the two agree, so a tile that changes its record width fails there rather than on the host.

Field names follow the goldens’ result types (GroupAggregate, BarAggregate); pad fields hold no data and keep the wider fields on their natural alignment.

Attributes

QUAD_ROW_FIELDS

KEYED_ROW_FIELDS

GROUP_RECORD_FIELDS

BAR_ROW_FIELDS

BAR_RECORD_FIELDS

QUAD_ROW_BYTES

KEYED_ROW_BYTES

GROUP_RECORD_BYTES

BAR_ROW_BYTES

BAR_RECORD_BYTES

Functions

struct_format(fields) → str

The little-endian struct format for a layout.

numpy_dtype_fields(fields) → list[tuple[str, str]]

The same layout as numpy dtype pairs, for vectorized consumers.

record_bytes(fields) → int

Bytes per row or record of a layout.

Module Contents

dau_core.records.QUAD_ROW_FIELDS: Layout = (('key', 'i4'), ('value', 'i4'), ('aux0', 'i4'), ('aux1', 'i4'))
dau_core.records.KEYED_ROW_FIELDS: Layout = (('key', 'i4'), ('value', 'u4'))
dau_core.records.GROUP_RECORD_FIELDS: Layout = (('key', 'i4'), ('first', 'i4'), ('last', 'i4'), ('minimum', 'i4'), ('maximum', 'i4'), ('pad',...
dau_core.records.BAR_ROW_FIELDS: Layout = (('key', 'i4'), ('price', 'i4'), ('shares', 'i4'), ('frac', 'i4'))
dau_core.records.BAR_RECORD_FIELDS: Layout = (('key', 'i4'), ('open', 'i4'), ('close', 'i4'), ('low', 'i4'), ('high', 'i4'), ('pad', 'i4'),...
dau_core.records.struct_format(fields: Layout) → str[source]

The little-endian struct format for a layout.

dau_core.records.numpy_dtype_fields(fields: Layout) → list[tuple[str, str]][source]

The same layout as numpy dtype pairs, for vectorized consumers.

dau_core.records.record_bytes(fields: Layout) → int[source]

Bytes per row or record of a layout.

dau_core.records.QUAD_ROW_BYTES
dau_core.records.KEYED_ROW_BYTES
dau_core.records.GROUP_RECORD_BYTES
dau_core.records.BAR_ROW_BYTES
dau_core.records.BAR_RECORD_BYTES