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
Copy file name to clipboardExpand all lines: docs/src/userguide.md
+7-2Lines changed: 7 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ For example, a squared exponential kernel is created by
8
8
k =SqExponentialKernel()
9
9
```
10
10
11
-
!!! tip "How do I set the lengthscale?"
11
+
!!! tip "How do I set the lengthscale(s)?"
12
12
Instead of having lengthscale(s) for each kernel we use [`Transform`](@ref) objects which act on the inputs before passing them to the kernel. Note that the transforms such as [`ScaleTransform`](@ref) and [`ARDTransform`](@ref)_multiply_ the input by a scale factor, which corresponds to the _inverse_ of the lengthscale.
13
13
For example, a lengthscale of 0.5 is equivalent to premultiplying the input by 2.0, and you can create the corresponding kernel in either of the following equivalent ways:
14
14
```julia
@@ -19,7 +19,12 @@ For example, a squared exponential kernel is created by
19
19
```julia
20
20
k = with_lengthscale(SqExponentialKernel(), 0.5)
21
21
```
22
-
[`with_lengthscale`](@ref) also works with vector-valued lengthscales for ARD.
22
+
[`with_lengthscale`](@ref) also works with vector-valued lengthscales for multiple-dimensional inputs, and is equivalent to pre-composing with an [`ARDTransform`](@ref):
23
+
```julia
24
+
length_scales = [1.0, 2.0]
25
+
k = with_lengthscale(SqExponentialKernel(), length_scales)
26
+
k = SqExponentialKernel() ∘ ARDTransform(1 ./ length_scales)
27
+
```
23
28
Check the [Input Transforms](@ref input_transforms) page for more details.
0 commit comments