Skip to content

Commit

Permalink
Merge pull request #1387 from JCSDA-internal/release/mpas-1.0
Browse files Browse the repository at this point in the history
Release/mpas 1.0
  • Loading branch information
Mark Miesch authored Sep 21, 2021
2 parents 0a07af4 + 81aeaa9 commit 9875a45
Show file tree
Hide file tree
Showing 359 changed files with 6,711 additions and 3,500 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ exp.summary.txt
CMakeLists.txt.user
dependencies.mk
loadmap
git-hammer-config.json

#Ignore the contents of these directories
#(html and latex directories are generated by doxygen)
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
################################################################################

cmake_minimum_required( VERSION 3.12 )
project( oops VERSION 1.1.0 LANGUAGES CXX Fortran )
project( oops VERSION 1.2.0 LANGUAGES CXX Fortran )

## Ecbuild integration
find_package( ecbuild 3.3.2 REQUIRED )
Expand Down
2 changes: 1 addition & 1 deletion LICENSE → LICENSE.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@
identification within third-party archives.

Copyright 2009-2016 European Centre for Medium-Range Weather Forecasts (ECMWF)
Copyright 2017-2020 University Corporation for Atmospheric Research (UCAR)
Copyright 2017-2021 University Corporation for Atmospheric Research (UCAR)

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
Object Oriented Prediction System (OOPS)

GNU: [![AWS-gnu](https://codebuild.us-east-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiN2RzbkhSR3o4dm9HN29wRW5laDRMdGlSdGFrNUswWE9pMVJHbmwrQ0EvYWZkNnRjMTFzZWFQL3dUdUpLbmUxNlJXYlFsYmRoaDR5K1NUdCtWNmNvTHFBPSIsIml2UGFyYW1ldGVyU3BlYyI6ImV5OWJFdFRWNWVnMVpwcHEiLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=develop)](https://console.aws.amazon.com/codesuite/codebuild/projects/automated-testing-oops-gnu/history?region=us-east-1)
INTEL: [![AWS-intel](https://codebuild.us-east-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiWG5KM0dQR3VBNWdVVUdJeURwUjhoOXNWYlBYdnpGR2prLzQ4RXk2ZlkrN2llZ2M4S05MeXdWcERMVFZ2RGIxbTRXZFMvTFM5cTRoamFzV3hYanlZVEVNPSIsIml2UGFyYW1ldGVyU3BlYyI6IjZJVnJYL1Z5VktTQWZzZUkiLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=develop)](https://console.aws.amazon.com/codesuite/codebuild/projects/automated-testing-oops-intel)
CLANG: [![AWS-clang](https://codebuild.us-east-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiNHdvREpKTnVOT2pneEx6cHpaMjlma3RsUmlLZFQrMmpDR0tNODBrMzA0Z0pFazFKMFloQVc0Q0xkeGRZbW9WSDJ4c2FWSFg0SkZWb1VXVmVQRk5rSTFJPSIsIml2UGFyYW1ldGVyU3BlYyI6InRQckQrWDdaY0l2RkZoWmUiLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=develop)](https://console.aws.amazon.com/codesuite/codebuild/projects/automated-testing-oops-clang/history?region=us-east-1)
[![codecov](https://codecov.io/gh/JCSDA/oops/branch/develop/graph/badge.svg?token=GdDzbEQedm)](https://codecov.io/gh/JCSDA/oops)
### Continuous integration:
| Platform | JCSDA-internal | JCSDA |
| ------------- | ------------- |------------- |
| GNU | [![AWS-gnu](https://codebuild.us-east-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiNjVsdE5keGM1Tk5yV3FEd2tiaU5YRFVLWEVUTitBdCs5dm9nc29LNjh0T1plank1bzB2TTB2ZkptT2lUSFNWMklmWWdkNW5IbFR1VXZ1NE12M0JiR3BrPSIsIml2UGFyYW1ldGVyU3BlYyI6IkthTWxpTkZaY21CUklINnciLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=develop)](https://console.aws.amazon.com/codesuite/codebuild/469205354006/projects/oops-internal-gnu/history) | [![AWS-gnu](https://codebuild.us-east-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiN2RzbkhSR3o4dm9HN29wRW5laDRMdGlSdGFrNUswWE9pMVJHbmwrQ0EvYWZkNnRjMTFzZWFQL3dUdUpLbmUxNlJXYlFsYmRoaDR5K1NUdCtWNmNvTHFBPSIsIml2UGFyYW1ldGVyU3BlYyI6ImV5OWJFdFRWNWVnMVpwcHEiLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=develop)](https://us-east-1.console.aws.amazon.com/codesuite/codebuild/projects/automated-testing-oops-gnu/history)
| Intel | [![AWS-intel](https://codebuild.us-east-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiUkd1YnZqN2RLWWhaOFE5MkdmbGZ5K1I0amlGU3l4Z3h5Ymw2KzR1Z3lhMXNFSEpkK2M2QTlIZk9mdVQ0ZEx5UFMvRDBZa2tUbVd6TkU1QmZPRWEycmNRPSIsIml2UGFyYW1ldGVyU3BlYyI6IjhmY2tER1c5SDVYekJZRS8iLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=develop)](https://console.aws.amazon.com/codesuite/codebuild/469205354006/projects/oops-internal-intel/history) | [![AWS-intel](https://codebuild.us-east-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiWG5KM0dQR3VBNWdVVUdJeURwUjhoOXNWYlBYdnpGR2prLzQ4RXk2ZlkrN2llZ2M4S05MeXdWcERMVFZ2RGIxbTRXZFMvTFM5cTRoamFzV3hYanlZVEVNPSIsIml2UGFyYW1ldGVyU3BlYyI6IjZJVnJYL1Z5VktTQWZzZUkiLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=develop)](https://us-east-1.console.aws.amazon.com/codesuite/codebuild/projects/automated-testing-oops-intel/history)
| CLANG | [![AWS-clang](https://codebuild.us-east-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiL3F2OHVEcmc0WitOTlY3Vm9LV0J3NHREZ0RicUZ6RDFXcFNlODhrRHN6a0RjNlF2TDI0VzM2S0VBKzMxR1BIREdYNmZrRWRUcm9xd0h2ZnhYNzVNc3NJPSIsIml2UGFyYW1ldGVyU3BlYyI6Iit1Y01tZSt4b1VtbGxKeDQiLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=develop)](https://console.aws.amazon.com/codesuite/codebuild/469205354006/projects/oops-internal-clang/history) | [![AWS-clang](https://codebuild.us-east-1.amazonaws.com/badges?uuid=eyJlbmNyeXB0ZWREYXRhIjoiNHdvREpKTnVOT2pneEx6cHpaMjlma3RsUmlLZFQrMmpDR0tNODBrMzA0Z0pFazFKMFloQVc0Q0xkeGRZbW9WSDJ4c2FWSFg0SkZWb1VXVmVQRk5rSTFJPSIsIml2UGFyYW1ldGVyU3BlYyI6InRQckQrWDdaY0l2RkZoWmUiLCJtYXRlcmlhbFNldFNlcmlhbCI6MX0%3D&branch=develop)](https://us-east-1.console.aws.amazon.com/codesuite/codebuild/projects/automated-testing-oops-clang/history)
| Code Coverage | [![codecov](https://codecov.io/gh/JCSDA/oops/branch/develop/graph/badge.svg?token=GdDzbEQedm)](https://codecov.io/gh/JCSDA/oops) |
64 changes: 64 additions & 0 deletions cmake/backtrace_deps.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# (C) Copyright 2021 UCAR.
#
# This software is licensed under the terms of the Apache Licence Version 2.0
# which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.

# This CMake file tests which stack trace provider libraries are available on
# a particular system. This is needed to set appropriate flags for
# boost stacktrace (used in src/oops/util/signal_trap.cc).

include(CheckCXXSourceCompiles)

# check_cxx_source_compiles uses global flags, unfortunately, so we need to
# save a bit of state to run the tests.

set(saved_libraries ${CMAKE_REQUIRED_LIBRARIES})
set(saved_defs ${CMAKE_REQUIRED_DEFINITIONS})

string(CONFIGURE [[
#include <iostream>
#include <boost/stacktrace.hpp>

int main() {
std::cout << boost::stacktrace::stacktrace() << std::endl;
return 0;
}
]] stacktracecode @ONLY)


# Different configs

list( APPEND OOPS_STACKTRACE_none_LIBS "")
set( OOPS_STACKTRACE_none_DEFS -DBOOST_STACKTRACE_USE_NOOP)

list( APPEND OOPS_STACKTRACE_default_LIBS -ldl)
set( OOPS_STACKTRACE_default_DEFS "")

list( APPEND OOPS_STACKTRACE_libbacktrace_LIBS -ldl -lbacktrace)
list( APPEND OOPS_STACKTRACE_libbacktrace_DEFS -DBOOST_STACKTRACE_USE_BACKTRACE)

list( APPEND OOPS_STACKTRACE_addr2line_LIBS -ldl -lbacktrace)
list( APPEND OOPS_STACKTRACE_addr2line_DEFS -DBOOST_STACKTRACE_USE_ADDR2LINE)
find_program(addr2line_PATH addr2line)
if(addr2line_PATH)
message( STATUS "Found addr2line at ${addr2line_PATH}." )
list(APPEND OOPS_STACKTRACE_addr2line_DEFS -DBOOST_STACKTRACE_ADDR2LINE_LOCATION=${addr2line_PATH})
endif()


# Test each configuration here.
foreach ( provider IN ITEMS libbacktrace addr2line default none )
list(APPEND CMAKE_REQUIRED_LIBRARIES ${OOPS_STACKTRACE_${provider}_LIBS})
list(APPEND CMAKE_REQUIRED_DEFINITIONS ${OOPS_STACKTRACE_${provider}_DEFS})
check_cxx_source_compiles("${stacktracecode}" OOPS_STACKTRACE_${provider}_AVAILABLE)
set(CMAKE_REQUIRED_LIBRARIES ${saved_libraries})
set(CMAKE_REQUIRED_DEFINITIONS ${saved_defs})
if ( OOPS_STACKTRACE_${provider}_AVAILABLE )
list( APPEND OOPS_STACKTRACE_AVAILABLE_PROVIDERS ${provider} )
endif()
endforeach()

message( STATUS "Boost stacktrace supports these providers: ${OOPS_STACKTRACE_AVAILABLE_PROVIDERS}.")
list(GET OOPS_STACKTRACE_AVAILABLE_PROVIDERS 0 OOPS_STACKTRACE_PROVIDER)
message( STATUS "Using this provider for stacktraces: ${OOPS_STACKTRACE_PROVIDER}.")

2 changes: 2 additions & 0 deletions cmake/oops_compiler_flags.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -49,3 +49,5 @@ elseif( CMAKE_CXX_COMPILER_ID MATCHES "Clang" )
else()
message( STATUS "C++ compiler with ID ${CMAKE_CXX_COMPILER_ID} will be used with CMake default options")
endif()


7 changes: 0 additions & 7 deletions docs/Doxyfile.in
Original file line number Diff line number Diff line change
Expand Up @@ -1127,13 +1127,6 @@ VERBATIM_HEADERS = YES

ALPHABETICAL_INDEX = YES

# The COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns in
# which the alphabetical index list will be split.
# Minimum value: 1, maximum value: 20, default value: 5.
# This tag requires that the tag ALPHABETICAL_INDEX is set to YES.

COLS_IN_ALPHA_INDEX = 5

# In case all classes in a project start with a common prefix, all classes will
# be put under the same header in the alphabetical index. The IGNORE_PREFIX tag
# can be used to specify a prefix (or a list of prefixes) that should be ignored
Expand Down
11 changes: 11 additions & 0 deletions docs/mainpage.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#pragma once

// This file defines what appears on the Main Page of the documentation
// generated by doxygen. The file contains no code, and does not appear
// in any cpp include statement.
//
/*!
* \mainpage Object Oriented Prediction System (OOPS)
*
* OOPS is the top level of JEDI that orchestrates the configuration and execution of applications. This is where DA applications are implemented. OOPS also includes the Lorenz 95 and Quasi-geostrophic toy models that can used to run many of the DA applications.
*/
32 changes: 16 additions & 16 deletions ewok/4dvar.yaml
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
cost function:
cost type: $(cost_function)
cost type: ${cost_function}
window begin: '{{window_begin}}'
window length: $(window_length)
window length: ${window_length}
geometry:
$(GEOMETRY)
${GEOMETRY}
model:
$(MODEL)
analysis variables: $(an_variables)
${MODEL}
analysis variables: ${an_variables}
background:
$(BACKGROUND)
${BACKGROUND}
background error:
$(BACKGROUND_ERROR)
${BACKGROUND_ERROR}
observations:
$(OBSERVATIONS)
${OBSERVATIONS}
constraints:
- $(JC)
- ${JC}
variational:
minimizer:
$(MINIMIZER)
${MINIMIZER}
iterations:
- ninner: $(ninner)
gradient norm reduction: $(reduc)
- ninner: ${ninner}
gradient norm reduction: ${reduc}
geometry:
$(GEOMETRY)
${GEOMETRY}
linear model:
$(LINEAR_MODEL)
${LINEAR_MODEL}
diagnostics:
departures: $(diag)
departures: ${diag}
final:
diagnostics:
departures: oman
prints:
frequency: PT3H
output:
$(AN_OUTPUT)
${AN_OUTPUT}
10 changes: 5 additions & 5 deletions ewok/forecast.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
forecast length: $(forecast_length)
forecast length: ${forecast_length}
initial condition:
$(FC_INPUT)
${FC_INPUT}
geometry:
$(GEOMETRY)
${GEOMETRY}
model:
$(MODEL)
${MODEL}
output:
$(FC_OUTPUT)
${FC_OUTPUT}
6 changes: 3 additions & 3 deletions ewok/hofx3d.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
geometry:
$(GEOMETRY)
${GEOMETRY}
state:
'{{BACKGROUND}}'
observations:
$(OBSERVATIONS)
${OBSERVATIONS}
window begin: '{{window_begin}}'
window length: $(window_length)
window length: ${window_length}

6 changes: 3 additions & 3 deletions ewok/hofx4d.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
geometry:
$(GEOMETRY)
${GEOMETRY}
states:
'{{BACKGROUND}}'
observations:
$(OBSERVATIONS)
${OBSERVATIONS}
window begin: '{{window_begin}}'
window length: $(window_length)
window length: ${window_length}

File renamed without changes.
2 changes: 1 addition & 1 deletion l95/ewok/defaults/an.yaml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
date: '{{current_cycle}}'
filename: '$(current_dir)/$(experiment).an.{{current_cycle}}'
filename: '$(run_dir)/$(experiment).an.{{current_cycle}}'
4 changes: 2 additions & 2 deletions l95/ewok/defaults/an_output.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
datadir: '$(current_dir)'
filename: '$(current_dir)/$(experiment).an.{{current_cycle}}'
datadir: $(run_dir)
filename: '$(run_dir)/$(experiment).an.{{current_cycle}}'
exp: $(experiment)
##first: '{% $(window_length) - $(window_offset) %}'
first: PT3H
Expand Down
2 changes: 1 addition & 1 deletion l95/ewok/defaults/bg.yaml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
date: '{{window_begin}}'
filename: '$(current_dir)/$(experiment).bg.{{current_cycle}}.l95'
filename: '$(run_dir)/$(experiment).bg.{{current_cycle}}.l95'
2 changes: 1 addition & 1 deletion l95/ewok/defaults/fc.yaml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
date: '{{current_cycle}}'
filename: $(current_dir)/$(experiment).fc.{{current_cycle}}.$(step)
filename: $(run_dir)/$(experiment).fc.{{current_cycle}}.$(step)
2 changes: 1 addition & 1 deletion l95/ewok/defaults/fc_output.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
datadir: $(current_dir)
datadir: $(run_dir)
date: '{{current_cycle}}'
exp: $(experiment)
frequency: PT3H
Expand Down
4 changes: 2 additions & 2 deletions l95/ewok/defaults/obs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ obs operator:
obs space:
source: truth
filetype: obt
obsdatain: '$(current_dir)/input.obs.{{window_begin}}.obt'
obsdataout: '$(current_dir)/$(experiment).obs.{{window_begin}}.obt'
obsdatain: '$(run_dir)/input.obs.{{window_begin}}.obt'
obsdataout: '$(run_dir)/$(experiment).obs.{{window_begin}}.obt'
obs error:
covariance model: diagonal
r2d2_type: l95_obs
Expand Down
2 changes: 2 additions & 0 deletions l95/src/executables/EDA.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
* which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.
*/

#include "lorenz95/instantiateL95ChangeVarFactory.h"
#include "lorenz95/instantiateLocalizationFactory.h"
#include "lorenz95/L95Traits.h"
#include "oops/runs/EnsembleApplication.h"
Expand All @@ -13,6 +14,7 @@

int main(int argc, char ** argv) {
oops::Run run(argc, argv);
lorenz95::instantiateL95ChangeVarFactory();
lorenz95::instantiateLocalizationFactory();
oops::EnsembleApplication<oops::Variational <lorenz95::L95Traits, lorenz95::L95ObsTraits> >eda;
return run.execute(eda);
Expand Down
2 changes: 2 additions & 0 deletions l95/src/executables/EnsHofX.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,15 @@
* does it submit to any jurisdiction.
*/

#include "lorenz95/instantiateL95ChangeVarFactory.h"
#include "lorenz95/L95Traits.h"
#include "oops/runs/EnsembleApplication.h"
#include "oops/runs/HofX4D.h"
#include "oops/runs/Run.h"

int main(int argc, char ** argv) {
oops::Run run(argc, argv);
lorenz95::instantiateL95ChangeVarFactory();
oops::EnsembleApplication<oops::HofX4D <lorenz95::L95Traits, lorenz95::L95ObsTraits> > enshofx;
return run.execute(enshofx);
}
2 changes: 2 additions & 0 deletions l95/src/executables/HofX.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@
* does it submit to any jurisdiction.
*/

#include "lorenz95/instantiateL95ChangeVarFactory.h"
#include "lorenz95/L95Traits.h"
#include "oops/runs/HofX4D.h"
#include "oops/runs/Run.h"

int main(int argc, char ** argv) {
oops::Run run(argc, argv);
lorenz95::instantiateL95ChangeVarFactory();
oops::HofX4D<lorenz95::L95Traits, lorenz95::L95ObsTraits> hofx;
return run.execute(hofx);
}
2 changes: 2 additions & 0 deletions l95/src/executables/LETKF.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@
* which can be obtained at http://www.apache.org/licenses/LICENSE-2.0.
*/

#include "lorenz95/instantiateL95ChangeVarFactory.h"
#include "lorenz95/L95Traits.h"
#include "oops/runs/LocalEnsembleDA.h"
#include "oops/runs/Run.h"

int main(int argc, char ** argv) {
oops::Run run(argc, argv);
lorenz95::instantiateL95ChangeVarFactory();
oops::LocalEnsembleDA<lorenz95::L95Traits, lorenz95::L95ObsTraits> letkf;
return run.execute(letkf);
}
2 changes: 2 additions & 0 deletions l95/src/executables/Main4dvar.cc
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,15 @@
* does it submit to any jurisdiction.
*/

#include "lorenz95/instantiateL95ChangeVarFactory.h"
#include "lorenz95/instantiateLocalizationFactory.h"
#include "lorenz95/L95Traits.h"
#include "oops/runs/Run.h"
#include "oops/runs/Variational.h"

int main(int argc, char ** argv) {
oops::Run run(argc, argv);
lorenz95::instantiateL95ChangeVarFactory();
lorenz95::instantiateLocalizationFactory();
oops::Variational<lorenz95::L95Traits, lorenz95::L95ObsTraits> var;
return run.execute(var);
Expand Down
7 changes: 3 additions & 4 deletions l95/src/lorenz95/BackgroundCheck.cc
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,12 @@
#include <vector>

#include "lorenz95/L95Traits.h"
#include "oops/interface/ObsFilter.h"

// -----------------------------------------------------------------------------
namespace lorenz95 {
// -----------------------------------------------------------------------------
static oops::FilterMaker<L95ObsTraits,
oops::ObsFilter<L95ObsTraits, BackgroundCheck> > makerBackgroundCheck_("Background Check");
static oops::interface::FilterMaker<L95ObsTraits, BackgroundCheck> makerBackgroundCheck_(
"Background Check");

// -----------------------------------------------------------------------------
BackgroundCheck::BackgroundCheck(const ObsTable & obsdb, const Parameters_ & parameters,
Expand All @@ -26,7 +25,7 @@ BackgroundCheck::BackgroundCheck(const ObsTable & obsdb, const Parameters_ & par
}

// -----------------------------------------------------------------------------
void BackgroundCheck::postFilter(const ObsVec1D & hofx, const ObsDiags1D &) const {
void BackgroundCheck::postFilter(const ObsVec1D & hofx, const ObsVec1D &, const ObsDiags1D &) {
std::vector<float> yobs;
obsdb_.getdb("ObsValue", yobs);
size_t inflate = 0;
Expand Down
Loading

0 comments on commit 9875a45

Please sign in to comment.