hikyuu 2.7.0__py3-none-manylinux2014_aarch64.whl → 2.7.5__py3-none-manylinux2014_aarch64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (295) hide show
  1. hikyuu/__init__.py +28 -8
  2. hikyuu/__init__.pyi +26 -14
  3. hikyuu/analysis/__init__.pyi +7 -1
  4. hikyuu/analysis/analysis.pyi +8 -2
  5. hikyuu/core.pyi +9 -3
  6. hikyuu/cpp/core310.pyi +172 -68
  7. hikyuu/cpp/core310.so +0 -0
  8. hikyuu/cpp/core311.pyi +172 -68
  9. hikyuu/cpp/core311.so +0 -0
  10. hikyuu/cpp/core312.pyi +172 -68
  11. hikyuu/cpp/core312.so +0 -0
  12. hikyuu/cpp/core313.pyi +172 -68
  13. hikyuu/cpp/core313.so +0 -0
  14. hikyuu/cpp/i18n/zh_CN/hikyuu.mo +0 -0
  15. hikyuu/cpp/i18n/zh_CN/hikyuu_plugin.mo +0 -0
  16. hikyuu/cpp/libboost_atomic.so +0 -0
  17. hikyuu/cpp/libboost_atomic.so.1.90.0 +0 -0
  18. hikyuu/cpp/{libboost_charconv-mt.so → libboost_charconv.so} +0 -0
  19. hikyuu/cpp/{libboost_charconv-mt.so.1.88.0 → libboost_charconv.so.1.90.0} +0 -0
  20. hikyuu/cpp/libboost_chrono.so +0 -0
  21. hikyuu/cpp/libboost_chrono.so.1.90.0 +0 -0
  22. hikyuu/cpp/libboost_container.so +0 -0
  23. hikyuu/cpp/libboost_container.so.1.90.0 +0 -0
  24. hikyuu/cpp/libboost_date_time.so +0 -0
  25. hikyuu/cpp/libboost_date_time.so.1.90.0 +0 -0
  26. hikyuu/cpp/libboost_locale.so +0 -0
  27. hikyuu/cpp/libboost_locale.so.1.90.0 +0 -0
  28. hikyuu/cpp/libboost_random.so +0 -0
  29. hikyuu/cpp/libboost_random.so.1.90.0 +0 -0
  30. hikyuu/cpp/libboost_serialization.so +0 -0
  31. hikyuu/cpp/libboost_serialization.so.1.90.0 +0 -0
  32. hikyuu/cpp/libboost_thread.so +0 -0
  33. hikyuu/cpp/libboost_thread.so.1.90.0 +0 -0
  34. hikyuu/cpp/libboost_wserialization.so +0 -0
  35. hikyuu/cpp/libboost_wserialization.so.1.90.0 +0 -0
  36. hikyuu/cpp/libhikyuu.so +0 -0
  37. hikyuu/cpp/libmimalloc.so +0 -0
  38. hikyuu/cpp/libmimalloc.so.3 +0 -0
  39. hikyuu/cpp/libmimalloc.so.3.1 +0 -0
  40. hikyuu/cpp/libsqlite3.so +0 -0
  41. hikyuu/data/clickhouse_upgrade/0001.sql +2 -0
  42. hikyuu/data/clickhouse_upgrade/0002.sql +9 -0
  43. hikyuu/data/common_clickhouse.py +1 -3
  44. hikyuu/data/common_mysql.py +1 -1
  45. hikyuu/data/download_block.py +1 -1
  46. hikyuu/data/em_block_to_mysql.py +16 -4
  47. hikyuu/data/em_block_to_sqlite.py +16 -4
  48. hikyuu/data/hku_config_template.py +31 -4
  49. hikyuu/data/mysql_upgrade/0029.sql +2 -0
  50. hikyuu/data/mysql_upgrade/0030.sql +3 -0
  51. hikyuu/data/pytdx_to_clickhouse.py +86 -32
  52. hikyuu/data/pytdx_to_h5.py +73 -28
  53. hikyuu/data/pytdx_to_mysql.py +65 -21
  54. hikyuu/data/pytdx_weight_to_clickhouse.py +2 -0
  55. hikyuu/data/pytdx_weight_to_mysql.py +2 -0
  56. hikyuu/data/pytdx_weight_to_sqlite.py +2 -0
  57. hikyuu/data/sqlite_upgrade/0029.sql +4 -0
  58. hikyuu/data/sqlite_upgrade/0030.sql +5 -0
  59. hikyuu/data/tdx_to_clickhouse.py +2 -2
  60. hikyuu/data/tdx_to_h5.py +11 -11
  61. hikyuu/data/tdx_to_mysql.py +2 -2
  62. hikyuu/draw/__init__.pyi +1 -1
  63. hikyuu/draw/drawplot/__init__.pyi +1 -1
  64. hikyuu/draw/drawplot/bokeh_draw.pyi +17 -9
  65. hikyuu/draw/drawplot/echarts_draw.pyi +17 -9
  66. hikyuu/draw/drawplot/matplotlib_draw.py +23 -9
  67. hikyuu/draw/drawplot/matplotlib_draw.pyi +17 -9
  68. hikyuu/examples/notebook/001-overview.ipynb +112 -78
  69. hikyuu/examples/notebook/004-IndicatorOverview.ipynb +52 -65
  70. hikyuu/examples/notebook/006-TradeManager.ipynb +402 -291
  71. hikyuu/examples/notebook/008-Pickle.ipynb +25 -17
  72. hikyuu/examples/notebook/009-RealData.ipynb +36 -38
  73. hikyuu/examples/notebook/Demo/Demo2.ipynb +146 -116
  74. hikyuu/extend.pyi +10 -4
  75. hikyuu/gui/HikyuuTDX.py +42 -3
  76. hikyuu/gui/data/MainWindow.py +189 -129
  77. hikyuu/gui/data/UseTdxImportToH5Thread.py +4 -2
  78. hikyuu/gui/start_qmt.py +1 -1
  79. hikyuu/hub.pyi +6 -6
  80. hikyuu/include/hikyuu/Block.h +9 -9
  81. hikyuu/include/hikyuu/HistoryFinanceInfo.h +3 -3
  82. hikyuu/include/hikyuu/KData.h +51 -28
  83. hikyuu/include/hikyuu/KDataImp.h +12 -7
  84. hikyuu/include/hikyuu/KDataPrivatedBufferImp.h +13 -7
  85. hikyuu/include/hikyuu/KDataSharedBufferImp.h +8 -6
  86. hikyuu/include/hikyuu/KQuery.h +11 -11
  87. hikyuu/include/hikyuu/KRecord.h +1 -1
  88. hikyuu/include/hikyuu/MarketInfo.h +10 -10
  89. hikyuu/include/hikyuu/Stock.h +30 -30
  90. hikyuu/include/hikyuu/StockManager.h +28 -12
  91. hikyuu/include/hikyuu/StockTypeInfo.h +9 -9
  92. hikyuu/include/hikyuu/StockWeight.h +9 -9
  93. hikyuu/include/hikyuu/StrategyContext.h +4 -4
  94. hikyuu/include/hikyuu/TimeLineRecord.h +1 -1
  95. hikyuu/include/hikyuu/TransRecord.h +1 -1
  96. hikyuu/include/hikyuu/data_driver/BaseInfoDriver.h +2 -1
  97. hikyuu/include/hikyuu/data_driver/BlockInfoDriver.h +6 -0
  98. hikyuu/include/hikyuu/data_driver/KDataDriver.h +6 -7
  99. hikyuu/include/hikyuu/data_driver/kdata/mysql/MySQLKDataDriver.h +5 -1
  100. hikyuu/include/hikyuu/data_driver/kdata/sqlite/SQLiteKDataDriver.h +1 -1
  101. hikyuu/include/hikyuu/global/sysinfo.h +24 -5
  102. hikyuu/include/hikyuu/indicator/IndParam.h +1 -1
  103. hikyuu/include/hikyuu/indicator/Indicator.h +56 -27
  104. hikyuu/include/hikyuu/indicator/Indicator2InImp.h +0 -4
  105. hikyuu/include/hikyuu/indicator/IndicatorImp.h +147 -74
  106. hikyuu/include/hikyuu/indicator/crt/CONTEXT.h +11 -1
  107. hikyuu/include/hikyuu/indicator/crt/IC.h +19 -14
  108. hikyuu/include/hikyuu/indicator/crt/ICIR.h +4 -7
  109. hikyuu/include/hikyuu/indicator/imp/IAbs.h +1 -0
  110. hikyuu/include/hikyuu/indicator/imp/IAcos.h +1 -0
  111. hikyuu/include/hikyuu/indicator/imp/IAd.h +0 -2
  112. hikyuu/include/hikyuu/indicator/imp/IAdvance.h +3 -0
  113. hikyuu/include/hikyuu/indicator/imp/IAma.h +3 -0
  114. hikyuu/include/hikyuu/indicator/imp/IAsin.h +1 -0
  115. hikyuu/include/hikyuu/indicator/imp/IAtan.h +1 -0
  116. hikyuu/include/hikyuu/indicator/imp/IAtr.h +2 -3
  117. hikyuu/include/hikyuu/indicator/imp/IBackset.h +2 -4
  118. hikyuu/include/hikyuu/indicator/imp/IBlockSetNum.h +3 -0
  119. hikyuu/include/hikyuu/indicator/imp/ICeil.h +1 -0
  120. hikyuu/include/hikyuu/indicator/imp/IContext.h +0 -3
  121. hikyuu/include/hikyuu/indicator/imp/ICorr.h +3 -0
  122. hikyuu/include/hikyuu/indicator/imp/ICos.h +1 -0
  123. hikyuu/include/hikyuu/indicator/imp/ICost.h +0 -2
  124. hikyuu/include/hikyuu/indicator/imp/ICount.h +2 -1
  125. hikyuu/include/hikyuu/indicator/imp/ICval.h +1 -4
  126. hikyuu/include/hikyuu/indicator/imp/ICycle.h +0 -2
  127. hikyuu/include/hikyuu/indicator/imp/IDecline.h +3 -0
  128. hikyuu/include/hikyuu/indicator/imp/IDevsq.h +4 -1
  129. hikyuu/include/hikyuu/indicator/imp/IDiff.h +1 -0
  130. hikyuu/include/hikyuu/indicator/imp/IDma.h +2 -0
  131. hikyuu/include/hikyuu/indicator/imp/IDropna.h +0 -4
  132. hikyuu/include/hikyuu/indicator/imp/IEma.h +3 -1
  133. hikyuu/include/hikyuu/indicator/imp/IEvery.h +5 -1
  134. hikyuu/include/hikyuu/indicator/imp/IExist.h +5 -1
  135. hikyuu/include/hikyuu/indicator/imp/IExp.h +1 -0
  136. hikyuu/include/hikyuu/indicator/imp/IFilter.h +4 -5
  137. hikyuu/include/hikyuu/indicator/imp/IFinance.h +1 -2
  138. hikyuu/include/hikyuu/indicator/imp/IFloor.h +1 -0
  139. hikyuu/include/hikyuu/indicator/imp/IHhvbars.h +5 -1
  140. hikyuu/include/hikyuu/indicator/imp/IHighLine.h +5 -1
  141. hikyuu/include/hikyuu/indicator/imp/IHsl.h +0 -2
  142. hikyuu/include/hikyuu/indicator/imp/IIc.h +3 -6
  143. hikyuu/include/hikyuu/indicator/imp/IInBlock.h +1 -2
  144. hikyuu/include/hikyuu/indicator/imp/IIntpart.h +1 -0
  145. hikyuu/include/hikyuu/indicator/imp/IIsInf.h +1 -0
  146. hikyuu/include/hikyuu/indicator/imp/IIsInfa.h +1 -0
  147. hikyuu/include/hikyuu/indicator/imp/IIsLastBar.h +0 -1
  148. hikyuu/include/hikyuu/indicator/imp/IIsNa.h +1 -0
  149. hikyuu/include/hikyuu/indicator/imp/IJumpDown.h +1 -0
  150. hikyuu/include/hikyuu/indicator/imp/IJumpUp.h +1 -0
  151. hikyuu/include/hikyuu/indicator/imp/IKData.h +1 -2
  152. hikyuu/include/hikyuu/indicator/imp/ILiuTongPan.h +0 -2
  153. hikyuu/include/hikyuu/indicator/imp/ILn.h +1 -0
  154. hikyuu/include/hikyuu/indicator/imp/ILog.h +1 -0
  155. hikyuu/include/hikyuu/indicator/imp/ILowLine.h +5 -1
  156. hikyuu/include/hikyuu/indicator/imp/ILowLineBars.h +5 -1
  157. hikyuu/include/hikyuu/indicator/imp/IMa.h +6 -1
  158. hikyuu/include/hikyuu/indicator/imp/IMacd.h +2 -0
  159. hikyuu/include/hikyuu/indicator/imp/INot.h +1 -0
  160. hikyuu/include/hikyuu/indicator/imp/IPow.h +3 -1
  161. hikyuu/include/hikyuu/indicator/imp/IQuantileTrunc.h +1 -0
  162. hikyuu/include/hikyuu/indicator/imp/IRecover.h +3 -0
  163. hikyuu/include/hikyuu/indicator/imp/IRef.h +3 -1
  164. hikyuu/include/hikyuu/indicator/imp/IResult.h +1 -0
  165. hikyuu/include/hikyuu/indicator/imp/IReverse.h +1 -0
  166. hikyuu/include/hikyuu/indicator/imp/IRoc.h +6 -1
  167. hikyuu/include/hikyuu/indicator/imp/IRocp.h +5 -1
  168. hikyuu/include/hikyuu/indicator/imp/IRocr.h +5 -1
  169. hikyuu/include/hikyuu/indicator/imp/IRocr100.h +5 -1
  170. hikyuu/include/hikyuu/indicator/imp/IRound.h +1 -0
  171. hikyuu/include/hikyuu/indicator/imp/IRoundDown.h +1 -0
  172. hikyuu/include/hikyuu/indicator/imp/IRoundUp.h +1 -0
  173. hikyuu/include/hikyuu/indicator/imp/ISaftyLoss.h +1 -0
  174. hikyuu/include/hikyuu/indicator/imp/ISign.h +1 -0
  175. hikyuu/include/hikyuu/indicator/imp/ISin.h +1 -0
  176. hikyuu/include/hikyuu/indicator/imp/ISlope.h +5 -1
  177. hikyuu/include/hikyuu/indicator/imp/ISma.h +2 -0
  178. hikyuu/include/hikyuu/indicator/imp/ISpearman.h +3 -0
  179. hikyuu/include/hikyuu/indicator/imp/ISqrt.h +1 -0
  180. hikyuu/include/hikyuu/indicator/imp/IStdev.h +5 -1
  181. hikyuu/include/hikyuu/indicator/imp/IStdp.h +5 -1
  182. hikyuu/include/hikyuu/indicator/imp/ISum.h +6 -1
  183. hikyuu/include/hikyuu/indicator/imp/ITan.h +1 -0
  184. hikyuu/include/hikyuu/indicator/imp/ITime.h +1 -2
  185. hikyuu/include/hikyuu/indicator/imp/ITimeLine.h +0 -2
  186. hikyuu/include/hikyuu/indicator/imp/ITr.h +1 -2
  187. hikyuu/include/hikyuu/indicator/imp/IVar.h +5 -1
  188. hikyuu/include/hikyuu/indicator/imp/IVarp.h +5 -1
  189. hikyuu/include/hikyuu/indicator/imp/IVigor.h +0 -2
  190. hikyuu/include/hikyuu/indicator/imp/IWma.h +5 -1
  191. hikyuu/include/hikyuu/indicator/imp/IZongGuBen.h +1 -2
  192. hikyuu/include/hikyuu/indicator_talib/imp/TaAdosc.h +0 -2
  193. hikyuu/include/hikyuu/indicator_talib/imp/TaSar.h +0 -2
  194. hikyuu/include/hikyuu/indicator_talib/imp/TaSarext.h +0 -4
  195. hikyuu/include/hikyuu/indicator_talib/imp/TaStoch.h +0 -3
  196. hikyuu/include/hikyuu/indicator_talib/imp/TaStochf.h +0 -2
  197. hikyuu/include/hikyuu/indicator_talib/imp/TaUltosc.h +0 -2
  198. hikyuu/include/hikyuu/indicator_talib/imp/ta_defines.h +2 -4
  199. hikyuu/include/hikyuu/indicator_talib/imp/ta_imp.h +70 -90
  200. hikyuu/include/hikyuu/plugin/KDataToClickHouseImporter.h +40 -0
  201. hikyuu/include/hikyuu/plugin/KDataToMySQLImporter.h +40 -0
  202. hikyuu/include/hikyuu/plugin/checkdata.h +20 -0
  203. hikyuu/include/hikyuu/plugin/extind.h +3 -0
  204. hikyuu/include/hikyuu/plugin/hkuextra.h +4 -0
  205. hikyuu/include/hikyuu/plugin/interface/CheckDataPluginInterface.h +25 -0
  206. hikyuu/include/hikyuu/plugin/interface/HkuExtraPluginInterface.h +4 -0
  207. hikyuu/include/hikyuu/plugin/interface/ImportKDataToClickHousePluginInterface.h +44 -0
  208. hikyuu/include/hikyuu/plugin/interface/ImportKDataToMySQLPluginInterface.h +42 -0
  209. hikyuu/include/hikyuu/plugin/interface/plugins.h +6 -0
  210. hikyuu/include/hikyuu/python/convert_any.h +9 -6
  211. hikyuu/include/hikyuu/python/pybind_utils.h +22 -5
  212. hikyuu/include/hikyuu/strategy/Strategy.h +1 -1
  213. hikyuu/include/hikyuu/trade_manage/TradeCostBase.h +5 -3
  214. hikyuu/include/hikyuu/trade_manage/TradeManagerBase.h +9 -3
  215. hikyuu/include/hikyuu/trade_manage/TradeRecord.h +2 -1
  216. hikyuu/include/hikyuu/trade_sys/allocatefunds/AllocateFundsBase.h +8 -4
  217. hikyuu/include/hikyuu/trade_sys/allocatefunds/build_in.h +1 -0
  218. hikyuu/include/hikyuu/trade_sys/allocatefunds/crt/AF_FixedAmount.h +26 -0
  219. hikyuu/include/hikyuu/trade_sys/allocatefunds/imp/FixAmountFunds.h +18 -0
  220. hikyuu/include/hikyuu/trade_sys/condition/ConditionBase.h +5 -3
  221. hikyuu/include/hikyuu/trade_sys/environment/EnvironmentBase.h +6 -3
  222. hikyuu/include/hikyuu/trade_sys/moneymanager/MoneyManagerBase.h +5 -3
  223. hikyuu/include/hikyuu/trade_sys/multifactor/MultiFactorBase.h +23 -20
  224. hikyuu/include/hikyuu/trade_sys/multifactor/NormalizeBase.h +6 -4
  225. hikyuu/include/hikyuu/trade_sys/multifactor/ScoresFilterBase.h +5 -3
  226. hikyuu/include/hikyuu/trade_sys/multifactor/crt/MF_EqualWeight.h +3 -3
  227. hikyuu/include/hikyuu/trade_sys/multifactor/crt/MF_ICIRWeight.h +4 -4
  228. hikyuu/include/hikyuu/trade_sys/multifactor/crt/MF_ICWeight.h +4 -4
  229. hikyuu/include/hikyuu/trade_sys/multifactor/crt/MF_Weight.h +4 -4
  230. hikyuu/include/hikyuu/trade_sys/portfolio/Portfolio.h +16 -13
  231. hikyuu/include/hikyuu/trade_sys/profitgoal/ProfitGoalBase.h +13 -13
  232. hikyuu/include/hikyuu/trade_sys/selector/SelectorBase.h +12 -3
  233. hikyuu/include/hikyuu/trade_sys/selector/crt/SE_MultiFactor.h +1 -1
  234. hikyuu/include/hikyuu/trade_sys/selector/crt/SE_MultiFactor2.h +1 -1
  235. hikyuu/include/hikyuu/trade_sys/selector/imp/MultiFactorSelector.h +1 -0
  236. hikyuu/include/hikyuu/trade_sys/selector/imp/MultiFactorSelector2.h +1 -0
  237. hikyuu/include/hikyuu/trade_sys/selector/imp/optimal/OptimalSelectorBase.h +0 -2
  238. hikyuu/include/hikyuu/trade_sys/selector/imp/optimal/PerformanceOptimalSelector.h +0 -4
  239. hikyuu/include/hikyuu/trade_sys/signal/SignalBase.h +5 -3
  240. hikyuu/include/hikyuu/trade_sys/slippage/SlippageBase.h +5 -3
  241. hikyuu/include/hikyuu/trade_sys/stoploss/StoplossBase.h +5 -3
  242. hikyuu/include/hikyuu/trade_sys/system/System.h +6 -4
  243. hikyuu/include/hikyuu/utilities/Log.h +6 -7
  244. hikyuu/include/hikyuu/utilities/LruCache.h +299 -0
  245. hikyuu/include/hikyuu/utilities/Parameter.h +17 -0
  246. hikyuu/include/hikyuu/utilities/arithmetic.h +2 -2
  247. hikyuu/include/hikyuu/utilities/config.h +28 -0
  248. hikyuu/include/hikyuu/utilities/omp_macro.h +25 -0
  249. hikyuu/include/hikyuu/utilities/plugin/PluginBase.h +17 -2
  250. hikyuu/include/hikyuu/utilities/plugin/PluginManager.h +46 -22
  251. hikyuu/include/hikyuu/utilities/thread/GlobalStealThreadPool.h +71 -19
  252. hikyuu/include/hikyuu/utilities/thread/GlobalThreadPool.h +1 -5
  253. hikyuu/include/hikyuu/utilities/thread/MQStealThreadPool.h +286 -0
  254. hikyuu/include/hikyuu/utilities/thread/MQThreadPool.h +1 -0
  255. hikyuu/include/hikyuu/utilities/thread/StealThreadPool.h +297 -0
  256. hikyuu/include/hikyuu/utilities/thread/ThreadPool.h +1 -4
  257. hikyuu/include/hikyuu/utilities/thread/WorkStealQueue.h +9 -8
  258. hikyuu/include/hikyuu/utilities/thread/algorithm.h +350 -14
  259. hikyuu/include/hikyuu/version.h +4 -4
  260. hikyuu/plugin/libbacktest.so +0 -0
  261. hikyuu/plugin/libcheckdata.so +0 -0
  262. hikyuu/plugin/libclickhousedriver.so +0 -0
  263. hikyuu/plugin/libdataserver.so +0 -0
  264. hikyuu/plugin/libdataserver_parquet.so +0 -0
  265. hikyuu/plugin/libdevice.so +0 -0
  266. hikyuu/plugin/libextind.so +0 -0
  267. hikyuu/plugin/libhkuextra.so +0 -0
  268. hikyuu/plugin/libimport2ch.so +0 -0
  269. hikyuu/plugin/libimport2hdf5.so +0 -0
  270. hikyuu/plugin/libimport2mysql.so +0 -0
  271. hikyuu/plugin/libtmreport.so +0 -0
  272. hikyuu/test/Indicator.py +1 -2
  273. hikyuu/trade_manage/__init__.pyi +14 -8
  274. hikyuu/trade_manage/trade.pyi +14 -8
  275. hikyuu/trade_sys/trade_sys.py +54 -5
  276. hikyuu/util/__init__.pyi +2 -2
  277. hikyuu/util/singleton.pyi +1 -1
  278. {hikyuu-2.7.0.dist-info → hikyuu-2.7.5.dist-info}/METADATA +10 -4
  279. {hikyuu-2.7.0.dist-info → hikyuu-2.7.5.dist-info}/RECORD +282 -252
  280. hikyuu/cpp/libboost_chrono-mt.so +0 -0
  281. hikyuu/cpp/libboost_chrono-mt.so.1.88.0 +0 -0
  282. hikyuu/cpp/libboost_date_time-mt.so +0 -0
  283. hikyuu/cpp/libboost_date_time-mt.so.1.88.0 +0 -0
  284. hikyuu/cpp/libboost_serialization-mt.so +0 -0
  285. hikyuu/cpp/libboost_serialization-mt.so.1.88.0 +0 -0
  286. hikyuu/cpp/libboost_system-mt.so +0 -0
  287. hikyuu/cpp/libboost_system-mt.so.1.88.0 +0 -0
  288. hikyuu/cpp/libboost_thread-mt.so +0 -0
  289. hikyuu/cpp/libboost_thread-mt.so.1.88.0 +0 -0
  290. hikyuu/cpp/libboost_wserialization-mt.so +0 -0
  291. hikyuu/cpp/libboost_wserialization-mt.so.1.88.0 +0 -0
  292. hikyuu/data/pytdx_to_taos.py +0 -736
  293. {hikyuu-2.7.0.dist-info → hikyuu-2.7.5.dist-info}/WHEEL +0 -0
  294. {hikyuu-2.7.0.dist-info → hikyuu-2.7.5.dist-info}/entry_points.txt +0 -0
  295. {hikyuu-2.7.0.dist-info → hikyuu-2.7.5.dist-info}/top_level.txt +0 -0
@@ -10,28 +10,44 @@
10
10
  #include <future>
11
11
  #include <functional>
12
12
  #include <vector>
13
+ #include <limits>
13
14
  #include "ThreadPool.h"
14
15
  #include "MQThreadPool.h"
16
+ #include "StealThreadPool.h"
17
+ #include "MQStealThreadPool.h"
18
+ #include "GlobalMQThreadPool.h"
19
+ #include "GlobalStealThreadPool.h"
20
+ #include "GlobalMQStealThreadPool.h"
21
+ #include "GlobalThreadPool.h"
22
+
23
+ #ifndef HKU_UTILS_API
24
+ #define HKU_UTILS_API
25
+ #endif
15
26
 
16
27
  //----------------------------------------------------------------
17
28
  // Note: 除 ThreadPool/MQThreadPool 外,其他线程池由于使用
18
29
  // 了 thread_local,本质为全局变量,只适合全局单例的方式使用,
19
30
  // 否则会出现不同线程池示例互相影响导致出错。
31
+ // 每次会创建独立的线程池计算。
32
+ // 如果都是纯计算(IO较少),
33
+ // 建议创建全局线程池,并使用全局线程池进行计算。
20
34
  //----------------------------------------------------------------
21
35
 
22
36
  namespace hku {
23
37
 
24
38
  typedef std::pair<size_t, size_t> range_t;
25
39
 
26
- inline std::vector<range_t> parallelIndexRange(size_t start, size_t end) {
40
+ inline std::vector<range_t> parallelIndexRange(size_t start, size_t end, size_t cpu_num = 0) {
27
41
  std::vector<std::pair<size_t, size_t>> ret;
28
42
  if (start >= end) {
29
43
  return ret;
30
44
  }
31
45
 
32
46
  size_t total = end - start;
33
- size_t cpu_num = std::thread::hardware_concurrency();
34
- if (cpu_num == 1) {
47
+ if (cpu_num == 0) {
48
+ cpu_num = std::thread::hardware_concurrency();
49
+ }
50
+ if (cpu_num <= 1) {
35
51
  ret.emplace_back(start, end);
36
52
  return ret;
37
53
  }
@@ -52,9 +68,13 @@ inline std::vector<range_t> parallelIndexRange(size_t start, size_t end) {
52
68
  }
53
69
 
54
70
  template <typename FunctionType, class TaskGroup = MQThreadPool>
55
- void parallel_for_index_void(size_t start, size_t end, FunctionType f) {
56
- auto ranges = parallelIndexRange(start, end);
57
- TaskGroup tg;
71
+ void parallel_for_index_void(size_t start, size_t end, FunctionType f, int cpu_num = 0) {
72
+ auto ranges = parallelIndexRange(start, end, cpu_num);
73
+ if (ranges.empty()) {
74
+ return;
75
+ }
76
+
77
+ TaskGroup tg(cpu_num == 0 ? std::thread::hardware_concurrency() : cpu_num);
58
78
  for (size_t i = 0, total = ranges.size(); i < total; i++) {
59
79
  tg.submit([=, range = ranges[i]]() {
60
80
  for (size_t ix = range.first; ix < range.second; ix++) {
@@ -67,9 +87,14 @@ void parallel_for_index_void(size_t start, size_t end, FunctionType f) {
67
87
  }
68
88
 
69
89
  template <typename FunctionType, class TaskGroup = MQThreadPool>
70
- auto parallel_for_index(size_t start, size_t end, FunctionType f) {
71
- auto ranges = parallelIndexRange(start, end);
72
- TaskGroup tg;
90
+ auto parallel_for_index(size_t start, size_t end, FunctionType f, size_t cpu_num = 0) {
91
+ std::vector<typename std::invoke_result<FunctionType, size_t>::type> ret;
92
+ auto ranges = parallelIndexRange(start, end, cpu_num);
93
+ if (ranges.empty()) {
94
+ return ret;
95
+ }
96
+
97
+ TaskGroup tg(cpu_num == 0 ? std::thread::hardware_concurrency() : cpu_num);
73
98
  std::vector<std::future<std::vector<typename std::invoke_result<FunctionType, size_t>::type>>>
74
99
  tasks;
75
100
  for (size_t i = 0, total = ranges.size(); i < total; i++) {
@@ -82,7 +107,6 @@ auto parallel_for_index(size_t start, size_t end, FunctionType f) {
82
107
  }));
83
108
  }
84
109
 
85
- std::vector<typename std::invoke_result<FunctionType, size_t>::type> ret;
86
110
  for (auto& task : tasks) {
87
111
  auto one = task.get();
88
112
  for (auto&& value : one) {
@@ -94,15 +118,19 @@ auto parallel_for_index(size_t start, size_t end, FunctionType f) {
94
118
  }
95
119
 
96
120
  template <typename FunctionType, class TaskGroup = MQThreadPool>
97
- auto parallel_for_range(size_t start, size_t end, FunctionType f) {
98
- auto ranges = parallelIndexRange(start, end);
99
- TaskGroup tg;
121
+ auto parallel_for_range(size_t start, size_t end, FunctionType f, size_t cpu_num = 0) {
122
+ typename std::invoke_result<FunctionType, range_t>::type ret;
123
+ auto ranges = parallelIndexRange(start, end, cpu_num);
124
+ if (ranges.empty()) {
125
+ return ret;
126
+ }
127
+
128
+ TaskGroup tg(cpu_num == 0 ? std::thread::hardware_concurrency() : cpu_num);
100
129
  std::vector<std::future<typename std::invoke_result<FunctionType, range_t>::type>> tasks;
101
130
  for (size_t i = 0, total = ranges.size(); i < total; i++) {
102
131
  tasks.emplace_back(tg.submit([func = f, range = ranges[i]]() { return func(range); }));
103
132
  }
104
133
 
105
- typename std::invoke_result<FunctionType, range_t>::type ret;
106
134
  for (auto& task : tasks) {
107
135
  auto one = task.get();
108
136
  for (auto&& value : one) {
@@ -113,4 +141,312 @@ auto parallel_for_range(size_t start, size_t end, FunctionType f) {
113
141
  return ret;
114
142
  }
115
143
 
144
+ template <typename FunctionType, class TaskGroup = ThreadPool>
145
+ void parallel_for_index_void_single(size_t start, size_t end, FunctionType f, int cpu_num = 0) {
146
+ if (start >= end) {
147
+ return;
148
+ }
149
+
150
+ TaskGroup tg(cpu_num == 0 ? std::thread::hardware_concurrency() : cpu_num);
151
+ for (size_t i = start; i < end; i++) {
152
+ tg.submit([func = f, i]() { func(i); });
153
+ }
154
+ tg.join();
155
+ return;
156
+ }
157
+
158
+ template <typename FunctionType, class TaskGroup = ThreadPool>
159
+ auto parallel_for_index_single(size_t start, size_t end, FunctionType f, size_t cpu_num = 0) {
160
+ std::vector<typename std::invoke_result<FunctionType, size_t>::type> ret;
161
+ if (start >= end) {
162
+ return ret;
163
+ }
164
+
165
+ TaskGroup tg(cpu_num == 0 ? std::thread::hardware_concurrency() : cpu_num);
166
+ std::vector<std::future<typename std::invoke_result<FunctionType, size_t>::type>> tasks;
167
+ for (size_t i = start; i < end; i++) {
168
+ tasks.emplace_back(tg.submit([func = f, i]() { return func(i); }));
169
+ }
170
+
171
+ for (auto& task : tasks) {
172
+ ret.push_back(std::move(task.get()));
173
+ }
174
+
175
+ return ret;
176
+ }
177
+
178
+ //----------------------------------------------------------------
179
+ // 创建全局任务偷取线程池,主要目的用于计算密集或少量混合IO的并行,不适合纯IO的并行
180
+ // 前面 parallel_for 系列每次都会创建独立线程池。
181
+ // note: 程序内全局,初始化一次即可,重复初始化被忽略
182
+ //----------------------------------------------------------------
183
+ void HKU_UTILS_API init_global_task_group(size_t work_num = 0);
184
+
185
+ void HKU_UTILS_API release_global_task_group();
186
+
187
+ HKU_UTILS_API GlobalStealThreadPool* get_global_task_group();
188
+
189
+ size_t HKU_UTILS_API get_global_task_group_work_num();
190
+
191
+ template <typename FutureContainer>
192
+ void wait_for_all_non_blocking(GlobalStealThreadPool& pool, FutureContainer& futures) {
193
+ bool all_ready = false;
194
+ auto init_delay = std::chrono::microseconds(1);
195
+ auto delay = init_delay;
196
+ const auto max_delay = std::chrono::microseconds(50000);
197
+
198
+ while (!all_ready && !pool.done()) {
199
+ all_ready = true;
200
+ for (auto& future : futures) {
201
+ if (future.wait_for(std::chrono::nanoseconds(0)) != std::future_status::ready) {
202
+ all_ready = false;
203
+ break;
204
+ }
205
+ }
206
+
207
+ // 如果不是所有任务都完成,尝试执行本地任务
208
+ if (!all_ready) {
209
+ if (!pool.run_available_task_once()) {
210
+ delay = init_delay;
211
+ } else if (pool.done()) {
212
+ break;
213
+ } else {
214
+ std::this_thread::sleep_for(delay);
215
+ if (delay < max_delay) {
216
+ delay = std::min(delay * 2, max_delay);
217
+ }
218
+ }
219
+ }
220
+ }
221
+ }
222
+
223
+ // 辅助类,用于确保线程执行状态的正确管理
224
+ #ifdef _MSC_VER
225
+ class ExecutionGuard {
226
+ #else
227
+ class HKU_UTILS_API ExecutionGuard {
228
+ #endif
229
+
230
+ public:
231
+ explicit ExecutionGuard(bool initial_value = true) : p_flag(&in_parallel_execution) {
232
+ *p_flag = initial_value;
233
+ }
234
+
235
+ ~ExecutionGuard() {
236
+ if (p_flag) {
237
+ *p_flag = false;
238
+ }
239
+ }
240
+
241
+ ExecutionGuard(const ExecutionGuard&) = delete;
242
+ ExecutionGuard& operator=(const ExecutionGuard&) = delete;
243
+
244
+ ExecutionGuard(ExecutionGuard&& other) : p_flag(other.p_flag) {
245
+ other.p_flag = nullptr;
246
+ }
247
+
248
+ static bool is_executing() {
249
+ return in_parallel_execution;
250
+ }
251
+
252
+ private:
253
+ #if CPP_STANDARD >= CPP_STANDARD_17 && !defined(__clang__)
254
+ inline static thread_local bool in_parallel_execution{false};
255
+ #else
256
+ static thread_local bool in_parallel_execution;
257
+ #endif
258
+ bool* p_flag;
259
+ };
260
+
261
+ template <typename FunctionType>
262
+ auto global_parallel_for_index_void(size_t start, size_t end, FunctionType f, size_t threshold = 2,
263
+ bool enable_nested = true) {
264
+ auto* tg = get_global_task_group();
265
+ HKU_CHECK(tg, "Global task group is not initialized!");
266
+ HKU_IF_RETURN(start >= end, void());
267
+
268
+ // 检查当前线程是否已经在执行某个任务,如果是则降级为串行执行
269
+ if ((end - start) < threshold || (!enable_nested && ExecutionGuard::is_executing())) {
270
+ for (size_t i = start; i < end; i++) {
271
+ f(i);
272
+ }
273
+ return;
274
+ }
275
+
276
+ ExecutionGuard guard;
277
+
278
+ auto ranges = parallelIndexRange(start, end, tg->worker_num());
279
+ if (ranges.empty()) {
280
+ return;
281
+ }
282
+
283
+ std::vector<std::future<void>> tasks;
284
+ tasks.reserve(ranges.size());
285
+ for (size_t i = 0, total = ranges.size(); i < total; i++) {
286
+ tasks.emplace_back(tg->submit([enable_nested, func = f, range = ranges[i]]() {
287
+ if (!enable_nested && ExecutionGuard::is_executing()) {
288
+ for (size_t ix = range.first; ix < range.second; ix++) {
289
+ func(ix);
290
+ }
291
+ } else {
292
+ ExecutionGuard guard_inner;
293
+ for (size_t ix = range.first; ix < range.second; ix++) {
294
+ func(ix);
295
+ }
296
+ }
297
+ }));
298
+ }
299
+
300
+ wait_for_all_non_blocking(*tg, tasks);
301
+
302
+ for (auto& task : tasks) {
303
+ task.get();
304
+ }
305
+
306
+ return;
307
+ }
308
+
309
+ template <typename FunctionType>
310
+ auto global_parallel_for_index(size_t start, size_t end, FunctionType f, size_t threshold = 2,
311
+ bool enable_nested = true) {
312
+ auto* tg = get_global_task_group();
313
+ HKU_CHECK(tg, "Global task group is not initialized!");
314
+
315
+ std::vector<typename std::invoke_result<FunctionType, size_t>::type> ret;
316
+ HKU_IF_RETURN(start >= end, ret);
317
+
318
+ ret.reserve(end - start);
319
+
320
+ // 检查当前线程是否已经在执行某个任务,如果是则降级为串行执行
321
+ if ((end - start) < threshold || (!enable_nested && ExecutionGuard::is_executing())) {
322
+ for (size_t i = start; i < end; i++) {
323
+ ret.emplace_back(f(i));
324
+ }
325
+ return ret;
326
+ }
327
+
328
+ ExecutionGuard guard;
329
+
330
+ auto ranges = parallelIndexRange(start, end, tg->worker_num());
331
+ if (ranges.empty()) {
332
+ return ret;
333
+ }
334
+
335
+ std::vector<std::future<std::vector<typename std::invoke_result<FunctionType, size_t>::type>>>
336
+ tasks;
337
+ tasks.reserve(ranges.size());
338
+ for (size_t i = 0, total = ranges.size(); i < total; i++) {
339
+ tasks.emplace_back(tg->submit([enable_nested, func = f, range = ranges[i]]() {
340
+ std::vector<typename std::invoke_result<FunctionType, size_t>::type> one_ret;
341
+ one_ret.reserve(range.second - range.first);
342
+ if (!enable_nested && ExecutionGuard::is_executing()) {
343
+ for (size_t ix = range.first; ix < range.second; ix++) {
344
+ one_ret.emplace_back(func(ix));
345
+ }
346
+ return one_ret;
347
+ } else {
348
+ ExecutionGuard guard_inner;
349
+ for (size_t ix = range.first; ix < range.second; ix++) {
350
+ one_ret.emplace_back(func(ix));
351
+ }
352
+ return one_ret;
353
+ }
354
+ }));
355
+ }
356
+
357
+ wait_for_all_non_blocking(*tg, tasks);
358
+
359
+ for (auto& task : tasks) {
360
+ auto one = task.get();
361
+ for (auto&& value : one) {
362
+ ret.emplace_back(std::move(value));
363
+ }
364
+ }
365
+
366
+ return ret;
367
+ }
368
+
369
+ template <typename FunctionType>
370
+ void global_parallel_for_index_void_single(size_t start, size_t end, FunctionType f,
371
+ size_t threshold = 1, bool enable_nested = true) {
372
+ auto* tg = get_global_task_group();
373
+ HKU_CHECK(tg, "Global task group is not initialized!");
374
+ HKU_IF_RETURN(start >= end, void());
375
+
376
+ // 检查当前线程是否已经在执行某个任务,如果是则降级为串行执行
377
+ if ((end - start) < threshold || (!enable_nested && ExecutionGuard::is_executing())) {
378
+ for (size_t i = start; i < end; i++) {
379
+ f(i);
380
+ }
381
+ return;
382
+ }
383
+
384
+ ExecutionGuard guard;
385
+
386
+ std::vector<std::future<void>> tasks;
387
+ tasks.reserve(end - start);
388
+ for (size_t i = start; i < end; i++) {
389
+ tasks.push_back(tg->submit([enable_nested, func = f, i]() {
390
+ if (!enable_nested && ExecutionGuard::is_executing()) {
391
+ func(i);
392
+ } else {
393
+ ExecutionGuard guard_inner;
394
+ func(i);
395
+ }
396
+ }));
397
+ }
398
+
399
+ wait_for_all_non_blocking(*tg, tasks);
400
+
401
+ for (auto& task : tasks) {
402
+ task.get();
403
+ }
404
+ return;
405
+ }
406
+
407
+ template <typename FunctionType>
408
+ auto global_parallel_for_index_single(size_t start, size_t end, FunctionType f,
409
+ size_t threshold = 1, bool enable_nested = true) {
410
+ auto* tg = get_global_task_group();
411
+ HKU_CHECK(tg, "Global task group is not initialized!");
412
+
413
+ std::vector<typename std::invoke_result<FunctionType, size_t>::type> ret;
414
+ HKU_IF_RETURN(start >= end, ret);
415
+
416
+ ret.reserve(end - start);
417
+
418
+ // 检查当前线程是否已经在执行某个任务,如果是则降级为串行执行
419
+ if ((end - start) < threshold || (!enable_nested && ExecutionGuard::is_executing())) {
420
+ for (size_t i = start; i < end; i++) {
421
+ ret.push_back(f(i));
422
+ }
423
+ return ret;
424
+ }
425
+
426
+ ExecutionGuard guard;
427
+
428
+ std::vector<std::future<typename std::invoke_result<FunctionType, size_t>::type>> tasks;
429
+ tasks.reserve(end - start);
430
+ for (size_t i = start; i < end; i++) {
431
+ tasks.emplace_back(tg->submit([func = f, i, enable_nested]() ->
432
+ typename std::invoke_result<FunctionType, size_t>::type {
433
+ // 在任务内部也要检查嵌套
434
+ if (!enable_nested && ExecutionGuard::is_executing()) {
435
+ return func(i);
436
+ } else {
437
+ ExecutionGuard guard_inner;
438
+ return func(i);
439
+ }
440
+ }));
441
+ }
442
+
443
+ wait_for_all_non_blocking(*tg, tasks);
444
+
445
+ for (auto& task : tasks) {
446
+ ret.push_back(std::move(task.get()));
447
+ }
448
+
449
+ return ret;
450
+ }
451
+
116
452
  } // namespace hku
@@ -12,13 +12,13 @@
12
12
  #define HKU_VERSION_H
13
13
 
14
14
  // clang-format off
15
- #define HKU_VERSION "2.7.0"
15
+ #define HKU_VERSION "2.7.5"
16
16
  #define HKU_VERSION_MAJOR 2
17
17
  #define HKU_VERSION_MINOR 7
18
- #define HKU_VERSION_ALTER 0
19
- #define HKU_VERSION_BUILD 202511020003
18
+ #define HKU_VERSION_ALTER 5
19
+ #define HKU_VERSION_BUILD 202602020435
20
20
  #define HKU_VERSION_MODE "RELEASE"
21
- #define HKU_VERSION_GIT "2.7.0 release.3d6e5754 (RELEASE)"
21
+ #define HKU_VERSION_GIT "2.7.5 release.b29df2ae (RELEASE)"
22
22
  // clang-format on
23
23
 
24
24
  #endif /* HKU_VERSION_H */
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
hikyuu/test/Indicator.py CHANGED
@@ -199,8 +199,7 @@ class IndicatorTest(unittest.TestCase):
199
199
  x = PRICELIST(a)
200
200
  m = MA(x, 2)
201
201
  self.assertEqual(len(m), 4)
202
- self.assertEqual(m.discard, 0)
203
- self.assertTrue(abs(m[0] - 0.0) < 0.0001)
202
+ self.assertEqual(m.discard, 1)
204
203
  self.assertTrue(abs(m[1] - 0.5) < 0.0001)
205
204
  self.assertTrue(abs(m[2] - 1.5) < 0.0001)
206
205
  self.assertTrue(abs(m[3] - 2.5) < 0.0001)
@@ -11,6 +11,7 @@ from hikyuu.cpp.core310 import ACOS
11
11
  from hikyuu.cpp.core310 import AD
12
12
  from hikyuu.cpp.core310 import ADVANCE
13
13
  from hikyuu.cpp.core310 import AF_EqualWeight
14
+ from hikyuu.cpp.core310 import AF_FixedAmount
14
15
  from hikyuu.cpp.core310 import AF_FixedWeight
15
16
  from hikyuu.cpp.core310 import AF_FixedWeightList
16
17
  from hikyuu.cpp.core310 import AF_MultiFactor
@@ -26,6 +27,7 @@ from hikyuu.cpp.core310 import AGG_QUANTILE
26
27
  from hikyuu.cpp.core310 import AGG_STD
27
28
  from hikyuu.cpp.core310 import AGG_SUM
28
29
  from hikyuu.cpp.core310 import AGG_VAR
30
+ from hikyuu.cpp.core310 import AGG_VWAP
29
31
  from hikyuu.cpp.core310 import ALIGN
30
32
  from hikyuu.cpp.core310 import AMA
31
33
  from hikyuu.cpp.core310 import ASIN
@@ -133,14 +135,16 @@ from hikyuu.cpp.core310 import KALMAN
133
135
  from hikyuu.cpp.core310 import KDATA_PART
134
136
  from hikyuu.cpp.core310 import KData
135
137
  from hikyuu.cpp.core310 import KDataDriver
138
+ from hikyuu.cpp.core310 import KDataToClickHouseImporter
136
139
  from hikyuu.cpp.core310 import KDataToHdf5Importer
140
+ from hikyuu.cpp.core310 import KDataToMySQLImporter
137
141
  from hikyuu.cpp.core310 import KRecord
138
142
  from hikyuu.cpp.core310 import KRecordList
139
143
  from hikyuu.cpp.core310 import LAST
140
- from hikyuu.cpp.core310 import LASTVALUE as CONST
141
144
  from hikyuu.cpp.core310 import LASTVALUE
142
- from hikyuu.cpp.core310 import LIUTONGPAN as CAPITAL
145
+ from hikyuu.cpp.core310 import LASTVALUE as CONST
143
146
  from hikyuu.cpp.core310 import LIUTONGPAN
147
+ from hikyuu.cpp.core310 import LIUTONGPAN as CAPITAL
144
148
  from hikyuu.cpp.core310 import LLV
145
149
  from hikyuu.cpp.core310 import LLVBARS
146
150
  from hikyuu.cpp.core310 import LN
@@ -192,8 +196,8 @@ from hikyuu.cpp.core310 import PG_FixedPercent
192
196
  from hikyuu.cpp.core310 import PG_NoGoal
193
197
  from hikyuu.cpp.core310 import POS
194
198
  from hikyuu.cpp.core310 import POW
195
- from hikyuu.cpp.core310 import PRICELIST
196
199
  from hikyuu.cpp.core310 import PRICELIST as VALUE
200
+ from hikyuu.cpp.core310 import PRICELIST
197
201
  from hikyuu.cpp.core310 import Parameter
198
202
  from hikyuu.cpp.core310 import Performance
199
203
  from hikyuu.cpp.core310 import Portfolio
@@ -265,8 +269,8 @@ from hikyuu.cpp.core310 import SP_Normal
265
269
  from hikyuu.cpp.core310 import SP_TruncNormal
266
270
  from hikyuu.cpp.core310 import SP_Uniform
267
271
  from hikyuu.cpp.core310 import SQRT
268
- from hikyuu.cpp.core310 import STDEV as STD
269
272
  from hikyuu.cpp.core310 import STDEV
273
+ from hikyuu.cpp.core310 import STDEV as STD
270
274
  from hikyuu.cpp.core310 import STDP
271
275
  from hikyuu.cpp.core310 import ST_FixedPercent
272
276
  from hikyuu.cpp.core310 import ST_Indicator
@@ -511,6 +515,7 @@ from hikyuu.cpp.core310 import backtest
511
515
  from hikyuu.cpp.core310 import batch_calculate_inds
512
516
  from hikyuu.cpp.core310 import bind_email
513
517
  from hikyuu.cpp.core310 import can_upgrade
518
+ from hikyuu.cpp.core310 import check_data
514
519
  from hikyuu.cpp.core310 import close_ostream_to_python
515
520
  from hikyuu.cpp.core310 import close_spend_time
516
521
  from hikyuu.cpp.core310 import combinate_ind
@@ -522,6 +527,7 @@ from hikyuu.cpp.core310 import crt_pf_strategy
522
527
  from hikyuu.cpp.core310 import crt_sys_strategy
523
528
  from hikyuu.cpp.core310 import dates_to_np
524
529
  from hikyuu.cpp.core310 import df_to_krecords
530
+ from hikyuu.cpp.core310 import enable_kdata_cache
525
531
  from hikyuu.cpp.core310 import fetch_trial_license
526
532
  from hikyuu.cpp.core310 import find_optimal_system
527
533
  from hikyuu.cpp.core310 import find_optimal_system_multi
@@ -532,7 +538,7 @@ from hikyuu.cpp.core310 import get_date_range
532
538
  from hikyuu.cpp.core310 import get_expire_date
533
539
  from hikyuu.cpp.core310 import get_funds_list
534
540
  from hikyuu.cpp.core310 import get_kdata
535
- from hikyuu.cpp.core310 import get_last_version
541
+ from hikyuu.cpp.core310 import get_latest_version_info
536
542
  from hikyuu.cpp.core310 import get_log_level
537
543
  from hikyuu.cpp.core310 import get_spot_from_buffer_server
538
544
  from hikyuu.cpp.core310 import get_stock
@@ -623,8 +629,8 @@ from hikyuu.util.mylog import class_logger
623
629
  from hikyuu.util.mylog import hku_benchmark
624
630
  from hikyuu.util.mylog import hku_debug as hku_trace
625
631
  from hikyuu.util.mylog import hku_debug
626
- from hikyuu.util.mylog import hku_debug_if
627
632
  from hikyuu.util.mylog import hku_debug_if as hku_trace_if
633
+ from hikyuu.util.mylog import hku_debug_if
628
634
  from hikyuu.util.mylog import hku_error
629
635
  from hikyuu.util.mylog import hku_error_if
630
636
  from hikyuu.util.mylog import hku_fatal
@@ -639,7 +645,6 @@ from hikyuu.util.mylog import with_trace
639
645
  from hikyuu.util.notebook import in_interactive_session
640
646
  from hikyuu.util.notebook import in_ipython_frontend
641
647
  from hikyuu.util.timeout import timeout
642
- import io as io
643
648
  import locale as locale
644
649
  import logging
645
650
  import numpy as np
@@ -648,12 +653,13 @@ import pandas as pd
648
653
  from pathlib import Path
649
654
  import pickle as pickle
650
655
  import sys as sys
656
+ import time as time
651
657
  import traceback as traceback
652
658
  from . import broker
653
659
  from . import broker_easytrader
654
660
  from . import broker_mail
655
661
  from . import trade
656
- __all__: list[str] = ['ABS', 'ACOS', 'AD', 'ADVANCE', 'AF_EqualWeight', 'AF_FixedWeight', 'AF_FixedWeightList', 'AF_MultiFactor', 'AGG_COUNT', 'AGG_FUNC', 'AGG_MAD', 'AGG_MAX', 'AGG_MEAN', 'AGG_MEDIAN', 'AGG_MIN', 'AGG_PROD', 'AGG_QUANTILE', 'AGG_STD', 'AGG_SUM', 'AGG_VAR', 'ALIGN', 'AMA', 'AMO', 'ASIN', 'ATAN', 'ATR', 'AVEDEV', 'AllocateFundsBase', 'BACKSET', 'BARSCOUNT', 'BARSLAST', 'BARSLASTCOUNT', 'BARSSINCE', 'BARSSINCEN', 'BASE_DIR', 'BETWEEN', 'BLOCKSETNUM', 'BUSINESS', 'Block', 'BlockInfoDriver', 'BorrowRecord', 'BrokerPositionRecord', 'CAPITAL', 'CEILING', 'CLOSE', 'CN_Bool', 'CN_OPLine', 'CONST', 'CONTEXT', 'CONTEXT_K', 'CORR', 'COS', 'COST', 'COUNT', 'CROSS', 'CVAL', 'CYCLE', 'C_AMO', 'C_CLOSE', 'C_HIGH', 'C_KDATA', 'C_LOW', 'C_OPEN', 'C_VOL', 'ConditionBase', 'Constant', 'CostRecord', 'DATE', 'DAY', 'DEBUG', 'DECLINE', 'DEVSQ', 'DIFF', 'DISCARD', 'DMA', 'DOWNNDAY', 'DROPNA', 'DataDriverFactory', 'Datetime', 'DatetimeList', 'DatetimeList_to_df', 'DatetimeList_to_np', 'Datetime_date', 'Datetime_datetime', 'Days', 'EMA', 'ERROR', 'EVERY', 'EV_Bool', 'EV_TwoLine', 'EXIST', 'EXP', 'EasyTraderOrderBroker', 'EnvironmentBase', 'FATAL', 'FILTER', 'FINANCE', 'FLOOR', 'FundsRecord', 'GROUP_COUNT', 'GROUP_FUNC', 'GROUP_MAX', 'GROUP_MEAN', 'GROUP_MIN', 'GROUP_PROD', 'GROUP_SUM', 'HHV', 'HHVBARS', 'HIGH', 'HKUCheckError', 'HKUException', 'HOUR', 'HSL', 'Hours', 'IC', 'ICIR', 'IF', 'INBLOCK', 'INDEXA', 'INDEXADV', 'INDEXC', 'INDEXDEC', 'INDEXH', 'INDEXL', 'INDEXO', 'INDEXV', 'INFO', 'INSUM', 'INTPART', 'IR', 'ISINF', 'ISINFA', 'ISLASTBAR', 'ISNA', 'IndParam', 'Indicator', 'IndicatorImp', 'JUMPDOWN', 'JUMPUP', 'KALMAN', 'KDATA', 'KDATA_PART', 'KDJ', 'KData', 'KDataDriver', 'KDataToHdf5Importer', 'KRecord', 'KRecordList', 'LAST', 'LASTVALUE', 'LIUTONGPAN', 'LLV', 'LLVBARS', 'LN', 'LOG', 'LOG_LEVEL', 'LONGCROSS', 'LOW', 'LoanRecord', 'LoggingContext', 'MA', 'MACD', 'MAX', 'MDD', 'MF_EqualWeight', 'MF_ICIRWeight', 'MF_ICWeight', 'MF_Weight', 'MIN', 'MINUTE', 'MM_FixedCapital', 'MM_FixedCapitalFunds', 'MM_FixedCount', 'MM_FixedCountTps', 'MM_FixedPercent', 'MM_FixedRisk', 'MM_FixedUnits', 'MM_Nothing', 'MM_WilliamsFixedRisk', 'MOD', 'MONTH', 'MRR', 'MailOrderBroker', 'MarketInfo', 'Microseconds', 'Milliseconds', 'Minutes', 'MoneyManagerBase', 'MultiFactorBase', 'NDAY', 'NORM_MinMax', 'NORM_NOTHING', 'NORM_Quantile', 'NORM_Quantile_Uniform', 'NORM_Zscore', 'NOT', 'NormalizeBase', 'OFF', 'OPEN', 'OrderBrokerBase', 'OrderBrokerWrap', 'PF_Simple', 'PF_WithoutAF', 'PG_FixedHoldDays', 'PG_FixedPercent', 'PG_NoGoal', 'POS', 'POW', 'PRICELIST', 'Parameter', 'Parameter_items', 'Parameter_iter', 'Parameter_keys', 'Parameter_to_dict', 'Path', 'Performance', 'Performance_to_df', 'Portfolio', 'PositionRecord', 'PositionRecordList', 'ProfitGoalBase', 'QUANTILE_TRUNC', 'Query', 'RANK', 'RECOVER_BACKWARD', 'RECOVER_EQUAL_BACKWARD', 'RECOVER_EQUAL_FORWARD', 'RECOVER_FORWARD', 'REF', 'REFX', 'REPLACE', 'RESULT', 'REVERSE', 'ROC', 'ROCP', 'ROCR', 'ROCR100', 'ROUND', 'ROUNDDOWN', 'ROUNDUP', 'RSI', 'SAFTYLOSS', 'SCFilter_AmountLimit', 'SCFilter_Group', 'SCFilter_IgnoreNan', 'SCFilter_LessOrEqualValue', 'SCFilter_Price', 'SCFilter_TopN', 'SE_EvaluateOptimal', 'SE_Fixed', 'SE_MaxFundsOptimal', 'SE_MultiFactor', 'SE_MultiFactor2', 'SE_PerformanceOptimal', 'SE_Signal', 'SGN', 'SG_Add', 'SG_AllwaysBuy', 'SG_And', 'SG_Band', 'SG_Bool', 'SG_Buy', 'SG_Cross', 'SG_CrossGold', 'SG_Cycle', 'SG_Div', 'SG_Flex', 'SG_Mul', 'SG_OneSide', 'SG_Or', 'SG_Sell', 'SG_Single', 'SG_Single2', 'SG_Sub', 'SIN', 'SLICE', 'SLOPE', 'SMA', 'SPEARMAN', 'SP_FixedPercent', 'SP_FixedValue', 'SP_LogNormal', 'SP_Normal', 'SP_TruncNormal', 'SP_Uniform', 'SQRT', 'STD', 'STDEV', 'STDP', 'ST_FixedPercent', 'ST_Indicator', 'ST_Saftyloss', 'SUM', 'SUMBARS', 'SYS_Simple', 'SYS_WalkForward', 'ScoreRecord', 'ScoreRecordList', 'ScoresFilterBase', 'Seconds', 'SelectorBase', 'SignalBase', 'SlippageBase', 'SpotRecord', 'Stock', 'StockManager', 'StockTypeInfo', 'StockWeight', 'StockWeightList', 'StoplossBase', 'Strategy', 'StrategyContext', 'System', 'SystemPart', 'SystemWeight', 'SystemWeightList', 'TAN', 'TA_ACCBANDS', 'TA_ACOS', 'TA_AD', 'TA_ADD', 'TA_ADOSC', 'TA_ADX', 'TA_ADXR', 'TA_APO', 'TA_AROON', 'TA_AROONOSC', 'TA_ASIN', 'TA_ATAN', 'TA_ATR', 'TA_AVGDEV', 'TA_AVGPRICE', 'TA_BBANDS', 'TA_BETA', 'TA_BOP', 'TA_CCI', 'TA_CDL2CROWS', 'TA_CDL3BLACKCROWS', 'TA_CDL3INSIDE', 'TA_CDL3LINESTRIKE', 'TA_CDL3OUTSIDE', 'TA_CDL3STARSINSOUTH', 'TA_CDL3WHITESOLDIERS', 'TA_CDLABANDONEDBABY', 'TA_CDLADVANCEBLOCK', 'TA_CDLBELTHOLD', 'TA_CDLBREAKAWAY', 'TA_CDLCLOSINGMARUBOZU', 'TA_CDLCONCEALBABYSWALL', 'TA_CDLCOUNTERATTACK', 'TA_CDLDARKCLOUDCOVER', 'TA_CDLDOJI', 'TA_CDLDOJISTAR', 'TA_CDLDRAGONFLYDOJI', 'TA_CDLENGULFING', 'TA_CDLEVENINGDOJISTAR', 'TA_CDLEVENINGSTAR', 'TA_CDLGAPSIDESIDEWHITE', 'TA_CDLGRAVESTONEDOJI', 'TA_CDLHAMMER', 'TA_CDLHANGINGMAN', 'TA_CDLHARAMI', 'TA_CDLHARAMICROSS', 'TA_CDLHIGHWAVE', 'TA_CDLHIKKAKE', 'TA_CDLHIKKAKEMOD', 'TA_CDLHOMINGPIGEON', 'TA_CDLIDENTICAL3CROWS', 'TA_CDLINNECK', 'TA_CDLINVERTEDHAMMER', 'TA_CDLKICKING', 'TA_CDLKICKINGBYLENGTH', 'TA_CDLLADDERBOTTOM', 'TA_CDLLONGLEGGEDDOJI', 'TA_CDLLONGLINE', 'TA_CDLMARUBOZU', 'TA_CDLMATCHINGLOW', 'TA_CDLMATHOLD', 'TA_CDLMORNINGDOJISTAR', 'TA_CDLMORNINGSTAR', 'TA_CDLONNECK', 'TA_CDLPIERCING', 'TA_CDLRICKSHAWMAN', 'TA_CDLRISEFALL3METHODS', 'TA_CDLSEPARATINGLINES', 'TA_CDLSHOOTINGSTAR', 'TA_CDLSHORTLINE', 'TA_CDLSPINNINGTOP', 'TA_CDLSTALLEDPATTERN', 'TA_CDLSTICKSANDWICH', 'TA_CDLTAKURI', 'TA_CDLTASUKIGAP', 'TA_CDLTHRUSTING', 'TA_CDLTRISTAR', 'TA_CDLUNIQUE3RIVER', 'TA_CDLUPSIDEGAP2CROWS', 'TA_CDLXSIDEGAP3METHODS', 'TA_CEIL', 'TA_CMO', 'TA_CORREL', 'TA_COS', 'TA_COSH', 'TA_DEMA', 'TA_DIV', 'TA_DX', 'TA_EMA', 'TA_EXP', 'TA_FLOOR', 'TA_HT_DCPERIOD', 'TA_HT_DCPHASE', 'TA_HT_PHASOR', 'TA_HT_SINE', 'TA_HT_TRENDLINE', 'TA_HT_TRENDMODE', 'TA_IMI', 'TA_KAMA', 'TA_LINEARREG', 'TA_LINEARREG_ANGLE', 'TA_LINEARREG_INTERCEPT', 'TA_LINEARREG_SLOPE', 'TA_LN', 'TA_LOG10', 'TA_MA', 'TA_MACD', 'TA_MACDEXT', 'TA_MACDFIX', 'TA_MAMA', 'TA_MAVP', 'TA_MAX', 'TA_MAXINDEX', 'TA_MEDPRICE', 'TA_MFI', 'TA_MIDPOINT', 'TA_MIDPRICE', 'TA_MIN', 'TA_MININDEX', 'TA_MINMAX', 'TA_MINMAXINDEX', 'TA_MINUS_DI', 'TA_MINUS_DM', 'TA_MOM', 'TA_MULT', 'TA_NATR', 'TA_OBV', 'TA_PLUS_DI', 'TA_PLUS_DM', 'TA_PPO', 'TA_ROC', 'TA_ROCP', 'TA_ROCR', 'TA_ROCR100', 'TA_RSI', 'TA_SAR', 'TA_SAREXT', 'TA_SIN', 'TA_SINH', 'TA_SMA', 'TA_SQRT', 'TA_STDDEV', 'TA_STOCH', 'TA_STOCHF', 'TA_STOCHRSI', 'TA_SUB', 'TA_SUM', 'TA_T3', 'TA_TAN', 'TA_TANH', 'TA_TEMA', 'TA_TRANGE', 'TA_TRIMA', 'TA_TRIX', 'TA_TSF', 'TA_TYPPRICE', 'TA_ULTOSC', 'TA_VAR', 'TA_WCLPRICE', 'TA_WILLR', 'TA_WMA', 'TC_FixedA', 'TC_FixedA2015', 'TC_FixedA2017', 'TC_TestStub', 'TC_Zero', 'TIME', 'TIMELINE', 'TIMELINEVOL', 'TR', 'TRACE', 'TURNOVER', 'TestOrderBroker', 'TimeDelta', 'TimeDelta_timedelta', 'TimeLineList', 'TimeLineRecord', 'TradeCostBase', 'TradeManager', 'TradeRecord', 'TradeRecordList', 'TradeRequest', 'TransList', 'TransRecord', 'UPNDAY', 'UTCOffset', 'VALUE', 'VAR', 'VARP', 'VIGOR', 'VOL', 'WARN', 'WEAVE', 'WEEK', 'WINNER', 'WITHDAY', 'WITHHALFYEAR', 'WITHHOUR', 'WITHHOUR2', 'WITHHOUR4', 'WITHKTYPE', 'WITHMIN', 'WITHMIN15', 'WITHMIN30', 'WITHMIN5', 'WITHMIN60', 'WITHMONTH', 'WITHQUARTER', 'WITHWEEK', 'WITHYEAR', 'WMA', 'YEAR', 'ZHBOND10', 'ZONGGUBEN', 'ZSCORE', 'active_device', 'add_class_logger_handler', 'atexit', 'backtest', 'batch_calculate_inds', 'bind_email', 'broker', 'broker_easytrader', 'broker_mail', 'can_upgrade', 'capture_multiprocess_all_logger', 'class_logger', 'close_ostream_to_python', 'close_spend_time', 'combinate_ind', 'combinate_index', 'concat_to_df', 'constant', 'core', 'cpp', 'crtBrokerTM', 'crtOB', 'crtSEOptimal', 'crtTM', 'crt_pf_strategy', 'crt_sys_strategy', 'current_path', 'date', 'dates_to_np', 'datetime', 'df_to_ind', 'df_to_krecords', 'dll_directory', 'extend', 'fetch_trial_license', 'find_optimal_system', 'find_optimal_system_multi', 'get_block', 'get_business_name', 'get_data_from_buffer_server', 'get_date_range', 'get_expire_date', 'get_funds_list', 'get_kdata', 'get_last_version', 'get_log_level', 'get_spot_from_buffer_server', 'get_stock', 'get_system_part_enum', 'get_system_part_name', 'get_version', 'get_version_git', 'get_version_with_build', 'hikyuu_init', 'hku_benchmark', 'hku_catch', 'hku_check', 'hku_check_ignore', 'hku_check_throw', 'hku_debug', 'hku_debug_if', 'hku_error', 'hku_error_if', 'hku_fatal', 'hku_fatal_if', 'hku_info', 'hku_info_if', 'hku_logger', 'hku_run_ignore_exception', 'hku_to_async', 'hku_trace', 'hku_trace_if', 'hku_warn', 'hku_warn_if', 'in_interactive_session', 'in_ipython_frontend', 'indicator', 'inner_analysis_sys_list', 'inner_combinate_ind_analysis', 'inner_combinate_ind_analysis_with_block', 'io', 'is_valid_license', 'isinf', 'isnan', 'krecords_to_df', 'krecords_to_np', 'locale', 'new_Query_init', 'new_path', 'np', 'old_Query_init', 'open_ostream_to_python', 'open_spend_time', 'os', 'parallel_run_pf', 'parallel_run_sys', 'pd', 'pickle', 'positions_to_df', 'positions_to_np', 'pyind', 'register_extra_ktype', 'release_extra_ktype', 'remove_license', 'roundDown', 'roundEx', 'roundUp', 'run_in_strategy', 'scorerecords_to_df', 'scorerecords_to_np', 'set_log_level', 'set_my_logger_file', 'set_python_in_interactive', 'set_python_in_jupyter', 'spend_time', 'spot_agent_is_connected', 'spot_agent_is_running', 'start_data_server', 'start_spot_agent', 'stop_data_server', 'stop_spot_agent', 'sys', 'systemweights_to_df', 'systemweights_to_np', 'timedelta', 'timeline_to_df', 'timeline_to_np', 'timeout', 'toPriceList', 'traceback', 'trade', 'trades_to_df', 'trades_to_np', 'translist_to_df', 'translist_to_np', 'util', 'view_license', 'weights_to_df', 'weights_to_np', 'with_trace']
662
+ __all__: list[str] = ['ABS', 'ACOS', 'AD', 'ADVANCE', 'AF_EqualWeight', 'AF_FixedAmount', 'AF_FixedWeight', 'AF_FixedWeightList', 'AF_MultiFactor', 'AGG_COUNT', 'AGG_FUNC', 'AGG_MAD', 'AGG_MAX', 'AGG_MEAN', 'AGG_MEDIAN', 'AGG_MIN', 'AGG_PROD', 'AGG_QUANTILE', 'AGG_STD', 'AGG_SUM', 'AGG_VAR', 'AGG_VWAP', 'ALIGN', 'AMA', 'AMO', 'ASIN', 'ATAN', 'ATR', 'AVEDEV', 'AllocateFundsBase', 'BACKSET', 'BARSCOUNT', 'BARSLAST', 'BARSLASTCOUNT', 'BARSSINCE', 'BARSSINCEN', 'BASE_DIR', 'BETWEEN', 'BLOCKSETNUM', 'BUSINESS', 'Block', 'BlockInfoDriver', 'BorrowRecord', 'BrokerPositionRecord', 'CAPITAL', 'CEILING', 'CLOSE', 'CN_Bool', 'CN_OPLine', 'CONST', 'CONTEXT', 'CONTEXT_K', 'CORR', 'COS', 'COST', 'COUNT', 'CROSS', 'CVAL', 'CYCLE', 'C_AMO', 'C_CLOSE', 'C_HIGH', 'C_KDATA', 'C_LOW', 'C_OPEN', 'C_VOL', 'ConditionBase', 'Constant', 'CostRecord', 'DATE', 'DAY', 'DEBUG', 'DECLINE', 'DEVSQ', 'DIFF', 'DISCARD', 'DMA', 'DOWNNDAY', 'DROPNA', 'DataDriverFactory', 'Datetime', 'DatetimeList', 'DatetimeList_to_df', 'DatetimeList_to_np', 'Datetime_date', 'Datetime_datetime', 'Days', 'EMA', 'ERROR', 'EVERY', 'EV_Bool', 'EV_TwoLine', 'EXIST', 'EXP', 'EasyTraderOrderBroker', 'EnvironmentBase', 'FATAL', 'FILTER', 'FINANCE', 'FLOOR', 'FundsRecord', 'GROUP_COUNT', 'GROUP_FUNC', 'GROUP_MAX', 'GROUP_MEAN', 'GROUP_MIN', 'GROUP_PROD', 'GROUP_SUM', 'HHV', 'HHVBARS', 'HIGH', 'HKUCheckError', 'HKUException', 'HOUR', 'HSL', 'Hours', 'IC', 'ICIR', 'IF', 'INBLOCK', 'INDEXA', 'INDEXADV', 'INDEXC', 'INDEXDEC', 'INDEXH', 'INDEXL', 'INDEXO', 'INDEXV', 'INFO', 'INSUM', 'INTPART', 'IR', 'ISINF', 'ISINFA', 'ISLASTBAR', 'ISNA', 'IndParam', 'Indicator', 'IndicatorImp', 'JUMPDOWN', 'JUMPUP', 'KALMAN', 'KDATA', 'KDATA_PART', 'KDJ', 'KData', 'KDataDriver', 'KDataToClickHouseImporter', 'KDataToHdf5Importer', 'KDataToMySQLImporter', 'KRecord', 'KRecordList', 'LAST', 'LASTVALUE', 'LIUTONGPAN', 'LLV', 'LLVBARS', 'LN', 'LOG', 'LOG_LEVEL', 'LONGCROSS', 'LOW', 'LoanRecord', 'LoggingContext', 'MA', 'MACD', 'MAX', 'MDD', 'MF_EqualWeight', 'MF_ICIRWeight', 'MF_ICWeight', 'MF_Weight', 'MIN', 'MINUTE', 'MM_FixedCapital', 'MM_FixedCapitalFunds', 'MM_FixedCount', 'MM_FixedCountTps', 'MM_FixedPercent', 'MM_FixedRisk', 'MM_FixedUnits', 'MM_Nothing', 'MM_WilliamsFixedRisk', 'MOD', 'MONTH', 'MRR', 'MailOrderBroker', 'MarketInfo', 'Microseconds', 'Milliseconds', 'Minutes', 'MoneyManagerBase', 'MultiFactorBase', 'NDAY', 'NORM_MinMax', 'NORM_NOTHING', 'NORM_Quantile', 'NORM_Quantile_Uniform', 'NORM_Zscore', 'NOT', 'NormalizeBase', 'OFF', 'OPEN', 'OrderBrokerBase', 'OrderBrokerWrap', 'PF_Simple', 'PF_WithoutAF', 'PG_FixedHoldDays', 'PG_FixedPercent', 'PG_NoGoal', 'POS', 'POW', 'PRICELIST', 'Parameter', 'Parameter_items', 'Parameter_iter', 'Parameter_keys', 'Parameter_to_dict', 'Path', 'Performance', 'Performance_to_df', 'Portfolio', 'PositionRecord', 'PositionRecordList', 'ProfitGoalBase', 'QUANTILE_TRUNC', 'Query', 'RANK', 'RECOVER_BACKWARD', 'RECOVER_EQUAL_BACKWARD', 'RECOVER_EQUAL_FORWARD', 'RECOVER_FORWARD', 'REF', 'REFX', 'REPLACE', 'RESULT', 'REVERSE', 'ROC', 'ROCP', 'ROCR', 'ROCR100', 'ROUND', 'ROUNDDOWN', 'ROUNDUP', 'RSI', 'SAFTYLOSS', 'SCFilter_AmountLimit', 'SCFilter_Group', 'SCFilter_IgnoreNan', 'SCFilter_LessOrEqualValue', 'SCFilter_Price', 'SCFilter_TopN', 'SE_EvaluateOptimal', 'SE_Fixed', 'SE_MaxFundsOptimal', 'SE_MultiFactor', 'SE_MultiFactor2', 'SE_PerformanceOptimal', 'SE_Signal', 'SGN', 'SG_Add', 'SG_AllwaysBuy', 'SG_And', 'SG_Band', 'SG_Bool', 'SG_Buy', 'SG_Cross', 'SG_CrossGold', 'SG_Cycle', 'SG_Div', 'SG_Flex', 'SG_Mul', 'SG_OneSide', 'SG_Or', 'SG_Sell', 'SG_Single', 'SG_Single2', 'SG_Sub', 'SIN', 'SLICE', 'SLOPE', 'SMA', 'SPEARMAN', 'SP_FixedPercent', 'SP_FixedValue', 'SP_LogNormal', 'SP_Normal', 'SP_TruncNormal', 'SP_Uniform', 'SQRT', 'STD', 'STDEV', 'STDP', 'ST_FixedPercent', 'ST_Indicator', 'ST_Saftyloss', 'SUM', 'SUMBARS', 'SYS_Simple', 'SYS_WalkForward', 'ScoreRecord', 'ScoreRecordList', 'ScoresFilterBase', 'Seconds', 'SelectorBase', 'SignalBase', 'SlippageBase', 'SpotRecord', 'Stock', 'StockManager', 'StockTypeInfo', 'StockWeight', 'StockWeightList', 'StoplossBase', 'Strategy', 'StrategyContext', 'System', 'SystemPart', 'SystemWeight', 'SystemWeightList', 'TAN', 'TA_ACCBANDS', 'TA_ACOS', 'TA_AD', 'TA_ADD', 'TA_ADOSC', 'TA_ADX', 'TA_ADXR', 'TA_APO', 'TA_AROON', 'TA_AROONOSC', 'TA_ASIN', 'TA_ATAN', 'TA_ATR', 'TA_AVGDEV', 'TA_AVGPRICE', 'TA_BBANDS', 'TA_BETA', 'TA_BOP', 'TA_CCI', 'TA_CDL2CROWS', 'TA_CDL3BLACKCROWS', 'TA_CDL3INSIDE', 'TA_CDL3LINESTRIKE', 'TA_CDL3OUTSIDE', 'TA_CDL3STARSINSOUTH', 'TA_CDL3WHITESOLDIERS', 'TA_CDLABANDONEDBABY', 'TA_CDLADVANCEBLOCK', 'TA_CDLBELTHOLD', 'TA_CDLBREAKAWAY', 'TA_CDLCLOSINGMARUBOZU', 'TA_CDLCONCEALBABYSWALL', 'TA_CDLCOUNTERATTACK', 'TA_CDLDARKCLOUDCOVER', 'TA_CDLDOJI', 'TA_CDLDOJISTAR', 'TA_CDLDRAGONFLYDOJI', 'TA_CDLENGULFING', 'TA_CDLEVENINGDOJISTAR', 'TA_CDLEVENINGSTAR', 'TA_CDLGAPSIDESIDEWHITE', 'TA_CDLGRAVESTONEDOJI', 'TA_CDLHAMMER', 'TA_CDLHANGINGMAN', 'TA_CDLHARAMI', 'TA_CDLHARAMICROSS', 'TA_CDLHIGHWAVE', 'TA_CDLHIKKAKE', 'TA_CDLHIKKAKEMOD', 'TA_CDLHOMINGPIGEON', 'TA_CDLIDENTICAL3CROWS', 'TA_CDLINNECK', 'TA_CDLINVERTEDHAMMER', 'TA_CDLKICKING', 'TA_CDLKICKINGBYLENGTH', 'TA_CDLLADDERBOTTOM', 'TA_CDLLONGLEGGEDDOJI', 'TA_CDLLONGLINE', 'TA_CDLMARUBOZU', 'TA_CDLMATCHINGLOW', 'TA_CDLMATHOLD', 'TA_CDLMORNINGDOJISTAR', 'TA_CDLMORNINGSTAR', 'TA_CDLONNECK', 'TA_CDLPIERCING', 'TA_CDLRICKSHAWMAN', 'TA_CDLRISEFALL3METHODS', 'TA_CDLSEPARATINGLINES', 'TA_CDLSHOOTINGSTAR', 'TA_CDLSHORTLINE', 'TA_CDLSPINNINGTOP', 'TA_CDLSTALLEDPATTERN', 'TA_CDLSTICKSANDWICH', 'TA_CDLTAKURI', 'TA_CDLTASUKIGAP', 'TA_CDLTHRUSTING', 'TA_CDLTRISTAR', 'TA_CDLUNIQUE3RIVER', 'TA_CDLUPSIDEGAP2CROWS', 'TA_CDLXSIDEGAP3METHODS', 'TA_CEIL', 'TA_CMO', 'TA_CORREL', 'TA_COS', 'TA_COSH', 'TA_DEMA', 'TA_DIV', 'TA_DX', 'TA_EMA', 'TA_EXP', 'TA_FLOOR', 'TA_HT_DCPERIOD', 'TA_HT_DCPHASE', 'TA_HT_PHASOR', 'TA_HT_SINE', 'TA_HT_TRENDLINE', 'TA_HT_TRENDMODE', 'TA_IMI', 'TA_KAMA', 'TA_LINEARREG', 'TA_LINEARREG_ANGLE', 'TA_LINEARREG_INTERCEPT', 'TA_LINEARREG_SLOPE', 'TA_LN', 'TA_LOG10', 'TA_MA', 'TA_MACD', 'TA_MACDEXT', 'TA_MACDFIX', 'TA_MAMA', 'TA_MAVP', 'TA_MAX', 'TA_MAXINDEX', 'TA_MEDPRICE', 'TA_MFI', 'TA_MIDPOINT', 'TA_MIDPRICE', 'TA_MIN', 'TA_MININDEX', 'TA_MINMAX', 'TA_MINMAXINDEX', 'TA_MINUS_DI', 'TA_MINUS_DM', 'TA_MOM', 'TA_MULT', 'TA_NATR', 'TA_OBV', 'TA_PLUS_DI', 'TA_PLUS_DM', 'TA_PPO', 'TA_ROC', 'TA_ROCP', 'TA_ROCR', 'TA_ROCR100', 'TA_RSI', 'TA_SAR', 'TA_SAREXT', 'TA_SIN', 'TA_SINH', 'TA_SMA', 'TA_SQRT', 'TA_STDDEV', 'TA_STOCH', 'TA_STOCHF', 'TA_STOCHRSI', 'TA_SUB', 'TA_SUM', 'TA_T3', 'TA_TAN', 'TA_TANH', 'TA_TEMA', 'TA_TRANGE', 'TA_TRIMA', 'TA_TRIX', 'TA_TSF', 'TA_TYPPRICE', 'TA_ULTOSC', 'TA_VAR', 'TA_WCLPRICE', 'TA_WILLR', 'TA_WMA', 'TC_FixedA', 'TC_FixedA2015', 'TC_FixedA2017', 'TC_TestStub', 'TC_Zero', 'TIME', 'TIMELINE', 'TIMELINEVOL', 'TR', 'TRACE', 'TURNOVER', 'TestOrderBroker', 'TimeDelta', 'TimeDelta_timedelta', 'TimeLineList', 'TimeLineRecord', 'TradeCostBase', 'TradeManager', 'TradeRecord', 'TradeRecordList', 'TradeRequest', 'TransList', 'TransRecord', 'UPNDAY', 'UTCOffset', 'VALUE', 'VAR', 'VARP', 'VIGOR', 'VOL', 'WARN', 'WEAVE', 'WEEK', 'WINNER', 'WITHDAY', 'WITHHALFYEAR', 'WITHHOUR', 'WITHHOUR2', 'WITHHOUR4', 'WITHKTYPE', 'WITHMIN', 'WITHMIN15', 'WITHMIN30', 'WITHMIN5', 'WITHMIN60', 'WITHMONTH', 'WITHQUARTER', 'WITHWEEK', 'WITHYEAR', 'WMA', 'YEAR', 'ZHBOND10', 'ZONGGUBEN', 'ZSCORE', 'active_device', 'add_class_logger_handler', 'atexit', 'backtest', 'batch_calculate_inds', 'bind_email', 'broker', 'broker_easytrader', 'broker_mail', 'can_upgrade', 'capture_multiprocess_all_logger', 'check_data', 'class_logger', 'close_ostream_to_python', 'close_spend_time', 'combinate_ind', 'combinate_index', 'concat_to_df', 'constant', 'core', 'cpp', 'crtBrokerTM', 'crtOB', 'crtSEOptimal', 'crtTM', 'crt_pf_strategy', 'crt_sys_strategy', 'current_path', 'date', 'dates_to_np', 'datetime', 'df_to_ind', 'df_to_krecords', 'dll_directory', 'enable_kdata_cache', 'extend', 'fetch_trial_license', 'find_optimal_system', 'find_optimal_system_multi', 'get_block', 'get_business_name', 'get_data_from_buffer_server', 'get_date_range', 'get_expire_date', 'get_funds_list', 'get_kdata', 'get_latest_version_info', 'get_log_level', 'get_spot_from_buffer_server', 'get_stock', 'get_system_part_enum', 'get_system_part_name', 'get_version', 'get_version_git', 'get_version_with_build', 'hikyuu_init', 'hku_benchmark', 'hku_catch', 'hku_check', 'hku_check_ignore', 'hku_check_throw', 'hku_debug', 'hku_debug_if', 'hku_error', 'hku_error_if', 'hku_fatal', 'hku_fatal_if', 'hku_info', 'hku_info_if', 'hku_logger', 'hku_run_ignore_exception', 'hku_to_async', 'hku_trace', 'hku_trace_if', 'hku_warn', 'hku_warn_if', 'in_interactive_session', 'in_ipython_frontend', 'indicator', 'inner_analysis_sys_list', 'inner_combinate_ind_analysis', 'inner_combinate_ind_analysis_with_block', 'is_valid_license', 'isinf', 'isnan', 'krecords_to_df', 'krecords_to_np', 'locale', 'new_Query_init', 'new_path', 'np', 'old_Query_init', 'open_ostream_to_python', 'open_spend_time', 'os', 'parallel_run_pf', 'parallel_run_sys', 'pd', 'pickle', 'positions_to_df', 'positions_to_np', 'pyind', 'register_extra_ktype', 'release_extra_ktype', 'remove_license', 'roundDown', 'roundEx', 'roundUp', 'run_in_strategy', 'scorerecords_to_df', 'scorerecords_to_np', 'set_log_level', 'set_my_logger_file', 'set_python_in_interactive', 'set_python_in_jupyter', 'spend_time', 'spot_agent_is_connected', 'spot_agent_is_running', 'start_data_server', 'start_spot_agent', 'stop_data_server', 'stop_spot_agent', 'sys', 'systemweights_to_df', 'systemweights_to_np', 'time', 'timedelta', 'timeline_to_df', 'timeline_to_np', 'timeout', 'toPriceList', 'traceback', 'trade', 'trades_to_df', 'trades_to_np', 'translist_to_df', 'translist_to_np', 'util', 'view_license', 'weights_to_df', 'weights_to_np', 'with_trace']
657
663
  AMO: hikyuu.cpp.core310.Indicator # value = Indicator{...
658
664
  BASE_DIR: str = '/app/hikyuu/hikyuu'
659
665
  CLOSE: hikyuu.cpp.core310.Indicator # value = Indicator{...