Skip to content

Commit

Permalink
Seasonal ma model Typo Fix (#1047)
Browse files Browse the repository at this point in the history
  • Loading branch information
smetam committed Dec 26, 2022
1 parent 2fd8fce commit 92e1ba4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion etna/models/deadline_ma.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def forecast(self, df: pd.DataFrame, prediction_size: int) -> np.ndarray:
history = df_history["target"]
history = history[history.index >= context_beginning]
if np.any(history.isnull()):
raise ValueError("There are NaNs in a forecast context, forecast method required context to filled!")
raise ValueError("There are NaNs in a forecast context, forecast method requires context to be filled!")

index = pd.date_range(start=context_beginning, end=df.index[-1], freq=self._freq)
result_template = np.append(history.values, np.zeros(prediction_size))
Expand Down
2 changes: 1 addition & 1 deletion etna/models/seasonal_ma.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ def forecast(self, df: pd.DataFrame, prediction_size: int) -> np.ndarray:

history = df["target"][-expected_length:-prediction_size]
if np.any(history.isnull()):
raise ValueError("There are NaNs in a forecast context, forecast method required context to filled!")
raise ValueError("There are NaNs in a forecast context, forecast method requires context to be filled!")

res = np.append(history, np.zeros(prediction_size))
for i in range(self.shift, len(res)):
Expand Down

1 comment on commit 92e1ba4

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.