Python3.6中pickle..dump报错
代码如下:model=sm.tsa.statespace.SARIMAX(endog=td_data_log,exog=train_data[holiday+weathe...
代码如下:
model = sm.tsa.statespace.SARIMAX(
endog=td_data_log,
exog=train_data[holiday+weather+peak],
order=order,
seasonal_order=seasonal_order,
enforce_stationarity=False,
enforce_invertibility=False,
)
answer = model.fit()
with open(path.join(out_model_path,out_model_pkl%(i)),'wb') as model_file:
pickle.dump(answer, model_file)
报错显示:TypeError: can't pickle statsmodels.tsa.statespace._statespace.dStatespace objects
网上找不到解决办法,还请大神帮忙看看,不胜感激! 展开
model = sm.tsa.statespace.SARIMAX(
endog=td_data_log,
exog=train_data[holiday+weather+peak],
order=order,
seasonal_order=seasonal_order,
enforce_stationarity=False,
enforce_invertibility=False,
)
answer = model.fit()
with open(path.join(out_model_path,out_model_pkl%(i)),'wb') as model_file:
pickle.dump(answer, model_file)
报错显示:TypeError: can't pickle statsmodels.tsa.statespace._statespace.dStatespace objects
网上找不到解决办法,还请大神帮忙看看,不胜感激! 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询