:class:`SimulationDirect` ========================= .. toctree:: :hidden: SourceSampling .. py:class:: ansys.speos.core.simulation.SimulationDirect(project, name, description = '', metadata = None, simulation_instance = None, default_parameters = None) Bases: :py:obj:`BaseSimulation` Type of Simulation: Direct. By default, geometry distance tolerance is set to 0.01, maximum number of impacts is set to 100, colorimetric standard is set to CIE 1931, dispersion is set to True, fast transmission gathering is set to False, ambient material URI is empty, and weight's minimum energy percentage is set to 0.005. By default, the simulation will stop after 200000 rays, with an automatic save frequency of 1800s. :Parameters: **project** : :obj:`ansys.speos.core.project.Project` Project in which simulation shall be created. **name** : :class:`python:str` Name of the simulation. **description** : :class:`python:str` Description of the Simulation. By default, ``""``. **metadata** : :obj:`Optional`\[:obj:`Mapping`\[:class:`python:str`, :class:`python:str`]] Metadata of the feature. By default, ``{}``. **simulation_instance** : :obj:`ansys.api.speos.scene.v2.scene_pb2.Scene.SimulationInstance`, :obj:`optional` Simulation instance to provide if the feature does not have to be created from scratch By default, ``None``, means that the feature is created from scratch by default. **default_parameters** : :obj:`ansys.speos.core.generic.parameters.DirectSimulationParameters`, :obj:`optional` If defined the values in the direct simulation instance will be overwritten by the values of the data class. .. !! processed by numpydoc !! .. py:currentmodule:: SimulationDirect Overview -------- .. tab-set:: .. tab-item:: Methods .. list-table:: :header-rows: 0 :widths: auto * - :py:attr:`~set_weight` - Activate weight. Highly recommended to fill. * - :py:attr:`~set_weight_none` - Deactivate weight. * - :py:attr:`~set_colorimetric_standard_CIE_1931` - Set the colorimetric standard to CIE 1931. * - :py:attr:`~set_colorimetric_standard_CIE_1964` - Set the colorimetric standard to CIE 1964. * - :py:attr:`~commit` - Save feature: send the local data to the speos server database. .. tab-item:: Properties .. list-table:: :header-rows: 0 :widths: auto * - :py:attr:`~dispersion` - Activate/Deactivate the dispersion calculation. * - :py:attr:`~ambient_material_file_uri` - The ambient material file URI. * - :py:attr:`~stop_condition_rays_number` - The number of rays to stop the simulation. * - :py:attr:`~stop_condition_duration` - The duration to stop the simulation. * - :py:attr:`~automatic_save_frequency` - The automatic save frequency. * - :py:attr:`~light_expert` - Whether light expert is enabled. Import detail ------------- .. code-block:: python from ansys.speos.core.simulation import SimulationDirect Property detail --------------- .. py:property:: dispersion :type: bool Activate/Deactivate the dispersion calculation. :Returns: :ref:`bool ` True if dispersion is activated. .. !! processed by numpydoc !! .. py:property:: ambient_material_file_uri :type: str The ambient material file URI. :Returns: :class:`python:str` The ambient material file URI. .. !! processed by numpydoc !! .. py:property:: stop_condition_rays_number :type: Optional[int] The number of rays to stop the simulation. :Returns: :obj:`Optional`\[:class:`python:int`] The number of rays, or None if no condition. .. !! processed by numpydoc !! .. py:property:: stop_condition_duration :type: Optional[int] The duration to stop the simulation. :Returns: :obj:`Optional`\[:class:`python:int`] The duration in seconds, or None if no condition. .. !! processed by numpydoc !! .. py:property:: automatic_save_frequency :type: int The automatic save frequency. :Returns: :class:`python:int` The save frequency in seconds. .. !! processed by numpydoc !! .. py:property:: light_expert :type: bool Whether light expert is enabled. :Returns: :ref:`bool ` True if light expert is enabled. .. !! processed by numpydoc !! Method detail ------------- .. py:method:: set_weight() Activate weight. Highly recommended to fill. :Returns: :obj:`ansys.speos.core.simulation.BaseSimulation.Weight` Weight. .. !! processed by numpydoc !! .. py:method:: set_weight_none() Deactivate weight. :Returns: :obj:`ansys.speos.core.simulation.SimulationDirect` Direct simulation .. !! processed by numpydoc !! .. py:method:: set_colorimetric_standard_CIE_1931() Set the colorimetric standard to CIE 1931. 2 degrees CIE Standard Colorimetric Observer Data. :Returns: :obj:`ansys.speos.core.simulation.SimulationDirect` Direct simulation .. !! processed by numpydoc !! .. py:method:: set_colorimetric_standard_CIE_1964() Set the colorimetric standard to CIE 1964. 10 degrees CIE Standard Colorimetric Observer Data. :Returns: :obj:`ansys.speos.core.simulation.SimulationDirect` Direct simulation .. !! processed by numpydoc !! .. py:method:: commit() Save feature: send the local data to the speos server database. :Returns: :obj:`ansys.speos.core.simulation.SimulationDirect` Simulation feature. .. !! processed by numpydoc !! Classes ------- .. autoapisummary:: ansys.speos.core.simulation.SimulationDirect.SourceSampling