summaryrefslogtreecommitdiff
path: root/hstwcs/dgeo.py
diff options
context:
space:
mode:
authordencheva <dencheva@stsci.edu>2009-03-26 11:26:59 -0400
committerdencheva <dencheva@stsci.edu>2009-03-26 11:26:59 -0400
commitfaf6b5f51af44a794f743a2e2b5de3f176023185 (patch)
tree87cb7e4db10e17062a5af526c2896e950550a54a /hstwcs/dgeo.py
parent39238c106e18b47b5f6f9be3352a01743342f59a (diff)
downloadstwcs_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/dgeo.py')
-rw-r--r--hstwcs/dgeo.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/hstwcs/dgeo.py b/hstwcs/dgeo.py
index d6313d7..00178d9 100644
--- a/hstwcs/dgeo.py
+++ b/hstwcs/dgeo.py
@@ -1,7 +1,6 @@
import pyfits
from pytools import fileutil
-#from hstwcs.mappings import dgeo_vals
-import numpy
+import numpy as np
class DGEOCorr(object):
"""
@@ -148,8 +147,8 @@ class DGEOCorr(object):
"""
coeffs = cls.getCoeffs(header)
idcscale = header['IDCSCALE']
- sclcoeffs = numpy.linalg.inv(coeffs/idcscale)
- ndx, ndy = numpy.dot(sclcoeffs, [dx.ravel(), dy.ravel()])
+ sclcoeffs = np.linalg.inv(coeffs/idcscale)
+ ndx, ndy = np.dot(sclcoeffs, [dx.ravel(), dy.ravel()])
ndx.shape = dx.shape
ndy.shape=dy.shape
return ndx, ndy
@@ -168,7 +167,7 @@ class DGEOCorr(object):
print 'First order IDCTAB coefficients are not available.\n'
print 'Cannot convert SIP to IDC coefficients.\n'
return None
- return numpy.array([[ocx11, ocx10], [ocy11,ocy10]], dtype=numpy.float32)
+ return np.array([[ocx11, ocx10], [ocy11,ocy10]], dtype=np.float32)
getCoeffs = classmethod(getCoeffs)