Skip to content

Commit

Permalink
Update soft_dependencies.jl
Browse files Browse the repository at this point in the history
Authorize same process at different scales (e.g. same process simulated at the same scale but different organ symbol, e;g.: cumulated temperature at organ scale for leaves and internode
  • Loading branch information
VEZY committed Dec 2, 2023
1 parent 774a322 commit 6fca765
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/dependencies/soft_dependencies.jl
Original file line number Diff line number Diff line change
Expand Up @@ -400,7 +400,7 @@ function search_inputs_in_multiscale_output(process, organ, inputs, soft_dep_gra
for org in var_organ # e.g. org = "Soil"
# The variable is a multiscale variable:
for (proc_output, pairs_vars_output) in soft_dep_graphs[org][:outputs] # e.g. proc_output = :soil_water; pairs_vars_output = [:soil_water=>(:soil_water_content,)]
process == proc_output && error("Process $process declared at two scales: $organ and $org. A process can only be simulated at one scale.")
process == proc_output && @info "Process $process declared at two scales: $organ and $org. Are you sure this process has to be simulated at several scales?"
vars_output = flatten_vars(pairs_vars_output)
if var.var in vars_output
# The variable is found at another scale:
Expand Down

0 comments on commit 6fca765

Please sign in to comment.