當前位置: 首頁>>代碼示例>>Python>>正文


Python Load.blocksize方法代碼示例

本文整理匯總了Python中mantid.simpleapi.Load.blocksize方法的典型用法代碼示例。如果您正苦於以下問題:Python Load.blocksize方法的具體用法?Python Load.blocksize怎麽用?Python Load.blocksize使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在mantid.simpleapi.Load的用法示例。


在下文中一共展示了Load.blocksize方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: test_sum_range_operator_sums_to_single_workspace

# 需要導入模塊: from mantid.simpleapi import Load [as 別名]
# 或者: from mantid.simpleapi.Load import blocksize [as 別名]
    def test_sum_range_operator_sums_to_single_workspace(self):
        data = Load("TSC15352-15353.raw", OutputWorkspace=self.wsname)

        self.assertTrue(isinstance(data, MatrixWorkspace))
        self.assertEquals(149, data.getNumberHistograms())
        self.assertEquals(24974, data.blocksize())

        self.assertAlmostEqual(9.0, data.readX(2)[1], places=DIFF_PLACES)
        self.assertAlmostEqual(46352.0, data.readY(2)[1], places=DIFF_PLACES)
        self.assertAlmostEqual(215.29514625276622, data.readE(2)[1], places=DIFF_PLACES)
開發者ID:mantidproject,項目名稱:systemtests,代碼行數:12,代碼來源:LoadTest.py

示例2: test_sum_range_operator_with_step_sums_to_single_workspace

# 需要導入模塊: from mantid.simpleapi import Load [as 別名]
# 或者: from mantid.simpleapi.Load import blocksize [as 別名]
    def test_sum_range_operator_with_step_sums_to_single_workspace(self):
        data = Load("TSC15352-15354:2.raw", OutputWorkspace=self.wsname)

        self.assertTrue(isinstance(data, MatrixWorkspace))
        self.assertEquals(149, data.getNumberHistograms())
        self.assertEquals(24974, data.blocksize())

        self.assertAlmostEqual(9.0, data.readX(2)[1], places=DIFF_PLACES)
        self.assertAlmostEqual(35640.0, data.readY(2)[1], places=DIFF_PLACES)
        self.assertAlmostEqual(188.78559267062727, data.readE(2)[1], places=DIFF_PLACES)
開發者ID:mantidproject,項目名稱:systemtests,代碼行數:12,代碼來源:LoadTest.py

示例3: test_plus_operator_sums_single_set_files

# 需要導入模塊: from mantid.simpleapi import Load [as 別名]
# 或者: from mantid.simpleapi.Load import blocksize [as 別名]
    def test_plus_operator_sums_single_set_files(self):
        data = Load("TSC15352+15353.raw", OutputWorkspace=self.wsname)

        self.assertTrue(isinstance(data, MatrixWorkspace))
        self.assertEquals(149, data.getNumberHistograms())
        self.assertEquals(24974, data.blocksize())

        self.assertAlmostEqual(9.0, data.readX(2)[1], places=DIFF_PLACES)
        self.assertAlmostEqual(46352.0, data.readY(2)[1], places=DIFF_PLACES)
        self.assertAlmostEqual(215.29514625276622, data.readE(2)[1], places=DIFF_PLACES)

        deleted_names = ["TSC15352", "TSC15353"]
        for name in deleted_names:
            self.assertTrue(name not in AnalysisDataService)
開發者ID:mantidproject,項目名稱:systemtests,代碼行數:16,代碼來源:LoadTest.py


注:本文中的mantid.simpleapi.Load.blocksize方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。