【发布时间】:2020-07-02 17:55:10
【问题描述】:
AttributeError: Can't get attribute 'DeprecationDict' on
在model = pickle.load(open('rf_regression_model.pkl', 'rb')) 这一行显示错误。
【问题讨论】:
标签: python machine-learning scikit-learn pickle
AttributeError: Can't get attribute 'DeprecationDict' on
在model = pickle.load(open('rf_regression_model.pkl', 'rb')) 这一行显示错误。
【问题讨论】:
标签: python machine-learning scikit-learn pickle
您使用新版本的 sklearn 加载了由旧版本的 sklearn 训练的模型。
所以,选项是:
【讨论】:
试试这个
with open('rf_regression_model','rb') as f:
model=pickle.load(f)
【讨论】: