Skip to content

Commit

Permalink
Better formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
nefrathenrici committed Aug 24, 2023
1 parent a6d2c6d commit 164d90c
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/callbacks/callbacks.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,9 @@ import ClimaCore.Fields: ColumnField
include("callback_helpers.jl")

"""
display_status_callback!(::Type{tType})
display_status_callback!()
Given typeof(dt), returns a callback to display:
- percentage of work completed,
- total wallclock time elapsed,
- estimated wallclock time remaining.
Returns a callback to display simulation information.
Adapted from ClimaTimeSteppers.jl #89.
"""
function display_status_callback!()
Expand Down Expand Up @@ -63,7 +60,8 @@ function display_status_callback!()
else
@info "$(Dates.format(Dates.now(), "HH:MM:SS:ss u-d")) \n\
Timestep: $(step[]) / $(nsteps[]); Simulation Time: $(t[]) seconds \n\
Walltime: $(round(time[] - start_time[], digits=2)) seconds; Time/Step: $(round(time[] - prev_time[], digits=2)) \n\
Walltime: $(round(time[] - start_time[], digits=2)) seconds; \
Time/Step: $(round(speed[] * integrator.dt, digits=2)) seconds \n\
Time Remaining: $(Int64(round(eta[]))) seconds"
end
prev_t[] = t[]
Expand Down

0 comments on commit 164d90c

Please sign in to comment.