Closed htnphu closed 2 months ago
Hello,
I have found a solution to the issue. There is a forked repository called alt-profanity-check
that addresses the import problem with joblib
. This repository is a drop-in replacement for profanity-check
and aims to maintain compatibility with newer versions of scikit-learn
.
You guys can find the alt-profanity-check
repository here: https://github.com/dimitrismistriotis/alt-profanity-check
Best regards, htnphu
Hello,
I'm encountering an issue while trying to use the
profanity_check
library in Python. Upon importingprofanity_check
, I'm receiving the following error:Traceback (most recent call last): File “path/to/your/script.py”, line X, in from profanity_check import predict, predict_prob File “path/to/venv/lib/pythonX.X/site-packages/profanity_check/init.py”, line X, in from .profanity_check import predict, predict_prob File “path/to/venv/lib/pythonX.X/site-packages/profanity_check/profanity_check.py”, line X, in from sklearn.externals import joblib ImportError: cannot import name ‘joblib’ from ‘sklearn.externals’ (path/to/venv/lib/pythonX.X/site-packages/sklearn/externals/init.py)
It seems that
profanity_check
is relying onjoblib
fromsklearn.externals
, which has been removed in newer versions ofscikit-learn
.Could you please advise on how to resolve this issue? Alternatively, could the library be updated to use
joblib
directly or provide compatibility with newer versions ofscikit-learn
?Thank you for your assistance.
Best regards, htnphu