Last answered:

16 Dec 2021

Posted on:

07 Nov 2021

2

ModuleNotFoundError: No module named 'sklearn.linear_model.logistic'

When i try to run

absenteeism_model('model','scaler')

It shows me this error


     40             # read the 'model' and 'scaler' files which were saved
     41             with open('model','rb') as model_file, open('scaler', 'rb') as scaler_file:
---> 42                 self.reg = pickle.load(model_file)
     43                 self.scaler = pickle.load(scaler_file)
     44                 self.data = None

ModuleNotFoundError: No module named 'sklearn.linear_model.logistic'
2 answers ( 0 marked as helpful)
Posted on:

18 Nov 2021

0

Check the answer to this question https://365datascience.com/q/b09723d5e6 , you should use your own versions of model and scaler files, not the provided ones.

Instructor
Posted on:

16 Dec 2021

0

Hi Ahmed and Bassant!
Thanks for reaching out.

@: Bassant
Thanks for sharing this piece of information with the Community!
@: Ahmed
You should use your own versions of model and scaler files. Please, read the thread. Thank you.

Hope this helps.
Best,
Tsvetelin

Submit an answer