punchbowl.level3.stellar#

Classes#

PUNCHImageProcessor

Special loader for PUNCH data.

Functions#

to_celestial(→ ndcube.NDCube)

Convert polarization from mzpsolar to Celestial frame.

from_celestial(→ ndcube.NDCube)

Convert polarization from Celestial frame to mzpsolar.

generate_starfield_background(→ [ndcube.NDCube, ...)

Create a background starfield_bg map from a series of PUNCH images over a long period of time.

subtract_starfield_background_task(→ ndcube.NDCube)

Subtracts a background starfield from an input data frame.

create_empty_starfield_background(→ numpy.ndarray)

Create an empty starfield background map.

Module Contents#

punchbowl.level3.stellar.to_celestial(input_data: ndcube.NDCube) ndcube.NDCube#

Convert polarization from mzpsolar to Celestial frame.

All images need their polarization converted to Celestial frame to generate the background starfield model.

punchbowl.level3.stellar.from_celestial(input_data: ndcube.NDCube) ndcube.NDCube#

Convert polarization from Celestial frame to mzpsolar.

All images need their polarization converted back to Solar frame after removing the stellar polarization.

class punchbowl.level3.stellar.PUNCHImageProcessor(layer: int, apply_mask: bool = True, key: str = ' ')#

Bases: remove_starfield.ImageProcessor

Special loader for PUNCH data.

layer#
apply_mask = True#
key = ' '#
load_image(filename: str) remove_starfield.ImageHolder#

Load an image.

punchbowl.level3.stellar.generate_starfield_background(filenames: list[str], map_scale: float = 0.01, target_mem_usage: float = 1000, n_procs: int | None = None, reference_time: datetime.datetime | None = None) [ndcube.NDCube, ndcube.NDCube]#

Create a background starfield_bg map from a series of PUNCH images over a long period of time.

punchbowl.level3.stellar.subtract_starfield_background_task(data_object: ndcube.NDCube, starfield_background_path: str | None) ndcube.NDCube#

Subtracts a background starfield from an input data frame.

checks the dimensions of input data frame and background starfield match and subtracts the background starfield from the data frame of interest.

Parameters:
  • data_object (NDCube) – A NDCube data frame to be background subtracted

  • starfield_background_path (str) – path to a NDCube background starfield map

Returns:

A background starfield subtracted data frame

Return type:

NDCube

punchbowl.level3.stellar.create_empty_starfield_background(data_object: ndcube.NDCube) numpy.ndarray#

Create an empty starfield background map.