示例#1
0
文件: op2.py 项目: POETSII/PyOP2
def exit():
    """Exit OP2 and clean up"""
    if configuration['print_cache_size'] and COMM_WORLD.rank == 0:
        from caching import report_cache, Cached, ObjectCached
        print '**** PyOP2 cache sizes at exit ****'
        report_cache(typ=ObjectCached)
        report_cache(typ=Cached)
    configuration.reset()

    if backends.get_backend() != 'pyop2.void':
        backends.unset_backend()
示例#2
0
文件: op2.py 项目: eccstartup/PyOP2
def exit():
    """Exit OP2 and clean up"""
    if configuration['print_cache_size'] and MPI.comm.rank == 0:
        from caching import report_cache, Cached, ObjectCached
        print '**** PyOP2 cache sizes at exit ****'
        report_cache(typ=ObjectCached)
        report_cache(typ=Cached)
    if configuration['print_summary'] and MPI.comm.rank == 0:
        from profiling import summary
        print '**** PyOP2 timings summary ****'
        summary()
    configuration.reset()

    if backends.get_backend() != 'pyop2.void':
        backends.unset_backend()
示例#3
0
文件: op2.py 项目: jabooth/PyOP2
def exit():
    """Exit OP2 and clean up"""
    configuration.reset()

    if backends.get_backend() != "pyop2.void":
        backends.unset_backend()
示例#4
0
文件: op2.py 项目: joshcc3/PyOP2
def exit():
    """Exit OP2 and clean up"""
    cfg.reset()
    if backends.get_backend() != 'pyop2.void':
        backends.unset_backend()