Skip to content

Commit

Permalink
Merge pull request #933 from GEOS-ESM/develop
Browse files Browse the repository at this point in the history
Merge develop into main for 2.8.1 release
  • Loading branch information
mathomp4 authored Jul 28, 2021
2 parents e66a362 + c477b97 commit f7f133a
Show file tree
Hide file tree
Showing 19 changed files with 641 additions and 1,070 deletions.
1 change: 1 addition & 0 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ on:
# Do not run if the only files changed cannot affect the build
paths-ignore:
- "**.md"
- "**.json"
- "Python/**"
- ".github/CODEOWNERS"
- ".github/PULL_REQUEST_TEMPLATE.md"
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@
/ESMA_env@/
/.mepo/
*.py.bak
CMakeUserPresets.json
22 changes: 22 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,28 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed
### Fixed

## [2.8.1] - 2021-07-28

### Removed

- Removed MAPL_OldCubedShereGridFactory.F90 and consilidated with MAPL_CubedSphereGridFactory.F90

### Added

- Add stretch parameters to restarts and check the file grid compared to MAPL grid
when reading restarts
- Add `CMakePresets.json` file
- Note: requires CMake 3.21.0 to use
- Per CMake advice, add `CMakeUserPresets.json` to `.gitignore`

### Changed

- Widened the throughput timer format

### Fixed

- Fixed bug with tripolar grids and restarts to not check the file grid matches the application grid if application grid is tripolar

## [2.8.0] - 2021-07-12

### Added
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ cmake_policy (SET CMP0054 NEW)

project (
MAPL
VERSION 2.8.0
VERSION 2.8.1
LANGUAGES Fortran CXX C) # Note - CXX is required for ESMF

# mepo can now clone subrepos in three styles
Expand Down
126 changes: 126 additions & 0 deletions CMakePresets.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,126 @@
{
"version": 3,
"cmakeMinimumRequired": {
"major": 3,
"minor": 21,
"patch": 0
},
"configurePresets": [
{
"name": "base-configure",
"hidden": true,
"displayName": "Base Configure Settings",
"description": "Sets build and install directories",
"binaryDir": "${sourceDir}/build-${presetName}",
"cacheVariables": {
"BASEDIR": "$env{BASEDIR}",
"CMAKE_INSTALL_PREFIX": "${sourceDir}/install-${presetName}",
"CMAKE_BUILD_TYPE": "${presetName}"
}
},
{
"name": "base-gnu",
"hidden": true,
"inherits": "base-configure",
"displayName": "Base GNU Make Config",
"description": "Sets GNU Make generator",
"generator": "Unix Makefiles"
},
{
"name": "base-ninja",
"hidden": true,
"inherits": "base-configure",
"displayName": "Base Ninja Config",
"description": "Sets Ninja generator",
"generator": "Ninja"
},
{
"name": "Release",
"inherits": "base-gnu",
"displayName": "Release Configure",
"description": "Release build using GNU Make generator"
},
{
"name": "Debug",
"inherits": "base-gnu",
"displayName": "Debug Configure",
"description": "Debug build using GNU Make generator"
},
{
"name": "Aggressive",
"inherits": "base-gnu",
"displayName": "Aggressive Configure",
"description": "Aggressive build using GNU Make generator"
},
{
"name": "Release-Ninja",
"inherits": "base-ninja",
"displayName": "Release Ninja Configure",
"description": "Release build using Ninja generator"
},
{
"name": "Debug-Ninja",
"inherits": "base-ninja",
"displayName": "Debug Ninja Configure",
"description": "Debug build using Ninja generator"
},
{
"name": "Aggressive-Ninja",
"inherits": "base-ninja",
"displayName": "Aggressive Ninja Configure",
"description": "Aggressive build using Ninja generator"
}
],
"buildPresets": [
{
"name": "base-build",
"hidden": true,
"displayName": "Base Build Config",
"description": "Sets default build options",
"jobs": 6,
"targets": ["install"]
},
{
"name": "Release",
"configurePreset": "Release",
"inherits": "base-build",
"displayName": "Release Build",
"description": "Release build using GNU Make generator"
},
{
"name": "Debug",
"configurePreset": "Debug",
"inherits": "base-build",
"displayName": "Debug Build",
"description": "Debug build using GNU Make generator"
},
{
"name": "Aggressive",
"configurePreset": "Aggressive",
"inherits": "base-build",
"displayName": "Aggressive Build",
"description": "Aggressive build using GNU Make generator"
},
{
"name": "Release-Ninja",
"configurePreset": "Release-Ninja",
"inherits": "base-build",
"displayName": "Release Ninja Build",
"description": "Release build using Ninja generator"
},
{
"name": "Debug-Ninja",
"configurePreset": "Debug-Ninja",
"inherits": "base-build",
"displayName": "Debug Ninja Build",
"description": "Debug build using Ninja generator"
},
{
"name": "Aggressive-Ninja",
"configurePreset": "Aggressive-Ninja",
"inherits": "base-build",
"displayName": "Aggressive Ninja Build",
"description": "Aggressive build using Ninja generator"
}
]
}
2 changes: 1 addition & 1 deletion base/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ set (srcs
MAPL_ExtDataGridCompMod.F90 MAPL_OrbGridCompMod.F90
MAPL_LocStreamFactoryMod.F90 MAPL_LocstreamRegridder.F90
MAPL_ExternalGridFactory.F90
ServerManager.F90 ApplicationSupport.F90 MAPL_OldCubedSphereGridFactory.F90
ServerManager.F90 ApplicationSupport.F90
regex_module.F90 StringTemplate.F90 MAPL_SphericalGeometry.F90 FieldBundleWrite.F90 FieldBundleRead.F90
regex_F.c
c_mapl_locstream_F.c getrss.c memuse.c
Expand Down
22 changes: 19 additions & 3 deletions base/MAPL_AbstractGridFactory.F90
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ module MAPL_AbstractGridFactoryMod
procedure(generate_file_reference2D), deferred :: generate_file_reference2D
procedure(generate_file_reference3D), deferred :: generate_file_reference3D
procedure(get_file_format_vars), deferred :: get_file_format_vars
procedure(decomps_are_equal), deferred :: decomps_are_equal
procedure(physical_params_are_equal), deferred :: physical_params_are_equal
end type AbstractGridFactory

abstract interface
Expand All @@ -89,6 +91,18 @@ logical function equals(a, b)
class (AbstractGridFactory), intent(in) :: b
end function equals

logical function decomps_are_equal(this,a)
import AbstractGridFactory
class (AbstractGridFactory), intent(in) :: this
class (AbstractGridFactory), intent(in) :: a
end function decomps_are_equal

logical function physical_params_are_equal(this,a)
import AbstractGridFactory
class (AbstractGridFactory), intent(in) :: this
class (AbstractGridFactory), intent(in) :: a
end function physical_params_are_equal

function make_new_grid(this, unusable, rc) result(grid)
use esmf
use MAPL_KeywordEnforcerMod
Expand Down Expand Up @@ -180,14 +194,16 @@ subroutine append_variable_metadata(this,var)
type(Variable), intent(inout) :: var
end subroutine append_variable_metadata

subroutine generate_file_bounds(this,grid,local_start,global_start,global_count,rc)
subroutine generate_file_bounds(this,grid,local_start,global_start,global_count,metadata,rc)
use esmf
use pFIO
import AbstractGridFactory
class (AbstractGridFactory), intent(inout) :: this
type(ESMF_Grid), intent(inout) :: grid
integer, allocatable, intent(out) :: local_start(:)
integer, allocatable, intent(out) :: global_start(:)
integer, allocatable, intent(out) :: global_count(:)
type(FileMetadata), intent(in), optional :: metaData
integer, optional, intent(out) :: rc

end subroutine generate_file_bounds
Expand All @@ -212,12 +228,13 @@ function generate_file_reference2D(this,fpointer) result(ref)
real, pointer, intent(in) :: fpointer(:,:)
end function generate_file_reference2D

function generate_file_reference3D(this,fpointer) result(ref)
function generate_file_reference3D(this,fpointer,metadata) result(ref)
use pFIO
import AbstractGridFactory
type(ArrayReference) :: ref
class (AbstractGridFactory), intent(inout) :: this
real, pointer, intent(in) :: fpointer(:,:,:)
type(FileMetadata), intent(in), optional :: metaData
end function generate_file_reference3D

end interface
Expand Down Expand Up @@ -1013,6 +1030,5 @@ function get_grid(this, unusable, rc) result(grid)
end if

end function get_grid


end module MAPL_AbstractGridFactoryMod
Loading

0 comments on commit f7f133a

Please sign in to comment.