Skip to content
This repository has been archived by the owner on Jun 18, 2023. It is now read-only.

Commit

Permalink
Force X 2d for sklearn>=0.17.0
Browse files Browse the repository at this point in the history
  • Loading branch information
ceholden committed Dec 6, 2015
1 parent 8fbf596 commit 29ddd4c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions yatsm/algorithms/ccdc.py
Original file line number Diff line number Diff line change
Expand Up @@ -355,10 +355,10 @@ def train(self):
m = self.models[b]
_rmse = max(self.min_rmse, m.rmse)
start_resid[i] = (np.abs(self._Y[b, self.start] -
m.predict(self._X[self.start, :])) /
m.predict(self._X[self.start, :][None, :])) /
_rmse)
end_resid[i] = (np.abs(self._Y[b, self.here] -
m.predict(self._X[self.here, :])) /
m.predict(self._X[self.here, :][None, :])) /
_rmse)
slope_resid[i] = (np.abs(m.coef_[self.idx_slope] *
(self.here - self.start)) /
Expand Down Expand Up @@ -417,7 +417,7 @@ def monitor(self):
# Get test score for future observations
scores[i, i_b] = (
(self.Y[b, self.here + i] -
m.predict(self.X[self.here + i, :])) /
m.predict(self.X[self.here + i, :][None, :])) /
max(self.min_rmse, rmse[i_b])
)

Expand Down

0 comments on commit 29ddd4c

Please sign in to comment.