checkpoint_monitor_m Module

Module containing general driver for monitoring checkpoints



Contents


Derived Types

type, public ::  checkpoint_monitor_t

Datatype for checkpoint monitor

Type-Bound Procedures

procedure , public :: get_major_tally Function
procedure , public :: get_minor_tally_fwd Function
procedure , public :: get_minor_tally_bwd Function
procedure , public :: on_major_checkpoint Function
procedure , public :: on_minor_checkpoint Function
procedure , public :: init => init_monitor Subroutine
procedure , public :: drive Subroutine

Functions

public pure function get_minor_tally_fwd(self)

Return current fwd tally for the minor cycle

Arguments

Type IntentOptional Attributes Name
class(checkpoint_monitor_t), intent(in) :: self

Instance of class

Return Value integer

public pure function get_minor_tally_bwd(self)

Return current bwd tally for the minor cycle

Arguments

Type IntentOptional Attributes Name
class(checkpoint_monitor_t), intent(in) :: self

Instance of class

Return Value integer

public pure function get_major_tally(self)

Return current tally for the major cycle

Arguments

Type IntentOptional Attributes Name
class(checkpoint_monitor_t), intent(in) :: self

Instance of class

Return Value integer

public pure function on_minor_checkpoint(self)

Return current checkpoint state for the minor cycle

Arguments

Type IntentOptional Attributes Name
class(checkpoint_monitor_t), intent(in) :: self

Instance of class

Return Value logical

public pure function on_major_checkpoint(self)

Return current checkpoint state for the major cycle

Arguments

Type IntentOptional Attributes Name
class(checkpoint_monitor_t), intent(in) :: self

Instance of class

Return Value logical


Subroutines

public subroutine init_monitor(self, major_interval, minor_interval, major_tally_offset)

Initialize checkpoint monitor

Arguments

Type IntentOptional Attributes Name
class(checkpoint_monitor_t), intent(inout) :: self

Instance of class

real(kind=GP), intent(in) :: major_interval

Time interval of major cycle

real(kind=GP), intent(in), optional :: minor_interval

Time interval of minor cycle If not provided, minor cycle is set to match major cycle

integer, intent(in), optional :: major_tally_offset

Offset of tally of elapsed major cycles If not given, tally starts at 0 (1 after first major checkpoint)

public subroutine drive(self, tau, dtau)

Check if time aligns with cycle and set according checkpoint flag

Arguments

Type IntentOptional Attributes Name
class(checkpoint_monitor_t), intent(inout) :: self

Instance of class

real(kind=GP), intent(in) :: tau

Current time

real(kind=GP), intent(in) :: dtau

Time step