shancx 1.9.33.172__py3-none-any.whl → 1.9.33.174__py3-none-any.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.
shancx/NN/__init__.py CHANGED
@@ -132,6 +132,27 @@ def Mul_sub(task, param_list, num=6):
132
132
  sys.exit(1)
133
133
  print("All tasks completed")
134
134
 
135
+ from concurrent.futures import ThreadPoolExecutor
136
+ from itertools import product
137
+ def Mul_TH(task, param_list, max_workers=6):
138
+ print(f"Thread num: {max_workers}")
139
+ validate_param_list(param_list)
140
+ task_args = [
141
+ (arg,) if len(param_list) == 1 else arg
142
+ for arg in (
143
+ param_list[0] if len(param_list) == 1
144
+ else product(*param_list)
145
+ )
146
+ ]
147
+ with ThreadPoolExecutor(max_workers) as ex:
148
+ try:
149
+ list(ex.map(task, task_args))
150
+ except KeyboardInterrupt:
151
+ print("\n用户中断操作")
152
+ ex.shutdown(wait=False)
153
+ sys.exit(1)
154
+
155
+
135
156
  # import os
136
157
  # from datetime import datetime
137
158
  # from shancx.NN import _loggers
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: shancx
3
- Version: 1.9.33.172
3
+ Version: 1.9.33.174
4
4
  Summary: A simple timer decorator
5
5
  Home-page: https://gitee.com/shancx
6
6
  Author: shancx
@@ -56,9 +56,13 @@ shancx/Fillmiss/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
56
56
  shancx/Fillmiss/imgidwJU.py,sha256=CyP4ZlhPpXPqGVzzcLR7lohVl8bWjEceJLo7yvKgtEM,1708
57
57
  shancx/Fillmiss/imgidwLatLonJU.py,sha256=ltYZj9CwN8cVs4Kow64oVN1EiBERgW9FceTUBFkCOAs,4314
58
58
  shancx/Gpu/__init__.py,sha256=4Ahq04phTGVlFWN9Vih0WAh-IqFrhtwM5hj4G1IU2Dk,1950
59
+ shancx/H9/__init__.py,sha256=FCarcXfU2tVD2KrCGKNNUuL51zAWZYHV7lrP7gntvaI,4911
60
+ shancx/H9/ahi_read_hsd.py,sha256=bt9oOOARcXijmyGpmHYXj0NKnuTntZjqx0_tu6Vp2vs,33522
61
+ shancx/H9/ahisearchtable.py,sha256=e2kpz-P5npgL4gzNxn8igERJuWWIysvTNLkptr5_Zcc,9579
62
+ shancx/H9/geometry.py,sha256=ZoCfgP07ANqDxyLf8uFN016DPl7QqW9pAV3sr2ekCng,95893
59
63
  shancx/Hug/__init__.py,sha256=NvcqXM0CSwXYtTr5yj4zfkag_7PZcI5tCsIHjuLNXTQ,3040
60
64
  shancx/Mos/__init__.py,sha256=IDlCLNN6a_mguYmRcAPcevHSDaud5ZhvYNSuASqztcE,1563
61
- shancx/NN/__init__.py,sha256=y3HcHvM-AhOLCGzWy053pcLDxaEG5Jgpi4oDMidOffE,6388
65
+ shancx/NN/__init__.py,sha256=uN2Dkqm-rRnp8TDitwMm1PcYYH9KsaQXcraFVuIRf98,7027
62
66
  shancx/Plot/GlobMap.py,sha256=WRvZOf5bo8IfECk1-sN4g6K0CrcJhSoEJAiLvZAWDwg,13021
63
67
  shancx/Plot/Gray2RGB.py,sha256=yDXu1xWVi7OtrS8_ExxK_ev1988kj1ZxoNCWf-kl4Zc,2734
64
68
  shancx/Plot/__init__.py,sha256=R4pywzeVDqEWGMkWeGBAVmopgPBThiLv2RBDlGquNGc,31891
@@ -79,7 +83,7 @@ shancx/Train/multiGpu.py,sha256=D_oZeiSc7VWktpnVDwrFOC1CYZSt9rxOKY5lngE5vFg,820
79
83
  shancx/Train/prepare.py,sha256=vL_8UOA66oZCBIwCICtihsGibivtNgaVJGulJxfNdn8,6793
80
84
  shancx/Train/renet50.py,sha256=wEhYk1X96WE5zuqHqVxWLJa-A5jDNkz4z6edORNufnA,6428
81
85
  shancx/tensBoard/__init__.py,sha256=ga2C5YyJITvvQA1ocpxna_KNFnNRJVwkTjLoIglLZUQ,993
82
- shancx-1.9.33.172.dist-info/METADATA,sha256=SxwmImhbBAxNgwIZ814dXZAa_C4EulV5v0_KxHJXRzo,644
83
- shancx-1.9.33.172.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
84
- shancx-1.9.33.172.dist-info/top_level.txt,sha256=akfCS1vKWz3pNmEN_yN9ZiGp-60IQY5ET38mRx_i_-4,7
85
- shancx-1.9.33.172.dist-info/RECORD,,
86
+ shancx-1.9.33.174.dist-info/METADATA,sha256=Yr3IRyjoqztZUku4KsVKubHkG-88GXh4FwUxl4QFOb8,644
87
+ shancx-1.9.33.174.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
88
+ shancx-1.9.33.174.dist-info/top_level.txt,sha256=akfCS1vKWz3pNmEN_yN9ZiGp-60IQY5ET38mRx_i_-4,7
89
+ shancx-1.9.33.174.dist-info/RECORD,,