Skip to content

Commit 32ddf54

Browse files
committed
Updated docs about it!
1 parent 29d9ef2 commit 32ddf54

File tree

5 files changed

+26
-7
lines changed

5 files changed

+26
-7
lines changed

docs/src/api.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,13 @@ getvariance
7171
getlengthscales
7272
```
7373

74+
## Prior Means
75+
76+
```@docs
77+
ZeroMean
78+
ConstantMean
79+
EmpiricalMean
80+
```
7481

7582
## Index
7683

docs/src/comparison.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,13 @@ AGP.jl stands for AugmentedGaussianProcesses.jl and GP.jl for GaussianProcesses.
4343
| Sum of kernel ||||
4444
| Product of kernels ||||
4545

46+
Note that the kernels will be defered to `MLKernels.jl` in the future.
47+
4648
# Other features
4749

4850
| Feature | AGP.jl | Stheno.jl | GP.jl |
4951
| --- | :-: | :-: | :-: |
5052
| Sparse GP ||||
51-
| Custom prior Mean | |||
53+
| Custom prior Mean | |||
5254
| Hyperparam. Opt. || ? | ? |
5355
| MultiOutput ||||

src/prior/constantmean.jl

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,13 @@ mutable struct ConstantMean{T<:Real} <: MeanPrior{T}
44
end
55

66
"""
7-
ConstantMean(c)
8-
Construct a constant mean with constant `c`
9-
Optionally give an optimizer `opt` (`Adam(α=0.01)` by default)
7+
**ConstantMean**
8+
```julia
9+
ConstantMean(c::T=1.0;opt::Optimizer=Adam(α=0.01))
10+
```
11+
12+
Construct a prior mean with constant `c`
13+
Optionally set an optimizer `opt` (`Adam(α=0.01)` by default)
1014
"""
1115
function ConstantMean(c::T=1.0;opt::Optimizer=Adam=0.01)) where {T<:Real}
1216
ConstantMean{T}(c,opt)

src/prior/empiricalmean.jl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@ mutable struct EmpiricalMean{T<:Real,V<:AbstractVector{<:Real}} <: MeanPrior{T}
44
end
55

66
"""
7-
EmpiricalMean(c)
7+
**EmpiricalMean**
8+
```julia`
9+
function EmpiricalMean(c::V=1.0;opt::Optimizer=Adam(α=0.01)) where {V<:AbstractVector{<:Real}}
10+
```
811
Construct a constant mean with values `c`
912
Optionally give an optimizer `opt` (`Adam(α=0.01)` by default)
1013
"""

src/prior/zeromean.jl

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,11 @@ mutable struct ZeroMean{T<:Real} <: MeanPrior{T}
22
end
33

44
"""
5-
ZeroMean(c)
6-
Construct a constant mean with constant 0
5+
ZeroMean
6+
```julia
7+
ZeroMean()
8+
```
9+
Construct a mean prior set to 0 and cannot be changed.
710
"""
811
function ZeroMean()
912
ZeroMean{Float64}()

0 commit comments

Comments
 (0)