-
-
Notifications
You must be signed in to change notification settings - Fork 553
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
The PredictionError can't be visualized due to the dim error #1297
Comments
I am using yellowbrick on keras deep learning via sckit-wrapper and can't plot prediction error because of this. It would be great to get this one fixed. |
Could you guys try: visualizer = PredictionError(model, bestfit=False)
self.y_test = self.y_test.squeeze()
visualizer.fit(self.x_train, self.y_train)
visualizer.score(self.x_test, self.y_test)
visualizer.show() To see if the problem is only with the best fit line? If so then it may be tricky to figure out how to incorporate the best fit line but at least you will be able to get a prediction error plot for your models. If not, we'll have to discuss how models that output a 2D array of outputs make sense in a prediction error context which is intended to plot y against y_hat. Potentially if in Keras the second dimension is just the batches, we could find a way to flatten them with an argument. Let me know how the above goes and we'll move on from there. |
Describe the bug
The PredictionError can't be visualized due to the dim error.
To Reproduce
I use the following code:
And I think the error happens in
yellowbrick/regressor/prediction_error.py
The dimension of y_pred is 2. But in
draw_best_fit
function,y.ndim>1
will raise error!Traceback
The text was updated successfully, but these errors were encountered: