Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multi level hydrofabric #615

Merged
merged 55 commits into from
Sep 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
a8e8eb8
Add trival multi layer hydrofabric sample.
donaldwj May 11, 2022
7b58b2f
Added Multlevel hydrofabric sample file.
donaldwj Jun 6, 2022
8629583
Added level variable to HY_Catchment. Added function to get and set c…
donaldwj Sep 28, 2022
412cf44
Add missing config file for a multilevel configuration testing.
donaldwj Sep 28, 2022
644e5a7
Updated level variables in multilevel hydrofabric test to match docum…
donaldwj Sep 28, 2022
cf1b3ba
Update non mpi code to handle hydro fabric multiple levels. Fix bug w…
donaldwj Oct 5, 2022
d81d997
Add support for hydrofabric levels.
donaldwj Nov 2, 2022
112ea55
Added runtime loop based on levels.
donaldwj Nov 2, 2022
1011c6d
saving for merge
donaldwj Feb 15, 2023
5b307d2
Fix for error in rebase.
donaldwj Feb 15, 2023
60d0144
Fix missing variable in HY_Features.hpp
donaldwj Feb 15, 2023
ca02835
added test file using google test replacing stand alone test.
donaldwj Mar 1, 2023
d69efd9
fix parsing of layer data from the formulation config file.
donaldwj Mar 1, 2023
8ba767d
Update test code for multilayer.
donaldwj Mar 1, 2023
69dc62e
Multilayer test added to CMake.
donaldwj Mar 1, 2023
5e50dde
Add datastructures for storing layer meta data and add those structur…
donaldwj Mar 3, 2023
f15f0f8
Inital multi time step muti level time loop
donaldwj Mar 7, 2023
0050ffd
Simulation_Time methods useful for multilayer
Mar 9, 2023
7ffc077
Change get_properties() of the FeatureBase class to return const or n…
donaldwj Mar 15, 2023
110c30d
add an internal map to the network class to track layer association.
donaldwj Mar 15, 2023
ce4a0d5
Add support for filtering a network based on level.
donaldwj Mar 17, 2023
13a4cbe
Create inital skelton of layer class.
donaldwj Mar 22, 2023
e6ea817
add <string> to simulation_time.hpp to fix VSCode issue
donaldwj Mar 22, 2023
eeb71de
Add missing changes to Layer.hpp
donaldwj Mar 29, 2023
5f943b1
moved logic to run catchments into layer class
donaldwj Apr 5, 2023
b5d0c5e
remove code that is no longer needed
donaldwj Apr 5, 2023
a92fe02
Fix typos
donaldwj Apr 5, 2023
ef9c291
update layer control for better depnd btwn layers
donaldwj Apr 5, 2023
f79c724
Add command to advance the current time stored in a layer.
donaldwj Apr 5, 2023
de6c260
add current_timestep_epoch_time to layers
donaldwj Apr 5, 2023
64d9ee2
commit changes to simulation time object to allow current time update.
donaldwj Apr 11, 2023
f097218
Fix to missing changes on pervious commit.
donaldwj Apr 11, 2023
11e5f61
Updates to fix testing on Multilayer
donaldwj Apr 20, 2023
f621088
Add current_time_index to SurfaceLayer to
donaldwj Apr 20, 2023
1ae6af5
Added more documentation to main time loop.
donaldwj Apr 27, 2023
2484962
Fix to HY_Features constructor
donaldwj Apr 27, 2023
4a0ab26
Add defualt layer creation to formulation manager
donaldwj Apr 28, 2023
7fe9637
fix bad units on defualt layer
donaldwj Apr 28, 2023
ec348fb
Correct units string for default layer.
donaldwj May 5, 2023
d367fa2
Fix merge error in HH_Features_MPI.hpp
donaldwj May 5, 2023
0330977
Required fixes for serial build
mattw-nws Jul 6, 2023
b9a8fd6
Create HY_Catchments with level metadata in single processor mode.
donaldwj Jul 14, 2023
9c7422d
Change HY_Features constructor to use the link hydrofabric version th…
donaldwj Jul 14, 2023
45da193
Apply spelling/grammar/clarity suggestions from code review
mattw-nws Jul 17, 2023
647021f
Resolving issues from pr review.
donaldwj Aug 3, 2023
d05b57c
Fixes after rebase, mainly to remove pdm03 dependency and `using name…
mattw-nws Aug 17, 2023
1bfa484
Missed precompiled header file from removed code
mattw-nws Aug 18, 2023
20edbe9
Correct typedef to ussing change that was not finished.
donaldwj Aug 23, 2023
88ed539
Correct primary time loop time objects was not being advanced.
donaldwj Aug 23, 2023
d8d58b2
More corrections to time object advancment.
donaldwj Aug 23, 2023
ed85017
Remove debuging code.
donaldwj Aug 23, 2023
f57eb73
Change call to get response in layer code to use the built in simulat…
donaldwj Aug 28, 2023
f4df6d2
Apply typographical suggestions from code review
mattw-nws Aug 28, 2023
0a524e7
Changes to make multilayer tests pass
mattw-nws Sep 19, 2023
8f162e3
Unifying terminology from "level" to "layer"
mattw-nws Sep 19, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
68 changes: 68 additions & 0 deletions data/bmi/fortran/noah-owp-modular-init-agg-1.namelist.input
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
&timing ! and output
dt = 1800.0 ! timestep [seconds]
startdate = "199801010630" ! UTC time start of simulation (YYYYMMDDhhmm)
enddate = "199901010630" ! UTC time end of simulation (YYYYMMDDhhmm)
forcing_filename = "data/config/bmi/sugar_creek/noah-mp-modular.dat" ! change filename to match your forcing data
output_filename = "data/config/bmi/sugar_creek/output.nc"
/

&parameters
parameter_dir = "extern/noah-owp-modular/noah-owp-modular/parameters/"
general_table = "GENPARM.TBL" ! general param tables and misc params
soil_table = "SOILPARM.TBL" ! soil param table
noahowp_table = "MPTABLE.TBL" ! noah-mp related param tables
soil_class_name = "STAS" ! soil class data source - "STAS" or "STAS-RUC"
veg_class_name = "MODIFIED_IGBP_MODIS_NOAH" ! vegetation class data source - "MODIFIED_IGBP_MODIS_NOAH" or "USGS"
/

&location ! for point runs, needs to be modified for gridded
lat = 40.01 ! latitude [degrees]
lon = -88.37 ! longitude [degrees]
terrain_slope = 0.0 ! terrain slope [degrees]
azimuth = 0.0 ! terrain azimuth or aspect [degrees clockwise from north]
/

&forcing
ZREF = 10.0 ! measurment height for wind speed
rain_snow_thresh = 1.0 ! rain-snow temperature threshold (degrees Celcius)
/

&model_options
precip_phase_option = 2
snow_albedo_option = 2 ! 1 = BATS, 2 = CLASS
dynamic_veg_option = 1
runoff_option = 8
drainage_option = 8
frozen_soil_option = 1
dynamic_vic_option = 1
radiative_transfer_option = 3
sfc_drag_coeff_option = 1
canopy_stom_resist_option = 1
crop_model_option = 0
snowsoil_temp_time_option = 3
soil_temp_boundary_option = 2
supercooled_water_option = 1
stomatal_resistance_option = 1
evap_srfc_resistance_option = 1
subsurface_option = 1
/

&structure
isltyp = 1 ! soil texture class
nsoil = 4 ! number of soil levels
nsnow = 3 ! number of snow levels
nveg = 20 ! number of vegetation types
vegtyp = 1 ! vegetation type modis
croptype = 0 ! crop type (0 = no crops)
sfctyp = 1 ! land surface type, 1:soil, 2:lake
soilcolor = 4 ! soil color code
/

&initial_values
dzsnso = 0.0, 0.0, 0.0, 0.1, 0.3, 0.6, 1.0 ! level thickness [m]
sice = 0.0, 0.0, 0.0, 0.0 ! initial soil ice profile [vol]
sh2o = 0.3, 0.3, 0.3, 0.3 ! initial soil liquid profile [vol]
zwt = -2.0 ! initial water table depth below surface [m]
/


11 changes: 11 additions & 0 deletions data/catchment_data_multilayer.geojson

Large diffs are not rendered by default.

131 changes: 131 additions & 0 deletions data/example_multilayer_realization_config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,131 @@
{
"global": {
"formulations": [
{
"name": "bmi_c++",
"params": {
"model_type_name": "test_bmi_cpp",
"library_file": "./extern/test_bmi_cpp/cmake_build/libtestbmicppmodel.so",
"init_config": "./data/bmi/c/test/test_bmi_c_config.ini",
"main_output_variable": "OUTPUT_VAR_2",
"variables_names_map" : {
"INPUT_VAR_2": "TMP_2maboveground",
"INPUT_VAR_1": "precip_rate"
},
"create_function": "bmi_model_create",
"destroy_function": "bmi_model_destroy",
"uses_forcing_file": false
}
}
],
"forcing": {
"file_pattern": ".*{{id}}.*.csv",
"path": "./data/forcing/"
}
},
"time": {
"start_time": "2015-12-01 00:00:00",
"end_time": "2015-12-30 23:00:00",
"output_interval": 3600
},
"catchments": {
"cat-27": {
"formulations": [
{
"name": "bmi_c++",
"params": {
"model_type_name": "test_bmi_cpp",
"library_file": "./extern/test_bmi_cpp/cmake_build/libtestbmicppmodel.so",
"init_config": "./data/bmi/c/test/test_bmi_c_config.ini",
"main_output_variable": "OUTPUT_VAR_2",
"variables_names_map" : {
"INPUT_VAR_2": "TMP_2maboveground",
"INPUT_VAR_1": "precip_rate"
},
"create_function": "bmi_model_create",
"destroy_function": "bmi_model_destroy",
"uses_forcing_file": false
}
}
],
"forcing": {
"path": "./data/forcing/cat-27_2015-12-01 00_00_00_2015-12-30 23_00_00.csv"
}
},
"cat-52": {
"formulations": [
{
"name": "bmi_c++",
"params": {
"model_type_name": "test_bmi_cpp",
"library_file": "./extern/test_bmi_cpp/cmake_build/libtestbmicppmodel.so",
"init_config": "./data/bmi/c/test/test_bmi_c_config.ini",
"main_output_variable": "OUTPUT_VAR_2",
"variables_names_map" : {
"INPUT_VAR_2": "TMP_2maboveground",
"INPUT_VAR_1": "precip_rate"
},
"create_function": "bmi_model_create",
"destroy_function": "bmi_model_destroy",
"uses_forcing_file": false
}
}
],
"forcing": {
"path": "./data/forcing/cat-52_2015-12-01 00_00_00_2015-12-30 23_00_00.csv"
}
},
"cat-67": {
"formulations": [
{
"name": "bmi_c++",
"params": {
"model_type_name": "test_bmi_cpp",
"library_file": "./extern/test_bmi_cpp/cmake_build/libtestbmicppmodel.so",
"init_config": "./data/bmi/c/test/test_bmi_c_config.ini",
"main_output_variable": "OUTPUT_VAR_2",
"variables_names_map" : {
"INPUT_VAR_2": "TMP_2maboveground",
"INPUT_VAR_1": "precip_rate"
},
"create_function": "bmi_model_create",
"destroy_function": "bmi_model_destroy",
"uses_forcing_file": false
}
}
],
"forcing": {
"path": "./data/forcing/cat-67_2015-12-01 00_00_00_2015-12-30 23_00_00.csv"
}
},
"agg-1": {
"formulations": [
{
"name": "bmi_fortran",
"params": {
"model_type_name": "bmi_fortran_noahowp",
"library_file": "./extern/noah-owp-modular/cmake_build/libsurfacebmi.so",
"forcing_file": "",
"init_config": "./data/bmi/fortran/noah-owp-modular-init-agg-1.namelist.input",
"allow_exceed_end_time": true,
"main_output_variable": "QINSUR",
"variables_names_map": {
"PRCPNONC": "atmosphere_water__liquid_equivalent_precipitation_rate",
"Q2": "atmosphere_air_water~vapor__relative_saturation",
"SFCTMP": "land_surface_air__temperature",
"UU": "land_surface_wind__x_component_of_velocity",
"VV": "land_surface_wind__y_component_of_velocity",
"LWDN": "land_surface_radiation~incoming~longwave__energy_flux",
"SOLDN": "land_surface_radiation~incoming~shortwave__energy_flux",
"SFCPRS": "land_surface_air__pressure"
},
"uses_forcing_file": false
}
}
],
"forcing": {
"path": "./data/forcing/agg-1_2015-12-01 00_00_00_2015-12-30 23_00_00.csv"
}
}
}
}
Loading