You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|`gradient` and `gradient!`|`ForwardDiffADGradient`/`GenericForwardDiffADGradient`|`ReverseDiffADGradient`/`GenericReverseDiffADGradient`|`ZygoteADGradient`|`EnzymeADGradient`| -- |
grad(nlp, nlp.meta.x0) # returns the gradient at x0 using `NewADGradient`
84
+
grad(nlp, nlp.meta.x0) # returns the gradient at x0 using `NewADGradient`
85
85
```
86
86
87
87
### Change backend
@@ -104,7 +104,7 @@ set_adbackend!(nlp, adback)
104
104
get_adbackend(nlp)
105
105
```
106
106
107
-
The alternative is to use ``set_adbackend!` and pass the new backends via `kwargs`. In the second approach, it is possible to pass either the type of the desired backend or an instance as shown below.
107
+
The alternative is to use `set_adbackend!` and pass the new backends via `kwargs`. In the second approach, it is possible to pass either the type of the desired backend or an instance as shown below.
Choosing another optimization problem with the optimized backend will compute sparse Jacobian and Hessian matrices.
75
-
76
58
```@example ex1
77
59
f(x) = (x[1] - 1)^2
78
60
T = Float64
@@ -92,4 +74,6 @@ x = rand(T, 2)
92
74
jac(nlp, x)
93
75
```
94
76
95
-
The package [`Symbolics.jl`](https://github.com/JuliaSymbolics/Symbolics.jl) is used to compute the sparsity pattern of the sparse matrix. The evaluation of the number of directional derivatives needed to evaluate the matrix is done by [`ColPack.jl`](https://github.com/michel2323/ColPack.jl).
77
+
The package [`SparseConnectivityTracer.jl`](https://github.com/adrhill/SparseConnectivityTracer.jl) is used to compute the sparsity pattern of Jacobians and Hessians.
78
+
The evaluation of the number of directional derivatives and the seeds needed to evaluate the compressed Jacobians and Hessians is done by [`ColPack.jl`](https://github.com/exanauts/ColPack.jl).
79
+
We acknowledge Guillaume Dalle (@gdalle), Adrian Hill (@adrhill), and Michel Schanen (@michel2323) for the development of these packages.
0 commit comments