Skip to content

Commit 2aa3c4f

Browse files
docs: add docstrings, restructure api manual
1 parent 11ef816 commit 2aa3c4f

File tree

23 files changed

+376
-263
lines changed

23 files changed

+376
-263
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ esn = ReservoirChain(
109109
StatefulLayer(ESNCell(input_size => res_size; init_reservoir=rand_sparse(; radius=1.2, sparsity=6/300))),
110110
NLAT2(),
111111
Readout(res_size => input_size)
112-
)
112+
) #or ESN(input_size, res_size, input_size; init_reservoir=rand_sparse(; radius=1.2, sparsity=6/300))
113113
```
114114

115115
The echo state network can now be trained and tested.

docs/Project.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ CellularAutomata = "878138dc-5b27-11ea-1a71-cb95d38d6b29"
33
DifferentialEquations = "0c46a032-eb83-5123-abaf-570d42b7fbaa"
44
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
55
DocumenterCitations = "daee34ce-89f3-4625-b898-19384cb65244"
6+
DocumenterInterLinks = "d12716ef-a0f6-4df4-a9f1-a5a34e75c656"
67
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
78
OrdinaryDiffEq = "1dea7af3-3e70-54e6-95c3-0bf5283fa5ed"
89
Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80"

docs/make.jl

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
using Documenter, DocumenterCitations, ReservoirComputing
22

3-
cp("./docs/Manifest.toml", "./docs/src/assets/Manifest.toml"; force = true)
4-
cp("./docs/Project.toml", "./docs/src/assets/Project.toml"; force = true)
3+
cp("./docs/Manifest.toml", "./docs/src/assets/Manifest.toml"; force=true)
4+
cp("./docs/Project.toml", "./docs/src/assets/Project.toml"; force=true)
55

66
ENV["PLOTS_TEST"] = "true"
77
ENV["GKSwstype"] = "100"
@@ -10,19 +10,23 @@ mathengine = Documenter.MathJax()
1010

1111
bib = CitationBibliography(
1212
joinpath(@__DIR__, "src", "refs.bib");
13-
style = :authoryear
13+
style=:authoryear
1414
)
1515

16-
makedocs(; modules = [ReservoirComputing],
17-
sitename = "ReservoirComputing.jl",
18-
clean = true, doctest = false, linkcheck = true,
19-
plugins = [bib],
20-
format = Documenter.HTML(;
16+
links = InterLinks(
17+
"Lux" => "https://lux.csail.mit.edu/stable/"
18+
)
19+
20+
makedocs(; modules=[ReservoirComputing],
21+
sitename="ReservoirComputing.jl",
22+
clean=true, doctest=false, linkcheck=true,
23+
plugins=[links, bib],
24+
format=Documenter.HTML(;
2125
mathengine,
22-
assets = ["assets/favicon.ico"],
23-
canonical = "https://docs.sciml.ai/ReservoirComputing/stable/"),
24-
pages = pages
26+
assets=["assets/favicon.ico"],
27+
canonical="https://docs.sciml.ai/ReservoirComputing/stable/"),
28+
pages=pages
2529
)
2630

27-
deploydocs(; repo = "github.com/SciML/ReservoirComputing.jl.git",
28-
push_preview = true)
31+
deploydocs(; repo="github.com/SciML/ReservoirComputing.jl.git",
32+
push_preview=true)

docs/pages.jl

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,24 @@
11
pages = [
22
"ReservoirComputing.jl" => "index.md",
33
"General Settings" => Any[
4-
"Changing Training Algorithms" => "general/different_training.md",
5-
"Altering States" => "general/states_variation.md",
6-
"Generative vs Predictive" => "general/predictive_generative.md"],
4+
"Changing Training Algorithms"=>"general/different_training.md",
5+
"Altering States"=>"general/states_variation.md",
6+
"Generative vs Predictive"=>"general/predictive_generative.md"],
77
"Echo State Network Tutorials" => Any[
8-
"Lorenz System Forecasting" => "esn_tutorials/lorenz_basic.md",
8+
"Lorenz System Forecasting"=>"esn_tutorials/lorenz_basic.md",
99
#"Mackey-Glass Forecasting on GPU" => "esn_tutorials/mackeyglass_basic.md",
10-
"Using Different Layers" => "esn_tutorials/change_layers.md",
11-
"Using Different Reservoir Drivers" => "esn_tutorials/different_drivers.md",
10+
"Using Different Layers"=>"esn_tutorials/change_layers.md",
11+
"Using Different Reservoir Drivers"=>"esn_tutorials/different_drivers.md",
1212
#"Using Different Training Methods" => "esn_tutorials/different_training.md",
13-
"Deep Echo State Networks" => "esn_tutorials/deep_esn.md",
14-
"Hybrid Echo State Networks" => "esn_tutorials/hybrid.md"],
13+
"Deep Echo State Networks"=>"esn_tutorials/deep_esn.md",
14+
"Hybrid Echo State Networks"=>"esn_tutorials/hybrid.md"],
1515
"Reservoir Computing with Cellular Automata" => "reca_tutorials/reca.md",
16-
"API Documentation" => Any["Training Algorithms" => "api/training.md",
17-
"States Modifications" => "api/states.md",
18-
"Prediction Types" => "api/predict.md",
19-
"Echo State Networks" => "api/esn.md",
20-
"ESN Initializers" => "api/inits.md",
21-
"ESN Drivers" => "api/esn_drivers.md",
22-
"ESN Variations" => "api/esn_variations.md",
23-
"ReCA" => "api/reca.md"] #"References" => "references.md"
16+
"API Documentation" => Any[
17+
"Layers"=>"api/layers.md",
18+
"Models"=>"api/models.md",
19+
"States"=>"api/states.md",
20+
"Train"=>"api/training.md",
21+
"Predict"=>"api/predict.md",
22+
"Initializers"=>"api/inits.md",
23+
"ReCA"=>"api/reca.md"] #"References" => "references.md"
2424
]

docs/src/api/esn.md

Lines changed: 0 additions & 17 deletions
This file was deleted.

docs/src/api/esn_drivers.md

Lines changed: 0 additions & 23 deletions
This file was deleted.

docs/src/api/esn_variations.md

Lines changed: 0 additions & 14 deletions
This file was deleted.

docs/src/api/layers.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Layers
2+
3+
## Base Layers
4+
```@doc
5+
ReservoirChain
6+
Readout
7+
Collect
8+
StatefulLayer
9+
```
10+
11+
## Echo State Networks
12+
13+
```@doc
14+
ESNCell
15+
```

docs/src/api/models.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Models
2+
3+
```@docs
4+
ESN
5+
DeepESN
6+
```

docs/src/api/predict.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
1-
# Prediction Types
1+
# Predict
22

33
```@docs
4-
Generative
5-
Predictive
4+
predict
65
```

0 commit comments

Comments
 (0)