Skip to content

Commit

Permalink
Bring WrappedPeriodic signature in line with other Covariance funcs
Browse files Browse the repository at this point in the history
  • Loading branch information
Joseph Hall committed Jul 19, 2023
1 parent 539061c commit 5fe3fba
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions pymc/gp/cov.py
Original file line number Diff line number Diff line change
Expand Up @@ -933,19 +933,12 @@ class WrappedPeriodic(Covariance):
"""

def __init__(self, cov_func: Stationary, period):
super().__init__(cov_func.input_dim, cov_func.active_dims)
if not isinstance(cov_func, Stationary):
raise TypeError("Must inherit from the Stationary class")
self.cov_func = cov_func
self.period = period

Check warning on line 940 in pymc/gp/cov.py

View check run for this annotation

Codecov / codecov/patch

pymc/gp/cov.py#L936-L940

Added lines #L936 - L940 were not covered by tests

@property
def input_dim(self) -> int:
return self.cov_func.input_dim

@property
def active_dims(self) -> IntSequence:
return self.cov_func.active_dims

def full(self, X: TensorLike, Xs: Optional[TensorLike] = None) -> TensorVariable:
X, Xs = self._slice(X, Xs)
if Xs is None:
Expand Down

0 comments on commit 5fe3fba

Please sign in to comment.