PyPrimeMesh fails on STEP files

I am using PyPrimeMesh (i.e., from ansys.meshing import prime) in a Python script to mesh CAD models.

For an extremely simple model (i.e., a cube), this import works for an x_t file but does not for the corresponding STEP file.

While the x_t import happens rather quickly in a few seconds, the STEP import hangs for >1min and finally reports ansys.meshing.prime.internals.error_handling.PrimeRuntimeError: CAD import failed.

Note that the server, which I start with "%AWP_ROOT251%\meshing\Prime\runPrime.bat" server -np 1 --ip 127.0.0.1 --port 50057 is functional the whole time and does not crash. After the failed STEP import, I can still successfully import an x_t file without having to restart the server.

Could you perhaps send me a basic Python script that shows how to import a trivial cube model from a STEP file?

Tagged:

Answers