Closed parikshit-pareek closed 1 year ago
Hi @parikshit-pareek , thanks for opening this issue!
Have you seen this section of the docs, or the input-types docs in KernelFunctions?
@willtebbutt I did saw and found x =ColVecs(X)
to use. However, not sure how to provide different length scales to Kernels i.e. ARD kernels. So, an example of large dimensional learning would be of help.
In case such an example not specifically available, I am happy to close the issue.
Ah I see. Yes, that's definitely possible.
The best option is the ARDTransform
defined in KernelFunctions
. You would do something like
inverse_length_scales = rand(5)
k = SEKernel() ∘ ARDTransform(inverse_length_scales)
x = ColVecs(randn(5, 13))
kernelmatrix(k, x)
and then plug that into your Stheno.jl model.
Would it have been helpful to have this advice in an FAQ section or something?
Also, it turns out that with_lengthscale
generalises to vectors of lengthscales (I had just forgotten that it's a thing!):
length_scales = rand(5)
k = with_lengthscale(SEKernel(), length_scales)
@parikshit-pareek the docs in KernelFunctions have been improved to make it more obvious how this would be done. Could you please let me know if you also find them sufficiently clear?
@willtebbutt Yes, its clear now.
Need to perform GP regression for a function y = g(x) where x is a vector of say 'D' length.