Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
141 commits
Select commit Hold shift + click to select a range
1d40976
[AutoDiff] Milestone C (incr 1): scalar-template the Internals state …
dfalster Jun 26, 2026
8423653
[AutoDiff] Milestone C (incr 2): scalar-template FF16_Pars (#472 scop…
dfalster Jun 26, 2026
f304ec6
[AutoDiff] Milestone C (incr 3): live FF16_Strategy -> AD trait gradi…
dfalster Jun 26, 2026
6060619
[AutoDiff] Milestone C (incr 4): exact AD growth-rate gradient (#537 …
dfalster Jun 26, 2026
1f377d0
[AutoDiff] Milestone C (incr 5): scalar-template Individual<T,E,S> (#…
dfalster Jun 26, 2026
e51f610
[AutoDiff] Milestone C (incr 6): exact growth-rate gradient as a stra…
dfalster Jun 26, 2026
acc26c2
[AutoDiff] Milestone C (incr 7): exact growth-rate gradient in a VARY…
dfalster Jun 26, 2026
38b7bef
[AutoDiff] CI fix: drop Rcpp::depends(BH) from AD tests (rely on -I B…
dfalster Jun 26, 2026
99150a2
[AutoDiff] Milestone C (incr 8): exact growth-rate gradient for DEEP-…
dfalster Jun 26, 2026
54e1205
[AutoDiff] Milestone C (incr 9): time-integrated trait gradient throu…
dfalster Jun 26, 2026
541c123
[AutoDiff] CI fix: skip strategy-including AD tests when BH include u…
dfalster Jun 26, 2026
2718650
[AutoDiff] Milestone C (incr 10): wire exact AD growth-rate gradient …
dfalster Jun 26, 2026
eb30a21
[AutoDiff] Milestone C (incr 11): expose growth_rate_gradient_exact t…
dfalster Jun 26, 2026
bb98533
[AutoDiff] Milestone C (incr 12): template Node<T,E,S=double> (#472 s…
dfalster Jun 26, 2026
df1d0a5
[AutoDiff] Milestone C (incr 13): template Species<T,E,S=double> (#47…
dfalster Jun 26, 2026
574cba7
[AutoDiff] Milestone C (incr 14): template Patch<T,E,S=double> (#472 …
dfalster Jun 26, 2026
d66fece
[AutoDiff] Milestone C (incr 15): template FF16 update_dependent_aux …
dfalster Jun 26, 2026
db64241
[AutoDiff] Milestone C (incr 16): scalar-templated FF16 demographic r…
dfalster Jun 26, 2026
fb37240
[AutoDiff] Milestone C (incr 17): full-state demographic trajectory k…
dfalster Jun 26, 2026
75e2de5
[AutoDiff] Milestone C (incr 18): ff16_replay_cohort -- two-pass SCM …
dfalster Jun 26, 2026
b7d068f
[AutoDiff] Milestone C (incr 19): active-query light in the cohort re…
dfalster Jun 26, 2026
4275d14
[AutoDiff] Milestone C (incr 20): resident self-shading light kernel …
dfalster Jun 26, 2026
7061894
[AutoDiff] Add runnable AD gradient examples script (#472 scope B)
dfalster Jun 26, 2026
2dfad5a
[AutoDiff] Document the templating plan + milestone process (#472 sco…
dfalster Jun 26, 2026
a81438c
[AutoDiff] guide + examples: cover the earlier groundwork and the one…
dfalster Jun 26, 2026
9b12899
[AutoDiff] examples: add the leaf-gradient precedent (forward-mode AD…
dfalster Jun 26, 2026
477fc36
[AutoDiff] CI-runnable test for the FF16 demographic rate gradient (#…
dfalster Jun 27, 2026
21ab9d8
[AutoDiff] Live-SCM two-pass emergent gradient: Cash-Karp RKCK replay…
dfalster Jun 27, 2026
626caef
[AutoDiff] Gradient of the real SCM offspring_production via shared C…
dfalster Jun 27, 2026
81ed80e
[AutoDiff] Deep-crown (default FF16 shading) live-SCM emergent gradie…
dfalster Jun 27, 2026
ff5f9b9
[AutoDiff] Deep-crown gradient of the real SCM offspring_production (…
dfalster Jun 27, 2026
bcee1d6
[AutoDiff] Whole trait-gradient of offspring_production in one revers…
dfalster Jun 27, 2026
0969a48
[AutoDiff] Differentiate the establishment (recruitment) filter (#472…
dfalster Jun 27, 2026
63c07c9
[AutoDiff] Self-shading (active-knot) gradient on the live resident s…
dfalster Jun 27, 2026
530376e
[AutoDiff] Time-integrated self-shading: per-step stand harvest + act…
dfalster Jun 27, 2026
c21e55a
[AutoDiff] Roadmap: Phases A-F incl. production API (C), fidelity (D)…
dfalster Jun 28, 2026
1cc375c
[AutoDiff] Phase C: offspring_production_gradient() -- compiled, CI-t…
dfalster Jun 28, 2026
1294b75
[AutoDiff] Phase D: differentiate height_0 (seedling size) via IFT in…
dfalster Jun 28, 2026
767b26c
[AutoDiff] Phase F1: TF24 leaf-trait gradient d(profit*)/d(vcmax_25) …
dfalster Jun 28, 2026
8a12af1
[AutoDiff] Phase F1: first TF24 net-production trait gradient, end-to…
dfalster Jun 28, 2026
ea92ce6
[AutoDiff] Phase F1-full: TF24 hydraulic leaf-trait gradients g1_TF24…
dfalster Jun 28, 2026
cedc461
[AutoDiff] Phase F1-full: TF24 vulnerability-shape gradients d(profit…
dfalster Jun 28, 2026
7556e01
[AutoDiff] Phase F1-full: TF24 photosynthesis leaf-trait gradients jm…
dfalster Jun 28, 2026
2248993
[AutoDiff] Phase F1-full: TF24 mass-cascade net gradients -- FF16-ide…
dfalster Jun 28, 2026
20174b8
[AutoDiff] Phase F1-full: committed scalar-templated TF24 demographic…
dfalster Jun 28, 2026
005b5fd
[AutoDiff] Phase F1-full: TF24 27-trait d(net)/d(trait) in ONE revers…
dfalster Jun 28, 2026
1cfd960
[AutoDiff] Phase F1-full: TF24 EMERGENT community gradient over the l…
dfalster Jun 28, 2026
9331fd3
[AutoDiff] Phase F1-full: TF24 emergent gradient of the REAL offsprin…
dfalster Jun 28, 2026
b6a39dc
[AutoDiff] Phase F1-full: TF24 emergent gradient for a CASCADE trait …
dfalster Jun 28, 2026
05f95cc
[AutoDiff] Phase F1-full: full 27-trait TF24 emergent gradient over t…
dfalster Jun 28, 2026
00d57fe
[AutoDiff] Phase F1-full: TF24 REVERSE-mode emergent gradient through…
dfalster Jun 28, 2026
802d9c6
[AutoDiff] guide: extend the FF16 AD story through the live-SCM emerg…
dfalster Jun 28, 2026
9ce68c6
[AutoDiff] guide: reconcile TF24 forward-note with the completed TF24…
dfalster Jun 28, 2026
1db61a7
[documentation] AutoDiff guide: full TF24 story + lessons + what's ne…
dfalster Jun 28, 2026
652c393
[AutoDiff] Phase F1-full: differentiate establishment in the TF24 eme…
dfalster Jun 28, 2026
30d16a9
[AutoDiff] Phase F1-full: full per-trait FD validation of the TF24 em…
dfalster Jun 29, 2026
bf3f523
[documentation] AutoDiff guide: mark establishment + full-FD validati…
dfalster Jun 29, 2026
ce5b339
[AutoDiff] Phase F1-full: committed tf24_offspring_production_gradien…
dfalster Jun 29, 2026
3c00dc5
[documentation] AutoDiff guide: note the committed tf24_offspring_pro…
dfalster Jun 29, 2026
4164fb2
[documentation] AutoDiff guide: fix stale What's-next (committed TF24…
dfalster Jun 29, 2026
db7ea69
[AutoDiff] Phase C/F1-full: multi-species emergent offspring_producti…
dfalster Jun 29, 2026
1cc2b92
[AutoDiff] [documentation] design: calibration-facing generic stand-g…
dfalster Jun 29, 2026
f98363d
[AutoDiff] [documentation] guide: multi-species done + calibration-fa…
dfalster Jun 29, 2026
bc2c007
[AutoDiff] scope-B step 1: generic (w,f) stand-gradient engine, FF16 …
dfalster Jun 29, 2026
5367b14
[AutoDiff] scope-B step 1: state x trait Jacobian escape hatch, FF16
dfalster Jun 29, 2026
14fb9d4
[AutoDiff] scope-B step 1: census metrics (LAI/biomass/size_moment) o…
dfalster Jun 29, 2026
3faac7c
[AutoDiff] scope-B step 1: CI test for the generic stand-gradient eng…
dfalster Jun 29, 2026
bddfdd7
[AutoDiff] [documentation] scope-B step 1: export the generic engine …
dfalster Jun 29, 2026
82d19ee
[AutoDiff] scope-B step 1: TF24 mirror of the generic stand-gradient …
dfalster Jun 29, 2026
894bf35
[AutoDiff] [documentation] guide: TF24 mirror done (offspring + escap…
dfalster Jun 29, 2026
31f2563
[AutoDiff] [speed] emergent gradient: ~30x faster harvest + per-cohor…
dfalster Jun 29, 2026
9507e1b
[AutoDiff] [documentation] scope the resident-gradient build (R0-R2 f…
dfalster Jun 29, 2026
6a6b1ef
[AutoDiff] resident-gradient R0-R1: FF16 freeze-geometry light feedba…
dfalster Jun 29, 2026
580ffd7
[AutoDiff] [documentation] resident-gradient: a_l1/a_l2 graft is COMP…
dfalster Jun 29, 2026
443f0df
[AutoDiff] [documentation] resident-gradient: course-correct to the c…
dfalster Jun 29, 2026
b8bad96
[AutoDiff] resident coupled-replay R0: harvest boundary new_node per …
dfalster Jun 29, 2026
5cb47e3
[AutoDiff] resident coupled-replay R0: whole-stand re-evolution + bas…
dfalster Jun 29, 2026
5c1caad
[AutoDiff] resident coupled-replay R1: reverse-sweep total gradient, …
dfalster Jun 29, 2026
64bcb0e
[AutoDiff] resident coupled-replay: wire into stand_gradient(feedback…
dfalster Jun 29, 2026
0a5d073
[AutoDiff] [documentation] guide: resident coupled-replay total gradi…
dfalster Jun 29, 2026
19da4e1
[AutoDiff] [documentation] seed: rounding out the FF16 coupled reside…
dfalster Jun 29, 2026
c408bab
[AutoDiff] FF16 resident gradient round-out: active birth-env, multi-…
dfalster Jun 29, 2026
b445822
[AutoDiff] [documentation] seed: FF16 grow_individual_to_size trait g…
dfalster Jun 29, 2026
723aa5a
[AutoDiff] [documentation] scope: TF24/TF24F stand-metric gradient fe…
dfalster Jun 29, 2026
1bb6029
[AutoDiff] FF16 grow_individual_to_size trait gradient (the last FF16…
dfalster Jun 29, 2026
deef682
[AutoDiff] TF24f frozen census R0 gate + exact-AD growth-rate gradien…
dfalster Jun 29, 2026
0e6a4a2
[AutoDiff] TF24f frozen census R1 gate: finite-difference d(census)/d…
dfalster Jun 29, 2026
babefb2
[AutoDiff] TF24f individual grow-to-size trait gradient (FD prototype…
dfalster Jun 29, 2026
b331b7d
[AutoDiff] TF24f resident (coupled) census trait gradient (FD prototy…
dfalster Jun 29, 2026
31e421d
[AutoDiff] [documentation] seed: TF24f reverse-mode AD census tape (t…
dfalster Jun 29, 2026
013000d
[AutoDiff] TF24f frozen census reverse-mode AD trait gradient (the re…
dfalster Jun 29, 2026
fcbfc60
[AutoDiff] Wire stand_gradient(strat="TF24f") to the frozen census AD…
dfalster Jun 29, 2026
ce6184c
[AutoDiff] [documentation] note step 3 (stand_gradient TF24f wiring) …
dfalster Jun 29, 2026
8037235
[AutoDiff] TF24f individual grow-to-size reverse-mode AD trait gradie…
dfalster Jun 30, 2026
905dd1e
[AutoDiff] [documentation] note step 4 (TF24f individual grow-to-size…
dfalster Jun 30, 2026
fa8bc4d
[AutoDiff] TF24f resident (coupled) census reverse-mode AD trait grad…
dfalster Jun 30, 2026
34515ca
[AutoDiff] TF24f offspring tape + cross-species coupled census AD gra…
dfalster Jun 30, 2026
b3b4e18
[AutoDiff] [documentation] refactor + optimize roadmap for the AD gra…
dfalster Jun 30, 2026
b91b3b1
[AutoDiff] [speed] Phase 1 safety net: gradient benchmark + AD-vs-AD …
dfalster Jun 30, 2026
d69014b
[AutoDiff] Phase 2a: native-env FF16 stand_gradient (kills the Rcpp::…
dfalster Jun 30, 2026
735d02c
[AutoDiff] Phase 2b: native-env TF24f census recon + gradient (+ key …
dfalster Jun 30, 2026
d51cc12
[AutoDiff] [documentation] record env-round-trip-faithful finding in …
dfalster Jun 30, 2026
db8ff3d
[AutoDiff] [documentation] timing-history: env-faithful finding + Pha…
dfalster Jun 30, 2026
cb8edf5
[AutoDiff] Phase 2: full native FF16 frozen harvest (no R ff16_harves…
dfalster Jun 30, 2026
af06619
[AutoDiff] [speed] Phase 2: full native TF24f census harvest (~28% fa…
dfalster Jun 30, 2026
63d456e
[AutoDiff] [speed] Phase 2: full native FF16 coupled (resident) harve…
dfalster Jun 30, 2026
b2fef89
[AutoDiff] [speed] Phase 2: full native TF24f coupled (resident) harv…
dfalster Jun 30, 2026
27aa111
[AutoDiff] Phase 3: shared gradient harvest helpers (birth_steps / re…
dfalster Jun 30, 2026
8e7329e
[AutoDiff] Phase 3: shared Yokozawa canopy_comp_at (FF16 + TF24f coup…
dfalster Jun 30, 2026
0e82a54
[AutoDiff] [documentation] Phase 3 outcome: safe dedup done; engines …
dfalster Jun 30, 2026
d4a864a
[AutoDiff] Phase 4: retire 10 superseded coupled/recon validation scr…
dfalster Jun 30, 2026
d0525ca
[AutoDiff] [bug] restore TF24f strategy guard on the native census en…
dfalster Jun 30, 2026
d994a91
[AutoDiff] [speed] native FF16 offspring_production_gradient (the inv…
dfalster Jun 30, 2026
c37c7dc
[AutoDiff] [speed] native TF24f + TF24 offspring (invasion/selection)…
dfalster Jun 30, 2026
0422a8e
[AutoDiff] [documentation] guide: consolidated "access points at a gl…
dfalster Jun 30, 2026
e076e10
[AutoDiff] consolidate offspring API: one strategy-agnostic offspring…
dfalster Jun 30, 2026
f43b10b
[AutoDiff] [documentation] guide: TF24f supports all metrics (same as…
dfalster Jun 30, 2026
2a2da7e
[AutoDiff] [documentation] guide: make the executable chunks self-con…
dfalster Jun 30, 2026
2156a42
[AutoDiff] [documentation] roadmap: record next-session jobs (handoff)
dfalster Jun 30, 2026
8153c92
[AutoDiff] [bug] coupled resident gradient: establish final-boundary …
dfalster Jun 30, 2026
279cae5
[AutoDiff] dead-code: remove 7 superseded _impl entries; bench uses p…
dfalster Jun 30, 2026
cde1758
[AutoDiff] [documentation] dead-code: remove the 21 sourceCpp ad_*.R …
dfalster Jun 30, 2026
bef2503
[AutoDiff] [speed] native FF16 multi-species coupled resident gradien…
dfalster Jun 30, 2026
b6830bb
[AutoDiff] [documentation] notes/: keep only the active roadmap; trim…
dfalster Jun 30, 2026
49a163a
[AutoDiff] [documentation] roadmap: handoff for session 3 (TF24f MS n…
dfalster Jun 30, 2026
e82841f
[AutoDiff] [speed] native TF24f multi-species coupled resident gradie…
dfalster Jun 30, 2026
47e24ba
[AutoDiff] [bug] TF24f single-species coupled gradient: gate the stif…
dfalster Jun 30, 2026
15590bf
[AutoDiff] [documentation] roadmap: record session 3 (A+B done, Job 3…
dfalster Jun 30, 2026
ac749bc
[AutoDiff] FF16 resident-coupled birth_rate gradient (the birth-rate …
dfalster Jun 30, 2026
7a39794
[AutoDiff] add make test-ad: run AD suite against installed DLL (no l…
dfalster Jun 30, 2026
8840d87
[AutoDiff] FF16 cross-species resident birth_rate gradient (the cross…
dfalster Jun 30, 2026
a7d3116
[AutoDiff] [documentation] roadmap: record FF16 cross-species birth_r…
dfalster Jun 30, 2026
51ca961
[AutoDiff] FF16 exact-AD d(net_reproduction_ratio)/d(birth_rate) -- t…
dfalster Jun 30, 2026
35b9151
[AutoDiff] [documentation] roadmap: record dR0/db (net_reproduction_r…
dfalster Jun 30, 2026
715836c
[AutoDiff] [documentation] guide: document the birth-rate axis (birth…
dfalster Jul 1, 2026
9f84df9
[AutoDiff] [documentation] guide: add the operational-envelope map (w…
dfalster Jul 1, 2026
af62064
[AutoDiff] [documentation] guide: define H / nsp / census / cross-spe…
dfalster Jul 1, 2026
0f111db
[AutoDiff] [documentation] guide: envelope table names the metric (ce…
dfalster Jul 1, 2026
23460bf
[AutoDiff] [documentation] roadmap: note TF24f coupled-gradient failu…
dfalster Jul 1, 2026
6d1b15c
Merge branch 'develop' into spike-ff16-scm-emergent
dfalster Jul 1, 2026
69083fa
[AutoDiff] [bug] fix cross-platform CI: skip same-machine AD fixture …
dfalster Jul 1, 2026
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
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ Meta
*.pdf
*.png
*.RDS
# ...except committed test fixtures (the AD-gradient regression baseline).
!tests/testthat/fixtures/gradient-baseline.rds

# Overstorey guide preview figures — regenerated when the guide builds in the
# Overstorey repo; not version-controlled here.
Expand Down
9 changes: 8 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,13 @@ roxygen:
test: all
Rscript -e 'library(methods); devtools::test()'

# AD tests self-skip under load_all (pkgload DLL). Run against the INSTALLED
# package: library(plant) loads the installed .so so the skip-gate passes;
# test_dir (not test_local) avoids re-loading via load_all; the namespace-parented
# env exposes unexported internals; parallel off so callr workers inherit the load.
test-ad: install
TESTTHAT_PARALLEL=false Rscript -e 'library(plant); e <- new.env(parent = asNamespace("plant")); testthat::test_dir("tests/testthat", filter = "ad", env = e)'

benchmark:
Rscript scripts/benchmark.R

Expand All @@ -49,4 +56,4 @@ check: build
clean:
rm -f src/*.o src/*.so src/*.o.tmp

.PHONY: all compile doc clean test attributes roxygen install build check
.PHONY: all compile doc clean test test-ad attributes roxygen install build check
5 changes: 5 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ export(TF24f_hyperpar)
export(Weibull_Disturbance_Regime)
export(add_mutant)
export(add_strategies)
export(birth_rate_gradient)
export(control)
export(control_accurate)
export(environment_type)
Expand All @@ -52,6 +53,7 @@ export(export_patch_state)
export(generate_strategy)
export(grow_individual_to_height)
export(grow_individual_to_size)
export(grow_individual_to_size_gradient)
export(grow_individual_to_time)
export(hyperpar)
export(integrate_over_size_distribution)
Expand All @@ -65,6 +67,7 @@ export(make_hyperpar)
export(make_initial_state)
export(mutant_parameters)
export(node_schedule_times_default)
export(offspring_production_gradient)
export(optimise_individual_rate_at_height_by_trait)
export(optimise_individual_rate_at_size_by_trait)
export(param_hyperpar)
Expand All @@ -79,6 +82,8 @@ export(seq_log)
export(seq_log_range)
export(seq_range)
export(set_initial_state)
export(stand_gradient)
export(stand_state_jacobian)
export(strategy_list)
export(tidy_individual)
export(trait_matrix)
Expand Down
564 changes: 564 additions & 0 deletions R/RcppExports.R

Large diffs are not rendered by default.

Loading
Loading