Skip to content

Commit 80325fc

Browse files
authored
Use inventory links in docs (#260)
1 parent 1cc1741 commit 80325fc

5 files changed

Lines changed: 14 additions & 32 deletions

File tree

DifferentiationInterface/docs/Project.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4"
55
DifferentiationInterface = "a0c0ee7d-e4b9-4e03-894e-1c5f64a51d63"
66
Diffractor = "9f5e2b26-1114-432f-b630-d3fe2085c51c"
77
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
8+
DocumenterInterLinks = "d12716ef-a0f6-4df4-a9f1-a5a34e75c656"
89
DocumenterMermaid = "a078cd44-4d9c-4618-b545-3ab9d77f9177"
910
Enzyme = "7da242da-08ed-463a-9acd-ee780be4f1d9"
1011
FastDifferentiation = "eb9bf01b-bf85-4b60-bf87-ee5de06c00be"

DifferentiationInterface/docs/make.jl

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ using DifferentiationInterface
33
import DifferentiationInterface as DI
44
using Documenter
55
using DocumenterMermaid
6+
using DocumenterInterLinks
67

78
using ADTypes: ADTypes
89
using Diffractor: Diffractor
@@ -18,10 +19,15 @@ using Tapir: Tapir
1819
using Tracker: Tracker
1920
using Zygote: Zygote
2021

22+
links = InterLinks(
23+
"ADTypes" => "https://sciml.github.io/ADTypes.jl/stable/",
24+
"SparseConnectivityTracer" => "https://adrianhill.de/SparseConnectivityTracer.jl/stable/",
25+
)
26+
2127
cp(joinpath(@__DIR__, "..", "README.md"), joinpath(@__DIR__, "src", "index.md"); force=true)
2228

2329
makedocs(;
24-
modules=[DifferentiationInterface, ADTypes],
30+
modules=[DifferentiationInterface],
2531
authors="Guillaume Dalle, Adrian Hill",
2632
sitename="DifferentiationInterface.jl",
2733
format=Documenter.HTML(; assets=["assets/favicon.ico"]),
@@ -32,7 +38,7 @@ makedocs(;
3238
"Advanced" => ["design.md", "overloads.md"],
3339
],
3440
checkdocs=:exports,
35-
warnonly=[:missing_docs, :cross_references],
41+
plugins=[links],
3642
)
3743

3844
deploydocs(;

DifferentiationInterface/docs/src/backends.md

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -94,28 +94,3 @@ You can check this compatibility using [`check_twoarg`](@ref).
9494

9595
Only some backends are able to compute Hessians.
9696
You can use [`check_hessian`](@ref) to check this feature (beware that it will try to compute a small Hessian, so it is not instantaneous).
97-
98-
## API reference
99-
100-
!!! warning
101-
The following documentation has been borrowed from ADTypes.jl.
102-
Refer to the [ADTypes documentation](https://sciml.github.io/ADTypes.jl/stable/) for more information.
103-
104-
```@docs
105-
ADTypes
106-
ADTypes.AbstractADType
107-
AutoChainRules
108-
AutoDiffractor
109-
AutoEnzyme
110-
AutoFastDifferentiation
111-
AutoFiniteDiff
112-
AutoFiniteDifferences
113-
AutoForwardDiff
114-
AutoPolyesterForwardDiff
115-
AutoReverseDiff
116-
AutoSymbolics
117-
AutoTapir
118-
AutoTracker
119-
AutoZygote
120-
AutoSparse
121-
```

DifferentiationInterface/docs/src/overview.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ We offer two ways to perform second-order differentiation (for [`second_derivati
114114

115115
### Sparsity
116116

117-
[ADTypes.jl](https://github.com/SciML/ADTypes.jl) provides [`AutoSparse`](@ref) to accelerate the computation of sparse Jacobians and Hessians.
117+
[ADTypes.jl](https://github.com/SciML/ADTypes.jl) provides [`AutoSparse`](@extref ADTypes.AutoSparse) to accelerate the computation of sparse Jacobians and Hessians.
118118
Just wrap it around any backend, with an appropriate choice of sparsity detector and coloring algorithm, and call `jacobian` or `hessian`: the result will be sparse.
119119
See the [tutorial section on sparsity](@ref sparsity-tutorial) for details.
120120

DifferentiationInterface/docs/src/tutorial.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -145,12 +145,12 @@ To compute sparse Jacobians or Hessians, you need three ingredients (read [this
145145

146146
1. An underlying (dense) AD backend
147147
2. A sparsity pattern detector like:
148-
- `TracerSparsityDetector`, implemented by [SparseConnectivityTracer.jl](https://github.com/adrhill/SparseConnectivityTracer.jl) (our default recommendation)
149-
- [`DifferentiationInterface.SymbolicsSparsityDetector`](@ref), implemented by DifferentiationInterface.jl with [Symbolics.jl](https://github.com/JuliaSymbolics/Symbolics.jl) but not part of the public API (it will soon be [transferred](https://github.com/JuliaSymbolics/Symbolics.jl/pull/1134))
148+
- [`TracerSparsityDetector`](@extref SparseConnectivityTracer.TracerSparsityDetector), implemented by [SparseConnectivityTracer.jl](https://github.com/adrhill/SparseConnectivityTracer.jl) (our default recommendation)
149+
- [`SymbolicsSparsityDetector`](@ref DifferentiationInterface.SymbolicsSparsityDetector), implemented by DifferentiationInterface.jl with [Symbolics.jl](https://github.com/JuliaSymbolics/Symbolics.jl) but not exported nor part of the public API (it will soon be [transferred](https://github.com/JuliaSymbolics/Symbolics.jl/pull/1134))
150150
3. A coloring algorithm like:
151151
- [`GreedyColoringAlgorithm`](@ref), implemented by DifferentiationInterface.jl
152152

153-
ADTypes.jl v1.0 provides the [`AutoSparse`](@ref) wrapper to combine these three ingredients, and DifferentiationInterface.jl re-exports it.
153+
ADTypes.jl v1.0 provides the [`AutoSparse`](@extref ADTypes.AutoSparse) wrapper to combine these three ingredients, and DifferentiationInterface.jl re-exports it.
154154
Here's an example:
155155

156156
```@example tuto
@@ -181,4 +181,4 @@ After preparation, the sparse computation itself will be much faster than the de
181181

182182
!!! info
183183
The symbolic backends have built-in sparsity handling, so `AutoSparse(AutoSymbolics())` and `AutoSparse(AutoFastDifferentiation())` do not need additional configuration for detection or coloring.
184-
However they still benefit from preparation.
184+
However they still benefit from preparation.

0 commit comments

Comments
 (0)