Images (craftutils.observation.image)

Contains classes representing astronomical images, for performing transformations and processing on them.

Functions

craftutils.observation.image.quantity_support(format='latex_inline')

Enable support for plotting astropy.units.Quantity instances in matplotlib.

craftutils.observation.image.fits_table(input_path: str, ...)

Produces and writes to disk a table of .fits files in the given path, with the vital statistics of each. Intended only for use with raw ESO data.

craftutils.observation.image.fits_table_all(input_path: str, ...)

Produces and writes to disk a table of .fits files in the given path, with the vital statistics of each. Intended only for use with raw ESO data. :param input_path: :param output_path: :param science_only: If True, we are writing a list for a folder that also contains calibration files, which we want

to ignore.

Returns

craftutils.observation.image.detect_instrument(path: str, ...)
craftutils.observation.image.from_path(path: str, ...)

To be used when there may already be an image instance for this path floating around in memory, and it’s okay (or better) to access this one instead of creating a new instance. When the image may have overwritten a previous file, instantiating the image directly is better.

craftutils.observation.image.expunge()
craftutils.observation.image.register(source, target, ...)

Transform source to coincide pixel to pixel with target.

craftutils.observation.image.cat_columns(cat, f: str | None = None)
Parameters
cat

f: str | None = None

Returns

craftutils.observation.image.gaussian_distributed_point(x_0, ...)
craftutils.observation.image.solve_field(...)

Returns True if successful (by checking whether the corrected file is generated); False if not. :param image_files: :param base_filename: :param overwrite: :param flags: :param params: :return:

craftutils.observation.image.deepest(img_1: ImagingImage, ...)
craftutils.observation.image.imaging_set_class_dict()
craftutils.observation.image.coadded_set_class_dict()

Classes

class craftutils.observation.image.ESOImage(craftutils.observation.epoch.Epoch.frame_class)

Generic parent class for ESO images, both spectra and imaging

class craftutils.observation.image.Ellipse(matplotlib.patches.Patch)

A scale-free ellipse.

class craftutils.observation.image.Rectangle(matplotlib.patches.Patch)

A rectangle defined via an anchor point xy and its width and height.

class craftutils.observation.image.SigmaClip

Class to perform sigma clipping.

class craftutils.observation.image.ImageNormalize(matplotlib.colors.Normalize)

Normalization class to be used with Matplotlib.

class craftutils.observation.image.LogStretch(astropy.visualization.stretch.BaseStretch)

A log stretch.

class craftutils.observation.image.LinearStretch(astropy.visualization.stretch.BaseStretch)

A linear stretch with a slope and offset.

class craftutils.observation.image.SqrtStretch(astropy.visualization.stretch.BaseStretch)

A square root stretch.

class craftutils.observation.image.MinMaxInterval(astropy.visualization.interval.BaseInterval)

Interval based on the minimum and maximum values in the data.

class craftutils.observation.image.ZScaleInterval(astropy.visualization.interval.BaseInterval)

Interval based on IRAF’s zscale.

class craftutils.observation.image.F4CoaddedImage(craftutils.observation.epoch.ImagingEpoch.coadded_class)
class craftutils.observation.image.GMOSCoaddedImage(craftutils.observation.epoch.ImagingEpoch.coadded_class)
class craftutils.observation.image.HubbleImage(craftutils.observation.epoch.ImagingEpoch.coadded_class)
class craftutils.observation.image.ESOImagingImage(craftutils.observation.epoch.ImagingEpoch.frame_class, craftutils.observation.image.ESOImage)
class craftutils.observation.image.SurveyCutout(craftutils.observation.epoch.ImagingEpoch.coadded_class)
class craftutils.observation.image.WISECutout(craftutils.observation.image.SurveyCutout)
class craftutils.observation.image.DESCutout(craftutils.observation.image.SurveyCutout)
class craftutils.observation.image.PanSTARRS1Cutout(craftutils.observation.image.SurveyCutout)
class craftutils.observation.image.RawSpectrum(craftutils.observation.epoch.SpectroscopyEpoch.frame_class)
class craftutils.observation.image.IFUImage(craftutils.observation.epoch.ImagingEpoch.frame_class)
class craftutils.observation.image.MUSEImage(craftutils.observation.image.IFUImage)