diff options
| author | dencheva <dencheva@stsci.edu> | 2014-04-28 15:44:02 -0400 |
|---|---|---|
| committer | dencheva <dencheva@stsci.edu> | 2014-04-28 15:44:02 -0400 |
| commit | a4081a38404b8759a185638fb49687c196153464 (patch) | |
| tree | 8313dd70d6493dae50854a1ffb19b68c7b3d8520 /lib/stwcs/gui/archive_headerlet.py | |
| parent | d7256629cc01af99cb5e3be70a64000f6d2fb0dc (diff) | |
| download | stwcs_hcf-a4081a38404b8759a185638fb49687c196153464.tar.gz | |
changes to use astropy instead of pyfits and pywcs
git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/stwcs/trunk@31240 fe389314-cf27-0410-b35b-8c050e845b92
Diffstat (limited to 'lib/stwcs/gui/archive_headerlet.py')
| -rw-r--r-- | lib/stwcs/gui/archive_headerlet.py | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/lib/stwcs/gui/archive_headerlet.py b/lib/stwcs/gui/archive_headerlet.py index 735baa4..65e133a 100644 --- a/lib/stwcs/gui/archive_headerlet.py +++ b/lib/stwcs/gui/archive_headerlet.py @@ -1,7 +1,8 @@ import os -import string +import string -import pyfits +#import pyfits +from astropy.io import fits as pyfits from stsci.tools import teal import stwcs @@ -41,7 +42,7 @@ def run(configObj=None): print ' Please restart this task and provide a value for this parameter.' print '='*60 return - + str_kw = ['wcsname','destim','sipname','npolfile','d2imfile', 'descrip','history','author'] @@ -53,16 +54,16 @@ def run(configObj=None): del cdict['_task_name_'] del cdict['filename'] del cdict['hdrname'] - + # Convert blank string input as None for kw in str_kw: if cdict[kw] == '': cdict[kw] = None if cdict['wcskey'].lower() == 'primary': cdict['wcskey'] = ' ' # Call function with properly interpreted input parameters - # Syntax: archive_as_headerlet(filename, sciext='SCI', wcsname=None, wcskey=None, + # Syntax: archive_as_headerlet(filename, sciext='SCI', wcsname=None, wcskey=None, # hdrname=None, destim=None, - # sipname=None, npolfile=None, d2imfile=None, + # sipname=None, npolfile=None, d2imfile=None, # author=None, descrip=None, history=None, # hdrlet=None, clobber=False) headerlet.archive_as_headerlet(configObj['filename'], configObj['hdrname'], |
