Esempio n. 1
0
 def test_2D_tile(self):
     ws = LoadLamp('199902_LAMP.hdf')
     self.assertTrue(ws)
     self.assertEquals(ws.blocksize(),2048)
     self.assertEquals(ws.getNumberHistograms(),18)
     self.assertAlmostEqual(ws.readY(8)[1534],0.2546,4)
     self.assertEquals(ws.readX(3)[4],5)
     self.assertAlmostEqual(ws.readE(10)[1535],0.0012,4)
     self.assertAlmostEqual(ws.getAxis(1).extractValues()[11],95.3,1)
Esempio n. 2
0
 def test_2D_tile(self):
     ws = LoadLamp('199902_LAMP.hdf')
     self.assertTrue(ws)
     self.assertEqual(ws.blocksize(), 2048)
     self.assertEqual(ws.getNumberHistograms(), 18)
     self.assertAlmostEqual(ws.readY(8)[1534], 0.2546, 4)
     self.assertEqual(ws.readX(3)[4], 5)
     self.assertAlmostEqual(ws.readE(10)[1535], 0.0012, 4)
     self.assertAlmostEqual(ws.getAxis(1).extractValues()[11], 95.3, 1)
Esempio n. 3
0
 def test_2D_ragged(self):
     ws = LoadLamp('967076_LAMP.hdf')
     self.assertTrue(ws)
     self.assertEquals(ws.blocksize(),3199)
     self.assertEquals(ws.getNumberHistograms(),571)
     self.assertEquals(ws.readY(103)[373],73)
     self.assertAlmostEqual(ws.readE(105)[205],80.7279,4)
     self.assertAlmostEqual(ws.readX(7)[8],-27.0516,4)
     self.assertAlmostEqual(ws.getAxis(1).extractValues()[5],-30.8006,4)
Esempio n. 4
0
 def test_2D_ragged(self):
     ws = LoadLamp('967076_LAMP.hdf')
     self.assertTrue(ws)
     self.assertEqual(ws.blocksize(), 3199)
     self.assertEqual(ws.getNumberHistograms(), 571)
     self.assertEqual(ws.readY(103)[373], 73)
     self.assertAlmostEqual(ws.readE(105)[205], 80.7279, 4)
     self.assertAlmostEqual(ws.readX(7)[8], -27.0516, 4)
     self.assertAlmostEqual(ws.getAxis(1).extractValues()[5], -30.8006, 4)