mOverlaps
- Description:
- Analyze an image metadata table to determine a list of overlapping images. Each image is compared with every other image to determine all overlapping image pairs. A pair of images are deemed to overlap if any pixel around the perimeter of one image falls within the boundary of the other image.
- Syntax:
- mOverlaps [-e] [-d level] [-s statusfile] images.tbl diffs.tbl
Switches:
- -e
- Enables 'exact' overlaps mode, as opposed to the default approximate algorithm. The default mode uses great-circle connecting lines between image corners to determine which images overlap. Exact mode will instead check the edge pixels of every image to determine which pixels are inside the others.
Although the default mode will occasionally report some incorrect overlaps, this is not a concern since mDiff will detect and ignore these false positive results when processing the table. - -d level
- Turns on debugging to the specified level (1 or 2)
- -s statusfile
- Output and errors are sent to statusfile instead of to stdout
Arguments:
- images.tbl
- Table of image metadata generated by mImgtbl.
- diffs.tbl
- Path of output table to be generated containing overlap information.
- Results:
- Output table contains overlap information for each pair of overlapping images. The first two columns are integer identifiers for the images from images.tbl; the second two give their filenames, and the final column shows the filename of the FITS file that will be generated using mDiffExec.
Examples:
The following example looks at a list of 16 images, described in images.tbl, and calculates which images overlap:
- $ mOverlaps images.tbl diffs.tbl
- [struct stat="OK", count=42]
Output file: diffs.tbl.
Return Codes:
- [struct stat="OK", countnum-overlaps]
- [struct stat="ERROR", msg="Usage: mOverlaps [-e] [-d level] [-s statusfile] images.tbl diffs.tbl"]
- [struct stat="ERROR", msg="Cannot open status file: statusfile"]
- [struct stat="ERROR", msg="Failed to open output filename"]
- [struct stat="ERROR", msg="Invalid image metadata file: filename"]
- [struct stat="ERROR", msg="Not enough information to determine coverages (CDELTs or CD matrix)"]
- [struct stat="ERROR", msg="Need columns: cntr ctype1 ctype2 nl ns crval1 crval2 crpix1 crpix2 cdelt1 cdelt2 crota2 fname (equinox optional)"] (columns missing from image metadata table)
- [struct stat="ERROR", msg="Bad WCS for image n"]