[Dart-dev] DART/branches Revision: 11410

dart at ucar.edu dart at ucar.edu
Wed Mar 29 15:26:38 MDT 2017


nancy at ucar.edu
2017-03-29 15:26:34 -0600 (Wed, 29 Mar 2017)
191
updates for the revised model_mod interfaces, changes to
assim_model, assim_tools, the location modules, netcdf_utils, etc.

this works for L63 and bgrid_solo only.  i'm now working on wrf.




Modified: DART/branches/model_mod_changes/assimilation_code/location/annulus/location_mod.f90
===================================================================
--- DART/branches/model_mod_changes/assimilation_code/location/annulus/location_mod.f90	2017-03-29 21:14:52 UTC (rev 11409)
+++ DART/branches/model_mod_changes/assimilation_code/location/annulus/location_mod.f90	2017-03-29 21:26:34 UTC (rev 11410)
@@ -16,9 +16,10 @@
 
 use      types_mod, only : r8, PI, RAD2DEG, DEG2RAD, MISSING_R8, MISSING_I
 use  utilities_mod, only : register_module, error_handler, E_ERR, ascii_file_format, &
-                           nc_check, find_namelist_in_file, check_namelist_read, &
+                           find_namelist_in_file, check_namelist_read, &
                            do_output, do_nml_file, do_nml_term, nmlfileunit, &
-                           open_file, close_file, nc_check, is_longitude_between
+                           open_file, close_file, is_longitude_between
+use ensemble_manager_mod, only : ensemble_type
 use random_seq_mod, only : random_seq_type, init_random_seq, random_uniform
 
 implicit none
@@ -27,14 +28,12 @@
 public :: location_type, get_location, set_location, &
           set_location_missing, is_location_in_region, &
           write_location, read_location, interactive_location, query_location, &
-          LocationDims, LocationName, LocationLName, get_close_obs, &
-          get_close_maxdist_init, get_close_obs_init, get_close_type, &
-          operator(==), operator(/=), get_dist, get_close_obs_destroy, &
-          nc_write_location_atts, nc_get_location_varids, nc_write_location, &
-          vert_is_height, vert_is_pressure, vert_is_undef, vert_is_level, &
-          vert_is_surface, has_vertical_localization, VERTISSURFACE, &
-          VERTISLEVEL, VERTISHEIGHT, &
-          set_vert, get_vert, set_which_vert
+          LocationDims, LocationName, LocationLName, LocationStorageOrder, LocationUnits, &
+          get_close_type, get_close_init, get_close, get_close_destroy, &
+          operator(==), operator(/=), get_dist, &
+          vertical_localization_on, is_vertical, set_vertical, &
+          get_vertical_localization_coordinate, set_vertical_localization_coordinate, &
+          VERTISSURFACE, VERTISLEVEL, VERTISHEIGHT
 
 
 ! version controlled file description for error handling, do not edit
@@ -47,10 +46,6 @@
    private
    real(r8) :: azm, rad, vloc
    integer  :: which_vert
-   ! which_vert determines if the location is by level or by height
-   ! -1 ==> obs is on surface
-   ! 1 ===> obs is by level
-   ! 3 ===> obs is by height
 end type location_type
 
 integer, parameter :: VERTISSURFACE  = -1 ! surface
@@ -67,11 +62,14 @@
 logical :: ran_seq_init = .false.
 logical, save :: module_initialized = .false.
 
-integer,              parameter :: LocationDims = 3
-character(len = 129), parameter :: LocationName = "loc_annulus"
-character(len = 129), parameter :: LocationLName = &
+integer,             parameter :: LocationDims = 3
+character(len = 64), parameter :: LocationName = "loc_annulus"
+character(len = 64), parameter :: LocationLName = &
                                    "Annulus location: azimuthal angle, radius, and height"
+character(len = 64), parameter :: LocationStorageOrder = 'Azimuth Radius Vertical'
+character(len = 64), parameter :: LocationUnits = 'degrees meters which_vert'
 
+
 ! really just a placeholder.  there was a comment that this code
 ! needs a namelist with a min & max limit on the radius, but 
 ! the code no longer has one.  
@@ -566,196 +564,64 @@
 
 !----------------------------------------------------------------------------
 
-function nc_write_location_atts( ncFileID, fname, ObsNumDimID ) result (ierr)
+subroutine get_close_init(gc, num, maxdist, locs, maxdist_list)
  
-! Writes the "location module" -specific attributes to a netCDF file.
-
-use typeSizes
-use netcdf
-
-integer,          intent(in) :: ncFileID     ! handle to the netcdf file
-character(len=*), intent(in) :: fname        ! file name (for printing purposes)
-integer,          intent(in) :: ObsNumDimID  ! handle to the dimension that grows
-integer                      :: ierr
-
-integer :: LocDimID
-integer :: VarID
-
-if ( .not. module_initialized ) call initialize_module
-
-ierr = -1 ! assume things will fail ...
-
-! define the rank/dimension of the location information
-call nc_check(nf90_def_dim(ncid=ncFileID, name='location', len=LocationDims, &
-       dimid = LocDimID), 'nc_write_location_atts', 'def_dim:location '//trim(fname))
-
-! Define the observation location variable and attributes
-
-call nc_check(nf90_def_var(ncid=ncFileID, name='location', xtype=nf90_double, &
-          dimids=(/ LocDimID, ObsNumDimID /), varid=VarID), &
-            'nc_write_location_atts', 'location:def_var')
-


More information about the Dart-dev mailing list