Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #396 +/- ##
==========================================
+ Coverage 89.23% 89.27% +0.04%
==========================================
Files 52 52
Lines 1198 1212 +14
==========================================
+ Hits 1069 1082 +13
- Misses 129 130 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
| @doc raw""" | ||
| InverseMultiQuadricKernel(; α::Real=1.0, c::Real=1.0, metric=Euclidean()) | ||
|
|
||
| Inverse multiquadric kernel with respect to the `metric` with parameters `α` and `c`. |
There was a problem hiding this comment.
I don't think this sentence is needed, it does not bring anything
There was a problem hiding this comment.
Yes, I guess one has to know at least what the inverse multiquadric kernel is. However, the same problem exists in all other docstrings. I added this sentence only to be consistent with them.
| For inputs ``x, x'`` and metric ``d(\cdot, \cdot)``, the inverse multiquadric kernel with | ||
| parameters ``\alpha, c > 0`` is defined as | ||
| ```math | ||
| k(x, x'; \alpha, c) = \big(c + d(x, x')^2\big)^{-\alpha}. |
There was a problem hiding this comment.
Looking at this, it looks extremely similar to the polynomial kernel (except for -alpha < 0). Could this eventually be unified?
There was a problem hiding this comment.
IMO it is more similar to the rational quadratic kernel, therefore I put it in this file.
There was a problem hiding this comment.
As the tests show it is the same as scaling an RQ kernel with rescaled inputs. The construction is a bit annoying though, so the question is more: should it be a separate kernel or a function that constructs the corresponding RQ kernel?
This PR adds the inverse multiquadric kernel
with parameters
alpha, c > 0.In recent years, in particular in the ML community (possibly due to https://arxiv.org/abs/1711.01558) this kernel or some special cases (e.g. with
alpha = 1/2andc = 1: http://proceedings.mlr.press/v119/delbridge20a/delbridge20a.pdf) are called "inverse multiquadratic kernel". As far as I know, however, the traditional name is "inverse multiquadric kernel" (see e.g. Schölkopf and Smola's "Learning with Kernels").