# Transforms¶

## ASDF Schema Definitions¶

This package defines ASDF schemas that are used for validating the representation of transforms in the ASDF format. These schemas contain useful documentation about the associated types, and can also be used by other implementations that wish to interoperate with these transform definitions.

## jwst.transforms Package¶

### Classes¶

 AngleFromGratingEquation(groove_density, …) Solve the 3D Grating Dispersion Law for the refracted angle. Solve the 3D Grating Dispersion Law for the wavelength. Unitless2DirCos(**kwargs) Transform a vector to directional cosines. DirCos2Unitless(**kwargs) Transform directional cosines to vector. Rotation3DToGWA(angles, axes_order[, name]) Perform a 3D rotation given an angle in degrees. Gwa2Slit(slits, models) NIRSpec GWA to slit transform. Slit2Msa(slits, models) Transform from Nirspec slit_frame to msa_frame. Snell(angle, kcoef, lcoef, tcoef, tref, …) Apply transforms, including Snell law, through the NIRSpec prism. Logical(condition, compareto, value, **kwargs) Substitute values in an array where the condition is evaluated to True. NirissSOSSModel(spectral_orders, models) NIRISS SOSS wavelength solution model. V23ToSky(angles, axes_order[, name]) Transform from V2V3 to a standard coordinate system (ICRS). Slit(name, shutter_id, dither_position, …) Nirspec Slit structure definition NIRCAMForwardRowGrismDispersion(orders[, …]) Return the transform from grism to image for the given spectral order. NIRCAMForwardColumnGrismDispersion(orders[, …]) Return the transform from grism to image for the given spectral order. NIRCAMBackwardGrismDispersion(orders[, …]) Return the valid pixel(s) and wavelengths given center x,y and lam MIRI_AB2Slice([beta_zero, beta_del, channel]) MIRI MRS alpha, beta to slice transform GrismObject([sid, order_bounding, …]) Grism Objects identified from a direct image catalog and segment map. NIRISSForwardRowGrismDispersion(orders[, …]) This model calculates the wavelengths of vertically dispersed NIRISS grism data. NIRISSForwardColumnGrismDispersion(orders[, …]) This model calculates the wavelengths for horizontally dispersed NIRISS grism data. NIRISSBackwardGrismDispersion(orders[, …]) This model calculates the dispersion extent of NIRISS pixels. V2V3ToIdeal(v3idlyangle, v2ref, v3ref, vparity) Performs the transform from telescope V2,V3 to Ideal coordinate system. IdealToV2V3(v3idlyangle, v2ref, v3ref, vparity) Performs the transform from Ideal to telescope V2,V3 coordinate system.

## jwst.transforms.models Module¶

Models used by the JWST pipeline.

The models are written using the astropy.modeling framework. Since they are specific to JWST, the models and their ASDF schemas are kept here separately from astropy. An ASDF extension for this package is registered with ASDF through entry points.

### Classes¶

 AngleFromGratingEquation(groove_density, …) Solve the 3D Grating Dispersion Law for the refracted angle. Solve the 3D Grating Dispersion Law for the wavelength. Unitless2DirCos(**kwargs) Transform a vector to directional cosines. DirCos2Unitless(**kwargs) Transform directional cosines to vector. Rotation3DToGWA(angles, axes_order[, name]) Perform a 3D rotation given an angle in degrees. Gwa2Slit(slits, models) NIRSpec GWA to slit transform. Slit2Msa(slits, models) Transform from Nirspec slit_frame to msa_frame. Snell(angle, kcoef, lcoef, tcoef, tref, …) Apply transforms, including Snell law, through the NIRSpec prism. Logical(condition, compareto, value, **kwargs) Substitute values in an array where the condition is evaluated to True. NirissSOSSModel(spectral_orders, models) NIRISS SOSS wavelength solution model. V23ToSky(angles, axes_order[, name]) Transform from V2V3 to a standard coordinate system (ICRS). Slit(name, shutter_id, dither_position, …) Nirspec Slit structure definition NIRCAMForwardRowGrismDispersion(orders[, …]) Return the transform from grism to image for the given spectral order. NIRCAMForwardColumnGrismDispersion(orders[, …]) Return the transform from grism to image for the given spectral order. NIRCAMBackwardGrismDispersion(orders[, …]) Return the valid pixel(s) and wavelengths given center x,y and lam MIRI_AB2Slice([beta_zero, beta_del, channel]) MIRI MRS alpha, beta to slice transform GrismObject([sid, order_bounding, …]) Grism Objects identified from a direct image catalog and segment map. NIRISSForwardRowGrismDispersion(orders[, …]) This model calculates the wavelengths of vertically dispersed NIRISS grism data. NIRISSForwardColumnGrismDispersion(orders[, …]) This model calculates the wavelengths for horizontally dispersed NIRISS grism data. NIRISSBackwardGrismDispersion(orders[, …]) This model calculates the dispersion extent of NIRISS pixels. V2V3ToIdeal(v3idlyangle, v2ref, v3ref, vparity) Performs the transform from telescope V2,V3 to Ideal coordinate system. IdealToV2V3(v3idlyangle, v2ref, v3ref, vparity) Performs the transform from Ideal to telescope V2,V3 coordinate system.