Source code for casatools.linearmosaic

#
# stub class definition file for docstring parsing
#

[docs]class linearmosaic: """ combining images in a weighted fashion The ``linearmosaic`` tool (``lm``) provides a toolkit for stitching images in a weighted fashion. The default linear mosaic equation is defined by Equation (6) in Cornwell, Holdaway et al (Astronomy and Astrophysics, Vol. 271, p. 697 (1993)). .. math:: I^{lm}(\theta)={{\sum\_p A\_p(\theta)(I\_p(\theta)A\_p(\theta))w\_p}\over{\sum\_p A\_p^2(\theta)w\_p}} where :math:`A\_p(\theta)` is the primary beam (PB) of a given pointing :math:`p`, :math:`w\_p` is a sensitivity weight and the image of that pointing is :math:`I\_p(\theta)`; the linear mosaic being :math:`I^{lm}(\theta)` """
[docs] def linearmosaic(self): """ Construct a linearmosaic tool Create a {\tt linearmosaic} tool. """ pass
[docs] def defineoutputimage(self, nx=128, ny=-1, cellx='1.0', celly='', imagecenter='0', outputimage='', outputweight=''): """ Set the output direction image parameters and name Define the direction axes output image parameters. The output image will get the same number of spectral and polarization planes as the input images. This function create a fresh new output image. If an image of the same name exist on disk it will be erased. The spectral and polarization part of the image will be identical to the images that are being mosaiced. The output image will by default be flux correct and the weight image will be ${\sum_p A_p^2(\theta)}$ where the primary beam is $ A_p(\theta)$ .. rubric:: Parameters - ``nx (int=128)`` - Total number of spatial pixels in x - ``ny (int=-1)`` - Total number of spatial pixels in y - ``cellx (variant='1.0')`` - Cellsize in x (e.g. '1arcsec') - ``celly (variant='')`` - Cellsize in y (e.g. '1arcsec') - ``imagecenter (variant='0')`` - Direction of phase center as a diretion measure - ``outputimage (string='')`` - output image name - ``outputweight (string='')`` - output weight image name """ pass
[docs] def setoutputimage(self, outputimage='', outputweight='', imageweighttype=1, weighttype=1): """ Use this function to mosaic on an existing image and weight image Use this function if the mosaicing is to be done onto a previous mosaic or image. For now the stokes and spectral characteristic of the images to be mosaic and the output image has to be similar (i.e the user has to regrid them prior to linearmosaic if necessary). The weightimage represents the sensitivity image of the image (for example the weighted primary beam coverage of a mosaic) {\tt imageweighttype} parameter: If the image is of the type that has been normalized to be flux correct then the imageweighttype should 0. If the image has been apodized by a primary beam then imageweighttype should be 1 and if the image is multiplied by $PB^2$ then it should be 2. {\tt weighttype} parameter: This should be 1 if the weight image is the sum of Primary beams or equivalent and it should be 2 if it is the sum of of $PB^2$ .. rubric:: Parameters - ``outputimage (string='')`` - Existing mosaic imagename - ``outputweight (string='')`` - Existing weight image for mosaic - ``imageweighttype (int=1)`` - what kind of weight was already applied to image \n 0: flux correct \n 1: Primary beam equivalent weight \n 2: $PB^2$ equivalent weight \n - ``weighttype (int=1)`` - what kind of weight is weight image \n 1: Primary beam equivalent weight \n 2: $PB^2$ equivalent \n """ pass
[docs] def saultweightimage(self, outputimage='', fracpeak=0.1): """ Use this function to create a Sault-weighted image "Sault weighted" image is one which is more pleasant to view (without high noise at the edges of mosaic images), it is flux correct upto a where the beam coverage becomes low and is tapered off onwards just to keep the noise from rising in the overall image(see Eq[2] from Sault, Staveley-Smith and Brouw (1996), Astron. Astrophys. Suppl, 120, 375) .. rubric:: Parameters - ``outputimage (string='')`` - Name of image to create the Sault-Weighted image - ``fracpeak (double=0.1)`` - Upto what fraction of peak of coverage should the image be flux correct """ pass
[docs] def setlinmostype(self, linmostype='optimal'): """ Use this function to set if you want to mosaic in flatnoise domain Use this function if the mosaicing is to be done using a non optimal weighting mode. For now {\tt optimal} (which is the default) follows this equation \begin{equation} I^{lm}(\theta)={{\sum_p A_p(\theta)(I_p(\theta)A_p(\theta))w_p}\over{\sum_p A_p^2(\theta)w_p}} \end{equation} And {\tt pbweight} follows this one \begin{equation} I^{lm}(\theta)={{\sum_p (I_p(\theta)A_p(\theta))w_p}\over{\sum_p A_p(\theta)w_p}} \end{equation} where $A_p(\theta)$ is the primary beam (PB) of a given pointing $p$, $w_p$ is a sensitivity weight and the image of that pointing is $I_p(\theta)$; the linear mosaic being $I^{lm}(\theta)$ For now $w_p=1$ .. rubric:: Parameters - ``linmostype (string='optimal')`` - Type of weighting for linear mosaic """ pass
[docs] def makemosaic(self, images='', weightimages='', imageweighttype=1, weighttype=1): """ mosaic images in a weighted fashion onto ouput image Put the list of images onto the mosaic image using the weight images .. rubric:: Parameters - ``images (variant='')`` - Name of images to mosaic - ``weightimages (variant='')`` - Name of images to mosaic - ``imageweighttype (int=1)`` - what kind of weight is already applied to image \n 0: flux correct \n 1: Primary beam equivalent weight \n 2: PB^2 equivalent \n - ``weighttype (int=1)`` - what kind of weight image it is \n 1: Primary beam equivalent weight \n 2: PB^2 equivalent \n """ pass