uvotwcs

Major functions

makewcshdr()

uvotpy.uvotwcs.makewcshdr(filestub, ext, attfile, indir='./', teldef=None, wheelpos=None, continue_when_graspcorr_fails=True, catspec=None, uvotgraspcorr_on=True, update_pnt=True, chatter=1)

make the header of a lenticular filter for a grism image to use in uvotapplywcs writes a file with a bogus image returns the name of the file

Parameters:

filestub : str

identifying part of filename being “sw”+`obsid`

ext : int

extension of fits file to process

attfile : str

attitude file name. Needs to be set when update_pnt set.

indir : str

path, directory of data files

teldef : str

filename teldef file for epoch of anchor calibration

wheelpos : int, {160,200,955,1000}

filterwheel position for grism

continue_when_graspcorr_fails : float

this would supply a solution - though quite bad

uvotgraspcorr_on: bool

if not set, then the original pointing is used after optional update when update_pnt was set

update_pnt : bool

allows updating the header RA_PNT,DEC_PNT,PA_PNT keywords using the atttitude file (which is required)

catspec : path

path to catalog spec file other than default

chatter : int

verbosity

Returns:

creates a fake sky file with appropriate header to run findInputAngle

Notes

need to update the tstart and tstop of the primary header (not a showstopper)

Other functions

uvotpy.uvotwcs.correct_image_distortion(x, y, header)

This routine applies to the (x,y) position on the image the grism distortion correction input header must be from the grism image (position) to be corrected

uvotpy.uvotwcs.get_pointing_from_attfile(tstart, tstop, attfile)
uvotpy.uvotwcs.get_distortion_keywords(wheelpos)

provide the grism header with distortion keywords