[Dart-dev] DART/branches Revision: 12184

dart at ucar.edu dart at ucar.edu
Wed Dec 6 16:49:18 MST 2017


thoar at ucar.edu
2017-12-06 16:49:16 -0700 (Wed, 06 Dec 2017)
292
Changed comments about how the io buffer is being used. Previous 
comments were not clear that it was the buffer
that was being filled all at once or in pieces.

If all the variables can fit (one-by-one) in the buffer, there is no need to
chunk the variable into pieces before distributing.




Modified: DART/branches/rma_trunk/assimilation_code/modules/io/direct_netcdf_mod.f90
===================================================================
--- DART/branches/rma_trunk/assimilation_code/modules/io/direct_netcdf_mod.f90	2017-12-06 16:05:31 UTC (rev 12183)
+++ DART/branches/rma_trunk/assimilation_code/modules/io/direct_netcdf_mod.f90	2017-12-06 23:49:16 UTC (rev 12184)
@@ -1114,11 +1114,17 @@
 
    endif
 
-   ! Reading of the state variables is broken up into
+   ! Read the state variables into a buffer to distribute.
+   ! If possible, reading all the variables into a single buffer 
+   ! (i.e. a large block_size) is preferable to reading variables
+   ! into multiple buffers. Huge DART states may require using
+   ! the same buffer multiple times.
+
    VARIABLE_LOOP: do dummy_loop = 1, num_state_variables
-      if (start_var > num_state_variables) exit ! instead of using do while loop
 
-      ! calculate how many variables will be read
+      if (start_var > num_state_variables) exit VARIABLE_LOOP
+
+      ! calculate how many variables will be read into one buffer
       if (read_var_by_var) then 
          end_var = start_var
       else

Modified: DART/branches/rma_trunk/assimilation_code/modules/io/state_vector_io_mod.f90
===================================================================
--- DART/branches/rma_trunk/assimilation_code/modules/io/state_vector_io_mod.f90	2017-12-06 16:05:31 UTC (rev 12183)
+++ DART/branches/rma_trunk/assimilation_code/modules/io/state_vector_io_mod.f90	2017-12-06 23:49:16 UTC (rev 12184)
@@ -116,11 +116,11 @@
 
 ! namelist variables with default values
 ! Aim: to have the regular transpose as the default
-logical :: buffer_state_io         = .false. !< Write one variable at a time. This is for models
-                                             !< whose entire model state can not fit into a single array on
-                                             !< a given node
-logical :: single_precision_output = .false. !< Allows you to write r4 netcdf files 
-                                             !< even if filter is double precision
+logical :: buffer_state_io         = .false. !< .false. puts the  entire model state 
+                                             !< into a single array on a given node
+                                             !< (desirable if possible).
+logical :: single_precision_output = .false. !< .true. writes 32 bit netcdf variables
+                                             !< even if filter uses 64 bit 
 
 namelist /  state_vector_io_nml / buffer_state_io, single_precision_output
 


More information about the Dart-dev mailing list