Issue
I am getting Import error for LogisticRegression while importing in my code.
from sklearn.model_selection import LogisticRegression
Error :-
Traceback (most recent call last):
File "e:\VSCODE\GIT_Hub\myML\Proj2-FruitSurvey-SimpleClassificationModels\ML-Models.py", line 78, in <module>
from sklearn.model_selection import LogisticRegression
ImportError: cannot import name 'LogisticRegression'
I have no issues while loading other modules like
from sklearn.model_selection import GridSearchCV,cross_validate
from sklearn.model_selection import train_test_split
I am using python version =3.6.5 scikit-learn=0.21.0 windows 10 code editor = vscode
Solution
It is in sklearn.linear_model
, https://scikit-learn.org/stable/modules/generated/sklearn.linear_model.LogisticRegression.html
Answered By - rsyed0
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.