Trelis in Abaqus

Dear all,

I’m currently automating an abaqus mesh optimization with meshes generated from Trelis. I’m able to generate a mesh in Trelis and Python with the same code, but when I try to run the same code in Abaqus, the following error pops up:

File “C:/Program Files/Trelis 16.5.4/bin/cubit.py”, line 28, in
_cubit = swig_import_helper()

File “C:/Program Files/Trelis 16.5.4/bin/cub.py”, line 24, in swig_import_helper
_mod = imp.load_module(’_cubit’, fp,pathname, description)
RuntimeERror: Import error: module not found.

Has anyone experienced the same issue or do someone know a possible solution for this?

Thank you very much in advance

Best regards,
Laurens

You will need to set your environment path variable to include the Trelis bin directory. Or set it through Python with

os.environ[“path”]+=";path/to/Trelis/bin"

Dear all,

I’ve tried that but the same error remains. It’s very strange because it’s working in python itself but not in Abaqus.

Best regards,
Laurens

Please add “acis/code/bin” to the environment “path” variable.