Merge #1062
1062: docstring ensure signature code formatting r=CarloLucibello a=visr by using a four space indent instead of two Fixes issues seen here:  Where the type signature has no code formatting, and a code block is introduced that throws off the rest of the formatting. Co-authored-by: Martijn Visser <mgvisser@gmail.com>
This commit is contained in:
commit
3cf131b8de
@ -28,7 +28,6 @@ function load()
|
|||||||
end
|
end
|
||||||
|
|
||||||
"""
|
"""
|
||||||
|
|
||||||
labels()
|
labels()
|
||||||
|
|
||||||
Get the labels of the iris dataset, a 150 element array of strings listing the
|
Get the labels of the iris dataset, a 150 element array of strings listing the
|
||||||
@ -53,7 +52,6 @@ function labels()
|
|||||||
end
|
end
|
||||||
|
|
||||||
"""
|
"""
|
||||||
|
|
||||||
features()
|
features()
|
||||||
|
|
||||||
Get the features of the iris dataset. This is a 4x150 matrix of Float64
|
Get the features of the iris dataset. This is a 4x150 matrix of Float64
|
||||||
|
@ -444,14 +444,13 @@ end
|
|||||||
InvDecay(γ)
|
InvDecay(γ)
|
||||||
|
|
||||||
Applies inverse time decay to an optimiser, i.e., the effective step size at iteration `n` is `eta / (1 + γ * n)` where `eta` is the initial step size. The wrapped optimiser's step size is not modified.
|
Applies inverse time decay to an optimiser, i.e., the effective step size at iteration `n` is `eta / (1 + γ * n)` where `eta` is the initial step size. The wrapped optimiser's step size is not modified.
|
||||||
```
|
|
||||||
|
|
||||||
## Parameters
|
## Parameters
|
||||||
- gamma (γ): Defaults to `0.001`
|
- gamma (γ): Defaults to `0.001`
|
||||||
|
|
||||||
## Example
|
## Example
|
||||||
```julia
|
```julia
|
||||||
Optimiser(InvDecay(..), Opt(..))
|
Optimiser(InvDecay(..), Opt(..))
|
||||||
```
|
```
|
||||||
"""
|
"""
|
||||||
mutable struct InvDecay
|
mutable struct InvDecay
|
||||||
@ -483,9 +482,8 @@ Discount the learning rate `eta` by a multiplicative factor `decay` every `decay
|
|||||||
## Example
|
## Example
|
||||||
To apply exponential decay to an optimiser:
|
To apply exponential decay to an optimiser:
|
||||||
```julia
|
```julia
|
||||||
Optimiser(ExpDecay(..), Opt(..))
|
Optimiser(ExpDecay(..), Opt(..))
|
||||||
|
opt = Optimiser(ExpDecay(), ADAM())
|
||||||
opt = Optimiser(ExpDecay(), ADAM())
|
|
||||||
```
|
```
|
||||||
"""
|
"""
|
||||||
mutable struct ExpDecay
|
mutable struct ExpDecay
|
||||||
|
Loading…
Reference in New Issue
Block a user