We’re putting the final touches on our new badges platform. Badge issuance remains temporarily paused, but all completions are being recorded and will be fulfilled once the platform is live. Thank you for your patience.

Ansys Learning Forum Forums Discuss Simulation 3D Design How to run a Spaceclaim script from an external IDE like vscode? Reply To: How to run a Spaceclaim script from an external IDE like vscode?

mjmiddle
Ansys Employee

Since IronPython use .Net Framework it does not support a lot of CPython modules. An alternative is to use MathNet library (http://numerics.mathdotnet.com/). You can download the library yourself, but Ansys has distributed it inside the Ansys installation. Here is how you can access it with IronPython:

import os
import clr
clr.AddReference("Ans.Utilities")
version = Ansys.Utilities.ApplicationConfiguration.DefaultConfiguration.VersionInfo.VersionString
sys.path.append(os.environ["AWP_ROOT" + version] + "\\Addins\\ACT\\bin\\Win64")
clr.AddReferenceToFile("MathNet.Numerics.dll")
import MathNet.Numerics