profoundChisel: Noise Chisel Esque Sky

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/profoundSky.R

Description

This is an implementation of a Noise Chisel like approach method of identifying sky pixels. It is conceptually similar on some regards, but does not attempt to produce the same solutions (i.e. it is more like "inspired by").

Usage

1
2
3
profoundChisel(image = NULL, sky = NULL, skythresh = 0.005, blurcut = 0.01,
objthresh = 1 - skythresh, sigma = 2, iterchisel = 5, itersky = 5,
objbias = 0.5, box = 100, skyconv = 0.01)

Arguments

image

Numeric matrix; required, the image we want to analyse. Note, image NAs are treated as masked pixels.

sky

User provided estimate of the absolute sky level. Can be a scalar or a matrix matching the dimensions of image (allows values to vary per pixel). This will be subtracted off the image internally, so only provide this if the sky does need to be subtracted!

skythresh

Numeric scalar; the quantile level to use to identify sink pixels for the sky (so should be between 0 and 1).

blurcut

Numeric scalar; PDF level to cut the blurring kernel at when dilating. Lower values mean larger dilations.

objthresh

Numeric scalar; the quantile level to use to identify source pixels for real objects (so should be between 0 and 1).

sigma

Numeric scalar; standard deviation of the blur used. This should be well matched to the PSF of the image in most cases.

iterchisel

Integer scalar; how many iterations of the inner chisel routine to run for.

itersky

Integer scalar; how many iterations of the outer sky estimation routine to run for.

objbias

Numeric scalar; how much to bias the dilations towards assuming pixels belong to objects (larger values mean more object pixels will in general be created).

box

Integer scalar; the dimensions of the box car filter to estimate the sky with.

skyconv

Numeric scalar; when <= skyconv fraction of pixels change sky/object designation, the solution is considered converged and itersky iterations stop.

Details

This is an implementation of a Noise Chisel like approach method of identifying sky pixels. It is conceptually similar on some regards, but does not attempt to produce the same solutions (i.e. it is more like "inspired by").

Value

A list with two parts:

objects

Logical matrix; the object map matched pixel by pixel to image. 1 means there is an object at this pixel, 0 means it is a sky pixel. Can be used as a mask in various other functions that require objects to be masked out.

sky

The estimated sky level of the image.

Author(s)

Aaron Robotham

References

Akhlaghi et al, 2015, ApJSS, 220, 1

See Also

profoundMakeSkyGrid

Examples

1
2
3
image=readFITS(system.file("extdata", 'VIKING/mystery_VIKING_Z.fits',
package="ProFound"))$imDat
magimage(profoundChisel(image)$objects)

ProFound documentation built on Jan. 8, 2021, 5:37 p.m.