Skip to content

Commit

Permalink
logging fixes (#901)
Browse files Browse the repository at this point in the history
  • Loading branch information
matthiasdiener authored May 9, 2023
1 parent bd2a79a commit 07c324c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
10 changes: 5 additions & 5 deletions examples/combozzle-mpi.py
Original file line number Diff line number Diff line change
Expand Up @@ -1234,11 +1234,6 @@ def dummy_rhs(t, state):
my_write_restart(step=current_step, t=current_t, state=final_fluid_state,
temperature_seed=tseed)

if logmgr:
logmgr.close()
elif use_profiling:
print(actx.tabulate_profiling_data())

comm.Barrier()

finish_tol = 1e-16
Expand All @@ -1256,6 +1251,11 @@ def dummy_rhs(t, state):

comm.Barrier()

if logmgr:
logmgr.close()
elif use_profiling:
print(actx.tabulate_profiling_data())


if __name__ == "__main__":
import argparse
Expand Down
6 changes: 3 additions & 3 deletions examples/heat-source-mpi.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,14 +179,14 @@ def rhs(t, u):
set_dt(logmgr, dt)
logmgr.tick_after()

if logmgr:
logmgr.close()

final_answer = actx.to_numpy(op.norm(dcoll, u, np.inf))
resid = abs(final_answer - 0.0002062062188374177)
if resid > 1e-15:
raise ValueError(f"Run did not produce the expected result {resid=}")

if logmgr:
logmgr.close()


if __name__ == "__main__":
import argparse
Expand Down

0 comments on commit 07c324c

Please sign in to comment.