In this step the median image now gets blotted back to create median-cleaned images which can be compared directly with each input image to identify cosmic-rays.
Authors: | |
---|---|
Warren Hack | |
License: | |
http://www.stsci.edu/resources/software_hardware/pyraf/LICENSE |
The median image is the combination of the WCS aligned input images that have already had the distortion model applied. Taking the median of the aligned images allows for a statistical rejection of bad pixels from the image stack. The resulting median image can then be input for the blot task with the goal of creating ‘cleaned’ versions of the input images at each of their respective dither locations. These “blotted” images can then be directly compared to the original distorted input images for detection of image artifacts (i.e. bad-pixels, hot pixels, and cosmic-rays) whose locations will be saved to the output badpixel masks.
Aside from the input parameters, this step only requires opening the single median image created from all the input images. A distorted version of the median image corresponding to each input ‘chip’ (extension) is written as output from this step as separate simple FITS images.
For more information on the science applications of the blot task, see the DrizzlePac Handbook
Parameters: | |
---|---|
data : str
reference : str
outdata : str
coeffs : bool (Default Value = True)
interp : str{‘nearest’, ‘linear’, ‘poly3’, ‘poly5’, ‘sinc’} (Default = ‘poly5’)
sinscl : float (Default Value = 1.0)
stepsize : int (Default Value = 10)
addsky : bool (Default Value = Yes)
skyval : float (Default Value = 0.0)
in_units : str{‘cps’, ‘counts’} (Default Value= ‘cps’)
out_units : str{‘cps’, ‘counts’} (Default Value = ‘counts’)
expkey : str (Default Value = ‘exptime)
expout : str or float (Default Value = ‘input’)
outscale : float,optional
orient : float
raref : float
decref : float
xrefpix : float
yrefpix : float
outnx : float
outny : float
|
Notes
These tasks are designed to work together seemlessly when run in the full AstroDrizzle interface. More advanced users may wish to create specialized scripts for their own datasets, making use of only a subset of the predefined AstroDrizzle tasks, or add additional processing, which may be usefull for their particular data. In these cases, individual access to the tasks is important.
Something to keep in mind is that the full AstroDrizzle interface will make backup copies of your original files and place them in the OrIg/ directory of your current working directory. If you are working with the stand alone interfaces, it is assumed that the user has already taken care of backing up their original datafiles as the input file with be directly altered.
Examples
1. Basic example of how to call blot yourself from a python command line, using the default parameter settings:
>>> from drizzlepac import ablot
>>> ablot.blot()
2. Creation of a blotted image from the products generated by running the astrodrizzle task can be done for the median image “adriz_aligned_wcs_f814w_med.fits” to re-create the (SCI,1) chip from “j8c0d1bwq_flc.fits” using:
>>> from drizzlepac import ablot
>>> from stsci.tools import teal
>>> blotobj = teal.load('ablot') # get default values
>>> ablot.blot('adriz_aligned_wcs_f814w_med.fits','j8c0d1bwq_flc.fits[sci,1]',
'aligned_f814w_sci1_blot.fits',configObj=blotobj)
or
>>> a = teal.teal('ablot')
# set data = adriz_aligned_wcs_f814w_med.fits
# set reference = j8c0d1bwq_flc.fits[sci,1]
# set outdata = aligned_f814w_sci1_blot.fits
Core functionality of performing the ‘blot’ operation to create a single blotted image from a single source image. All distortion information is assumed to be included in the WCS specification of the ‘output’ blotted image given in ‘blot_wcs’.
This is the simplest interface that can be called for stand-alone use of the blotting function.
Parameters: | |
---|---|
source
source_wcs
blot_wcs
exptime
coeffs
interp
sinscl
stepsize
wcsmap
|
return useful help from a file in the script directory called __taskname__.help
Print out syntax help for running astrodrizzle
Parameters: | |
---|---|
file : str (Default = None)
|
Run the blot task based on parameters provided interactively by the user.
Perform the blot operation on the list of images.