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


Python PetscManager.PetscManager類代碼示例

本文整理匯總了Python中pylith.utils.PetscManager.PetscManager的典型用法代碼示例。如果您正苦於以下問題:Python PetscManager類的具體用法?Python PetscManager怎麽用?Python PetscManager使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


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

示例1: main

 def main(self):
   """
   Run the application.
   """
   from pylith.utils.PetscManager import PetscManager
   manager = PetscManager()
   manager.initialize()
   unittest.TextTestRunner(verbosity=2).run(self._suite())
   manager.finalize()
   return
開發者ID:jjle,項目名稱:pylith,代碼行數:10,代碼來源:testgensimple.py

示例2: main

  def main(self, *args, **kwds):
    """
    Run the application.
    """
    from pylith.utils.PetscManager import PetscManager
    manager = PetscManager()
    manager.initialize()

    self._runTest()

    manager.finalize()
    return
開發者ID:youngsolar,項目名稱:pylith,代碼行數:12,代碼來源:test_meshmem.py

示例3: test_initfinal

 def test_initfinal(self):
   """
   Test initialize/finalize.
   """
   from pylith.utils.PetscManager import PetscManager
   from pylith.utils.petsc import optionsSetValue
   manager = PetscManager()
   manager.options = [("vec_type", "seq")]
   manager.initialize()
   manager.finalize()
   return
開發者ID:rishabhdutta,項目名稱:pylith,代碼行數:11,代碼來源:TestPetscManager.py

示例4: main

  def main(self):
    """
    Run the application.
    """
    from pylith.utils.PetscManager import PetscManager
    petsc = PetscManager()
    petsc.options = [("malloc_dump", "true")]
    petsc.initialize()

    unittest.TextTestRunner(verbosity=2).run(self._suite())

    petsc.finalize()
    return
開發者ID:rishabhdutta,項目名稱:pylith,代碼行數:13,代碼來源:testcubit.py

示例5: main

  def main(self):
    """
    Run the application.
    """
    from pylith.utils.PetscManager import PetscManager
    petsc = PetscManager()
    petsc.options = self.petscOptions
    petsc.initialize()

    success = unittest.TextTestRunner(verbosity=2).run(self._suite()).wasSuccessful()
    
    petsc.finalize()

    if not success:
      import sys
      sys.exit(1)
    return
開發者ID:geodynamics,項目名稱:pylith,代碼行數:17,代碼來源:UnitTestApp.py


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