Skip to content
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

Refactor KernelSum and KernelProduct? #68

Closed
devmotion opened this issue Mar 27, 2020 · 1 comment
Closed

Refactor KernelSum and KernelProduct? #68

devmotion opened this issue Mar 27, 2020 · 1 comment
Milestone

Comments

@devmotion
Copy link
Member

Copying from https://github.com/JuliaGaussianProcesses/KernelFunctions.jl/pull/66/files#r399342003:

I have been thinking about restricting the KernelSum and the KernelProduct to only two kernels since

  1. that would easily allow to obtain a concretely typed fields (I don't like the fact that both types use abstract fields),
  2. that would make it trivial to check if the metric of both kernels (if existent) is the same and hence allow to optimize computations in such cases by only evaluating the metric once.

I guess the same could be achieved by considering tuples of kernels and checking all their metrics but it doesn't feel as clean.

I'm just copying @theogf's response as well:

Regarding 1. : that's a good point, that would avoid this weird thing I have to do with sums of scaled kernels.
For 2. I am not sure how this would go in terms of performance. An issue would be very welcome to explore the options

@devmotion
Copy link
Member Author

Fixed by #146.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants