[Dart-dev] DART/branches Revision: 10776

dart at ucar.edu dart at ucar.edu
Wed Nov 23 15:43:10 MST 2016


hendric at ucar.edu
2016-11-23 15:43:09 -0700 (Wed, 23 Nov 2016)
331
* Checking for empty file string in restart list rather than 
  just null.  
* Adding file quotes around filenames in E_MSG's.
* Giving file description to input and output restart files.
* The logic of write_assim_files.  Mean, SD, and Inflation should
  not depend on the number of output state members in order to be
  written




Modified: DART/branches/rma_fixed_filenames/filter/filter_mod.f90
===================================================================
--- DART/branches/rma_fixed_filenames/filter/filter_mod.f90	2016-11-22 23:10:53 UTC (rev 10775)
+++ DART/branches/rma_fixed_filenames/filter/filter_mod.f90	2016-11-23 22:43:09 UTC (rev 10776)
@@ -375,12 +375,11 @@
 call     trace_message('Before reading in ensemble restart files')
 call timestamp_message('Before reading in ensemble restart files')
 ! Load up the file_info structure with all the namelist options from filter.
-file_info_input = io_filenames_init(state_ens_handle, single_file_in, &
-                     restart_list = input_restart_file_list, root_name='input')
-file_info_output = io_filenames_init(state_ens_handle, single_file_out, &
-                     restart_list = output_restart_file_list, root_name='output', &
-                     check_output_compatibility = .true.)
-
+file_info_input     = io_filenames_init(state_ens_handle, single_file_in, &
+                                   restart_list = input_restart_file_list, root_name='input')
+file_info_output    = io_filenames_init(state_ens_handle, single_file_out, &
+                                  restart_list = output_restart_file_list, root_name='output', &
+                                  check_output_compatibility = .true.)
 file_info_preassim  = io_filenames_init(state_ens_handle, single_file_out, root_name='preassim')
 file_info_postassim = io_filenames_init(state_ens_handle, single_file_out, root_name='postassim')
 
@@ -767,7 +766,7 @@
    ! gone in Posterior_Diag.nc and write them at the end
    call store_posterior(state_ens_handle)
 
-   !>todo FIXME JPH: option to write copies after inflation and before
+   !>@todo FIXME JPH: option to write copies after inflation and before
    !> posterior inflation.
    if ((output_interval > 0) .and. &
        (time_step_number / output_interval * output_interval == time_step_number)) then

Modified: DART/branches/rma_fixed_filenames/io/direct_netcdf_mod.f90
===================================================================
--- DART/branches/rma_fixed_filenames/io/direct_netcdf_mod.f90	2016-11-22 23:10:53 UTC (rev 10775)
+++ DART/branches/rma_fixed_filenames/io/direct_netcdf_mod.f90	2016-11-23 22:43:09 UTC (rev 10776)
@@ -197,7 +197,7 @@
    if (query_read_copy(copy)) then
       netcdf_filename = get_restart_filename(name_handle, copy, domain)
       ret = nf90_open(netcdf_filename, NF90_NOWRITE, ncfile)
-      call nc_check(ret, 'read_transpose_single_task: opening', netcdf_filename)
+      call nc_check(ret, 'direct_netcdf_mod.f90 read_transpose_single_task: opening', netcdf_filename)
    endif
 
    block_size = get_domain_size(domain)

Modified: DART/branches/rma_fixed_filenames/io/io_filenames_mod.f90
===================================================================
--- DART/branches/rma_fixed_filenames/io/io_filenames_mod.f90	2016-11-22 23:10:53 UTC (rev 10775)
+++ DART/branches/rma_fixed_filenames/io/io_filenames_mod.f90	2016-11-23 22:43:09 UTC (rev 10776)
@@ -50,7 +50,6 @@
                                  get_has_missing_value
 use ensemble_manager_mod, only : ensemble_type
 
-!>@todo used to require the copies_on_off_mod ... remove from path_names_files where appropriate
 use netcdf
 
 implicit none
@@ -265,9 +264,9 @@
 
 ens_size = num_copies - num_extras
 
-!>@todo check for a zero-length string - same as null
+write(*,*) "RESTART_LIST_FILE ", file_info%root_name,  restart_list(idom)
 
-if (restart_list(idom) == 'null') then
+if (trim(restart_list(idom)) == trim('null') .or. trim(restart_list(idom)) == '') then
 
   write(msgstring,*) 'NO restart_file_list provided using default names'
   call error_handler(E_MSG,'construct_restart_file_list', &
@@ -280,8 +279,8 @@
                      msgstring, source, revision, revdate)
       else
          file_info%stage_metadata%filenames(icopy, idom) = construct_file_names(file_info, ens_size, icopy, idom)
-         !>@todo need a constructor for file_descriptions
-         file_info%stage_metadata%file_description(icopy, idom) = construct_file_names(file_info, ens_size, icopy, idom)
+         write(msgstring,'(2A,I4)') trim(file_info%root_name), ' ensemble member ', icopy
+         file_info%stage_metadata%file_description(icopy,idom) = trim(msgstring)
       endif
    enddo
 
@@ -295,7 +294,7 @@
    endif
   
    !>@todo qualifiers around file name strings 
-   write(msgstring,*) 'files from : ', trim(restart_list(idom))
+   write(msgstring,*) 'files from : "'//trim(restart_list(idom))//'"'
    call error_handler(E_MSG,'construct_restart_file_list', &
                       msgstring, source, revision, revdate)
    
@@ -303,8 +302,7 @@
    call find_textfile_dims(trim(restart_list(idom)), nlines)
    if( nlines < ens_size) then
       write(msgstring,*) 'io_filenames_mod: expecting ',ens_size, &
-                         'files in ', trim(restart_list(idom)),  &
-                         'and only found ', nlines
+                         'files in "'//trim(restart_list(idom))//'" and only found ', nlines
       call error_handler(E_ERR,'construct_restart_file_list', msgstring, &
                          source, revision, revdate)
    endif 
@@ -314,6 +312,8 @@


More information about the Dart-dev mailing list