Skip to content

Commit

Permalink
Merge pull request #706 from GFDL-Eric/ascii_io
Browse files Browse the repository at this point in the history
Ascii io
  • Loading branch information
rem1776 authored Mar 26, 2021
2 parents 1d7d2f4 + a85eca0 commit 1a653fc
Show file tree
Hide file tree
Showing 10 changed files with 506 additions and 17 deletions.
11 changes: 8 additions & 3 deletions data_override/data_override.F90
Original file line number Diff line number Diff line change
Expand Up @@ -62,15 +62,16 @@ module data_override_mod
NO_REGION, INSIDE_REGION, OUTSIDE_REGION, &
get_external_fileobj
use fms_mod, only: write_version_number, field_exist, lowercase, check_nml_error
use fms_io_mod, only: fms_io_init, get_mosaic_tile_file
use axis_utils_mod, only: get_axis_bounds
use axis_utils2_mod, only : nearest_index, axis_edges
use fms_io_mod, only: fms_io_init, get_mosaic_tile_file_classic=>get_mosaic_tile_file
use mpp_domains_mod, only : domain2d, mpp_get_compute_domain, NULL_DOMAIN2D,operator(.NE.),operator(.EQ.)
use mpp_domains_mod, only : mpp_get_global_domain, mpp_get_data_domain
use mpp_domains_mod, only : domainUG, mpp_pass_SG_to_UG, mpp_get_UG_SG_domain, NULL_DOMAINUG
use time_manager_mod, only: time_type
use fms2_io_mod, only : FmsNetcdfFile_t, open_file, close_file, &
read_data, fms2_io_init, variable_exists
read_data, fms2_io_init, variable_exists, &
get_mosaic_tile_file_fms2_io=>get_mosaic_tile_file
use get_grid_version_mpp_mod, only: get_grid_version_classic_1, get_grid_version_classic_2
use get_grid_version_fms2io_mod, only: get_grid_version_1, get_grid_version_2

Expand Down Expand Up @@ -879,7 +880,11 @@ subroutine data_override_3d(gridname,fieldname_code,data,time,override,data_inde
! Allow on-grid data_overrides on cubed sphere grid
inquire(file=trim(filename),EXIST=exists)
if (.not. exists) then
call get_mosaic_tile_file(filename,filename2,.false.,domain)
if (use_mpp_bug) then
call get_mosaic_tile_file_classic(filename,filename2,.false.,domain)
else
call get_mosaic_tile_file_fms2_io(filename,filename2,.false.,domain)
endif
filename = filename2
endif

Expand Down
3 changes: 3 additions & 0 deletions fms2_io/fms2_io.F90
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,9 @@ module fms2_io_mod
public :: write_restart_bc
public :: read_restart_bc
public :: get_mosaic_tile_grid
public :: ascii_read
public :: get_mosaic_tile_file
public :: parse_mask_table
public :: get_filename_appendix
public :: set_filename_appendix
public :: get_instance_filename
Expand Down
Loading

0 comments on commit 1a653fc

Please sign in to comment.