Explorar el Código

带标题 tag 去做训练

罗俊辉 hace 1 año
padre
commit
fa184a0502
Se han modificado 2 ficheros con 4 adiciones y 4 borrados
  1. 3 3
      main.py
  2. 1 1
      process_data.py

+ 3 - 3
main.py

@@ -128,13 +128,13 @@ class LightGBM(object):
         评估模型性能
         :return:
         """
-        fw = open("summary.txt", "a+", encoding="utf-8")
+        fw = open("summary_tag.txt", "a+", encoding="utf-8")
         # 测试数据
-        with open("whole_data/x_data_total_return_prid.json") as f1:
+        with open("produce_data/x_data_total_return_predict.json") as f1:
             x_list = json.loads(f1.read())
 
         # 测试 label
-        with open("whole_data/y_data_total_return_prid.json") as f2:
+        with open("whole_data/y_data_total_return_predict.json") as f2:
             Y_test = json.loads(f2.read())
 
         Y_test = [0 if i <= 26 else 1 for i in Y_test]

+ 1 - 1
process_data.py

@@ -114,5 +114,5 @@ class DataProcessor(object):
 
 
 if __name__ == "__main__":
-    D = DataProcessor(flag="train")
+    D = DataProcessor(flag="predict")
     D.producer()