Skip to main content
Ctrl+K
ansys-speos-core 0.5.2 documentation - Home ansys-speos-core 0.5.2 documentation - Home
  • Overview
  • Getting started
  • API reference
  • Examples
  • Contribute
    • Release notes
Ctrl+K
  • GitHub
Ctrl+K
  • Overview
  • Getting started
  • API reference
  • Examples
  • Contribute
  • Release notes
  • GitHub

Section Navigation

  • ansys.speos.core
    • kernel
      • body
      • client
      • crud
      • face
      • intensity_template
      • job
      • part
      • proto_message_utils
      • scene
      • sensor_template
      • simulation_template
        • SimulationTemplateLink
        • SimulationTemplateStub
      • sop_template
      • source_template
      • spectrum
      • vop_template
    • workflow
    • body
    • bsdf
    • face
    • geo_ref
    • intensity
    • launcher
    • logger
    • lxp
    • opt_prop
    • part
    • project
    • proto_message_utils
    • sensor
    • simulation
    • source
    • spectrum
    • speos
  • API reference
  • The ansys.speos.core library
  • The kernel package
  • The simulation_template.py module
  • SimulationTemplateLink

SimulationTemplateLink#

class ansys.speos.core.kernel.simulation_template.SimulationTemplateLink(db, key)#

Bases: ansys.speos.core.kernel.crud.CrudItem

Link object for simulation template in database.

Parameters:
dbansys.speos.core.kernel.simulation_template.SimulationTemplateStub

Database to link to.

keystr

Key of the simulation_template in the database.

Parameters:

key (str)

Examples

>>> from ansys.speos.core.speos import Speos
>>> from ansys.api.speos.simulation.v1 import simulation_template_pb2
>>> from ansys.speos.core.kernel.simulation_template import (
...     ProtoSimulationTemplate,
... )
>>> speos = Speos(host="localhost", port=50098)
>>> sim_t_db = speos.client.simulation_templates()
>>> sim_t_message = ProtoSimulationTemplate(name="Direct")
>>> sim_t_message.direct_mc_simulation_template.geom_distance_tolerance = 0.01
>>> sim_t_message.direct_mc_simulation_template.max_impact = 100
>>> sim_t_message.direct_mc_simulation_template.weight.minimum_energy_percentage = 0.005
>>> sim_t_message.direct_mc_simulation_template.colorimetric_standard = (
...     simulation_template_pb2.CIE_1931
... )
>>> sim_t_message.direct_mc_simulation_template.dispersion = True
>>> sim_t_link = sim_t_db.create(message=sim_t_message)

Overview#

get

Get the datamodel from database.

set

Change datamodel in database.

delete

Remove datamodel from database.

__str__

Return the string representation of the simulation_template.

Import detail#

from ansys.speos.core.kernel.simulation_template import SimulationTemplateLink

Method detail#

SimulationTemplateLink.__str__()#

Return the string representation of the simulation_template.

SimulationTemplateLink.get()#

Get the datamodel from database.

Returns:
simulation_template.SimulationTemplate

SimulationTemplate datamodel.

SimulationTemplateLink.set(data)#

Change datamodel in database.

Parameters:
datasimulation_template.SimulationTemplate

New simulation_template datamodel.

SimulationTemplateLink.delete()#

Remove datamodel from database.

On this page
  • ansys.speos.core.kernel.simulation_template.SimulationTemplateLink
  • Overview
  • Import detail
  • Method detail
    • __str__()
    • get()
    • set()
    • delete()
  • Show Source

© Copyright (c) 2025 ANSYS, Inc. All rights reserved.

Created using Sphinx 8.1.3.

Built with the Ansys Sphinx Theme 1.4.4.
Last updated on