Skip to content

Commit 28fcc61

Browse files
committed
Use Mooncake in BNN doc (#521)
1 parent aca574f commit 28fcc61

File tree

1 file changed

+2
-2
lines changed
  • tutorials/03-bayesian-neural-network

1 file changed

+2
-2
lines changed

tutorials/03-bayesian-neural-network/index.qmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ using Turing
1919
using FillArrays
2020
using Lux
2121
using Plots
22-
using Tracker
22+
import Mooncake
2323
using Functors
2424
2525
using LinearAlgebra
@@ -208,7 +208,7 @@ setprogress!(false)
208208
```{julia}
209209
# Perform inference.
210210
N = 2_000
211-
ch = sample(bayes_nn(reduce(hcat, xs), ts), NUTS(; adtype=AutoTracker()), N);
211+
ch = sample(bayes_nn(reduce(hcat, xs), ts), NUTS(; adtype=AutoMooncake(; config=nothing)), N);
212212
```
213213

214214
Now we extract the parameter samples from the sampled chain as `θ` (this is of size `5000 x 20` where `5000` is the number of iterations and `20` is the number of parameters).

0 commit comments

Comments
 (0)