hikyuu 2.6.3__py3-none-win_amd64.whl → 2.6.6__py3-none-win_amd64.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 (146) hide show
  1. hikyuu/__init__.py +6 -0
  2. hikyuu/__init__.pyi +548 -546
  3. hikyuu/analysis/__init__.pyi +519 -514
  4. hikyuu/analysis/analysis.pyi +520 -515
  5. hikyuu/core.pyi +521 -516
  6. hikyuu/cpp/__init__.pyi +2 -2
  7. hikyuu/cpp/boost_date_time-mt.dll +0 -0
  8. hikyuu/cpp/boost_serialization-mt.dll +0 -0
  9. hikyuu/cpp/boost_wserialization-mt.dll +0 -0
  10. hikyuu/cpp/core310.pyd +0 -0
  11. hikyuu/cpp/core310.pyi +167 -36
  12. hikyuu/cpp/core311.pyd +0 -0
  13. hikyuu/cpp/core311.pyi +167 -36
  14. hikyuu/cpp/core312.pyd +0 -0
  15. hikyuu/cpp/core312.pyi +167 -36
  16. hikyuu/cpp/core313.pyd +0 -0
  17. hikyuu/cpp/core313.pyi +167 -36
  18. hikyuu/cpp/core39.pyd +0 -0
  19. hikyuu/cpp/core39.pyi +167 -36
  20. hikyuu/cpp/hikyuu.dll +0 -0
  21. hikyuu/cpp/hikyuu.lib +0 -0
  22. hikyuu/cpp/i18n/__init__.py +0 -0
  23. hikyuu/cpp/i18n/zh_CN.mo +0 -0
  24. hikyuu/cpp/sqlite3.dll +0 -0
  25. hikyuu/data/clickhouse_upgrade/__init__.py +1 -0
  26. hikyuu/data/clickhouse_upgrade/createdb.sql +1085 -0
  27. hikyuu/data/common.py +1 -1
  28. hikyuu/data/common_clickhouse.py +512 -0
  29. hikyuu/data/common_mysql.py +19 -0
  30. hikyuu/data/common_pytdx.py +2 -0
  31. hikyuu/data/common_sqlite3.py +1 -0
  32. hikyuu/data/em_block_to_clickhouse.py +120 -0
  33. hikyuu/data/hku_config_template.py +70 -1
  34. hikyuu/data/mysql_upgrade/0028.sql +95 -0
  35. hikyuu/data/pytdx_finance_to_clickhouse.py +107 -0
  36. hikyuu/data/pytdx_to_clickhouse.py +841 -0
  37. hikyuu/data/pytdx_to_h5.py +53 -13
  38. hikyuu/data/pytdx_to_mysql.py +42 -9
  39. hikyuu/data/pytdx_to_taos.py +736 -0
  40. hikyuu/data/pytdx_weight_to_clickhouse.py +191 -0
  41. hikyuu/data/sqlite_upgrade/0028.sql +97 -0
  42. hikyuu/data/tdx_to_clickhouse.py +448 -0
  43. hikyuu/data/zh_bond10_to_clickhouse.py +49 -0
  44. hikyuu/draw/__init__.pyi +1 -1
  45. hikyuu/draw/drawplot/__init__.pyi +8 -8
  46. hikyuu/draw/drawplot/bokeh_draw.pyi +538 -536
  47. hikyuu/draw/drawplot/common.pyi +1 -1
  48. hikyuu/draw/drawplot/echarts_draw.pyi +540 -538
  49. hikyuu/draw/drawplot/matplotlib_draw.py +7 -7
  50. hikyuu/draw/drawplot/matplotlib_draw.pyi +550 -548
  51. hikyuu/draw/elder.pyi +11 -11
  52. hikyuu/draw/kaufman.pyi +18 -18
  53. hikyuu/draw/volume.pyi +10 -10
  54. hikyuu/examples/notebook/001-overview.ipynb +65 -100
  55. hikyuu/examples/notebook/004-IndicatorOverview.ipynb +34 -32
  56. hikyuu/examples/notebook/007-SystemDetails.ipynb +64 -50
  57. hikyuu/examples/notebook/010-Portfolio.ipynb +120 -124
  58. hikyuu/extend.py +1 -1
  59. hikyuu/extend.pyi +527 -527
  60. hikyuu/fetcher/stock/zh_block_em.py +349 -5
  61. hikyuu/fetcher/stock/zh_stock_a_pytdx.py +11 -21
  62. hikyuu/fetcher/stock/zh_stock_a_qmt.py +4 -5
  63. hikyuu/fetcher/stock/zh_stock_a_sina_qq.py +16 -60
  64. hikyuu/flat/Spot.py +96 -200
  65. hikyuu/gui/HikyuuTDX.py +175 -23
  66. hikyuu/gui/data/ImportBlockInfoTask.py +12 -1
  67. hikyuu/gui/data/ImportHistoryFinanceTask.py +62 -44
  68. hikyuu/gui/data/ImportPytdxTimeToH5Task.py +14 -2
  69. hikyuu/gui/data/ImportPytdxToH5Task.py +17 -3
  70. hikyuu/gui/data/ImportPytdxTransToH5Task.py +14 -2
  71. hikyuu/gui/data/ImportTdxToH5Task.py +13 -1
  72. hikyuu/gui/data/ImportWeightToSqliteTask.py +16 -2
  73. hikyuu/gui/data/ImportZhBond10Task.py +12 -1
  74. hikyuu/gui/data/MainWindow.py +191 -110
  75. hikyuu/gui/data/UsePytdxImportToH5Thread.py +52 -29
  76. hikyuu/gui/data/UseQmtImportToH5Thread.py +1 -0
  77. hikyuu/gui/data/UseTdxImportToH5Thread.py +21 -2
  78. hikyuu/gui/dataserver.py +12 -4
  79. hikyuu/gui/spot_server.py +30 -40
  80. hikyuu/gui/start_qmt.py +20 -3
  81. hikyuu/hub.pyi +6 -6
  82. hikyuu/include/hikyuu/DataType.h +11 -0
  83. hikyuu/include/hikyuu/MarketInfo.h +6 -0
  84. hikyuu/include/hikyuu/StockManager.h +8 -0
  85. hikyuu/include/hikyuu/data_driver/BaseInfoDriver.h +35 -0
  86. hikyuu/include/hikyuu/data_driver/kdata/mysql/KRecordTable.h +1 -0
  87. hikyuu/include/hikyuu/global/GlobalSpotAgent.h +1 -1
  88. hikyuu/include/hikyuu/global/SpotRecord.h +15 -31
  89. hikyuu/include/hikyuu/global/agent/spot_generated.h +48 -232
  90. hikyuu/include/hikyuu/global/schedule/scheduler.h +1 -1
  91. hikyuu/include/hikyuu/indicator/build_in.h +1 -0
  92. hikyuu/include/hikyuu/indicator/crt/BARSLASTCOUNT.h +33 -0
  93. hikyuu/include/hikyuu/indicator/imp/IBarsLastCount.h +27 -0
  94. hikyuu/include/hikyuu/plugin/KDataToHdf5Importer.h +3 -0
  95. hikyuu/include/hikyuu/plugin/backtest.h +2 -2
  96. hikyuu/include/hikyuu/plugin/dataserver.h +26 -1
  97. hikyuu/include/hikyuu/plugin/device.h +8 -4
  98. hikyuu/include/hikyuu/plugin/interface/BackTestPluginInterface.h +1 -1
  99. hikyuu/include/hikyuu/plugin/interface/DataDriverPluginInterface.h +27 -0
  100. hikyuu/include/hikyuu/plugin/interface/DataServerPluginInterface.h +2 -1
  101. hikyuu/include/hikyuu/plugin/interface/DevicePluginInterface.h +2 -1
  102. hikyuu/include/hikyuu/plugin/interface/ImportKDataToHdf5PluginInterface.h +3 -0
  103. hikyuu/include/hikyuu/plugin/interface/TMReportPluginInterface.h +80 -0
  104. hikyuu/include/hikyuu/plugin/interface/plugins.h +4 -0
  105. hikyuu/include/hikyuu/strategy/Strategy.h +0 -9
  106. hikyuu/include/hikyuu/trade_manage/Performance.h +17 -9
  107. hikyuu/include/hikyuu/trade_manage/PositionExtInfo.h +92 -0
  108. hikyuu/include/hikyuu/trade_manage/PositionRecord.h +7 -1
  109. hikyuu/include/hikyuu/trade_manage/TradeManagerBase.h +60 -1
  110. hikyuu/include/hikyuu/trade_sys/selector/crt/SE_Optimal.h +8 -0
  111. hikyuu/include/hikyuu/trade_sys/selector/imp/optimal/OptimalEvaluateSelector.h +28 -0
  112. hikyuu/include/hikyuu/trade_sys/selector/imp/optimal/OptimalSelectorBase.h +1 -0
  113. hikyuu/include/hikyuu/utilities/DllLoader.h +226 -0
  114. hikyuu/include/hikyuu/utilities/config.h +1 -1
  115. hikyuu/include/hikyuu/utilities/datetime/Datetime.h +20 -0
  116. hikyuu/include/hikyuu/utilities/datetime/TimeDelta.h +6 -0
  117. hikyuu/include/hikyuu/utilities/mo/mo.h +30 -14
  118. hikyuu/include/hikyuu/utilities/os.h +6 -0
  119. hikyuu/include/hikyuu/utilities/plugin/PluginLoader.h +10 -10
  120. hikyuu/include/hikyuu/utilities/thread/MQThreadPool.h +13 -7
  121. hikyuu/include/hikyuu/utilities/thread/ThreadPool.h +13 -6
  122. hikyuu/include/hikyuu/version.h +4 -4
  123. hikyuu/plugin/backtest.dll +0 -0
  124. hikyuu/plugin/clickhousedriver.dll +0 -0
  125. hikyuu/plugin/dataserver.dll +0 -0
  126. hikyuu/plugin/device.dll +0 -0
  127. hikyuu/plugin/extind.dll +0 -0
  128. hikyuu/plugin/import2hdf5.dll +0 -0
  129. hikyuu/plugin/tmreport.dll +0 -0
  130. hikyuu/trade_manage/__init__.pyi +537 -535
  131. hikyuu/trade_manage/broker.pyi +3 -3
  132. hikyuu/trade_manage/broker_easytrader.pyi +1 -1
  133. hikyuu/trade_manage/trade.pyi +537 -535
  134. hikyuu/util/__init__.py +1 -0
  135. hikyuu/util/__init__.pyi +4 -3
  136. hikyuu/util/check.py +8 -0
  137. hikyuu/util/check.pyi +5 -1
  138. hikyuu/util/singleton.pyi +1 -1
  139. {hikyuu-2.6.3.dist-info → hikyuu-2.6.6.dist-info}/METADATA +4 -3
  140. {hikyuu-2.6.3.dist-info → hikyuu-2.6.6.dist-info}/RECORD +144 -123
  141. {hikyuu-2.6.3.dist-info → hikyuu-2.6.6.dist-info}/top_level.txt +2 -2
  142. hikyuu/include/hikyuu/global/agent/hikyuu/__init__.py +0 -1
  143. hikyuu/include/hikyuu/global/agent/hikyuu/flat/__init__.py +0 -1
  144. {hikyuu-2.6.3.dist-info → hikyuu-2.6.6.dist-info}/LICENSE +0 -0
  145. {hikyuu-2.6.3.dist-info → hikyuu-2.6.6.dist-info}/WHEEL +0 -0
  146. {hikyuu-2.6.3.dist-info → hikyuu-2.6.6.dist-info}/entry_points.txt +0 -0
hikyuu/util/__init__.py CHANGED
@@ -27,6 +27,7 @@ __all__ = [
27
27
  'hku_check_ignore',
28
28
  'hku_catch',
29
29
  'hku_to_async',
30
+ "hku_run_ignore_exception",
30
31
  'hku_trace',
31
32
  'hku_debug',
32
33
  'hku_info',
hikyuu/util/__init__.pyi CHANGED
@@ -10,6 +10,7 @@ from hikyuu.util.check import hku_catch
10
10
  from hikyuu.util.check import hku_check
11
11
  from hikyuu.util.check import hku_check_ignore
12
12
  from hikyuu.util.check import hku_check_throw
13
+ from hikyuu.util.check import hku_run_ignore_exception
13
14
  from hikyuu.util.check import hku_to_async
14
15
  from hikyuu.util.mylog import LoggingContext
15
16
  from hikyuu.util.mylog import add_class_logger_handler
@@ -17,10 +18,10 @@ from hikyuu.util.mylog import capture_multiprocess_all_logger
17
18
  from hikyuu.util.mylog import class_logger
18
19
  from hikyuu.util.mylog import get_default_logger
19
20
  from hikyuu.util.mylog import hku_benchmark
20
- from hikyuu.util.mylog import hku_debug
21
21
  from hikyuu.util.mylog import hku_debug as hku_trace
22
- from hikyuu.util.mylog import hku_debug_if
22
+ from hikyuu.util.mylog import hku_debug
23
23
  from hikyuu.util.mylog import hku_debug_if as hku_trace_if
24
+ from hikyuu.util.mylog import hku_debug_if
24
25
  from hikyuu.util.mylog import hku_error
25
26
  from hikyuu.util.mylog import hku_error_if
26
27
  from hikyuu.util.mylog import hku_fatal
@@ -49,7 +50,7 @@ from . import mylog
49
50
  from . import notebook
50
51
  from . import singleton
51
52
  from . import slice
52
- __all__: list = ['spend_time', 'hku_benchmark', 'timeout', 'hku_logger', 'class_logger', 'add_class_logger_handler', 'HKUCheckError', 'hku_check', 'hku_check_throw', 'hku_check_ignore', 'hku_catch', 'hku_to_async', 'hku_trace', 'hku_debug', 'hku_info', 'hku_warn', 'hku_error', 'hku_fatal', 'hku_trace_if', 'hku_debug_if', 'hku_info_if', 'hku_warn_if', 'hku_info_if', 'hku_warn_if', 'hku_error_if', 'hku_fatal_if', 'with_trace', 'set_my_logger_file', 'capture_multiprocess_all_logger', 'LoggingContext', 'in_interactive_session', 'in_ipython_frontend']
53
+ __all__: list = ['spend_time', 'hku_benchmark', 'timeout', 'hku_logger', 'class_logger', 'add_class_logger_handler', 'HKUCheckError', 'hku_check', 'hku_check_throw', 'hku_check_ignore', 'hku_catch', 'hku_to_async', 'hku_run_ignore_exception', 'hku_trace', 'hku_debug', 'hku_info', 'hku_warn', 'hku_error', 'hku_fatal', 'hku_trace_if', 'hku_debug_if', 'hku_info_if', 'hku_warn_if', 'hku_info_if', 'hku_warn_if', 'hku_error_if', 'hku_fatal_if', 'with_trace', 'set_my_logger_file', 'capture_multiprocess_all_logger', 'LoggingContext', 'in_interactive_session', 'in_ipython_frontend']
53
54
  FORMAT: str = '%(asctime)-15s [%(levelname)s] %(message)s [%(name)s::%(funcName)s]'
54
55
  g_hku_logger_lock: multiprocessing.synchronize.Lock # value = <Lock(owner=None)>
55
56
  hku_logger: logging.Logger # value = <Logger hikyuu (INFO)>
hikyuu/util/check.py CHANGED
@@ -151,3 +151,11 @@ def hku_to_async(func):
151
151
  loop = asyncio.get_event_loop()
152
152
  return await loop.run_in_executor(None, func, *args, **kwargs)
153
153
  return async_func
154
+
155
+
156
+ def hku_run_ignore_exception(func, *args, **kwargs):
157
+ """运行函数并忽略异常"""
158
+ try:
159
+ return func(*args, **kwargs)
160
+ except:
161
+ return None
hikyuu/util/check.pyi CHANGED
@@ -5,7 +5,7 @@ import logging
5
5
  import multiprocessing.synchronize
6
6
  import sys as sys
7
7
  import traceback as traceback
8
- __all__ = ['HKUCheckError', 'HKUIngoreError', 'asyncio', 'checkif', 'functools', 'g_hku_logger_lock', 'get_exception_info', 'hku_catch', 'hku_check', 'hku_check_ignore', 'hku_check_throw', 'hku_logger', 'hku_to_async', 'sys', 'traceback']
8
+ __all__ = ['HKUCheckError', 'HKUIngoreError', 'asyncio', 'checkif', 'functools', 'g_hku_logger_lock', 'get_exception_info', 'hku_catch', 'hku_check', 'hku_check_ignore', 'hku_check_throw', 'hku_logger', 'hku_run_ignore_exception', 'hku_to_async', 'sys', 'traceback']
9
9
  class HKUCheckError(Exception):
10
10
  def __init__(self, expression, message):
11
11
  ...
@@ -52,6 +52,10 @@ def hku_check_throw(expression, message, excepion = None, **kwargs):
52
52
  :param str message: 异常注解信息
53
53
  :param Exception exception: 指定的异常类,为None时,为默认 HKUCheckError 异常
54
54
 
55
+ """
56
+ def hku_run_ignore_exception(func, *args, **kwargs):
57
+ """
58
+ 运行函数并忽略异常
55
59
  """
56
60
  def hku_to_async(func):
57
61
  ...
hikyuu/util/singleton.pyi CHANGED
@@ -12,7 +12,7 @@ class SingletonType(type):
12
12
  self.name = name
13
13
 
14
14
  """
15
- _instance_lock: typing.ClassVar[_thread.lock] # value = <unlocked _thread.lock object at 0x00000193FCE2CE70>
15
+ _instance_lock: typing.ClassVar[_thread.lock] # value = <unlocked _thread.lock object at 0x000001FC042D3700>
16
16
  @classmethod
17
17
  def __call__(cls, *args, **kwargs):
18
18
  ...
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: hikyuu
3
- Version: 2.6.3
3
+ Version: 2.6.6
4
4
  Summary: Hikyuu Quant Framework for System Trading Analysis and backtester
5
5
  Home-page: http://hikyuu.org/
6
6
  Author: fasiondog
@@ -31,7 +31,7 @@ Requires-Dist: click
31
31
  Requires-Dist: numpy
32
32
  Requires-Dist: matplotlib
33
33
  Requires-Dist: seaborn
34
- Requires-Dist: pandas>=0.17.1
34
+ Requires-Dist: pandas>=1.0.4
35
35
  Requires-Dist: pytdx
36
36
  Requires-Dist: PyQt5
37
37
  Requires-Dist: tables
@@ -49,6 +49,7 @@ Requires-Dist: pyecharts
49
49
  Requires-Dist: pipdeptree
50
50
  Requires-Dist: h5py
51
51
  Requires-Dist: tdqm
52
+ Requires-Dist: clickhouse-connect
52
53
 
53
54
  ![title](docs/source/_static/00000-title.png)
54
55
 
@@ -113,7 +114,7 @@ Hikyuu Quant Framework是一款基于C++/Python的开源量化交易研究框架
113
114
 
114
115
  # 想要更多了解Hikyuu?请使用以下方式联系:
115
116
 
116
- ## [项目支持与捐赠-VIP计划](vip-plan.md)
117
+ ## [VIP捐赠-附属功能](https://hikyuu.readthedocs.io/zh-cn/latest/vip/vip-plan.html)
117
118
 
118
119
  ## **加入知识星球**
119
120