Skip to content

Commit b231dba

Browse files
committed
FIX: Green?
1 parent 035726e commit b231dba

File tree

3 files changed

+11
-6
lines changed

3 files changed

+11
-6
lines changed

mne/decoding/base.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,11 @@ def __sklearn_tags__(self):
8585
"""Get sklearn tags."""
8686
from sklearn.utils import get_tags # added in 1.6
8787

88-
return get_tags(self.model)
88+
# fit method below does not allow sparse data via check_data, we could
89+
# eventually make it smarter if we had to
90+
tags = get_tags(self.model)
91+
tags.input_tags.sparse = False
92+
return tags
8993

9094
def __getattr__(self, attr):
9195
"""Wrap to model for some attributes."""

mne/decoding/transformer.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ def inverse_transform(self, epochs_data):
238238
return out
239239

240240

241-
class Vectorizer(TransformerMixin):
241+
class Vectorizer(TransformerMixin, BaseEstimator):
242242
"""Transform n-dimensional array into 2D array of n_samples by n_features.
243243
244244
This class reshapes an n-dimensional array into an n_samples * n_features
@@ -343,7 +343,7 @@ def inverse_transform(self, X):
343343

344344

345345
@fill_doc
346-
class PSDEstimator(TransformerMixin):
346+
class PSDEstimator(TransformerMixin, BaseEstimator):
347347
"""Compute power spectral density (PSD) using a multi-taper method.
348348
349349
Parameters
@@ -452,7 +452,7 @@ def transform(self, epochs_data):
452452

453453

454454
@fill_doc
455-
class FilterEstimator(TransformerMixin):
455+
class FilterEstimator(TransformerMixin, BaseEstimator):
456456
"""Estimator to filter RtEpochs.
457457
458458
Applies a zero-phase low-pass, high-pass, band-pass, or band-stop
@@ -743,7 +743,7 @@ def _apply_method(self, X, method):
743743

744744

745745
@fill_doc
746-
class TemporalFilter(TransformerMixin):
746+
class TemporalFilter(TransformerMixin, BaseEstimator):
747747
"""Estimator to filter data array along the last dimension.
748748
749749
Applies a zero-phase low-pass, high-pass, band-pass, or band-stop

tools/install_pre_requirements.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,11 @@ python -m pip install $STD_ARGS pip setuptools packaging \
1818
py-cpuinfo blosc2 hatchling
1919
echo "NumPy/SciPy/pandas etc."
2020
python -m pip uninstall -yq numpy
21+
python -m pip install --upgrade matplotlib # TODO: Until https://github.com/matplotlib/matplotlib/pull/29427 lands
2122
python -m pip install $STD_ARGS --only-binary ":all:" --default-timeout=60 \
2223
--index-url "https://pypi.anaconda.org/scientific-python-nightly-wheels/simple" \
2324
"numpy>=2.1.0.dev0" "scikit-learn>=1.6.dev0" "scipy>=1.15.0.dev0" \
24-
"pandas>=3.0.0.dev0" "matplotlib>=3.10.0.dev0" \
25+
"pandas>=3.0.0.dev0" \
2526
"h5py>=3.12.1" "dipy>=1.10.0.dev0" "pyarrow>=19.0.0.dev0" "tables>=3.10.2.dev0"
2627

2728
# statsmodels requires formulaic@main so we need to use --extra-index-url

0 commit comments

Comments
 (0)