# Chunks and chunksets

For the processing of the IMBFITS files, MRTCAL introduces the concept of chunks (see Fig ). One dump of the IMBFITS DATA column is a collection of such chunks. MRTCAL can make no assumption on the way they are ordered (this comes from ???). The PART column indicates to which spectrum each chunk belongs (spectra are identified with integer numbers). Each “set of chunks belonging to the same final spectrum” is called a chunkset in the MRTCAL nomenclature. From one chunkset, MRTCAL will produce one spectrum1.1.

The chunks in each DATA row can belong to several spectra (e.g., 8 for FTS), and by definition to as many chunksets. MRTCAL maps those chunksets internally as a chunkset_1D Fortran structure, i.e., an array of chunksets.

The DATA column has as many rows as the number of pixels of the receiver times the number of time dumps. This introduces 2 new dimensions which are used to map all1.2, the DATA column into a chunkset_3D Fortran structure. The 2 new dimensions here are pixels and time (see Fig ).

For its internal needs, MRTCAL has to refer to a single time dump in the 3rd dimension. It can also time-average this 3rd dimension. In those 2 use-cases, the final product is then available through a chunkset_2D Fortran structure.

Figure: How one dump in the IMBFITS DATA column is divided into chunks, gathered by family (chunksets), and reordered to produce the spectra.

Figure: How all the dumps in the IMBFITS DATA column is divided into 3D chunksets. After this, they can be time-averaged, or can be accessed one by one.

Subsections

- Chunks slicing
- Polarimetry