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

On def get_metrics(y_true, y_predicted): Error #3

Open
mrdeds opened this issue Feb 1, 2018 · 1 comment
Open

On def get_metrics(y_true, y_predicted): Error #3

mrdeds opened this issue Feb 1, 2018 · 1 comment

Comments

@mrdeds
Copy link

mrdeds commented Feb 1, 2018

@hundredblocks
captura de pantalla 2018-01-31 a la s 18 22 14
captura de pantalla 2018-01-31 a la s 18 22 07

ValueError: Classification metrics can't handle a mix of continuous and multiclass targets

@mrdeds
Copy link
Author

mrdeds commented Feb 1, 2018

Solved! There are some elements that are Nan on y_test and/or y_predicted_counts.
I tried something like this:
def nanToZero(nanlist):
newlist=[0 if math.isnan(x) else x for x in nanlist]
return newlist

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

No branches or pull requests

1 participant