From 51e505563735759f707eaa8edb1a4999644fef65 Mon Sep 17 00:00:00 2001 From: Uriel Ramirez Date: Fri, 25 Aug 2023 17:23:23 -0400 Subject: [PATCH] Remove time_step_count from the buffer object. This is not actually needed --- diag_manager/fms_diag_object.F90 | 2 -- diag_manager/fms_diag_output_buffer.F90 | 21 --------------------- 2 files changed, 23 deletions(-) diff --git a/diag_manager/fms_diag_object.F90 b/diag_manager/fms_diag_object.F90 index ab5e64159b..f8a17936ef 100644 --- a/diag_manager/fms_diag_object.F90 +++ b/diag_manager/fms_diag_object.F90 @@ -891,8 +891,6 @@ function fms_diag_do_reduction(this, field_data, diag_field_id, oor_mask, weight "Only none, min, max, sum, average, power, rms, and diurnal are supported." end select - call buffer_ptr%increase_time_step_count() - if (field_ptr%is_static() .or. file_ptr%FMS_diag_file%is_done_writing_data()) then call buffer_ptr%set_done_with_math() endif diff --git a/diag_manager/fms_diag_output_buffer.F90 b/diag_manager/fms_diag_output_buffer.F90 index 5dbe36265c..e8a4ad3aba 100644 --- a/diag_manager/fms_diag_output_buffer.F90 +++ b/diag_manager/fms_diag_output_buffer.F90 @@ -55,7 +55,6 @@ module fms_diag_output_buffer_mod integer, allocatable :: axis_ids(:) !< Axis ids for the buffer integer :: field_id !< The id of the field the buffer belongs to integer :: yaml_id !< The id of the yaml id the buffer belongs to - integer :: time_step_count !< The number of times that have been sent in this time_period type(time_type) :: time_period_end !< The time that the current math period ends logical :: done_with_math !< .True. if done doing the math @@ -70,8 +69,6 @@ module fms_diag_output_buffer_mod procedure :: get_time_period_end procedure :: is_done_with_math procedure :: set_done_with_math - procedure :: get_time_step_count - procedure :: increase_time_step_count procedure :: write_buffer !! These are needed because otherwise the write_data calls will go into the wrong interface procedure :: write_buffer_wrapper_netcdf @@ -368,7 +365,6 @@ subroutine set_time_period_end(this, is_static, freq, freq_units, init_time) this%time_period_end = diag_time_inc(local_time_init, freq, freq_units) endif - this%time_step_count = 0 this%done_with_math = .false. end subroutine @@ -400,23 +396,6 @@ subroutine set_done_with_math(this) this%done_with_math = .true. end subroutine set_done_with_math -!> @brief Get the time_step_count -!! @return A copy of time_step_count -function get_time_step_count(this) & - result(res) - class(fmsDiagOutputBuffer_type), intent(in) :: this !< Buffer object - integer :: res - - res = this%time_step_count -end function get_time_step_count - -!> @brief Increate the time_step count by 1 -subroutine increase_time_step_count(this) - class(fmsDiagOutputBuffer_type), intent(inout) :: this !< Buffer object - - this%time_step_count = this%time_step_count + 1 -end subroutine increase_time_step_count - !> @brief Get the yaml id of the buffer !! @return the yaml id of the buffer function get_yaml_id(this) &