mne-tools / mne-features

MNE-Features software for extracting features from multivariate time series
https://mne-tools.github.io/mne-features/
BSD 3-Clause "New" or "Revised" License
142 stars 32 forks source link

transform() takes 2 positional arguments but was given 3 #48

Closed akatav closed 5 years ago

akatav commented 5 years ago

Trying to run the example - https://github.com/mne-tools/mne-features/blob/master/examples/plot_seizure_example.py throws error as below:

~/miniconda3/lib/python3.6/site-packages/mne_features/feature_extraction.py in transform(self, X, y) 67 details. 68 """ ---> 69 X_out = super(FeatureFunctionTransformer, self).transform(X, y) 70 self.outputshape = X_out.shape[0] 71 return X_out

TypeError: transform() takes 2 positional arguments but 3 were given

Is this a scikit-learn version issue? sklearn is up to date.

jbschiratti commented 5 years ago

Actually you're right, with scikit-learn 0.21, the FeatureFunctionTransformer class raises an error. It is because the y parameter in the transform method is no longer supported in 0.21 (it was already deprecated in previous versions).

jbschiratti commented 5 years ago

See #49.