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

Update to work with latest scikit-learn (0.22.1) #2

Closed
randomir opened this issue Feb 25, 2020 · 0 comments · Fixed by #3
Closed

Update to work with latest scikit-learn (0.22.1) #2

randomir opened this issue Feb 25, 2020 · 0 comments · Fixed by #3
Assignees

Comments

@randomir
Copy link
Contributor

When run with the latest version (scikit-learn==0.22.1), the demo fails with:

$ python demo.py --mnist

======================================
Train#: 3333, Test: 1667
Num weak classifiers: 35
Tree depth: 3
Traceback (most recent call last):
  File "demo.py", line 196, in <module>
    clfs = train_model(X_train, y_train, X_test, y_test, 1.0)
  File "demo.py", line 80, in train_model
    X_train = centerer.fit_transform(X_train)
  File "/usr/local/lib/python3.7/site-packages/sklearn/base.py", line 571, in fit_transform
    return self.fit(X, **fit_params).transform(X)
  File "/usr/local/lib/python3.7/site-packages/sklearn/preprocessing/_data.py", line 2033, in fit
    .format(K.shape[0], K.shape[1]))
ValueError: Kernel matrix must be a square matrix. Input is a 3333x784 matrix.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants