-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
Manifold learners are not transformers #2887
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I bump into this issue today when I wanted to make a pipeline with a spectral embedding. |
same here - i think it would be good to add a transform method to these. they should act no differently from PCA imo. |
This issue comes from my (initially confused) question on Stackoverflow. It would be great to be able to project unseen points into the MDS space, but after thinking about it, I don't think the MDS algorithm can actually do this! Can it? I think it iteratively "moves points around" in the projected space. It doesn't actually represent the transformation. I suppose there is a possibility to hack it by find a few nearest neighbours of the unseen point in the original space, and sending it to a weighted average of their transforms or something like that. But there would be no justification in MDS theory for that, I think. |
i see where this is coming from now. indeed for many of these operators one can create a transform for the input data set, but it's not possible to apply that transformation to a different dataset. so i take back what i said earlier about adding the transform bit - i was indeed thinking the fit_transform process, which they already have. |
But what is the algorithm to transform on new data? I am not sure that I |
Unless we can come up with a principled algorithm to transform new data, |
I just stumbled upon this -- you can indeed project new points in MDS and other methods. See |
MDS
andSpectralEmbedding
are not transformers: they havefit_transform
, but notransform
. Of these,SpectralEmbedding
inherits fromTransformerMixin
without good cause. Either it should be removed or the class should get atransform
method.Ping @GaelVaroquaux, @kuantkid, @NelleV.
The text was updated successfully, but these errors were encountered: