Skip to content

Commit

Permalink
Refactor timestepping kinematic wave
Browse files Browse the repository at this point in the history
Now similar implementation as local inertial method: stable timestep is computed each sub timestep (or a fixed sub timestep is used) as part of a while loop (for each model timestep).
  • Loading branch information
vers-w committed Nov 20, 2024
1 parent bc1ba47 commit 3d9fc50
Show file tree
Hide file tree
Showing 9 changed files with 344 additions and 324 deletions.
6 changes: 3 additions & 3 deletions server/test/client.jl
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ end

@testset "model information functions" begin
@test request((fn = "get_component_name",)) == Dict("component_name" => "sbm")
@test request((fn = "get_input_item_count",)) == Dict("input_item_count" => 206)
@test request((fn = "get_output_item_count",)) == Dict("output_item_count" => 206)
@test request((fn = "get_input_item_count",)) == Dict("input_item_count" => 204)
@test request((fn = "get_output_item_count",)) == Dict("output_item_count" => 204)
to_check = [
"vertical.soil.parameters.nlayers",
"vertical.soil.parameters.theta_r",
Expand Down Expand Up @@ -81,7 +81,7 @@ vwc_1_size = 0
inds = [1, 5, 10],
)
@test request(msg)["value_at_indices"]
[2.198747900215207f0, 2.6880427720508515f0, 3.4848783702629564f0]
[2.1007361866518766, 2.5702292750107687, 3.2904803551115727]
msg =
(fn = "set_value", name = "vertical.soil.variables.zi", src = fill(300.0, zi_size))
@test request(msg) == Dict("status" => "OK")
Expand Down
2 changes: 1 addition & 1 deletion src/Wflow.jl
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ using Parameters: @with_kw
using Polyester: @batch
using ProgressLogging: @progress
using StaticArrays: SVector, pushfirst, setindex
using Statistics: mean, median, quantile!
using Statistics: mean, median, quantile!, quantile
using TerminalLoggers
using TOML: TOML

Expand Down
Loading

0 comments on commit 3d9fc50

Please sign in to comment.