pyedb 0.16.0__py3-none-any.whl → 0.18.0__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 pyedb might be problematic. Click here for more details.

Files changed (32) hide show
  1. pyedb/__init__.py +1 -1
  2. pyedb/configuration/cfg_components.py +47 -1
  3. pyedb/configuration/configuration.py +2 -0
  4. pyedb/dotnet/edb.py +133 -64
  5. pyedb/dotnet/edb_core/cell/hierarchy/component.py +12 -17
  6. pyedb/dotnet/edb_core/cell/hierarchy/hierarchy_obj.py +50 -0
  7. pyedb/dotnet/edb_core/cell/layout.py +0 -6
  8. pyedb/dotnet/edb_core/cell/voltage_regulator.py +0 -5
  9. pyedb/dotnet/edb_core/components.py +2 -2
  10. pyedb/dotnet/edb_core/dotnet/primitive.py +129 -3
  11. pyedb/dotnet/edb_core/edb_data/hfss_pi_simulation_setup_data.py +0 -460
  12. pyedb/dotnet/edb_core/edb_data/primitives_data.py +38 -38
  13. pyedb/dotnet/edb_core/edb_data/raptor_x_simulation_setup_data.py +1 -1
  14. pyedb/dotnet/edb_core/layout.py +21 -0
  15. pyedb/dotnet/edb_core/layout_validation.py +26 -0
  16. pyedb/dotnet/edb_core/nets.py +1 -1
  17. pyedb/dotnet/edb_core/sim_setup_data/data/sim_setup_info.py +1 -1
  18. pyedb/dotnet/edb_core/sim_setup_data/data/simulation_settings.py +357 -0
  19. pyedb/dotnet/edb_core/siwave.py +14 -0
  20. pyedb/dotnet/edb_core/utilities/hfss_simulation_setup.py +83 -0
  21. pyedb/dotnet/edb_core/utilities/simulation_setup.py +7 -4
  22. pyedb/misc/siw_feature_config/xtalk_scan/fd_xtalk_scan_config.py +91 -0
  23. pyedb/misc/siw_feature_config/xtalk_scan/impedance_scan_config.py +70 -0
  24. pyedb/misc/siw_feature_config/xtalk_scan/net.py +69 -0
  25. pyedb/misc/siw_feature_config/xtalk_scan/pins.py +60 -0
  26. pyedb/misc/siw_feature_config/xtalk_scan/scan_config.py +88 -0
  27. pyedb/misc/siw_feature_config/xtalk_scan/td_xtalk_config.py +104 -0
  28. pyedb/workflow.py +32 -0
  29. {pyedb-0.16.0.dist-info → pyedb-0.18.0.dist-info}/METADATA +1 -1
  30. {pyedb-0.16.0.dist-info → pyedb-0.18.0.dist-info}/RECORD +32 -24
  31. {pyedb-0.16.0.dist-info → pyedb-0.18.0.dist-info}/LICENSE +0 -0
  32. {pyedb-0.16.0.dist-info → pyedb-0.18.0.dist-info}/WHEEL +0 -0
@@ -1,460 +0,0 @@
1
- # Copyright (C) 2023 - 2024 ANSYS, Inc. and/or its affiliates.
2
- # SPDX-License-Identifier: MIT
3
- #
4
- #
5
- # Permission is hereby granted, free of charge, to any person obtaining a copy
6
- # of this software and associated documentation files (the "Software"), to deal
7
- # in the Software without restriction, including without limitation the rights
8
- # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- # copies of the Software, and to permit persons to whom the Software is
10
- # furnished to do so, subject to the following conditions:
11
- #
12
- # The above copyright notice and this permission notice shall be included in all
13
- # copies or substantial portions of the Software.
14
- #
15
- # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- # FITNE SS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- # SOFTWARE.
22
-
23
- from pyedb.dotnet.edb_core.general import convert_py_list_to_net_list
24
- from pyedb.dotnet.edb_core.sim_setup_data.data.sweep_data import SweepData
25
- from pyedb.dotnet.edb_core.utilities.simulation_setup import SimulationSetup
26
- from pyedb.generic.general_methods import generate_unique_name
27
-
28
-
29
- class HFSSPISimulationSetup(SimulationSetup):
30
- """Manages EDB methods for HFSSPI simulation setup."""
31
-
32
- def __init__(self, pedb, edb_object=None):
33
- super().__init__(pedb, edb_object)
34
- self._pedb = pedb
35
- self._setup_type = "kHFSSPI"
36
- self._edb_setup_info = None
37
- self.logger = self._pedb.logger
38
-
39
- def create(self, name=None):
40
- """Create an HFSS setup."""
41
- self._name = name
42
- self._create(name)
43
- return self
44
-
45
- @property
46
- def setup_type(self):
47
- return self._setup_type
48
-
49
- @property
50
- def settings(self):
51
- return HFSSPISimulationSettings(self._edb_setup_info, self._pedb)
52
-
53
- @property
54
- def enabled(self):
55
- return self.settings.enabled
56
-
57
- @enabled.setter
58
- def enabled(self, value):
59
- if isinstance(value, bool):
60
- self.settings.enabled = value
61
- else:
62
- self.logger.error(f"Property enabled expects a boolean value while the provided value is {value}.")
63
-
64
- @property
65
- def position(self):
66
- return self._edb_setup_info.Position
67
-
68
- @position.setter
69
- def position(self, value):
70
- if isinstance(value, int):
71
- self._edb_setup_info.Position = value
72
- else:
73
- self.logger.error(f"Property position expects an integer value while the provided value is {value}.")
74
-
75
- def add_frequency_sweep(self, name=None, frequency_sweep=None):
76
- """Add frequency sweep.
77
-
78
- Parameters
79
- ----------
80
- name : str, optional
81
- Name of the frequency sweep.
82
- frequency_sweep : list, optional
83
- List of frequency points.
84
-
85
- Returns
86
- -------
87
- :class:`pyedb.dotnet.edb_core.edb_data.hfss_simulation_setup_data.EdbFrequencySweep`wheen succeeded, ``False``
88
- when failed.
89
-
90
- Examples
91
- --------
92
- >>> setup1 = edbapp.create_hfss_setup("setup1")
93
- >>> setup1.add_frequency_sweep(frequency_sweep=[
94
- ... ["linear count", "0", "1kHz", 1],
95
- ... ["log scale", "1kHz", "0.1GHz", 10],
96
- ... ["linear scale", "0.1GHz", "10GHz", "0.1GHz"],
97
- ... ])
98
- """
99
- if name in self.frequency_sweeps:
100
- self.logger.error("Frequency sweep with same name already defined.")
101
- return False
102
- if not name:
103
- name = generate_unique_name("sweep")
104
- return SweepData(self, frequency_sweep, name)
105
-
106
-
107
- class HFSSPISimulationSettings(object):
108
- def __init__(self, edb_setup_info, pedb):
109
- self._pedb = pedb
110
- self.logger = self._pedb.logger
111
- self._edb_setup_info = edb_setup_info
112
- self._simulation_settings = edb_setup_info.SimulationSettings
113
-
114
- @property
115
- def auto_select_nets_for_simulation(self):
116
- """Auto select nets for simulation.
117
-
118
- Returns
119
- -------
120
- bool
121
- """
122
- return self._simulation_settings.AutoSelectNetsForSimulation
123
-
124
- @auto_select_nets_for_simulation.setter
125
- def auto_select_nets_for_simulation(self, value):
126
- if isinstance(value, bool):
127
- self._simulation_settings.AutoSelectNetsForSimulation = value
128
- else:
129
- self.logger.error(
130
- "Property auto_select_nets_for_simulation expects a boolean "
131
- f"value while the provided value is {value}."
132
- )
133
-
134
- @property
135
- def enabled(self):
136
- return self._simulation_settings.Enabled
137
-
138
- @enabled.setter
139
- def enabled(self, value):
140
- if isinstance(value, bool):
141
- self._simulation_settings.Enabled = value
142
- else:
143
- self.logger.error(f"Property enabled expects a boolean value while the provided value is {value}.")
144
-
145
- @property
146
- def ignore_dummy_nets_for_selected_nets(self):
147
- """Auto select Nets for simulation
148
-
149
- Returns
150
- -------
151
- bool
152
- """
153
- return self._simulation_settings.IgnoreDummyNetsForSelectedNets
154
-
155
- @ignore_dummy_nets_for_selected_nets.setter
156
- def ignore_dummy_nets_for_selected_nets(self, value):
157
- if isinstance(value, bool):
158
- self._simulation_settings.IgnoreDummyNetsForSelectedNets = value
159
- else:
160
- self.logger.error(
161
- "Property ignore_dummy_nets_for_selected_nets expects a boolean "
162
- f"value while the provided value is {value}."
163
- )
164
-
165
- @property
166
- def ignore_small_holes(self):
167
- """Ignore small holes choice.
168
-
169
- Returns
170
- -------
171
- bool
172
- """
173
- return self._simulation_settings.IgnoreSmallHoles
174
-
175
- @ignore_small_holes.setter
176
- def ignore_small_holes(self, value):
177
- if isinstance(value, bool):
178
- self._simulation_settings.IgnoreSmallHoles = value
179
- else:
180
- self.logger.error(
181
- f"Property ignore_small_holes expects a boolean value while the provided value is {value}."
182
- )
183
-
184
- @property
185
- def ignore_small_holes_min_diameter(self):
186
- """Min diameter to ignore small holes.
187
-
188
- Returns
189
- -------
190
- str
191
- """
192
- return self._simulation_settings.IgnoreSmallHolesMinDiameter
193
-
194
- @ignore_small_holes_min_diameter.setter
195
- def ignore_small_holes_min_diameter(self, value):
196
- self._simulation_settings.IgnoreSmallHolesMinDiameter = self._pedb.edb_value(value).ToString()
197
-
198
- @property
199
- def improved_loss_model(self):
200
- """Improved Loss Model on power ground nets option.
201
-
202
- Returns
203
- -------
204
- str
205
- ``Level1``, ``Level2``, ``Level3``
206
- """
207
- return self._simulation_settings.ImprovedLossModel
208
-
209
- @improved_loss_model.setter
210
- def improved_loss_model(self, value):
211
- expected_values = ["Level1", "Level2", "Level3"]
212
- if isinstance(value, str) and value in expected_values:
213
- self._simulation_settings.ImprovedLossModel = value
214
- else:
215
- self.logger.error(
216
- "Property improved_loss_model expects a string value among "
217
- f"'Level1', 'Level2' or 'Level3' while the provided value is {value}."
218
- )
219
-
220
- @property
221
- def include_enhanced_bond_wire_modeling(self):
222
- """Enhance Bond wire modeling.
223
-
224
- Returns
225
- -------
226
- bool
227
- """
228
- return self._simulation_settings.IncludeEnhancedBondWireModeling
229
-
230
- @include_enhanced_bond_wire_modeling.setter
231
- def include_enhanced_bond_wire_modeling(self, value):
232
- if isinstance(value, bool):
233
- self._simulation_settings.IncludeEnhancedBondWireModeling = value
234
- else:
235
- self.logger.error(
236
- "Property include_enhanced_bond_wire_modeling expects a "
237
- f"boolean value while the provided value is {value}."
238
- )
239
-
240
- @property
241
- def include_nets(self):
242
- """Add Additional Nets for simulation.
243
-
244
- Returns
245
- -------
246
- [str]
247
- List of net name.
248
- """
249
- return list(self._simulation_settings.IncludeNets)
250
-
251
- @include_nets.setter
252
- def include_nets(self, value):
253
- if isinstance(value, str):
254
- value = [value]
255
- if isinstance(value, list):
256
- self._simulation_settings.IncludeNets = convert_py_list_to_net_list(value)
257
- else:
258
- self.logger.error(
259
- f"Property include_nets expects a string or list of string while the provided value is {value}."
260
- )
261
-
262
- @property
263
- def min_plane_area_to_mesh(self):
264
- """The minimum area below which geometry is ignored.
265
-
266
- Returns
267
- -------
268
- str
269
- """
270
- return self._simulation_settings.MinPlaneAreaToMesh
271
-
272
- @min_plane_area_to_mesh.setter
273
- def min_plane_area_to_mesh(self, value):
274
- self._simulation_settings.MinPlaneAreaToMesh = self._pedb.edb_value(value).ToString()
275
-
276
- @property
277
- def min_void_area_to_mesh(self):
278
- """The minimum area below which voids are ignored.
279
-
280
- Returns
281
- -------
282
- str
283
- """
284
- return self._simulation_settings.MinVoidAreaToMesh
285
-
286
- @min_void_area_to_mesh.setter
287
- def min_void_area_to_mesh(self, value):
288
- self._simulation_settings.MinVoidAreaToMesh = self._pedb.edb_value(value).ToString()
289
-
290
- @property
291
- def model_type(self):
292
- """Model Type setting.
293
-
294
- Returns
295
- -------
296
- int
297
- Model type: ``0``=RDL, ``1``=Package, ``2``=PCB
298
- """
299
- return self._simulation_settings.ModelType
300
-
301
- @model_type.setter
302
- def model_type(self, value):
303
- if isinstance(value, int) and value in range(3):
304
- self._simulation_settings.ModelType = value
305
- else:
306
- self.logger.error(
307
- f"Property model_type expects an integer value among 0, 1 or 2 while the provided value is {value}."
308
- )
309
-
310
- @property
311
- def perform_erc(self):
312
- """Perform ERC
313
-
314
- Returns
315
- -------
316
- bool
317
- """
318
- return self._simulation_settings.PerformERC
319
-
320
- @perform_erc.setter
321
- def perform_erc(self, value):
322
- if isinstance(value, bool):
323
- self._simulation_settings.PerformERC = value
324
- else:
325
- self.logger.error(f"Property perform_erc expects a boolean value while the provided value is {value}.")
326
-
327
- @property
328
- def pi_slider_pos(self):
329
- """The Simulation Preference Slider setting
330
-
331
- Returns
332
- -------
333
- int
334
- Model type: ``0``= balanced, ``1``=Accuracy.
335
- """
336
- return self._simulation_settings.PISliderPos
337
-
338
- @pi_slider_pos.setter
339
- def pi_slider_pos(self, value):
340
- if isinstance(value, int) and value in range(2):
341
- self._simulation_settings.PISliderPos = value
342
- else:
343
- self.logger.error(
344
- f"Property pi_slider_pos expects an integer value among 0 or 1 while the provided value is {value}."
345
- )
346
-
347
- @property
348
- def rms_surface_roughness(self):
349
- """RMS Surface Roughness setting
350
-
351
- Returns
352
- -------
353
- str
354
- """
355
- return self._simulation_settings.RMSSurfaceRoughness
356
-
357
- @rms_surface_roughness.setter
358
- def rms_surface_roughness(self, value):
359
- self._simulation_settings.RMSSurfaceRoughness = self._pedb.edb_value(value).ToString()
360
-
361
- @property
362
- def signal_nets_conductor_modeling(self):
363
- """Conductor Modeling
364
-
365
- Returns
366
- -------
367
- str
368
- Value: ``"MeshInside"`` or ``"ImpedanceBoundary"``.
369
- """
370
- return self._simulation_settings.SignalNetsConductorModeling
371
-
372
- @signal_nets_conductor_modeling.setter
373
- def signal_nets_conductor_modeling(self, value):
374
- expected_values = ["MeshInside", "ImpedanceBoundary"]
375
- if isinstance(value, str) and value in expected_values:
376
- self._simulation_settings.SignalNetsConductorModeling = value
377
- else:
378
- self.logger.error(
379
- "Property signal_nets_conductor_modeling expects a string value among "
380
- f"'MeshInside' or 'ImpedanceBoundary' while the provided value is {value}."
381
- )
382
-
383
- @property
384
- def signal_nets_error_tolerance(self):
385
- """Error Tolerance
386
-
387
- Returns
388
- -------
389
- str
390
- Value between 0.02 and 1.
391
- """
392
- return self._simulation_settings.SignalNetsErrorTolerance
393
-
394
- @signal_nets_error_tolerance.setter
395
- def signal_nets_error_tolerance(self, value):
396
- self._simulation_settings.SignalNetsErrorTolerance = self._pedb.edb_value(value).ToString()
397
-
398
- @property
399
- def signal_nets_include_improved_dielectric_fill_refinement(self):
400
- return self._simulation_settings.SignalNetsIncludeImprovedDielectricFillRefinement
401
-
402
- @signal_nets_include_improved_dielectric_fill_refinement.setter
403
- def signal_nets_include_improved_dielectric_fill_refinement(self, value):
404
- if isinstance(value, bool):
405
- self._simulation_settings.SignalNetsIncludeImprovedDielectricFillRefinement = value
406
- else:
407
- self.logger.error(
408
- "Property signal_nets_include_improved_dielectric_fill_refinement "
409
- f"expects a boolean value while the provided value is {value}."
410
- )
411
-
412
- @property
413
- def signal_nets_include_improved_loss_handling(self):
414
- """Improved Dielectric Fill Refinement choice.
415
-
416
- Returns
417
- -------
418
- bool
419
- """
420
- return self._simulation_settings.SignalNetsIncludeImprovedLossHandling
421
-
422
- @signal_nets_include_improved_loss_handling.setter
423
- def signal_nets_include_improved_loss_handling(self, value):
424
- if isinstance(value, bool):
425
- self._simulation_settings.SignalNetsIncludeImprovedLossHandling = value
426
- else:
427
- self.logger.error(
428
- "Property signal_nets_include_improved_loss_handling "
429
- f"expects a boolean value while the provided value is {value}."
430
- )
431
-
432
- @property
433
- def snap_length_threshold(self):
434
- return self._simulation_settings.SnapLengthThreshold
435
-
436
- @snap_length_threshold.setter
437
- def snap_length_threshold(self, value):
438
- self._simulation_settings.SnapLengthThreshold = self._pedb.edb_value(value).ToString()
439
-
440
- @property
441
- def surface_roughness_model(self):
442
- """Chosen Model setting
443
-
444
- Returns
445
- -------
446
- str
447
- Model allowed, ``"None"``, ``"Exponential"`` or ``"Hammerstad"``.
448
- """
449
- return self._simulation_settings.SurfaceRoughnessModel
450
-
451
- @surface_roughness_model.setter
452
- def surface_roughness_model(self, value):
453
- expected_values = ["None", "Exponential", "Hammerstad"]
454
- if isinstance(value, str) and value in expected_values:
455
- self._simulation_settings.SurfaceRoughnessModel = value
456
- else:
457
- self.logger.error(
458
- "Property surface_roughness_model expects a string value among "
459
- f"'None', 'Exponential' or 'Hammerstad' while the provided value is {value}."
460
- )
@@ -558,6 +558,15 @@ class EDBPrimitives(Primitive):
558
558
  dist = GeometryOperators.points_distance(mid_point, point)
559
559
  return [out.X.ToDouble(), out.Y.ToDouble()]
560
560
 
561
+ @property
562
+ def voids(self):
563
+ """:obj:`list` of :class:`Primitive <ansys.edb.primitive.Primitive>`: List of void\
564
+ primitive objects inside the primitive.
565
+
566
+ Read-Only.
567
+ """
568
+ return [cast(void, self._app) for void in self.prim_obj.Voids]
569
+
561
570
  @property
562
571
  def arcs(self):
563
572
  """Get the Primitive Arc Data."""
@@ -896,6 +905,35 @@ class EdbPolygon(EDBPrimitives, PolygonDotNet):
896
905
  return cloned_poly
897
906
  return False
898
907
 
908
+ @property
909
+ def has_self_intersections(self):
910
+ """Check if Polygon has self intersections.
911
+
912
+ Returns
913
+ -------
914
+ bool
915
+ """
916
+ return self.polygon_data.edb_api.HasSelfIntersections()
917
+
918
+ def fix_self_intersections(self):
919
+ """Remove self intersections if they exists.
920
+
921
+ Returns
922
+ -------
923
+ list
924
+ All new polygons created from the removal operation.
925
+ """
926
+ new_polys = []
927
+ if self.has_self_intersections:
928
+ new_polygons = list(self.polygon_data.edb_api.RemoveSelfIntersections())
929
+ self.polygon_data = new_polygons[0]
930
+ for p in new_polygons[1:]:
931
+ cloned_poly = self._app.edb_api.cell.primitive.polygon.create(
932
+ self._app.active_layout, self.layer_name, self.net, p
933
+ )
934
+ new_polys.append(cloned_poly)
935
+ return new_polys
936
+
899
937
  def duplicate_across_layers(self, layers):
900
938
  """Duplicate across layer a primitive object.
901
939
 
@@ -989,44 +1027,6 @@ class EdbPolygon(EDBPrimitives, PolygonDotNet):
989
1027
  return self.api_object.SetPolygonData(polygon_data)
990
1028
  return False
991
1029
 
992
- def scale(self, factor, center=None):
993
- """Scales the polygon relative to a center point by a factor.
994
-
995
- Parameters
996
- ----------
997
- factor : float
998
- Scaling factor.
999
- center : List of float or str [x,y], optional
1000
- If None scaling is done from polygon center.
1001
-
1002
- Returns
1003
- -------
1004
- bool
1005
- ``True`` when successful, ``False`` when failed.
1006
-
1007
- Examples
1008
- --------
1009
- >>> edbapp = pyaedt.Edb("myproject.aedb")
1010
- >>> top_layer_polygon = [poly for poly in edbapp.modeler.polygons if poly.layer_name == "Top Layer"]
1011
- >>> for polygon in top_layer_polygon:
1012
- >>> polygon.scale(factor=2)
1013
- """
1014
- if not isinstance(factor, str):
1015
- factor = float(factor)
1016
- polygon_data = self._edb.Geometry.PolygonData.CreateFromArcs(self.polygon_data.edb_api.GetArcData(), True)
1017
- if not center:
1018
- center = polygon_data.GetBoundingCircleCenter()
1019
- if center:
1020
- polygon_data.Scale(factor, center)
1021
- return self.api_object.SetPolygonData(polygon_data)
1022
- elif isinstance(center, list) and len(center) == 2:
1023
- center = self._edb.Geometry.PointData(
1024
- self._edb.Utility.Value(center[0]), self._edb.Utility.Value(center[1])
1025
- )
1026
- polygon_data.Scale(factor, center)
1027
- return self.api_object.SetPolygonData(polygon_data)
1028
- return False
1029
-
1030
1030
  def move_layer(self, layer):
1031
1031
  """Move polygon to given layer.
1032
1032
 
@@ -38,7 +38,7 @@ class RaptorXSimulationSetup(SimulationSetup):
38
38
  def create(self, name=None):
39
39
  """Create an HFSS setup."""
40
40
  self._name = name
41
- self._create(name)
41
+ self._create(name, simulation_setup_type=self._setup_type)
42
42
  return self
43
43
 
44
44
  @property
@@ -94,6 +94,27 @@ class EdbLayout(object):
94
94
  """
95
95
  return self._pedb.stackup.layers
96
96
 
97
+ def get_primitive(self, primitive_id):
98
+ """Retrieve primitive from give id.
99
+
100
+ Parameters
101
+ ----------
102
+ primitive_id : int
103
+ Primitive id.
104
+
105
+ Returns
106
+ -------
107
+ list of :class:`pyedb.dotnet.edb_core.edb_data.primitives_data.EDBPrimitives`
108
+ List of primitives.
109
+ """
110
+ for p in self._layout.primitives:
111
+ if p.id == primitive_id:
112
+ return p
113
+ for p in self._layout.primitives:
114
+ for v in p.voids:
115
+ if v.id == primitive_id:
116
+ return v
117
+
97
118
  @property
98
119
  def primitives(self):
99
120
  """Primitives.
@@ -258,6 +258,32 @@ class LayoutValidation:
258
258
 
259
259
  return new_nets
260
260
 
261
+ def fix_self_intersections(self, net_list=None):
262
+ """Find and fix self intersections from a given netlist.
263
+
264
+ Parameters
265
+ ----------
266
+ net_list : str, list, optional
267
+ List of nets on which check disjoints. If `None` is provided then the algorithm will loop on all nets.
268
+
269
+ Returns
270
+ -------
271
+ bool
272
+ """
273
+ if not net_list:
274
+ net_list = list(self._pedb.nets.keys())
275
+ elif isinstance(net_list, str):
276
+ net_list = [net_list]
277
+ new_prims = []
278
+ for prim in self._pedb.modeler.polygons:
279
+ if prim.net_name in net_list:
280
+ new_prims.extend(prim.fix_self_intersections())
281
+ if new_prims:
282
+ self._pedb._logger.info("Self-intersections detected and removed.")
283
+ else:
284
+ self._pedb._logger.info("Self-intersection not found.")
285
+ return True
286
+
261
287
  def illegal_net_names(self, fix=False):
262
288
  """Find and fix illegal net names."""
263
289
  pattern = r"[\(\)\\\/:;*?<>\'\"|`~$]"
@@ -38,7 +38,7 @@ class EdbNets(object):
38
38
 
39
39
  Examples
40
40
  --------
41
- >>> from pyedb.dotnet.edb import Edb
41
+ >>> from pyedb import Edb
42
42
  >>> edbapp = Edb("myaedbfolder", edbversion="2021.2")
43
43
  >>> edb_nets = edbapp.nets
44
44
  """
@@ -46,7 +46,7 @@ class SimSetupInfo:
46
46
  "kAnalysisOption": None,
47
47
  "kSIwaveDCIR": self._pedb.simsetupdata.SIwave.SIWDCIRSimulationSettings,
48
48
  "kSIwaveEMI": None,
49
- "kHFSSPI": None,
49
+ "kHFSSPI": self._pedb.simsetupdata.HFSSPISimulationSettings,
50
50
  "kDDRwizard": None,
51
51
  "kQ3D": None,
52
52
  "kNumSetupTypes": None,