lmstack 1 ano atrás
pai
commit
16c4c7bcab
2 arquivos alterados com 47 adições e 26 exclusões
  1. 26 6
      demo.ipynb
  2. 21 20
      demo.py

+ 26 - 6
demo.ipynb

@@ -268,6 +268,23 @@
     "df_fault.to_csv('c.csv')"
    ]
   },
+  {
+   "cell_type": "code",
+   "execution_count": 1,
+   "metadata": {},
+   "outputs": [
+    {
+     "name": "stdout",
+     "output_type": "stream",
+     "text": [
+      "1\n"
+     ]
+    }
+   ],
+   "source": [
+    "print(1)"
+   ]
+  },
   {
    "cell_type": "code",
    "execution_count": null,
@@ -277,11 +294,9 @@
   }
  ],
  "metadata": {
-  "interpreter": {
-   "hash": "b3ba2566441a7c06988d0923437866b63cedc61552a5af99d1f4fb67d367b25f"
-  },
   "kernelspec": {
-   "display_name": "Python 3.8.8 64-bit ('base': conda)",
+   "display_name": "py388",
+   "language": "python",
    "name": "python3"
   },
   "language_info": {
@@ -294,9 +309,14 @@
    "name": "python",
    "nbconvert_exporter": "python",
    "pygments_lexer": "ipython3",
-   "version": "3.8.12"
+   "version": "3.8.16"
   },
-  "orig_nbformat": 4
+  "orig_nbformat": 4,
+  "vscode": {
+   "interpreter": {
+    "hash": "9bb309b059ca3dc41bcdf6b07c770e5a501ed97315f8b1ee2607bdea1906eb5f"
+   }
+  }
  },
  "nbformat": 4,
  "nbformat_minor": 2

+ 21 - 20
demo.py

@@ -1,28 +1,29 @@
-#LIB/MIDDLE/算法名/main.py   该文件调用核心算法
+# #LIB/MIDDLE/算法名/main.py   该文件调用核心算法
 
-# 准备算法输入参数
-parameter1 = * 
-parameter2 = *
+# # 准备算法输入参数
+# parameter1 = * 
+# parameter2 = *
 
 
-# 多次调用核心算法时,将循环写在外面
-for (i=1:n){
+# # 多次调用核心算法时,将循环写在外面
+# for (i=1:n){
      
-     # 获取数据
-     data1 = get_data(sn[i], start_time, end_time, ....)
-     data2 = get_data_by_sql(sn[i], start_time, end_time, ....)
+#      # 获取数据
+#      data1 = get_data(sn[i], start_time, end_time, ....)
+#      data2 = get_data_by_sql(sn[i], start_time, end_time, ....)
 
-     # 通用数据预处理 (可选,由算法说明文档说明算法输入数据是否需要预处理)
-     data1 = data_process(data1)
-     data2 = data_process(data2)
+#      # 通用数据预处理 (可选,由算法说明文档说明算法输入数据是否需要预处理)
+#      data1 = data_process(data1)
+#      data2 = data_process(data2)
      
-     # 调用核心算法
-     [res1, res2] = core_algorithm(data1, data2, parameter1, parameter2)
+#      # 调用核心算法
+#      [res1, res2] = core_algorithm(data1, data2, parameter1, parameter2)
 
-     # 使用结果
-     res1 = res1.append(res)
-     res1.to_csv(...)
-}
+#      # 使用结果
+#      res1 = res1.append(res)
+#      res1.to_csv(...)
+# }
 
-# 批量使用结果
-res.to_csv(...)
+# # 批量使用结果
+# res.to_csv(...)
+print(1)