[英]profanity check error cannot import name 'joblib' from 'sklearn.externals'
I have a env that I just Installed profanity_check but when I run my code I get a error:我有一个环境,我刚刚安装了 profanity_check,但是当我运行我的代码时,出现错误:
Traceback (most recent call last):
File "bot.py", line 1, in <module>
from profanity_check import predict, predict_prob
File "D:\bot\bot\lib\site-packages\profanity_check\__init__.py", line 1, in <module>
from .profanity_check import predict, predict_prob
File "D:\bot\bot\lib\site-packages\profanity_check\profanity_check.py", line 3, in <module>
from sklearn.externals import joblib
ImportError: cannot import name 'joblib' from 'sklearn.externals' (D:\bot\bot\lib\site-packages\sklearn\externals\__init__.py)
I searched into stackoverflow but I get more errors.我搜索了 stackoverflow,但出现了更多错误。
thank you for reading:D感谢您的阅读:D
Try this out:试试这个:
pip install alt-profanity-check
pip install sklearn --upgrade
from profanity_check import predict, predict_prob
Details here: https://github.com/vzhou842/profanity-check/issues/28详情在这里: https://github.com/vzhou842/profanity-check/issues/28
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.