Launch a local session#

If Ansys 2023 R2 or later and PyAnsys Geometry are installed, you can create a local backend session using Discovery, SpaceClaim, or the Geometry service. Once the backend is running, PyAnsys Geometry can manage the connection.

To launch and establish a connection to the service, open Python and use the following commands for either Discovery, SpaceClaim, or the Geometry service.

from ansys.geometry.core import launch_modeler_with_discovery

modeler = launch_modeler_with_discovery()
from ansys.geometry.core import launch_modeler_with_spaceclaim

modeler = launch_modeler_with_spaceclaim()
from ansys.geometry.core import launch_modeler_with_geometry_service

modeler = launch_modeler_with_geometry_service()

For more information on the arguments accepted by the launcher methods, see their API documentation:

Note

Because this is the first release of the Geometry service, you cannot yet define a product version or API version.

Go to Getting started