I tried to upgrade my scikit-learn
using the below command, still, that didn’t solve the AttributeError: 'str' object has no attribute 'decode'
issue
pip install scikit-learn -U
Finally, below code snippet solved the issue, add the solver as liblinear
model = LogisticRegression(solver="liblinear")