mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-07 11:02:38 +02:00
[cacher] now taking over the attributes from cached functions, such as docstring
This commit is contained in:
parent
9b3498a912
commit
4f89c25321
2 changed files with 11 additions and 2 deletions
|
|
@ -71,6 +71,13 @@ class Stationary(Kern):
|
|||
|
||||
@Cache_this(limit=5, ignore_args=())
|
||||
def K(self, X, X2=None):
|
||||
"""
|
||||
Kernel function applied on inputs X and X2.
|
||||
In the stationary case there is an inner function depending on the
|
||||
distances from X to X2, called r.
|
||||
|
||||
K(X, X2) = K_of_r((X-X2)**2)
|
||||
"""
|
||||
r = self._scaled_dist(X, X2)
|
||||
return self.K_of_r(r)
|
||||
|
||||
|
|
@ -311,7 +318,7 @@ class Matern52(Stationary):
|
|||
|
||||
class ExpQuad(Stationary):
|
||||
"""
|
||||
The Exponentiated quadratic covariance function.
|
||||
The Exponentiated quadratic covariance function.
|
||||
|
||||
.. math::
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue