diff options
author | dencheva <dencheva@stsci.edu> | 2009-03-26 11:26:59 -0400 |
---|---|---|
committer | dencheva <dencheva@stsci.edu> | 2009-03-26 11:26:59 -0400 |
commit | faf6b5f51af44a794f743a2e2b5de3f176023185 (patch) | |
tree | 87cb7e4db10e17062a5af526c2896e950550a54a /hstwcs/__init__.py | |
parent | 39238c106e18b47b5f6f9be3352a01743342f59a (diff) | |
download | stwcs_hcf-faf6b5f51af44a794f743a2e2b5de3f176023185.tar.gz |
Changed imports of numpy (as np).
Added d2imcorr parameter to top level updatewcs function.
git-svn-id: http://svn.stsci.edu/svn/ssb/stsci_python/development/trunk/updatewcs@7803 fe389314-cf27-0410-b35b-8c050e845b92
Diffstat (limited to 'hstwcs/__init__.py')
-rw-r--r-- | hstwcs/__init__.py | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/hstwcs/__init__.py b/hstwcs/__init__.py index a843888..7de38fe 100644 --- a/hstwcs/__init__.py +++ b/hstwcs/__init__.py @@ -7,7 +7,6 @@ from updatewcs.wcsutil import HSTWCS from updatewcs import utils import corrections, makewcs import dgeo, det2im -import time from pytools import parseinput, fileutil import apply_corrections @@ -17,7 +16,7 @@ __docformat__ = 'restructuredtext' __version__ = '0.3' -def updatewcs(input, vacorr=True, tddcorr=True, dgeocorr=True, checkfiles=True): +def updatewcs(input, vacorr=True, tddcorr=True, dgeocorr=True, checkfiles=True, d2imcorr=True): """ Purpose ======= @@ -33,7 +32,6 @@ def updatewcs(input, vacorr=True, tddcorr=True, dgeocorr=True, checkfiles=True): `pytools` `pyfits` `pywcs` - `numpy` :Parameters: `input`: a python list of file names or a string (wild card characters allowed) @@ -47,15 +45,16 @@ def updatewcs(input, vacorr=True, tddcorr=True, dgeocorr=True, checkfiles=True): geis and waiver fits files will be converted to MEF format. Default value is True for standalone mode. """ - files = parseinput.parseinput(input)[0] if checkfiles: files = checkFiles(files) if not files: print 'No valid input, quitting ...\n' - return + return for f in files: - acorr = apply_corrections.setCorrections(f, vacorr=vacorr, tddcorr=tddcorr,dgeocorr=dgeocorr) + acorr = apply_corrections.setCorrections(f, vacorr=vacorr, \ + tddcorr=tddcorr,dgeocorr=dgeocorr, d2imcorr=d2imcorr) + #restore the original WCS keywords utils.restoreWCS(f) makecorr(f, acorr) |