Changeset 2672 for trunk/test


Ignore:
Timestamp:
10/18/12 21:06:07 (12 years ago)
Author:
Malte Marquarding
Message:

introduce 'reshape' method; this includes a fix to c++ for the upper boundary assertion

Location:
trunk/test
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/test_observatories/test_parkes_mx.py

    r2522 r2672  
    2727        rms = avp.stats("rms")
    2828        mx = avp.stats("max_abc")
    29         print rms
    3029        assert_almost_equals(rms[0], 0.04148, 5)
    3130        assert_almost_equals(mx[0], 86.67328, 5)
  • trunk/test/test_scantable.py

    r2634 r2672  
    222222        assert_almost_equals(res_rms[0], 0.38346, 5)
    223223        assert_almost_equals(res_rms[1], 0.38780, 5)       
     224
     225
     226    def test_reshape(self):
     227        cp = self.st.copy()
     228        n = cp.nchan()
     229        rs = cp.reshape(10,-10,False)
     230        assert_equals(n-20, rs.nchan())
     231        assert_equals(cp.nchan(), n)
     232        rs = cp.reshape(10,n-11,False)
     233        assert_equals(n-20, rs.nchan())
     234        cp.reshape(10,-10,True)
     235        assert_equals(n-20, cp.nchan())
Note: See TracChangeset for help on using the changeset viewer.