anu_ctlab_io.raw

Raw binary format support for anu_ctlab_io.

Provides write-only support for headerless raw binary files (C-order, little-endian). No optional extras are required for this format.

Package Contents

anu_ctlab_io.raw.dataset_to_raw(dataset, path, compute=True, **kwargs)

Write dataset data to a headerless raw binary file.

Elements are written in C-order (row-major), little-endian byte order, with no metadata. The dtype matches the source dataset exactly.

Data is written via dask.array.store using a single compute() call, with each chunk sought to its correct byte offset so chunks may be written in any order.

Parameters:
  • dataset (anu_ctlab_io._dataset.Dataset) – The Dataset to write.

  • path (pathlib.Path) – The path to write the raw binary file to.

  • compute (bool)

  • kwargs (Any)

Return type:

dask.delayed.Delayed | None