{"description":"实验创建于2017/8/26","graph":{"edges":[{"to_node_id":"-322:features","from_node_id":"-331:data"},{"to_node_id":"-322:instruments","from_node_id":"-312:data"},{"to_node_id":"-1136:input_data","from_node_id":"-322:data"},{"to_node_id":"-322:user_functions","from_node_id":"-932:functions"},{"to_node_id":"-932:input_functions","from_node_id":"-937:functions"},{"to_node_id":"-937:input_functions","from_node_id":"-1111:functions"},{"to_node_id":"-1111:input_functions","from_node_id":"-1116:functions"},{"to_node_id":"-1116:input_functions","from_node_id":"-1121:functions"},{"to_node_id":"-1121:input_functions","from_node_id":"-1126:functions"},{"to_node_id":"-1136:features","from_node_id":"-1131:data"},{"to_node_id":"-1126:input_functions","from_node_id":"-584:functions"}],"nodes":[{"node_id":"-331","module_id":"BigQuantSpace.input_features.input_features-v1","parameters":[{"name":"features","value":"_c = close\n_o = open\n_ret = ret_sim(_c, _o)\n_rk1 = _ret.loc[93500:100000]\n_rk2 = _ret.loc[110000:113000]\n_rk3 = _ret.loc[143000:145700]\n\n# 1 收益方差\nRVar1 = RVar1(_ret)\nRVar2 = RVar2(_ret)\nRVar3 = (RVar2(_rk1) + RVar2(_rk2) + RVar2(_rk3)) / 3\n\n# 2 收益偏度\nRSkew1 = RSkew1(_ret, RVar1)\nRSkew2 = RSkew2(_ret, RVar2)\nRSkew3 = (RSkew2(_rk1, RVar2) + RSkew2(_rk2, RVar2) + RSkew2(_rk3, RVar2)) / 3\n\n\n# 3 收益峰度\nRKurt1 = RKurt1(_ret, RVar1)\nRKurt2 = RKurt2(_ret, RVar2)\nRKurt3 = (RKurt2(_rk1, RVar2) + RKurt2(_rk2, RVar2) + RKurt2(_rk3, RVar2)) / 3\n\n","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"features_ds","node_id":"-331"}],"output_ports":[{"name":"data","node_id":"-331"}],"cacheable":true,"seq_num":1,"comment":"","comment_collapsed":true},{"node_id":"-312","module_id":"BigQuantSpace.instruments.instruments-v2","parameters":[{"name":"start_date","value":"2014-03-03","type":"Literal","bound_global_parameter":null},{"name":"end_date","value":"2021-12-31","type":"Literal","bound_global_parameter":null},{"name":"market","value":"CN_STOCK_A","type":"Literal","bound_global_parameter":null},{"name":"instrument_list","value":"000001.SZA\n000002.SZA\n000005.SZA","type":"Literal","bound_global_parameter":null},{"name":"max_count","value":0,"type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"rolling_conf","node_id":"-312"}],"output_ports":[{"name":"data","node_id":"-312"}],"cacheable":true,"seq_num":2,"comment":"","comment_collapsed":true},{"node_id":"-322","module_id":"BigQuantSpace.feature_extractor_1m.feature_extractor_1m-v1","parameters":[{"name":"start_date","value":"","type":"Literal","bound_global_parameter":null},{"name":"end_date","value":"","type":"Literal","bound_global_parameter":null},{"name":"before_start_days","value":"10","type":"Literal","bound_global_parameter":null},{"name":"workers","value":2,"type":"Literal","bound_global_parameter":null},{"name":"parallel_mode","value":"测试","type":"Literal","bound_global_parameter":null},{"name":"table_1m","value":"level2_bar1m_CN_STOCK_A","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"instruments","node_id":"-322"},{"name":"features","node_id":"-322"},{"name":"user_functions","node_id":"-322"}],"output_ports":[{"name":"data","node_id":"-322"}],"cacheable":true,"seq_num":3,"comment":"","comment_collapsed":true},{"node_id":"-932","module_id":"BigQuantSpace.feature_extractor_user_function.feature_extractor_user_function-v1","parameters":[{"name":"name","value":"RVar1","type":"Literal","bound_global_parameter":null},{"name":"func","value":"def bigquant_run(df, ret):\n return (ret**2).sum()\n","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"input_functions","node_id":"-932"}],"output_ports":[{"name":"functions","node_id":"-932"}],"cacheable":false,"seq_num":4,"comment":"","comment_collapsed":true},{"node_id":"-937","module_id":"BigQuantSpace.feature_extractor_user_function.feature_extractor_user_function-v1","parameters":[{"name":"name","value":"RVar2","type":"Literal","bound_global_parameter":null},{"name":"func","value":"def bigquant_run(df, ret):\n return np.power(ret - (ret.mean()), 2).sum()\n","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"input_functions","node_id":"-937"}],"output_ports":[{"name":"functions","node_id":"-937"}],"cacheable":false,"seq_num":5,"comment":"","comment_collapsed":true},{"node_id":"-1111","module_id":"BigQuantSpace.feature_extractor_user_function.feature_extractor_user_function-v1","parameters":[{"name":"name","value":"RSkew1","type":"Literal","bound_global_parameter":null},{"name":"func","value":"def bigquant_run(df, ret, RVar):\n if RVar == 0:\n result = 0\n else:\n result = (np.power(ret, 3).sum()) * np.sqrt(240) / np.power(RVar, 1.5)\n return result\n","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"input_functions","node_id":"-1111"}],"output_ports":[{"name":"functions","node_id":"-1111"}],"cacheable":false,"seq_num":6,"comment":"","comment_collapsed":true},{"node_id":"-1116","module_id":"BigQuantSpace.feature_extractor_user_function.feature_extractor_user_function-v1","parameters":[{"name":"name","value":"RSkew2","type":"Literal","bound_global_parameter":null},{"name":"func","value":"def bigquant_run(df, ret, RVar):\n if RVar == 0:\n result = 0\n else:\n result = (np.power(ret - (ret.mean()), 3).sum()) * np.sqrt(240) / np.power(RVar, 1.5)\n return result\n","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"input_functions","node_id":"-1116"}],"output_ports":[{"name":"functions","node_id":"-1116"}],"cacheable":false,"seq_num":7,"comment":"","comment_collapsed":true},{"node_id":"-1121","module_id":"BigQuantSpace.feature_extractor_user_function.feature_extractor_user_function-v1","parameters":[{"name":"name","value":"RKurt1","type":"Literal","bound_global_parameter":null},{"name":"func","value":"def bigquant_run(df, ret, RVar):\n if RVar == 0:\n result = 1\n else:\n result = (np.power(ret, 4).sum()) * (240) / np.power(RVar, 2)\n \n return result\n","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"input_functions","node_id":"-1121"}],"output_ports":[{"name":"functions","node_id":"-1121"}],"cacheable":false,"seq_num":8,"comment":"","comment_collapsed":true},{"node_id":"-1126","module_id":"BigQuantSpace.feature_extractor_user_function.feature_extractor_user_function-v1","parameters":[{"name":"name","value":"RKurt2","type":"Literal","bound_global_parameter":null},{"name":"func","value":"def bigquant_run(df, ret, RVar):\n if RVar == 0:\n result = 1\n else:\n result = (np.power(ret - (ret.mean()), 4).sum()) * (240) / np.power(RVar, 2)\n return result\n","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"input_functions","node_id":"-1126"}],"output_ports":[{"name":"functions","node_id":"-1126"}],"cacheable":false,"seq_num":9,"comment":"","comment_collapsed":true},{"node_id":"-1131","module_id":"BigQuantSpace.input_features.input_features-v1","parameters":[{"name":"features","value":"RVar1_mean = nanmean(RVar1, 5)\nRVar2_mean = nanmean(RVar2, 5)\nRVar3_mean = nanmean(RVar3, 5)\n\nRSkew1_mean = nanmean(RSkew1, 5)\nRSkew2_mean = nanmean(RSkew2, 5)\nRSkew3_mean = nanmean(RSkew3, 5)\n\nRKurt1_mean = nanmean(RKurt1, 5)\nRKurt2_mean = nanmean(RKurt2, 5)\nRKurt3_mean = nanmean(RKurt3, 5)","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"features_ds","node_id":"-1131"}],"output_ports":[{"name":"data","node_id":"-1131"}],"cacheable":true,"seq_num":10,"comment":"","comment_collapsed":true},{"node_id":"-1136","module_id":"BigQuantSpace.derived_feature_extractor.derived_feature_extractor-v3","parameters":[{"name":"date_col","value":"date","type":"Literal","bound_global_parameter":null},{"name":"instrument_col","value":"instrument","type":"Literal","bound_global_parameter":null},{"name":"drop_na","value":"False","type":"Literal","bound_global_parameter":null},{"name":"remove_extra_columns","value":"False","type":"Literal","bound_global_parameter":null},{"name":"user_functions","value":"def nanmean(df, x_name, N):\n return df.groupby('instrument')[x_name.name].apply(lambda x: x.rolling(N,1).mean())\n\nbigquant_run = {\n 'nanmean': nanmean\n}","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"input_data","node_id":"-1136"},{"name":"features","node_id":"-1136"}],"output_ports":[{"name":"data","node_id":"-1136"}],"cacheable":true,"seq_num":11,"comment":"","comment_collapsed":true},{"node_id":"-584","module_id":"BigQuantSpace.feature_extractor_user_function.feature_extractor_user_function-v1","parameters":[{"name":"name","value":"ret_sim","type":"Literal","bound_global_parameter":null},{"name":"func","value":"def bigquant_run(df, close, op):\n res = close.pct_change()\n res.iloc[0] = close.iloc[0] / op.iloc[0] - 1\n return res\n","type":"Literal","bound_global_parameter":null}],"input_ports":[{"name":"input_functions","node_id":"-584"}],"output_ports":[{"name":"functions","node_id":"-584"}],"cacheable":false,"seq_num":12,"comment":"","comment_collapsed":true}],"node_layout":"<node_postions><node_position Node='-331' Position='79,-5,200,200'/><node_position Node='-312' Position='-256,-2,200,200'/><node_position Node='-322' Position='64,213,200,200'/><node_position Node='-932' Position='64,-114,200,200'/><node_position Node='-937' Position='65,-189,200,200'/><node_position Node='-1111' Position='66,-264,200,200'/><node_position Node='-1116' Position='69,-342,200,200'/><node_position Node='-1121' Position='56,-442,200,200'/><node_position Node='-1126' Position='50,-517,200,200'/><node_position Node='-1131' Position='394,202,200,200'/><node_position Node='-1136' Position='305,333,200,200'/><node_position Node='-584' Position='48.76287841796875,-603.71337890625,200,200'/></node_postions>"},"nodes_readonly":false,"studio_version":"v2"}
[2021-07-09 10:57:16.569089] INFO: moduleinvoker: input_features.v1 开始运行..
[2021-07-09 10:57:16.774595] INFO: moduleinvoker: input_features.v1 运行完成[0.205508s].
[2021-07-09 10:57:16.776877] INFO: moduleinvoker: instruments.v2 开始运行..
[2021-07-09 10:57:16.800720] INFO: moduleinvoker: instruments.v2 运行完成[0.023844s].
[2021-07-09 10:57:16.802511] INFO: moduleinvoker: input_features.v1 开始运行..
[2021-07-09 10:57:16.808254] INFO: moduleinvoker: 命中缓存
[2021-07-09 10:57:16.809338] INFO: moduleinvoker: input_features.v1 运行完成[0.006828s].
[2021-07-09 10:57:16.811599] INFO: moduleinvoker: feature_extractor_user_function.v1 运行完成[0.000106s].
[2021-07-09 10:57:16.813758] INFO: moduleinvoker: feature_extractor_user_function.v1 运行完成[6.7e-05s].
[2021-07-09 10:57:16.815927] INFO: moduleinvoker: feature_extractor_user_function.v1 运行完成[6.9e-05s].
[2021-07-09 10:57:16.818142] INFO: moduleinvoker: feature_extractor_user_function.v1 运行完成[7.1e-05s].
[2021-07-09 10:57:16.820311] INFO: moduleinvoker: feature_extractor_user_function.v1 运行完成[6.5e-05s].
[2021-07-09 10:57:16.822471] INFO: moduleinvoker: feature_extractor_user_function.v1 运行完成[6.5e-05s].
[2021-07-09 10:57:16.824640] INFO: moduleinvoker: feature_extractor_user_function.v1 运行完成[6.4e-05s].
[2021-07-09 10:57:16.831492] INFO: moduleinvoker: feature_extractor_1m.v1 开始运行..
[2021-07-09 10:57:16.851123] INFO: 高频特征抽取-分钟到日频: 测试模式运行, ['000002.SZA', '000001.SZA', '000005.SZA']
[2021-07-09 10:57:16.852085] INFO: fe1m_utils: extract chunk 3 instruments, 15 features ..
[2021-07-09 10:57:16.853118] INFO: fe1m_utils: extract chunk 3 instruments, n_jobs=18=(12+24)/2, 并行=False ..
[2021-07-09 10:57:24.933125] INFO: fe1m_utils: extracted chunk 3/3 instruments, (729, 11).
[2021-07-09 10:57:25.031520] INFO: 高频特征抽取-分钟到日频: extracted 3/3 instruments, (729, 11)
[2021-07-09 10:57:25.037196] INFO: moduleinvoker: feature_extractor_1m.v1 运行完成[8.205701s].
[2021-07-09 10:57:25.039800] INFO: moduleinvoker: derived_feature_extractor.v3 开始运行..
[2021-07-09 10:57:25.081859] INFO: derived_feature_extractor: 提取完成 RVar1_mean = nanmean(RVar1, 5), 0.004s
[2021-07-09 10:57:25.086389] INFO: derived_feature_extractor: 提取完成 RVar2_mean = nanmean(RVar2, 5), 0.003s
[2021-07-09 10:57:25.090086] INFO: derived_feature_extractor: 提取完成 RVar3_mean = nanmean(RVar3, 5), 0.003s
[2021-07-09 10:57:25.093782] INFO: derived_feature_extractor: 提取完成 RSkew1_mean = nanmean(RSkew1, 5), 0.003s
[2021-07-09 10:57:25.097374] INFO: derived_feature_extractor: 提取完成 RSkew2_mean = nanmean(RSkew2, 5), 0.003s
[2021-07-09 10:57:25.101134] INFO: derived_feature_extractor: 提取完成 RSkew3_mean = nanmean(RSkew3, 5), 0.003s
[2021-07-09 10:57:25.104807] INFO: derived_feature_extractor: 提取完成 RKurt1_mean = nanmean(RKurt1, 5), 0.003s
[2021-07-09 10:57:25.108544] INFO: derived_feature_extractor: 提取完成 RKurt2_mean = nanmean(RKurt2, 5), 0.003s
[2021-07-09 10:57:25.112755] INFO: derived_feature_extractor: 提取完成 RKurt3_mean = nanmean(RKurt3, 5), 0.004s
[2021-07-09 10:57:25.137553] INFO: derived_feature_extractor: /data, 729
[2021-07-09 10:57:25.198219] INFO: moduleinvoker: derived_feature_extractor.v3 运行完成[0.158413s].