Skip to content

Commit 09837a1

Browse files
committed
MT test fix, slightly pertube PSE benchmark
1 parent b071640 commit 09837a1

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

test/downstream/test-PSE-benchmark.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ function PlantSimEngine.run!(m::ToyInternodeCrazyEmergence, models, status, mete
3636
add_organ!(status.node, sim_object, "+", "Leaf", 2, index=4)
3737
add_organ!(status.node, sim_object, "+", "Leaf", 2, index=5)
3838
status_new_internode.TT_cu_emergence = status.TT_cu
39-
elseif (length(MultiScaleTreeGraph.children(status.node)) >= 7 && length(MultiScaleTreeGraph.children(status.node)) < 31) && status.TT_cu - status.TT_cu_emergence >= m.TT_emergence
39+
elseif (length(MultiScaleTreeGraph.children(status.node)) >= 7 && length(MultiScaleTreeGraph.children(status.node)) < 30) && status.TT_cu - status.TT_cu_emergence >= m.TT_emergence
4040
add_organ!(status.node, sim_object, "+", "Leaf", 2, index=6)
4141
add_organ!(status.node, sim_object, "+", "Leaf", 2, index=7)
4242
add_organ!(status.node, sim_object, "+", "Leaf", 2, index=8)

test/test-performance.jl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,18 +17,18 @@ end
1717

1818
PlantSimEngine.TimeStepDependencyTrait(::Type{<:ToySleepModel}) = PlantSimEngine.IsTimeStepIndependent()
1919

20+
meteo_day = read_weather(joinpath(pkgdir(PlantSimEngine), "examples/meteo_day.csv"), duration=Day)
21+
nrows = nrow(meteo_day)
22+
23+
vc = [0 for i in 1:nrows]
24+
2025
models1 = ModelList(process1=ToySleepModel(), status=(a=vc,))
2126
models2 = ModelList(process1=ToySleepModel(), status=(a=vc,))
2227

2328
@testset begin "Check number of threads"
2429
nthr = Threads.nthreads()
2530
@test nthr == 4
2631

27-
meteo_day = read_weather(joinpath(pkgdir(PlantSimEngine), "examples/meteo_day.csv"), duration=Day)
28-
nrows = nrow(meteo_day)
29-
30-
vc = [0 for i in 1:nrows]
31-
3232
t_seq = @benchmark run!(models1, meteo_day; executor = SequentialEx())
3333
#t_seq = run!(models1, meteo_day; executor = SequentialEx())
3434
min_time_seq = minimum(t_seq).time

0 commit comments

Comments
 (0)