This describes the columns and flags in the CMF/SMF files, version PS1_V3. They are listed in source:trunk/psModules/src/objects/pmSourceIO_CMF_PS1_V3.c, this is a slightly more descriptive version.

Columns

  • IPP_IDET - detection id (increment from 0 per chip - gaps are from magic)
  • X_PSF -position (in pixels
  • Y_PSF -position in pixels
  • X_PSF_SIGMA -position sigma
  • Y_PSF_SIGMA -position sigma
  • POSANGLE - position angle of the instrument coordinate system at source (ie, the angle between north and the y-axis) in degrees
  • PLTSCALE - plate-scale at the source position (it varies across the exposure!) in arcsec
  • PSF_INST_MAG - PSF Instrumental mag
  • PSF_INST_MAG_SIG - error for that
  • PSF_INST_FLUX
  • PSF_INST_FLUX_SIG
  • AP_MAG - aperture mag
  • AP_MAG_RAW
  • AP_MAG_RADIUS - aperture mag radius (pixels)
  • CAL_PSF_MAG - calibrated PSF MAG
  • CAL_PS_MAG_SIG - error
  • RA_PSF - ra
  • DEC_PSF - dec
  • PEAK_FLUX_AS_MAG - as it says, it is the flux (counts/pixel) for the peak pixel expressed as an instrumental magnitude (-2.5*log(flux))
  • SKY - background in counts (DN, not electrons)
  • SKY_SIGMA -error
  • PSF_CHISQ - chisq of psf
  • CR_NSIGMA - cosmic ray
  • EXT_NSIGMA - extended source
  • PSF_MAJOR - major axis (pixel)
  • PSF_MINOR - minor axis (pixel)
  • PSF_THETA - angle
  • PSF_QF - the psf-weighted fraction of unmasked pixels:
    • \Sum_i (psf_i * !masked) / \Sum_i (psf_i)
  • PSF_QF_PERFECT - the psf-weighted fraction of unmasked pixels (including suspect pixels):
    • \Sum_i (psf_i * !masked) / \Sum_i (psf_i)
  • PSF_NDOF - number of degrees of freedom for the fit -- for the diff detections, the only free parameter is the flux, so N_DOF = N_PIX - 1; in other cases, there may be more parameters (eg, position, size, etc).
  • PSF_NPIX - number of pixels for fit
  • MOMENTS_XX - second moment in x:
    • \Sum ((x_i - x_o)^2 f_i) / \Sum (f_i) where x_o is the centroid \Sum (x_i f_i) / \Sum f_i
  • MOMENTS_XY - second moment in xy:
    • \Sum ((x_i - x_o)(y_i - y_o)^2 f_i) / \Sum (f_i)
  • MOMENTS_YY - second moment in xy
    • \Sum ((y_i - y_o)^2 f_i) / \Sum (f_i)
  • MOMENTS_M3C - third moment cos theta:
    • \Sum r^3 cos(3t) = \Sum r^3 (cos^3 t - r^2 3 cos t sin^2 t) = \Sum(x^3 - 3 x y^2) divided by \Sum (f_i) where r is radius from the centroid
  • MOMENTS_M3S - third moment sin theta:
    • \Sum r^3 sin(3t) = \Sum r^3 (3 cos^2 t sin t - sin^3 t = (3 x^2 y - y^3) divided by \Sum (f_i) where r is radius from the centroid
  • MOMENTS_M4C - fourth moment cos theta:
    • \Sum r^4 cos(4t) = \Sum r^4 (cos^4 t - r^2 6 cos^2 t sin^2 t + r^2 sin^4 t) = (x^4 - 6 x^2 y^2 + y^4) divided by \Sum (f_i) where r is radius from the centroid
  • MOMENTS_M4S - fourth moment sin theta:
    • \Sum r^4 sin(4t) = \Sum r^4 (4 cos^3 t sin t - 4 sin^3 t cos t) = (4 x^3 y - 4 y^3 x) divided by \Sum (f_i) where r is radius from the centroid
  • MOMENTS_R1 - first radial moment (used to define the Kron radius = 2.5 R1)
    • \Sum r f_i) / \Sum (f_i) where r is radius from the centroid
  • MOMENTS_RH - half radial moment (an indicator of concentration)
    • \Sum sqrt(r) f_i) / \Sum (f_i) where r is radius from the centroid
  • KRON_FLUX - flux within Kron Radius (2.5 * first radial moment)
  • KRON_FLUX_ERR - error on the above
  • KRON_FLUX_INNER - flux within annulus (1.0 R1 < R < 2.5 R1)
  • KRON_FLUX_OUTER - flux within annulus (2.5 R1 < R < 4.0 R1)
  • FLAGS - see below
  • FLAGS2 - see below
  • N_FRAMES - this is not currently set, but it is supposed to have the value of the number of input images overlapping the center of the source (for warp-warp diff, it would be 2, for a single image it would be 1, for a stack it may be something else).
  • PADDING - a dummy block of data needed to fit the rows into 8-byte boundaries (this lets me read into structures as a bulk byte read operation).

FLAGS

(see also [wiki:IPP_Detection_Bitmasks)

Values defined in psModules/src/objects/pmSourceMasks.h

DEFAULT 0x0000.0000 Initial value: resets all bits
PSFMODEL 0x0000.0001 Source fitted with a psf model (linear or non-linear)
EXTMODEL 0x0000.0002 Source fitted with an extended-source model
FITTED 0x0000.0004 Source fitted with non-linear model (PSF or EXT; good or bad)
FITFAIL 0x0000.0008 Fit (non-linear) failed (non-converge, off-edge, run to zero)
POORFIT 0x0000.0010 Fit succeeds, but low-SN, high-Chisq, or large (for PSF -- drop?)
PAIR 0x0000.0020 Source fitted with a double psf
PSFSTAR 0x0000.0040 Source used to define PSF model
SATSTAR 0x0000.0080 Source model peak is above saturation
BLEND 0x0000.0100 Source is a blend with other sourcers
EXTERNALPOS 0x0000.0200 Source based on supplied input position
BADPSF 0x0000.0400 Failed to get good estimate of object's PSF
DEFECT 0x0000.0800 Source is thought to be a defect
SATURATED 0x0000.1000 Source is thought to be saturated pixels (bleed trail)
CR_LIMIT 0x0000.2000 Source has crNsigma above limit
EXT_LIMIT 0x0000.4000 Source has extNsigma above limit
MOMENTS_FAILURE 0x0000.8000 could not measure the moments
SKY_FAILURE 0x0001.0000 could not measure the local sky
SKYVAR_FAILURE 0x0002.0000 could not measure the local sky variance
MOMENTS_SN 0x0004.0000 moments not measured due to low S/N
0x0008.0000 this bit is not defined
BIG_RADIUS 0x0010.0000 poor moments for small radius, try large radius
AP_MAGS 0x0020.0000 source has an aperture magnitude
BLEND_FIT 0x0040.0000 source was fitted as a blend
EXTENDED_FIT 0x0080.0000 full extended fit was used
EXTENDED_STATS 0x0100.0000 extended aperture stats calculated
LINEAR_FIT 0x0200.0000 source fitted with the linear fit
NONLINEAR_FIT 0x0400.0000 source fitted with the non-linear fit
RADIAL_FLUX 0x0800.0000 radial flux measurements calculated
SIZE_SKIPPED 0x1000.0000 Warning:: if set, size could be determined
ON_SPIKE 0x2000.0000 peak lands on diffraction spike
ON_GHOST 0x4000.0000 peak lands on ghost or glint
OFF_CHIP 0x8000.0000 peak lands off edge of chip

FLAGS2

DIFF_WITH_SINGLE 0x0000.0001 diff source matched to a single positive detection
DIFF_WITH_DOUBLE 0x0000.0002 diff source matched to positive detections in both images
MATCHED 0x0000.0004 source was supplied at this location from somewhere else (eg, another image, forced photometry location, etc)
ON_SPIKE 0x0000.0008 > 25% of (PSF-weighted) pixels land on diffraction spike
ON_STARCORE 0x0000.0010 > 25% of (PSF-weighted) pixels land on star core
ON_BURNTOOL 0x0000.0020 > 25% of (PSF-weighted) pixels land on burntool subtraction region
ON_CONVPOOR 0x0000.0040 > 25% of (PSF-weighted) pixels land on region where convolution had substantial masked fraction contribution
PASS1_SRC 0x0000.0080 source was detected in the first pass of psphot (bright detection stage)
HAS_BRIGHTER_NEIGHBOR 0x0000.0100 peak is not the brightest in its footprint
BRIGHT_NEIGHBOR_1 0x0000.0200 flux_n / (r2 flux_p) > 1
BRIGHT_NEIGHBOR_10 0x0000.0400 flux_n / (r2 flux_p) > 10
DIFF_SELF_MATCH 0x0000.0800 positive detection match is probably this source
SATSTAR_PROFILE 0x0000.1000 saturated source is modeled with a radial profile