compute_deblended_segmap¶
-
muse_origin.
compute_deblended_segmap
(image, npixels=5, snr=3, dilate_size=11, maxiters=5, sigma=3, fwhm=3.0, kernelsize=5)[source]¶ Compute segmentation map using photutils.
The segmentation map is computed with the following steps:
Creation of a mask of sources with the
snr
threshold, usingphotutils.make_source_mask
.Estimation of the background statistics with this mask (
astropy.stats.sigma_clipped_stats
), to estimate a refined threshold withmedian + sigma * rms
.Convolution with a Gaussian kernel.
Creation of the segmentation image, using
photutils.detect_sources
.Deblending of the segmentation image, using
photutils.deblend_sources
.
- Parameters
- image
mpdaf.obj.Image
The input image.
- npixels
int
The number of connected pixels that an object must have to be detected.
- snr, dilate_size :
See
photutils.make_source_mask
.- maxiters, sigma :
- fwhm
float
Kernel size (pixels) for the PSF convolution.
- kernelsize
int
Size of the convolution kernel.
- image
- Returns
Image
The deblended segmentation map.