Skip to content
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

PUBDEV-5230: Update import statement for PCA #1962

Merged
merged 4 commits into from
Jan 24, 2018
Merged

PUBDEV-5230: Update import statement for PCA #1962

merged 4 commits into from
Jan 24, 2018

Conversation

ABartzGit
Copy link

PCA is now an estimator. Previous examples imported using:
from h2o.transforms.decomposition import H2OPCA
For this issue, I changed all of these examples to
from h2o.estimators.pca import H2OPrincipalComponentAnalysisEstimator
or
from h2o.estimators.pca import H2OPrincipalComponentAnalysisEstimator as H2OPCA (where appropriate)

PCA is now an estimator. Previous examples imported using:
`from h2o.transforms.decomposition import H2OPCA`
For this issue, I changed all of these examples to
`from h2o.estimators.pca import H2OPrincipalComponentAnalysisEstimator`
or
`from h2o.estimators.pca import H2OPrincipalComponentAnalysisEstimator
as H2OPCA` (where appropriate)
When using from h2o.estimators.pca import
H2OPrincipalComponentAnalysisEstimator in scikit learn examples, an
error occurs when running fit(). Reverting the import statement for
these tests until a fix can be found. Note that from
h2o.transforms.decomposition import H2OPCA is still supported for
backward compatibility.
@ledell
Copy link
Contributor

ledell commented Jan 18, 2018

Since there are errors in the booklet (and not just the demos) when we change the import statement to use H2OPrincipalComponentAnalysisEstimator, let's wait until @st-pasha has a fix for the pipline/sklearn .fit() issue that @angela0xdata reported:

H2OValueError: y should not be provided for an unsupervised model

It would be weird to only change some of the import statements in the booklet, so let's just wait on merging this until PUBDEV-5236 is complete. Thanks!

angela0xdata added 2 commits January 23, 2018 13:40
Using h2o.estimators.pca import H2OPrincipalComponentAnalysisEstimator
in scikit learn examples no longer  gives an error when running fit().
Using h2o.estimators.pca import H2OPrincipalComponentAnalysisEstimator
in scikit learn examples no longer  gives an error when running fit().
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants