简体   繁体   English

model 期间的错误适合机器学习

[英]Error during model fit in machine learning

When I am trying to fit my model on X_train and y_train, it gives me an error as shown in the image.当我试图在 X_train 和 y_train 上安装 model 时,它给了我一个错误,如图所示。 The term Alberta is one of the entry in the province column of the dataset.术语 Alberta 是数据集省列中的条目之一。 Here i am using Decision Tree and Random forest as it is an unbalanced dataset.这里我使用决策树和随机森林,因为它是一个不平衡的数据集。 Please help me to resolve this error.请帮我解决这个错误。 I don't know where am i going wrong..我不知道我哪里错了。。 在此处输入图像描述

This probably happens because you have both numerical values and strings in the dataset.这可能是因为数据集中既有数值又有字符串。 Some solutions I would suggest are:我建议的一些解决方案是:

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM