Skip to content

How to use scripting in HFSS to export the exact coordinates of any element as a csv format? #3911

Closed Answered by Samuelopez-ansys
Zdaymen asked this question in Q&A
Discussion options

You must be logged in to vote

@Zdaymen Not sure what you meant with exact coordinates, because for an sphere for instance, what is the exact coordinate?

What you can obtain with PyAEDT is the bounding box of each object (referred to the Global CS), the center, the mass... you just need to get the object:

hfss.modeler.objects

You can get the list of objects names:
names = hfss.modeler.objects.object_list

And then get the first object information:
hfss.modeler[names [0]]

With this information, you will get the faces, vertices info... and finally you can export this information in a CSV using any python module like import csv:
https://stackoverflow.com/questions/45549424/exporting-python-output-into-csv-or-text-file-be…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@mheroth
Comment options

@Samuelopez-ansys
Comment options

Answer selected by Samuelopez-ansys
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants