You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm getting an error when trying to draw a polyline with Ansys Maxwell 3d.
On the terminal i get:
PyAEDT ERROR: AEDT GRPC API CALL ERROR on create_polyline
PyAEDT ERROR: Failed to execute grpc AEDT command: CreatePolyline
PyAEDT ERROR: File "c:\Work\995_Python\Start_Ansys\Ansys_start_env\pattern_drawing.py", line 117, in pattern_drawing
PyAEDT ERROR: m3d.modeler.create_polyline(test_points)
PyAEDT ERROR: File "C:\Work\995_Python\Start_Ansys\Ansys_start_env\Lib\site-packages\pyaedt\modeler\cad\Primitives.py", line 6247, in create_polyline
PyAEDT ERROR: Last Electronics Desktop Message - [error] solve inside cannot be set for an object that is excluded due to material threshold constraints.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello all,
I'm getting an error when trying to draw a polyline with Ansys Maxwell 3d.
On the terminal i get:
PyAEDT ERROR: AEDT GRPC API CALL ERROR on create_polyline
PyAEDT ERROR: Failed to execute grpc AEDT command: CreatePolyline
PyAEDT ERROR: File "c:\Work\995_Python\Start_Ansys\Ansys_start_env\pattern_drawing.py", line 117, in pattern_drawing
PyAEDT ERROR: m3d.modeler.create_polyline(test_points)
PyAEDT ERROR: File "C:\Work\995_Python\Start_Ansys\Ansys_start_env\Lib\site-packages\pyaedt\modeler\cad\Primitives.py", line 6247, in create_polyline
PyAEDT ERROR: Last Electronics Desktop Message - [error] solve inside cannot be set for an object that is excluded due to material threshold constraints.
PyAEDT ERROR: Method arguments:
PyAEDT ERROR: position_list = [['0mm', '0mm', '0mm'], ['100mm', '20mm', '0mm'], ['71mm', '71mm', '0mm'], ['0mm', '100mm', '0mm']]
PyAEDT ERROR: Check Online documentation on: https://aedt.docs.pyansys.com/version/stable/search.html?q=create_polyline
About the code, in the main.py where i do the import of all the needed packages, and i first setup the Maxwell 3d
m3d, setup_config = Maxwell_cfg.setup_Maxwell_3D(Maxwell3d,project_name)
#Draw the desired pattern
objects_list_m3d = pattern_drawing.pattern_drawing(m3d, Excel_input_data, Others_data_excel)
where
def setup_Maxwell_3D(Maxwell3d,project):
and
def pattern_drawing(m3d, input_data_excel,others_data_excel):
[omissis]
test_points = [["0mm", "0mm", "0mm"], ["100mm", "20mm", "0mm"],
["71mm", "71mm", "0mm"], ["0mm", "100mm", "0mm"]]
#m3d.modeler.create_polyline(vertices_with_square_brackets,close_surface=True)
m3d.modeler.create_polyline(test_points,close_surface=True)
return
The point is that if i run the example code by itself(reported below), the polyline is drawn correctly. I don't understand what i'm missing.
from pyaedt import Desktop
from pyaedt import Maxwell3d
desktop=Desktop(specified_version="2023.2", new_desktop_session=False)
aedtapp = Maxwell3d()
aedtapp.modeler.model_units = "mm"
modeler = aedtapp.modeler
test_points = [["0mm", "0mm", "0mm"], ["100mm", "20mm", "0mm"],
["71mm", "71mm", "0mm"], ["0mm", "100mm", "0mm"]]
P1 = modeler.create_polyline(test_points, name="PL_line_segments")
I have searched around for a similar problem, but i didn't find something similar to solve the issue.....
Thank you in advance!!!
Beta Was this translation helpful? Give feedback.
All reactions