Skip to content

Commit da5f986

Browse files
Automatic build\nPublished by build of: SciML/SciMLBenchmarks.jl@4a18bd4
1 parent 65a24c7 commit da5f986

2 files changed

Lines changed: 140 additions & 53 deletions

File tree

markdown/AutomaticDifferentiation/SimpleODEAD.md

Lines changed: 137 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -455,7 +455,7 @@ function diffeq_sen_l2(df, u0, tspan, p, t, alg = Tsit5();
455455
abstol = 1e-5, reltol = 1e-7,
456456
sensalg = InterpolatingAdjoint(), kwargs...)
457457
prob = ODEProblem(df, u0, tspan, p)
458-
sol = solve(prob, alg, sensealg = SensitivityADPassThrough(),
458+
sol = solve(prob, alg, sensealg = SciMLSensitivity.SensitivityADPassThrough(),
459459
abstol = abstol, reltol = reltol; kwargs...)
460460
dg(out, u, p, t, i) = (out.=u .- 1.0)
461461
adjoint_sensitivities(sol, alg; t, abstol = abstol, dgdu_discrete = dg,
@@ -466,7 +466,7 @@ function auto_sen_l2(
466466
f, u0, tspan, p, t, alg = Tsit5(); diffalg = ReverseDiff.gradient, kwargs...)
467467
test_f(p) = begin
468468
prob = ODEProblem{true, SciMLBase.FullSpecialize}(f, eltype(p).(u0), tspan, p)
469-
sol = solve(prob, alg; sensealg = SensitivityADPassThrough(), kwargs...)(t)
469+
sol = solve(prob, alg; sensealg = SciMLSensitivity.SensitivityADPassThrough(), kwargs...)(t)
470470
sum(sol.u) do x
471471
sum(z->(1-z)^2/2, x)
472472
end
@@ -570,12 +570,12 @@ end
570570

571571
```
572572
6-element Vector{Float64}:
573-
0.000100759
574-
4.627e-5
575-
0.000399487
576-
0.000647775
577-
0.000455057
578-
0.000242498
573+
9.908e-5
574+
4.635e-5
575+
0.000415257
576+
0.000646965
577+
0.000462966
578+
0.000238998
579579
```
580580

581581

@@ -628,24 +628,24 @@ end
628628
```
629629

630630
```
631-
5.489964 seconds (7.16 M allocations: 729.196 MiB, 3.88% gc time, 85.74%
631+
5.672426 seconds (7.16 M allocations: 729.230 MiB, 3.63% gc time, 86.62%
632632
compilation time)
633-
13.717323 seconds (13.42 M allocations: 915.981 MiB, 2.04% gc time, 89.66%
633+
14.451520 seconds (13.41 M allocations: 915.535 MiB, 2.97% gc time, 89.20%
634634
compilation time)
635-
161.127989 seconds (23.81 M allocations: 24.256 GiB, 2.58% gc time, 7.14% c
635+
161.759422 seconds (22.91 M allocations: 24.190 GiB, 2.23% gc time, 7.49% c
636636
ompilation time)
637-
171.357774 seconds (8.37 M allocations: 23.536 GiB, 1.97% gc time, 2.81% co
637+
164.991275 seconds (8.36 M allocations: 23.535 GiB, 1.43% gc time, 2.84% co
638638
mpilation time)
639-
128.592884 seconds (4.21 M allocations: 23.045 GiB, 2.41% gc time, 1.89% co
639+
125.299715 seconds (4.21 M allocations: 23.045 GiB, 1.93% gc time, 1.96% co
640640
mpilation time)
641641
642642
6-element Vector{Float64}:
643-
121.700331685
644-
1.421836372
645-
162.331793897
646-
139.367959523
647-
153.437449874
648-
0.660885146
643+
119.404342363
644+
1.423966599
645+
164.948309049
646+
142.86665872
647+
152.751051491
648+
0.659537272
649649
```
650650

651651

@@ -685,11 +685,11 @@ end
685685
```
686686
6-element Vector{Float64}:
687687
0.0
688-
0.021311427
689-
0.585078671
690-
0.649033497
691-
0.766433549
692-
0.012270771
688+
0.022042546
689+
0.574981624
690+
0.653482901
691+
0.602860608
692+
0.012306228
693693
```
694694

695695

@@ -733,11 +733,11 @@ end
733733
```
734734
6-element Vector{Float64}:
735735
0.0
736-
0.002003415
737-
0.007639365
738-
0.006116326
739-
0.008520468
740-
0.00833677
736+
0.001980265
737+
0.007708673
738+
0.005891347
739+
0.008529136
740+
0.008444917
741741
```
742742

743743

@@ -759,18 +759,18 @@ display(forward_timings)
759759
64 ⋯
760760
─────┼─────────────────────────────────────────────────────────────────────
761761
─────
762-
1 │ Compile-time CSA 0.000100759 121.7 0.0 0.0
762+
1 │ Compile-time CSA 9.908e-5 119.404 0.0 0.0
763763
764-
2 │ DSA 4.627e-5 1.42184 0.0213114 0.002
765-
003
766-
3 │ CSA user-Jacobian 0.000399487 162.332 0.585079 0.007
767-
639
768-
4 │ AD-Jacobian 0.000647775 139.368 0.649033 0.006
769-
116
770-
5 │ AD-Jv seeding 0.000455057 153.437 0.766434 0.008
771-
520
772-
6 │ Numerical Differentiation 0.000242498 0.660885 0.0122708 0.008
773-
336
764+
2 │ DSA 4.635e-5 1.42397 0.0220425 0.001
765+
980
766+
3 │ CSA user-Jacobian 0.000415257 164.948 0.574982 0.007
767+
708
768+
4 │ AD-Jacobian 0.000646965 142.867 0.653483 0.005
769+
891
770+
5 │ AD-Jv seeding 0.000462966 152.751 0.602861 0.008
771+
529
772+
6 │ Numerical Differentiation 0.000238998 0.659537 0.0123062 0.008
773+
444
774774
1 column om
775775
itted
776776
```
@@ -819,7 +819,27 @@ end
819819
```
820820

821821
```
822-
Error: UndefVarError: `SensitivityADPassThrough` not defined
822+
3.552873 seconds (4.87 M allocations: 330.343 MiB, 3.78% gc time, 99.97%
823+
compilation time)
824+
5.224977 seconds (6.02 M allocations: 410.323 MiB, 1.45% gc time, 99.84%
825+
compilation time)
826+
79.164362 seconds (85.55 M allocations: 5.796 GiB, 2.73% gc time, 99.90% c
827+
ompilation time)
828+
0.631780 seconds (629.03 k allocations: 43.311 MiB, 99.27% compilation ti
829+
me)
830+
12-element Vector{Float64}:
831+
0.000116379
832+
0.005383269
833+
0.000589735
834+
0.001112532
835+
0.000860373
836+
0.001500329
837+
0.002923628
838+
0.004275179
839+
0.001074902
840+
0.001629078
841+
0.001092652
842+
0.002919679
823843
```
824844

825845

@@ -869,7 +889,25 @@ end
869889
```
870890

871891
```
872-
Error: UndefVarError: `SensitivityADPassThrough` not defined
892+
14.008573 seconds (12.36 M allocations: 864.436 MiB, 2.47% gc time, 89.26%
893+
compilation time)
894+
109.872843 seconds (55.53 M allocations: 4.247 GiB, 1.05% gc time, 86.24% c
895+
ompilation time)
896+
4.410434 seconds (2.62 M allocations: 661.947 MiB, 3.23% gc time, 55.92%
897+
compilation time)
898+
12-element Vector{Float64}:
899+
1.426976066
900+
NaN
901+
4.228929733
902+
2.19601197
903+
0.609090635
904+
0.245021316
905+
0.37500611
906+
0.167354125
907+
NaN
908+
NaN
909+
NaN
910+
1.821994714
873911
```
874912

875913

@@ -922,7 +960,25 @@ end
922960
```
923961

924962
```
925-
Error: UndefVarError: `SensitivityADPassThrough` not defined
963+
16.530452 seconds (13.24 M allocations: 871.309 MiB, 2.07% gc time, 99.87%
964+
compilation time)
965+
78.483841 seconds (52.82 M allocations: 3.846 GiB, 1.35% gc time, 90.54% c
966+
ompilation time)
967+
2.307349 seconds (2.14 M allocations: 150.700 MiB, 98.93% compilation tim
968+
e)
969+
12-element Vector{Float64}:
970+
0.019041353
971+
NaN
972+
1.066901612
973+
1.662611386
974+
0.364254968
975+
0.2945228
976+
0.795662524
977+
0.652061647
978+
NaN
979+
NaN
980+
NaN
981+
0.023790578
926982
```
927983

928984

@@ -975,7 +1031,27 @@ end
9751031
```
9761032

9771033
```
978-
Error: UndefVarError: `SensitivityADPassThrough` not defined
1034+
3.721435 seconds (4.70 M allocations: 319.270 MiB, 2.12% gc time, 99.88%
1035+
compilation time)
1036+
3.784623 seconds (5.65 M allocations: 318.446 MiB, 95.66% compilation tim
1037+
e)
1038+
34.411373 seconds (37.82 M allocations: 2.516 GiB, 2.50% gc time, 99.73% c
1039+
ompilation time)
1040+
0.255944 seconds (369.29 k allocations: 29.314 MiB, 91.80% compilation ti
1041+
me)
1042+
12-element Vector{Float64}:
1043+
0.00275472
1044+
0.147475379
1045+
0.007774834
1046+
0.005835227
1047+
0.002892819
1048+
0.007283558
1049+
0.00978936
1050+
0.013056866
1051+
NaN
1052+
NaN
1053+
NaN
1054+
0.017430845
9791055
```
9801056

9811057

@@ -990,13 +1066,24 @@ adjoint_timings = DataFrame(
9901066
methods = adjoint_methods, LV = adjoint_lv, Bruss = adjoint_bruss,
9911067
Pollution = adjoint_pollution, PKPD = adjoint_pkpd)
9921068
Markdown.parse(PrettyTables.pretty_table(
993-
String, adjoint_timings; backend = :markdown))
1069+
String, adjoint_timings; backend = :markdown, column_labels = names(adjoint_timings)))
9941070
```
9951071

996-
```
997-
Error: UndefVarError: `adjoint_lv` not defined
998-
```
9991072

1073+
| **methods** | **LV** | **Bruss** | **Pollution** | **PKPD** |
1074+
| -----------------------------:| -----------:| ---------:| -------------:| ----------:|
1075+
| ForwardDiff | 0.000116379 | 1.42698 | 0.0190414 | 0.00275472 |
1076+
| ReverseDiff | 0.00538327 | NaN | NaN | 0.147475 |
1077+
| InterpolatingAdjoint User Jac | 0.000589735 | 4.22893 | 1.0669 | 0.00777483 |
1078+
| InterpolatingAdjoint AD Jac | 0.00111253 | 2.19601 | 1.66261 | 0.00583523 |
1079+
| InterpolatingAdjoint v'J | 0.000860373 | 0.609091 | 0.364255 | 0.00289282 |
1080+
| QuadratureAdjoint User Jac | 0.00150033 | 0.245021 | 0.294523 | 0.00728356 |
1081+
| QuadratureAdjoint AD Jac | 0.00292363 | 0.375006 | 0.795663 | 0.00978936 |
1082+
| QuadratureAdjoint v'J | 0.00427518 | 0.167354 | 0.652062 | 0.0130569 |
1083+
| BacksolveAdjoint User Jac | 0.0010749 | NaN | NaN | NaN |
1084+
| BacksolveAdjoint AD Jac | 0.00162908 | NaN | NaN | NaN |
1085+
| BacksolveAdjoint v'J | 0.00109265 | NaN | NaN | NaN |
1086+
| Numerical Differentiation | 0.00291968 | 1.82199 | 0.0237906 | 0.0174308 |
10001087

10011088

10021089

@@ -1028,7 +1115,7 @@ Platform Info:
10281115
WORD_SIZE: 64
10291116
LIBM: libopenlibm
10301117
LLVM: libLLVM-15.0.7 (ORCJIT, znver2)
1031-
Threads: 1 default, 0 interactive, 1 GC (on 128 virtual cores)
1118+
Threads: 128 default, 0 interactive, 64 GC (on 128 virtual cores)
10321119
Environment:
10331120
JULIA_CPU_THREADS = 128
10341121
JULIA_DEPOT_PATH = /cache/julia-buildkite-plugin/depots/5b300254-1738-4989-ae0a-f4d2d937f953:
@@ -1327,7 +1414,7 @@ Status `/cache/build/exclusive-amdci1-0/julialang/scimlbenchmarks-dot-jl/benchma
13271414
[2efcf032] SymbolicIndexingInterface v0.3.46
13281415
[19f23fe9] SymbolicLimits v1.1.0
13291416
⌃ [d1185830] SymbolicUtils v4.18.5
1330-
[0c5d862f] Symbolics v7.15.3
1417+
[0c5d862f] Symbolics v7.15.3
13311418
[9ce81f87] TableMetadataTools v0.1.0
13321419
[3783bdb8] TableTraits v1.0.1
13331420
[bd369af6] Tables v1.12.1

script/AutomaticDifferentiation/SimpleODEAD.jl

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,7 @@ function diffeq_sen_l2(df, u0, tspan, p, t, alg = Tsit5();
380380
abstol = 1e-5, reltol = 1e-7,
381381
sensalg = InterpolatingAdjoint(), kwargs...)
382382
prob = ODEProblem(df, u0, tspan, p)
383-
sol = solve(prob, alg, sensealg = SensitivityADPassThrough(),
383+
sol = solve(prob, alg, sensealg = SciMLSensitivity.SensitivityADPassThrough(),
384384
abstol = abstol, reltol = reltol; kwargs...)
385385
dg(out, u, p, t, i) = (out.=u .- 1.0)
386386
adjoint_sensitivities(sol, alg; t, abstol = abstol, dgdu_discrete = dg,
@@ -391,7 +391,7 @@ function auto_sen_l2(
391391
f, u0, tspan, p, t, alg = Tsit5(); diffalg = ReverseDiff.gradient, kwargs...)
392392
test_f(p) = begin
393393
prob = ODEProblem{true, SciMLBase.FullSpecialize}(f, eltype(p).(u0), tspan, p)
394-
sol = solve(prob, alg; sensealg = SensitivityADPassThrough(), kwargs...)(t)
394+
sol = solve(prob, alg; sensealg = SciMLSensitivity.SensitivityADPassThrough(), kwargs...)(t)
395395
sum(sol.u) do x
396396
sum(z->(1-z)^2/2, x)
397397
end
@@ -742,7 +742,7 @@ adjoint_timings = DataFrame(
742742
methods = adjoint_methods, LV = adjoint_lv, Bruss = adjoint_bruss,
743743
Pollution = adjoint_pollution, PKPD = adjoint_pkpd)
744744
Markdown.parse(PrettyTables.pretty_table(
745-
String, adjoint_timings; backend = :markdown))
745+
String, adjoint_timings; backend = :markdown, column_labels = names(adjoint_timings)))
746746

747747

748748
using SciMLBenchmarks

0 commit comments

Comments
 (0)