Test Utilities#

lsst.images.tests Package#

Functions#

arrays_to_legacy_points(x, y)

Convert arrays of x and y to a list of lsst.geom.Point2D.

assert_cell_coadds_equal(a, b, *[, expect_view])

Assert that two CellCoadd instances carry the same persistent state.

assert_close(a, b, **kwargs)

Test that two arrays, floats, or quantities are almost equal.

assert_equal_allow_nan(a, b)

Test that two floating point values are equal, with nan == nan.

assert_images_equal(a, b, *[, rtol, atol, ...])

Assert that two images are equal or nearly equal.

assert_masked_images_equal(a, b, *[, rtol, ...])

Assert that two masked images are equal or nearly equal.

assert_masks_equal(a, b)

Assert that two masks are equal or nearly equal.

assert_psfs_equal(psf1, psf2[, points])

Compare two PSF objets.

assert_sky_projections_equal(a, b[, ...])

Test that two SkyProjection instances are equivalent.

assert_visit_images_equal(a, b, *[, expect_view])

Assert that two VisitImage instances carry the same persistent state.

check_archive_tree_class_invariants(tree_type)

Assert that one concrete serialization.ArchiveTree subclass declares well-formed schema-version constants and an in-memory type.

check_astropy_wcs_interface(wcs, pixel_xy, ...)

Test an Astropy WCS instance against known arrays of pixel and sky coordinates.

check_bounds_contains_broadcasting(bounds)

Verify that contains accepts array-like inputs.

check_projection(sky_projection, pixel_xy, ...)

Test a SkyProjection instance against known arrays of pixel and sky coordinates.

check_transform(transform, input_xy, ...[, ...])

Test Transform against known arrays of input and output points.

compare_amplifier_to_legacy(amplifier, ...)

Compare an Amplifier to a legacy lsst.afw.cameraGeom.Amplifier.

compare_aperture_corrections_to_legacy(...)

Test an aperture correction dict by comparing it to an equivalent lsst.afw.image.ApCorrMap.

compare_cell_coadd_to_legacy(cell_coadd, ...)

Compare a cells.CellCoadd object to a legacy lsst.cell_coadds.MultipleCellCoadd object.

compare_detector_to_legacy(detector, ...[, ...])

Compare a Detector to a lsst.afw.cameraGeom.Detector.

compare_field_to_legacy(field, legacy_field, ...)

Test a Field object by comparing it to an equivalent lsst.afw.math.BoundedField.

compare_image_to_legacy(image, legacy_image)

Compare an Image object to a legacy lsst.afw.image.Image object.

compare_mask_to_legacy(mask, legacy_mask[, ...])

Compare a Mask object to a legacy lsst.afw.image.Mask object.

compare_masked_image_to_legacy(masked_image, ...)

Compare a MaskedImage object to a legacy lsst.afw.image.MaskedImage object.

compare_observation_summary_stats_to_legacy(...)

Test an ObservationSummaryStats object by comparing it to an equivalent lsst.afw.image.ExposureSummaryStats.

compare_photo_calib_to_legacy(...[, ...])

compare_psf_to_legacy(psf, legacy_psf[, ...])

Compare a PSF model object to its legacy interface.

compare_sky_projection_to_legacy_wcs(...[, ...])

Test a Projection object by comparing it to an equivalent lsst.afw.geom.SkyWcs.

compare_visit_image_to_legacy(visit_image, ...)

Compare a VisitImage object to a legacy lsst.afw.image.Exposure object.

iter_concrete_archive_tree_subclasses()

Yield every importable concrete serialization.ArchiveTree subclass.

legacy_coords_to_astropy(legacy_coords)

Convert a list of lsst.geom.SpherePoint objects to an Astropy coordinate object.

legacy_points_to_xy_array(legacy_points)

Convert a list of lsst.geom.Point2D objects to an XY array.

make_random_sky_projection(rng, pixel_frame, ...)

Create a test sky_projection with random parameters.

Classes#

RoundtripFits(original[, storage_class, recipe])

RoundtripJson(original[, storage_class, recipe])

RoundtripNdf(original[, storage_class, recipe])

TemporaryButler([run, format, recipe])

Make a temporary butler repository.