generate_trace_model#
- Model.generate_trace_model(project_name, cca_name='', copper_layer_name='', max_arc_segment=0.0, max_arc_segment_units='mm', min_trace_area=0.0, min_trace_area_units='mm2', min_hole_area=0.0, min_hole_area_units='mm2', use_snapshot_for_non_image_layer=False)#
Generate one or more trace models for a project.
- Parameters:
project_name (str) – Name of the Sherlock project to generate one or more trace models for.
cca_name (str, optional) – Name of the CCA to generate one or more trace models from. The default is
""
, in which case trace models are generated for CCAs and all layers.copper_layer_name (str, optional) – Name of the copper layer to generate one or more trace models from. The default is
""
, in which case trace models are generated either for the given CCA or for all layers.max_arc_segment (float, optional) – Maximum length of the segment to generate when Sherlock converts EDA arc drawing commands to line segments. The default is
0.0
. Smaller values for the maximum arc segment result in smoother arc representations on the FEA model. However, the cost of generating a larger number of shorter segments is higher. Such short segments cause the FEA tool to generate a larger number of smaller elements to represent the curved solid.max_arc_segment_units (str, optional) – Units for the maximum arc segment. The default is
"mm"
.min_trace_area (float, optional) – Minimum area of any trace polygon to include in the trace model. The default is
0.0
, which turns off any area filtering.min_trace_area_units (str, optional) – Units for the minimum trace area. The default is
"mm2"
.min_hole_area (float, optional) – Minimum area of any trace hole to include in the trace model. The default is
0.0
, which turns off any hole filtering.min_hole_area_units (str, optional) – Units for the minimum hole area. The default is
"mm2"
.use_snapshot_for_non_image_layer (bool, optional) – Whether to use an image to generate the trace model for layers that are not image layers. The default is
False
. IfTrue
and a snapshot image for the layer exists, the snapshot image is used. Otherwise, an image is created in the same way as a snapshot image is created.
- Returns:
Status code of the response. 0 for success.
- Return type:
int
Examples
>>> from ansys.sherlock.core import launcher >>> from ansys.sherlock.core import model >>> sherlock = launcher.launch_sherlock() >>> sherlock.model.generate_trace_model( 'Tutorial Project', 'Main Board', 0.05, 'mm' 0.0, 'mm2', 0.0, 'mm2')