-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sum of independent kernels #506
Comments
It sounds like a reasonable composite to add, especially since the alternative is pretty ugly using |
I am willing to do a PR, but I'll need some guidance since it is my first contribution. My naive approach would be to create a new Kernel (I like the idea of What are the requirements for a fully functional kernel that can be used in AbstractGPs? From the documentation I identify the following:
|
Thanks for contributing, I think you got it all together! I would not build a For the name we can still change it during the PR review time if some other arguments come up. |
I guess you can mainly copy
Not in an initial version IMO (and maybe not at all). I would add a separate type, similar to how we distinguish between |
One technical question. Is it always the case that if you compare the same input, the correlation should be 1? julia> k = SqExponentialKernel();
julia> x = 0;
julia> k(x,x)
1.0 Independently adding the kernels results into the following behavior: julia> k1 = SqExponentialKernel();
julia> k2 = ExponentialKernel();
julia> k = KernelTensorSum(k1, k2)
Tensor sum of 2 kernels:
Squared Exponential Kernel (metric = Distances.Euclidean(0.0))
Exponential Kernel (metric = Distances.Euclidean(0.0))
julia> x = zeros(2);
julia> k(x,x)
2.0
So, should the kernel take the For inputs |
No it does not have to be! |
Of course... Simply scaling a kernel would also mean |
Following this discourse discussion. Currently, there is no building block to sum independent Kernels, analog to
KernelTensorProduct
but with addition instead of multiplication:For inputs$x = (x_1,\dots,x_n)$ and $x' = (x_1',\dots,x_n')$ , the independent sum of kernels $k_1, \dots, k_n$ :
The text was updated successfully, but these errors were encountered: