[Dart-dev] DART/branches Revision: 12735

dart at ucar.edu dart at ucar.edu
Wed Jul 11 15:28:16 MDT 2018


hendric at ucar.edu
2018-07-11 15:28:16 -0600 (Wed, 11 Jul 2018)
29

removing debug statements.




Modified: DART/branches/pertirb_tool/assimilation_code/programs/perturb_single_instance/perturb_single_instance.f90
===================================================================
--- DART/branches/pertirb_tool/assimilation_code/programs/perturb_single_instance/perturb_single_instance.f90	2018-07-11 20:29:09 UTC (rev 12734)
+++ DART/branches/pertirb_tool/assimilation_code/programs/perturb_single_instance/perturb_single_instance.f90	2018-07-11 21:28:16 UTC (rev 12735)
@@ -143,13 +143,16 @@
 ndomains = get_num_domains()
 
 !----------------------------------------------------------------------
-! is ens_size but rather a single file (or multiple files if more than one domain)
+! can be ens_size but rather a single file 
+! (or multiple files if more than one domain)
 !----------------------------------------------------------------------
 allocate(file_array_input(ens_size, ndomains))
 
 file_array_input = RESHAPE(input_files,  (/1,  ndomains/))
 
+!----------------------------------------------------------------------
 ! read in a single ensemble member
+!----------------------------------------------------------------------
 call io_filenames_init(file_info_input, &
                        ncopies       = 1, &
                        cycling       = single_restart_file_in, &
@@ -156,9 +159,11 @@
                        single_file   = single_restart_file_in, &
                        restart_files = file_array_input)
 
+!----------------------------------------------------------------------
 ! Read the template file to get the shape of netCDF file
 ! and its variables. It is possible to have multiple domains
 ! but only require one member.
+!----------------------------------------------------------------------
 write(my_base,'(A)') 'template'
 write(my_desc,'(A)') 'template file'
 call set_file_metadata(file_info_input,                  &
@@ -183,12 +188,15 @@
                       source, revision, revdate)
 enddo
 
+!----------------------------------------------------------------------
 ! Read the ensemble from files
+!----------------------------------------------------------------------
 member_time = set_time_missing()
 call read_state(ens_handle, file_info_input, read_time_from_file=.true., time=member_time)
-print*, 'after read_state()'
 
+!----------------------------------------------------------------------
 ! Copy from ensemble member 1 to the other copies
+!----------------------------------------------------------------------
 do i = 1, ens_handle%my_num_vars
    ens_handle%copies(2:ens_size, i) = ens_handle%copies(1, i)  ! How slow is this?
 enddo
@@ -195,11 +203,16 @@
 
 call pert_model_copies(ens_handle, ens_size, 0.2_r8, interf_provided)
 
-! be ens_size but rather a single file (or multiple files if more than one domain)
+!----------------------------------------------------------------------
+! can be ens_size but rather a single file 
+! (or multiple files if more than one domain)
+!----------------------------------------------------------------------
 allocate(file_array_output(ens_size, ndomains))
 
+!----------------------------------------------------------------------
 ! Given either a vector of in/output_files or a text file containing
 ! a list of files, return a vector of files containing the filenames.
+!----------------------------------------------------------------------
 call set_multiple_filename_lists(output_files(:), &
                                  output_file_list(:), &
                                  ndomains, &
@@ -209,11 +222,10 @@
                                  'input_state_file_list')
 
 file_array_output = RESHAPE(output_files,  (/ens_size,  ndomains/))
-print*, 'output_files     ', trim(output_files(1))
-print*, 'output_file_list ', trim(output_file_list(1))
-print*, 'file_array_output', trim(file_array_output(1,1))
 
-! read in a single ensemble member
+!----------------------------------------------------------------------
+! output ens_size perturbed restarts
+!----------------------------------------------------------------------
 call io_filenames_init(file_info_output, &
                        ncopies       = ens_size, &
                        cycling       = single_restart_file_in, &
@@ -248,9 +260,12 @@
 
 call write_state(ens_handle, file_info_output)
 
+!----------------------------------------------------------------------
 ! clean up allocated memory
+!----------------------------------------------------------------------
 call end_ensemble_manager(ens_handle)
 deallocate(file_array_output, file_array_input,)
+
 call finalize_mpi_utilities()   ! now closes log file, too
 
 !----------------------------------------------------------------


More information about the Dart-dev mailing list