From 757bc5317ab841cb91ca97be1e24e3dfff35da56 Mon Sep 17 00:00:00 2001 From: liurui Date: Thu, 14 Nov 2024 17:26:17 +0800 Subject: [PATCH] =?UTF-8?q?=E8=81=9A=E7=83=AF=E7=83=83=E4=B8=BB=E7=A8=8B?= =?UTF-8?q?=E5=BA=8F=E6=9B=B4=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config_juxiting.py | 4 ++-- lib/dataread.py | 4 ++-- main_juxiting.py | 9 +++------ 3 files changed, 7 insertions(+), 10 deletions(-) diff --git a/config_juxiting.py b/config_juxiting.py index 16009c6..7ffa7d3 100644 --- a/config_juxiting.py +++ b/config_juxiting.py @@ -211,7 +211,7 @@ upload_data = { ### 开关 is_train = True # 是否训练 is_debug = False # 是否调试 -is_eta = False # 是否使用eta接口 +is_eta = True # 是否使用eta接口 is_timefurture = True # 是否使用时间特征 is_fivemodels = False # 是否使用之前保存的最佳的5个模型 is_edbcode = False # 特征使用edbcoding列表中的 @@ -235,7 +235,7 @@ avg_cols = [ 'PP:拉丝:L5E89:出厂价:河北、鲁北:大唐内蒙多伦(日)', 'PP:拉丝:HP550J:市场价:青岛:金能化学(日)' ] -offsite = 50 +offsite = 80 offsite_col = ['PP:拉丝:HP550J:市场价:青岛:金能化学(日)'] horizon =5 # 预测的步长 input_size = 40 # 输入序列长度 diff --git a/lib/dataread.py b/lib/dataread.py index 92cbc15..a865ed0 100644 --- a/lib/dataread.py +++ b/lib/dataread.py @@ -20,8 +20,8 @@ plt.rcParams['font.sans-serif'] = ['SimHei'] # 用来正常显示中文标签 plt.rcParams['axes.unicode_minus'] = False # 用来正常显示负号 from datetime import timedelta -from config_jingbo import * -# from config_juxiting import * +# from config_jingbo import * +from config_juxiting import * from sklearn import metrics from reportlab.pdfbase import pdfmetrics # 注册字体 from reportlab.pdfbase.ttfonts import TTFont # 字体类 diff --git a/main_juxiting.py b/main_juxiting.py index df8f85a..5d130a3 100644 --- a/main_juxiting.py +++ b/main_juxiting.py @@ -140,12 +140,9 @@ def predict_main(): logger.info('制作报告ing') title = f'{settings}--{now}-预测报告' # 报告标题 - if 'Brent' in y: - brent_export_pdf(dataset=dataset,num_models = 5 if is_fivemodels else 22,time=end_time, - reportname=reportname,sqlitedb=sqlitedb), - else: - pp_export_pdf(dataset=dataset,num_models = 5 if is_fivemodels else 22,time=end_time, - reportname=reportname,sqlitedb=sqlitedb), + + pp_export_pdf(dataset=dataset,num_models = 5 if is_fivemodels else 22,time=end_time, + reportname=reportname,sqlitedb=sqlitedb), logger.info('制作报告end') logger.info('模型训练完成')