Lux.ComponentArray(p) throws an error that ComponentArray doesn't exist. To fix, I did Pkg add ComponentArrays, and deleted Lux., so the working line is then: pinit = Lux.ComponentArray(p)
Optimization.solve(..., ADAM(0.05),...) throws an error. To fix, I replaced ADAM(0.05) with Optimisers.ADAM(0.05).
After fixing these to bugs, the example ran for me. Not sure if this is best practices, but this is what worked for me.
Yeah these docs haven't built in awhile, and there's a few old things in there. It's one of the JuliaCon hackathon topics to revive these docs https://github.com/SciML/DiffEqFlux.jl/pull/848
On a fresh install of julia 1.9.2, I Pkg add Lux, DiffEqFlux, DifferentialEquations, Optimization, OptimizationOptimJL, Random, Plots
Then, I try to run the copy pastable code in the example here: https://docs.sciml.ai/DiffEqFlux/stable/examples/neural_ode/
There are two errors that occur:
After fixing these to bugs, the example ran for me. Not sure if this is best practices, but this is what worked for me.