Skip to content

Commit

Permalink
checking tests with wobble
Browse files Browse the repository at this point in the history
  • Loading branch information
zonca committed May 24, 2011
1 parent 087390c commit 8cb49ba
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions planck/LFI.py
Expand Up @@ -3,6 +3,7 @@
# Generic python class for dealing with Planck LFI
# by zonca@deepspace.ucsb.edu

import logging as l
import numpy as np
import Planck
import private
Expand Down Expand Up @@ -81,6 +82,7 @@ def instrument_db(self,ch):
if not hasattr(self,'_instrument_db') or self._instrument_db is None:
import pyfits
self._instrument_db = np.array(pyfits.open(private.instrument_db,ignore_missing_end=True)[1].data)
l.warning('Loading instrumentdb %s' % private.instrument_db)
det_index, = np.where([rad.strip().endswith(ch.tag) for rad in self._instrument_db['Radiometer']])
return self._instrument_db[det_index]

Expand Down
4 changes: 2 additions & 2 deletions planck/test_pointing.py
Expand Up @@ -60,7 +60,7 @@ def test_pointing_vs_dpc(self):
i_te = 697
te = {'sampleOBT':self.chlfi.f.obtx[i_te:],'name':'te'}
#pnt = Pointing(self.chlfi.f.obtx[697:698],coord='E')
pnt = Pointing(te['sampleOBT'],coord='E')
pnt = Pointing(te['sampleOBT'],coord='E', deaberration=False, wobble=False, horn_pointing=False)
vec = pnt.get(self.chlfi)
thetav, phiv, psiv = pnt.get_3ang(self.chlfi)
te['theta'] = thetav
Expand Down Expand Up @@ -102,7 +102,7 @@ def test_vector_ecl2gal(self):

def test_iqu_vs_m3(self):
obt = np.array([1629538385.0881653, 1629538385.3650208])
pnt = Pointing(obt)
pnt = Pointing(obt, deaberration=False, wobble=False, horn_pointing=False)
pix, qw, uw = pnt.get_pix_iqu(self.chlfi)
np.testing.assert_array_almost_equal(pix, [6100717, 6102734])
np.testing.assert_array_almost_equal(qw, [-8.252502679824829e-01, -8.330312371253967e-01])
Expand Down

0 comments on commit 8cb49ba

Please sign in to comment.