pyfemtet 1.1.3__py3-none-any.whl → 1.1.4__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.

Potentially problematic release.


This version of pyfemtet might be problematic. Click here for more details.

@@ -26,6 +26,8 @@ __all__ = [
26
26
 
27
27
  class BoTorchInterface(AbstractSurrogateModelInterfaceBase):
28
28
 
29
+ current_obj_std_values: dict[str, float]
30
+
29
31
  def __init__(
30
32
  self,
31
33
  history_path: str = None,
@@ -45,6 +47,7 @@ class BoTorchInterface(AbstractSurrogateModelInterfaceBase):
45
47
 
46
48
  self.model = SingleTaskGPModel()
47
49
  self.pyfemtet_model = PyFemtetModel()
50
+ self.current_obj_std_values = {}
48
51
 
49
52
  # get main only
50
53
  df = self.train_history.get_df(MAIN_FILTER)
@@ -64,11 +67,13 @@ class BoTorchInterface(AbstractSurrogateModelInterfaceBase):
64
67
  # update current objective values
65
68
  x = np.array([[variable.value for variable in self.current_prm_values.values()]])
66
69
 
67
- y, _ = self.pyfemtet_model.predict(x)
70
+ y, s = self.pyfemtet_model.predict(x)
68
71
  y = y[0]
72
+ s = s[0]
69
73
 
70
- for obj_name, obj_value in zip(self.train_history.obj_names, y):
74
+ for obj_name, obj_value, obj_std in zip(self.train_history.obj_names, y, s):
71
75
  self.current_obj_values.update({obj_name: obj_value})
76
+ self.current_obj_std_values.update({obj_name: obj_std})
72
77
 
73
78
 
74
79
  class PoFBoTorchInterface(BoTorchInterface, AbstractSurrogateModelInterfaceBase):
@@ -103,6 +108,7 @@ class PoFBoTorchInterface(BoTorchInterface, AbstractSurrogateModelInterfaceBase)
103
108
  self.train_history_c.load_csv(history_path, with_finalize=True)
104
109
  self.pof_threshold = 0.5
105
110
  self.feasibility_cdf_threshold = feasibility_cdf_threshold
111
+ self.current_obj_std_values = {}
106
112
 
107
113
  # use feasibility as a single objective
108
114
  self.train_history_c.obj_names = ['feasibility']
@@ -1,12 +1,13 @@
1
- Metadata-Version: 2.3
1
+ Metadata-Version: 2.4
2
2
  Name: pyfemtet
3
- Version: 1.1.3
3
+ Version: 1.1.4
4
4
  Summary: Design parameter optimization using Femtet.
5
- License: MIT
5
+ License-Expression: MIT
6
+ License-File: LICENSE
7
+ License-File: LICENSE_THIRD_PARTY.txt
6
8
  Author: pyfemtet
7
9
  Author-email: 148934231+pyfemtet@users.noreply.github.com
8
10
  Requires-Python: >= 3.10, < 3.14
9
- Classifier: License :: OSI Approved :: MIT License
10
11
  Classifier: Programming Language :: Python :: 3
11
12
  Classifier: Programming Language :: Python :: 3.10
12
13
  Classifier: Programming Language :: Python :: 3.11
@@ -29,8 +30,7 @@ Requires-Dist: optuna-integration (>=3.6.0,<5.0.0)
29
30
  Requires-Dist: pandas (>=2.2.3,<3)
30
31
  Requires-Dist: plotly (>=5.22.0,<6)
31
32
  Requires-Dist: psutil (>=5.9.6,<6)
32
- Requires-Dist: pywin32 (<307) ; sys_platform == "win32" and python_version < "3.13"
33
- Requires-Dist: pywin32 (>=309) ; sys_platform == "win32" and python_version >= "3.13"
33
+ Requires-Dist: pywin32 (>=310) ; sys_platform == "win32"
34
34
  Requires-Dist: pyyaml (>=6.0.2,<7)
35
35
  Requires-Dist: scipy (>=1.11.4,<2)
36
36
  Requires-Dist: torch
@@ -54,7 +54,7 @@ pyfemtet/opt/interface/_solidworks_interface/__init__.py,sha256=2c52Hfme1xdJepew
54
54
  pyfemtet/opt/interface/_solidworks_interface/solidworks_interface.py,sha256=KkXfXJ5IaTl2pJXBlH25rdmsKFWUbqNTk3sGjD3Qgys,8408
55
55
  pyfemtet/opt/interface/_surrogate_model_interface/__init__.py,sha256=9sjzQjJsMLdpBSpURyl8x4VQHEO_PGYgAshCHoycAPI,252
56
56
  pyfemtet/opt/interface/_surrogate_model_interface/base_surrogate_interface.py,sha256=48mUOPgOVi_SRs_VnElgh6BMUJHQG9jzWpCocK_gjiY,6355
57
- pyfemtet/opt/interface/_surrogate_model_interface/botorch_interface.py,sha256=ynaHIM08bnbsUhCdQAzumkDL8BlspZY5-ieVihqFeuo,10345
57
+ pyfemtet/opt/interface/_surrogate_model_interface/botorch_interface.py,sha256=JsFDs5GzlsstpyXjTYpUi_ctWlcEKliX3qMr4HBPj_E,10570
58
58
  pyfemtet/opt/interface/_surrogate_model_interface/debug-pof-botorch.reccsv,sha256=Clv7t2vgSWym8-uMQPtcc8-hyjwuCk-b69PjtqWqphc,1910
59
59
  pyfemtet/opt/interface/_with_excel_settings/__init__.py,sha256=B3ZTQDNUDpZBLEVnCh2iHL_bnTJTUaclEfOFztHfl5c,2265
60
60
  pyfemtet/opt/interface/_with_excel_settings/with_excel_settings.py,sha256=ZrVJcZz5Eut6UOhLaO1okqistp0vfoTC_KHRt2ChOhE,5482
@@ -171,9 +171,9 @@ pyfemtet/opt/visualization/plotter/parallel_plot_creator.py,sha256=VRhT0CUG1mCHD
171
171
  pyfemtet/opt/visualization/plotter/pm_graph_creator.py,sha256=7EwmoJlnHwDrpw65NchiA63FIjgGTLq6vTcpTzrSnJo,11841
172
172
  pyfemtet/opt/wat_ex14_parametric_jp.femprj,sha256=dMwQMt6yok_PbZLyxPYdmg5wJQwgQDZ4RhS76zdGLGk,177944
173
173
  pyfemtet/opt/worker_status.py,sha256=simvPa1AkO1idmPXrF5WjYVEBx3tO7hLhbM3J1rFjdo,3824
174
- pyfemtet-1.1.3.dist-info/LICENSE,sha256=LWUL5LlMGjSRTvsalS8_fFuwS4VMw18fJSNWFwDK8pc,1060
175
- pyfemtet-1.1.3.dist-info/LICENSE_THIRD_PARTY.txt,sha256=8_9-cgzTpmeuCqItPZb9-lyAZcH2Qp9sZTU_hYuOZIQ,191
176
- pyfemtet-1.1.3.dist-info/METADATA,sha256=qk__P-t_WDhuhnY6lrA2yylXtX5tkAy8faNia9Jkwys,3503
177
- pyfemtet-1.1.3.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
178
- pyfemtet-1.1.3.dist-info/entry_points.txt,sha256=Tsb_l_8Z6pyyq2tRfuKiwfJUV3nq_cHoLS61foALtsg,134
179
- pyfemtet-1.1.3.dist-info/RECORD,,
174
+ pyfemtet-1.1.4.dist-info/METADATA,sha256=Q9l6olWlrWO1Hhy_67IdqqhyKvJyjBiq25ywjv05TTs,3410
175
+ pyfemtet-1.1.4.dist-info/WHEEL,sha256=M5asmiAlL6HEcOq52Yi5mmk9KmTVjY2RDPtO4p9DMrc,88
176
+ pyfemtet-1.1.4.dist-info/entry_points.txt,sha256=Tsb_l_8Z6pyyq2tRfuKiwfJUV3nq_cHoLS61foALtsg,134
177
+ pyfemtet-1.1.4.dist-info/licenses/LICENSE,sha256=LWUL5LlMGjSRTvsalS8_fFuwS4VMw18fJSNWFwDK8pc,1060
178
+ pyfemtet-1.1.4.dist-info/licenses/LICENSE_THIRD_PARTY.txt,sha256=8_9-cgzTpmeuCqItPZb9-lyAZcH2Qp9sZTU_hYuOZIQ,191
179
+ pyfemtet-1.1.4.dist-info/RECORD,,
@@ -1,4 +1,4 @@
1
1
  Wheel-Version: 1.0
2
- Generator: poetry-core 2.1.3
2
+ Generator: poetry-core 2.2.0
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any