Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
84 commits
Select commit Hold shift + click to select a range
a9a6582
doc: remove mentions of `TSMP_pdaf` in the documentation
jjokella Aug 22, 2023
e245c42
TSMP-PDAF: update introduction sentence
jjokella Aug 30, 2023
51861d7
Merge branch 'master' into master-jjokella
jjokella Sep 4, 2023
9ceb0a5
doc: performance remark about `da_interval`, `delt_obs` usage
jjokella Sep 6, 2023
079c6cc
doc: Updating the remark about maximizing `da_interval`
jjokella Sep 7, 2023
c37cb83
doc: Updating the remark about maximizing `da_interval`
jjokella Sep 7, 2023
b392fed
Merge branch 'master' into master-jjokella
jjokella Oct 4, 2023
05505cc
intf_DA: document observation input `gw_indicator`
jjokella Oct 5, 2023
6a4280e
intf_DA: remove `double *dat;` from `enkf_parflow.c`
jjokella Oct 5, 2023
4eb7598
typo fix
jjokella Oct 9, 2023
757517f
documentation update
jjokella Oct 10, 2023
70e019f
doc: better documentation of LEnKF command line input
jjokella Oct 10, 2023
af1e967
doc: more documentation and reference for `HCP_TRUNCATE_SAT`
jjokella Oct 10, 2023
539b3b2
Merge branch 'master-jjokella' into master-snow-da
jjokella Oct 12, 2023
e35aba3
Start of Implementation of snow depth assimilation. Includes enkfpf.p…
Oct 24, 2023
a2669be
Fixed the dz, zi, z calculations and adjusted the loop indexing to be…
Oct 25, 2023
7118edb
Added H2OSNO calculation based on prior snow depth and snow fraction.…
Oct 25, 2023
97b5a57
Fix snow layer iteration lower boundary of by 1 causing NaN errors.
Oct 27, 2023
f5c3bbb
Added: clmupdate_snow=2 in enkfpf.par now does SWE assimilation in th…
Nov 3, 2023
9f7bb3d
Latest version to assimilate SWE inlcuding clmupdate_snow_repartition…
Feb 28, 2024
78f945b
Added workaround for SEG11 fault in obs_op_pdaf for variable obs_inde…
Mar 27, 2024
eafedfa
dco: mention size limit for `obs_filename`
jjokella May 22, 2024
6d4cdb4
doc: update CLM5-PDAF build-commands
jjokella May 23, 2024
1377681
intf_oas3/clm5_0: update `NODENAME_REGEX` for JUWELS
jjokella May 23, 2024
9b2bd82
doc: updating CLM5 build and setup commands
jjokella May 23, 2024
fdfdaad
clm5 debug output of state vector, first implementation
jjokella May 23, 2024
0fe6142
bugfix: use `tstartcycle`
jjokella May 23, 2024
e10c31f
clm5 debug output of obs_index_p, first implementation
jjokella May 23, 2024
3f7eddb
debug output of `clm_statevec` to double precision
jjokella May 24, 2024
dd3ce49
Merge branch 'master' into lstrebel-master-snow-da
jjokella May 28, 2024
7d355e2
Merge branch 'lstrebel-master-snow-da' into master-jjokella
jjokella May 28, 2024
8c9cae9
Merge branch 'master' into lstrebel-master-snow-da
jjokella Jul 5, 2024
1839d3e
correct end subroutine names
jjokella Jul 5, 2024
0f5b80e
remove `clmupdate_texture.eq.2` conditions
jjokella Jul 5, 2024
2902a13
remove additional `newgridcell`
jjokella Jul 5, 2024
8c417df
add `clmt_printensemble` condition to debug output
jjokella Jul 5, 2024
042d43d
remove double code of debug output
jjokella Jul 5, 2024
788b595
remove `snlsno` specification statement from executable section
jjokella Jul 5, 2024
1ab01f6
copy out `average_swc_crp`
jjokella Jul 8, 2024
2206815
remove use-statement for `mod_parallel_model`
jjokella Jul 8, 2024
62934e9
Merge branch 'master' into jjokella-lstrebel-master-snow-da
jjokella Jul 11, 2024
264f210
some documentation
jjokella Jul 12, 2024
c99f6c4
remove outdated observation-fix
jjokella Jul 12, 2024
008f16b
style changes as in master-branch
jjokella Jul 12, 2024
4af0ccf
Merge branch 'master' into jjokella-lstrebel-master-snow-da
jjokella Jul 12, 2024
c97b42e
`clmstatevec_allcol` for SWE update
jjokella Jul 18, 2024
838a151
Merge branch 'master' into jjokella-lstrebel-master-snow-da
jjokella Aug 23, 2024
36aa082
Snow-DA: Warn also for zero SWE
jjokella Oct 30, 2024
988148a
Snow-DA: more warnings during update
jjokella Oct 30, 2024
47c6e93
Merge branch 'master' into jjokella-lstrebel-master-snow-da
jjokella Nov 8, 2024
66f9d86
Merge branch 'master' into dev-snow-da-up-to-date-old
jjokella Dec 2, 2024
c4a5bbc
Merge branch 'master' into dev-snow-da-up-to-date
jjokella Mar 4, 2025
f367d8a
Snow-DA for eCLM
jjokella Mar 4, 2025
cd9115a
Update enkf_clm_mod_5.F90 (#265)
lstrebel Mar 4, 2025
993156a
clmupdate_snow.eq.3: snow depth observations, h2osoi_ice in state
jjokella Mar 14, 2025
621b9c3
Merge branch 'master' into dev-snow-da
jjokella Mar 14, 2025
a5779e2
snow: update eclm
jjokella Mar 14, 2025
6a0c920
clmupdate_snow.eq.3: snow_depth and h2osno in state vector
jjokella Mar 14, 2025
d4d2003
Snow-DA: Re-introduce standard "point-obs" observation operator
jjokella Mar 17, 2025
b3be8a3
doc: Snow-DA inputs
jjokella Mar 17, 2025
5f1e7ac
doc: fix links
jjokella Mar 17, 2025
d2bb862
Snow-DA: Refactoring to prepare for PR into `master`
jjokella Mar 17, 2025
a2ff707
Snow-DA: Refactoring to prepare for PR into `master`
jjokella Mar 17, 2025
09854d4
Snow-DA: adapt dimension of `rsnow`, `nsnow`
jjokella Mar 17, 2025
f44b95b
Snow-DA: try to fix update conditions
jjokella Mar 17, 2025
19ac5e3
Snow-DA: debug output of `h2osoi_ice`
jjokella Mar 17, 2025
46dc8d0
Snow-DA: No layer variable used for setting `obs_index_p`
jjokella Mar 18, 2025
3f5e0c9
Snow-DA: Default for `CLM:update_snow_repartitioning` to `3`
jjokella Mar 18, 2025
abf9bda
Snow-DA: CLM3.5 variable declarations and error messages
jjokella Mar 18, 2025
865b20f
Snow-DA: bugfix repartitioning condition
jjokella Mar 21, 2025
5c91e44
Snow-DA: document experimental nature of repartitioning routine
jjokella Mar 21, 2025
797eb5e
Snow-DA: bugfix repartitioning condition II
jjokella Mar 21, 2025
0ea6e7c
Snow-DA: numerically better check for `rsnow.ne.0.0`
jjokella Mar 21, 2025
963b562
Snow-DA: repartitioning function only for `clmupdate_snow.eq.1,2`
jjokella Mar 21, 2025
a029d6d
Snow-DA: rename `incr_h2osno` to `incr_sno`
jjokella Mar 21, 2025
84273e1
Snow-DA: Refactor Snow-DA
jjokella Mar 27, 2025
c119c81
Snow-DA: Introduce `CLM:update_snow.eq.4`
jjokella Mar 27, 2025
42356c2
Snow-DA: `CLM:update_snow=5,6,7`
jjokella Mar 28, 2025
4b74c78
Snow-DA: Fix error stop condition
jjokella Mar 28, 2025
8c2e5e9
Snow-DA: No SWE/SD update for `CLM:update_snow >= 3`
jjokella Mar 28, 2025
7ffc8fd
Snow-DA: Remove difference-check for increment-updates
jjokella Mar 28, 2025
39568e6
Snow-DA: `CLM:update_snow=4..7`, check both SD and SWE
jjokella Mar 28, 2025
f40140f
Snow-DA: Rule out very small SD/SWE for updates
jjokella Mar 28, 2025
517fd75
Snow-DA: Bugfix for `CLM:update_snow=7`
jjokella Mar 29, 2025
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
8 changes: 7 additions & 1 deletion bldsva/intf_DA/pdaf/framework/init_dim_obs_f_pdaf.F90
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ SUBROUTINE init_dim_obs_f_pdaf(step, dim_obs_f)
USE enkf_clm_mod, only: domain_def_clm
USE enkf_clm_mod, only: get_interp_idx
use enkf_clm_mod, only: clmstatevec_allcol
use enkf_clm_mod, only: clmupdate_snow
!hcp end
#endif
#endif
Expand Down Expand Up @@ -966,7 +967,12 @@ SUBROUTINE init_dim_obs_f_pdaf(step, dim_obs_f)
end if
#endif
else
obs_index_p(cnt) = g-begg+1 + ((endg-begg+1) * (clmobs_layer(i)-1))
if(clmupdate_snow.ne.0) then
! Snow-DA: no layer in state vector variables
obs_index_p(cnt) = g-begg+1
else
obs_index_p(cnt) = g-begg+1 + ((endg-begg+1) * (clmobs_layer(i)-1))
end if
end if

!write(*,*) 'obs_index_p(',cnt,') is',obs_index_p(cnt)
Expand Down
8 changes: 7 additions & 1 deletion bldsva/intf_DA/pdaf/framework/init_dim_obs_pdaf.F90
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ SUBROUTINE init_dim_obs_pdaf(step, dim_obs_p)
USE enkf_clm_mod, only: domain_def_clm
USE enkf_clm_mod, only: get_interp_idx
use enkf_clm_mod, only: clmstatevec_allcol
use enkf_clm_mod, only: clmupdate_snow
!hcp end
#endif
#endif
Expand Down Expand Up @@ -959,7 +960,12 @@ SUBROUTINE init_dim_obs_pdaf(step, dim_obs_p)
end if
#endif
else
obs_index_p(cnt) = g-begg+1 + ((endg-begg+1) * (clmobs_layer(i)-1))
if(clmupdate_snow.ne.0) then
! Snow-DA: no layer in state vector variables
obs_index_p(cnt) = g-begg+1
else
obs_index_p(cnt) = g-begg+1 + ((endg-begg+1) * (clmobs_layer(i)-1))
end if
end if

!write(*,*) 'obs_index_p(',cnt,') is',obs_index_p(cnt)
Expand Down
38 changes: 38 additions & 0 deletions bldsva/intf_DA/pdaf/model/clm3_5/enkf_clm_mod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ module enkf_clm_mod
integer(c_int),bind(C,name="clmupdate_swc") :: clmupdate_swc
integer(c_int),bind(C,name="clmupdate_T") :: clmupdate_T ! by hcp
integer(c_int),bind(C,name="clmupdate_texture") :: clmupdate_texture
integer(c_int),bind(C,name="clmupdate_snow") :: clmupdate_snow
integer(c_int),bind(C,name="clmupdate_snow_repartitioning") :: clmupdate_snow_repartitioning
integer(c_int),bind(C,name="clmprint_swc") :: clmprint_swc
#endif
integer(c_int),bind(C,name="clmprint_et") :: clmprint_et
Expand Down Expand Up @@ -147,6 +149,25 @@ subroutine define_clm_statevec(mype)
error stop "Not implemented: clmupdate_texture.eq.2"
endif

! Snow assimilation
! Case 1: Assimilation of snow depth : allocated 1 per column in CLM5
! But observations and history file 1 per grid cell and therefore statevecsize 1 per grid cell
! Case 2: Assimilation of snow water equivalent same as above
if(clmupdate_snow.eq.1 .or. clmupdate_snow.eq.2) then
error stop "Not implemented: clmupdate_snow.eq.1 or clmupdate_snow.eq.1"
endif
! Case 3: Assimilation of snow depth: Snow depth and snow water
! equivalent in the state vector. Update of h2osoi_ice
if(clmupdate_snow.eq.3) then
error stop "Not implemented: clmupdate_snow.eq.3"
endif
! Case 4: Assimilation of snow depth: Snow depth and snow water
! equivalent in the state vector. Update of h2osoi_ice, h2osoi_liq
! and dz
if(clmupdate_snow.eq.4) then
error stop "Not implemented: clmupdate_snow.eq.4"
endif

!hcp LST DA
if(clmupdate_T.eq.1) then
clm_varsize = endg-begg+1
Expand Down Expand Up @@ -287,6 +308,14 @@ subroutine set_clm_statevec(tstartcycle, mype)
end do
endif

! Snow assimilation state vector
! Case 1: Snow depth
! Case 2: SWE
! Case 3: Snow depth + SWE
if(clmupdate_snow.ne.0) then
error stop "Not implemented: clmupdate_snow.ne.0"
endif

#ifdef PDAF_DEBUG
IF(clmt_printensemble == tstartcycle + 1 .OR. clmt_printensemble < 0) THEN
! TSMP-PDAF: For debug runs, output the state vector in files
Expand Down Expand Up @@ -534,6 +563,15 @@ subroutine update_clm(tstartcycle, mype) bind(C,name="update_clm")
call clm_texture_to_parameters
endif

! Snow assimilation:
! Case 1: Snow depth
! Case 2: Snow water equivalent
! Case 3: Snow depth (assimilated) and SWE (used for increment) in state vector
! Write updated snow variable back to CLM and then repartition snow and adjust related variables
if(clmupdate_snow.ne.0) then
error stop "Not implemented: clmupdate_snow.ne.0"
endif

end subroutine update_clm

subroutine clm_correct_texture()
Expand Down
Loading