MultiTanProcessor

class toasty.multi_tan.MultiTanProcessor(collection)[source]

Bases: object

Generate tiles from a collection of images on a common TAN projection.

Some large astronomical images are stored as a collection of sub-images that share a common tangential projection, a format is that is nice and easy to convert into a WWT “study” tile pyramid. This class can process a collection of such images and break them into the highest-resolution layer of such a tile pyramid.

Methods Summary

compute_global_pixelization(builder)

Read the input images to determine the global pixelation of this data set.

tile(pio[, parallel, cli_progress])

Tile the input images into the deepest layer of the pyramid.

Methods Documentation

compute_global_pixelization(builder)[source]

Read the input images to determine the global pixelation of this data set.

This function reads the FITS headers of all of the input data files to determine the overall image size and the parameters of its tiling as a WWT study. This should be pretty easy, because we’ve been assured that everything is on a nice common TAN, which is exactly what we need to end up with anyway.

tile(pio, parallel=None, cli_progress=False, **kwargs)[source]

Tile the input images into the deepest layer of the pyramid.

Parameters:
piotoasty.pyramid.PyramidIO

A PyramidIO instance to manage the I/O with the tiles in the tile pyramid.

parallelinteger or None (the default)

The level of parallelization to use. If unspecified, defaults to using all CPUs. If the OS does not support fork-based multiprocessing, parallel processing is not possible and serial processing will be forced. Pass 1 to force serial processing.

cli_progressoptional boolean, defaults False

If true, a progress bar will be printed to the terminal.