Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into test-change-in-foreca…
Browse files Browse the repository at this point in the history
…sting

* origin/main:
  [BUG] Fix pandas `FutureWarning` for silent upcasting (sktime#5395)
  [BUG] CLASP logic: remove indexes from exclusion zone that are out of range (sktime#5459)
  [MNT] Split CI jobs per components with specific soft-dependencies (sktime#5304)
  [MNT] new CI workflow to test extras (sktime#5375)
  [MNT] xfail remote data loaders to silence sporadic failures (sktime#5461)
  [BUG] [MNT] removed two recently added hooks (sktime#5453)
  [MNT] bound `pycatch22<0.4.4` due to breaking change in patch version (sktime#5434)
  • Loading branch information
yarnabrina committed Oct 22, 2023
2 parents babd215 + f48b1f5 commit 9a4e7e3
Show file tree
Hide file tree
Showing 7 changed files with 78 additions and 66 deletions.
12 changes: 11 additions & 1 deletion .all-contributorsrc
Expand Up @@ -2423,7 +2423,7 @@
"contributions": [
"test"
]
}
},
{
"login": "xansh",
"name": "Ansh Kumar",
Expand All @@ -2433,5 +2433,15 @@
"doc"
]
},
{
"login": "tpvasconcelos",
"name": "Tomas P. de Vasconcelos",
"avatar_url": "https://avatars.githubusercontent.com/u/17701527?v=4",
"profile": "https://github.com/tpvasconcelos",
"contributions": [
"bug",
"code"
]
}
]
}
10 changes: 0 additions & 10 deletions .pre-commit-config.yaml
Expand Up @@ -76,13 +76,3 @@ repos:
hooks:
- id: shellcheck
name: shellcheck

- repo: https://github.com/tox-dev/pyproject-fmt
rev: 1.2.0
hooks:
- id: pyproject-fmt

- repo: https://github.com/abravalheri/validate-pyproject
rev: v0.15
hooks:
- id: validate-pyproject
105 changes: 54 additions & 51 deletions CONTRIBUTORS.md

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions pyproject.toml
Expand Up @@ -78,7 +78,7 @@ all_extras = [
'numba<0.59,>=0.53; python_version < "3.12"',
'pmdarima!=1.8.1,<3.0.0,>=1.8; python_version < "3.12"',
'prophet>=1.1; python_version < "3.12"',
"pycatch22",
"pycatch22<0.4.4",
"pykalman-bardo<0.10,>=0.9.7",
'pyod>=0.8; python_version < "3.11"',
"scikit-optimize",
Expand Down Expand Up @@ -114,7 +114,7 @@ all_extras_pandas2 = [
'numba<0.59,>=0.53; python_version < "3.12"',
'pmdarima!=1.8.1,<3.0.0,>=1.8; python_version < "3.12"',
'prophet>=1.1; python_version < "3.12"',
"pycatch22",
"pycatch22<0.4.4",
"pykalman-bardo<0.10,>=0.9.7",
'pyod>=0.8; python_version < "3.11"',
"scikit_posthocs>=0.6.5",
Expand Down Expand Up @@ -228,7 +228,7 @@ transformations = [
"holidays<0.35,>=0.29",
"mne<1.6,>=1.5",
'numba<0.59,>=0.53; python_version < "3.12"',
"pycatch22<0.5,>=0.4",
"pycatch22<0.4.4,>=0.4",
"pykalman-bardo<0.10,>=0.9.7",
"statsmodels<0.15,>=0.12.1",
'stumpy<1.13,>=1.5.1; python_version < "3.12"',
Expand Down
2 changes: 2 additions & 0 deletions sktime/datasets/tests/test_single_problem_loaders.py
Expand Up @@ -81,6 +81,7 @@ def test_load_numpy2d_multivariate_raises(loader):
X, y = loader(return_type="numpy2d")


@pytest.mark.xfail(reason="known sporadic failure of unknown cause, see #5460")
def test_load_UEA():
"""Test loading of a random subset of the UEA data, to check API."""
from sktime.datasets.tsc_dataset_names import multivariate, univariate
Expand Down Expand Up @@ -114,6 +115,7 @@ def test_load_forecastingdata():
assert metadata["contain_equal_length"] is False


@pytest.mark.xfail(reason="known sporadic failure of unknown cause, see #5462")
@pytest.mark.parametrize("name", TSF_SUBSAMPLE)
def test_check_link_downloadable(name):
"""Test dataset URL from forecasting.org is downloadable and exits."""
Expand Down
8 changes: 7 additions & 1 deletion sktime/transformations/series/_clasp_numba.py
Expand Up @@ -161,7 +161,13 @@ def _calc_knn_labels(knn_mask, split_idx, m):

# apply exclusion zone at split point
exclusion_zone = np.arange(split_idx - m, split_idx)
y_pred[exclusion_zone] = np.ones(m, dtype=np.int64)

# Remove indexes outside the range of y_pred
exclusion_zone = exclusion_zone[
(exclusion_zone >= -len(y_pred)) & (exclusion_zone < len(y_pred))
]

y_pred[exclusion_zone] = np.ones(len(exclusion_zone), dtype=np.int64)

return y_true, y_pred

Expand Down
1 change: 1 addition & 0 deletions sktime/transformations/series/summarize.py
Expand Up @@ -288,6 +288,7 @@ def _fit(self, X, y=None):
lags = func_dict["summarizer"] == "lag"
# Convert lags to default list notation with window_length 1
boost_lag = func_dict.loc[lags, "window"].apply(lambda x: [int(x), 1])
func_dict.loc[:, "window"] = func_dict["window"].astype("object")
func_dict.loc[lags, "window"] = boost_lag
self.truncate_start = func_dict["window"].apply(lambda x: x[0] + x[1] - 1).max()
self._func_dict = func_dict
Expand Down

0 comments on commit 9a4e7e3

Please sign in to comment.