ansys-speos-core 0.3.0__py3-none-any.whl → 0.5.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ansys/speos/core/__init__.py +2 -1
- ansys/speos/core/body.py +9 -0
- ansys/speos/core/bsdf.py +1131 -0
- ansys/speos/core/face.py +10 -0
- ansys/speos/core/generic/constants.py +40 -0
- ansys/speos/core/generic/general_methods.py +169 -1
- ansys/speos/core/generic/visualization_methods.py +289 -0
- ansys/speos/core/kernel/client.py +76 -35
- ansys/speos/core/launcher.py +91 -2
- ansys/speos/core/logger.py +1 -1
- ansys/speos/core/lxp.py +35 -14
- ansys/speos/core/opt_prop.py +18 -3
- ansys/speos/core/part.py +9 -0
- ansys/speos/core/project.py +88 -13
- ansys/speos/core/py.typed +0 -0
- ansys/speos/core/sensor.py +237 -6
- ansys/speos/core/source.py +24 -6
- ansys/speos/core/speos.py +36 -6
- {ansys_speos_core-0.3.0.dist-info → ansys_speos_core-0.5.0.dist-info}/METADATA +21 -12
- {ansys_speos_core-0.3.0.dist-info → ansys_speos_core-0.5.0.dist-info}/RECORD +22 -18
- {ansys_speos_core-0.3.0.dist-info → ansys_speos_core-0.5.0.dist-info}/WHEEL +1 -1
- {ansys_speos_core-0.3.0.dist-info → ansys_speos_core-0.5.0.dist-info/licenses}/LICENSE +0 -0
ansys/speos/core/__init__.py
CHANGED
|
@@ -28,13 +28,14 @@ It gathers functionaties and tools of these APIs.
|
|
|
28
28
|
try:
|
|
29
29
|
import importlib.metadata as importlib_metadata
|
|
30
30
|
except ModuleNotFoundError: # pragma: no cover
|
|
31
|
-
import importlib_metadata
|
|
31
|
+
import importlib_metadata # type: ignore[no-redef]
|
|
32
32
|
|
|
33
33
|
# Version
|
|
34
34
|
__version__ = importlib_metadata.version("ansys-speos-core")
|
|
35
35
|
|
|
36
36
|
|
|
37
37
|
from ansys.speos.core.body import Body
|
|
38
|
+
import ansys.speos.core.bsdf as bsdf
|
|
38
39
|
from ansys.speos.core.face import Face
|
|
39
40
|
from ansys.speos.core.geo_ref import GeoRef
|
|
40
41
|
from ansys.speos.core.intensity import Intensity
|
ansys/speos/core/body.py
CHANGED
|
@@ -29,6 +29,7 @@ from typing import List, Mapping, Optional, Union
|
|
|
29
29
|
|
|
30
30
|
from ansys.speos.core import proto_message_utils
|
|
31
31
|
import ansys.speos.core.face as face
|
|
32
|
+
from ansys.speos.core.geo_ref import GeoRef
|
|
32
33
|
from ansys.speos.core.kernel.body import ProtoBody
|
|
33
34
|
from ansys.speos.core.kernel.client import SpeosClient
|
|
34
35
|
import ansys.speos.core.part as part
|
|
@@ -81,6 +82,14 @@ class Body:
|
|
|
81
82
|
|
|
82
83
|
self._geom_features = []
|
|
83
84
|
|
|
85
|
+
@property
|
|
86
|
+
def geo_path(self) -> GeoRef:
|
|
87
|
+
"""Geometry path to be used within other speos objects."""
|
|
88
|
+
geo_paths = [self._name]
|
|
89
|
+
if isinstance(self._parent_part, part.Part.SubPart):
|
|
90
|
+
geo_paths.insert(0, self._parent_part.geo_path.metadata["GeoPath"])
|
|
91
|
+
return GeoRef.from_native_link("/".join(geo_paths))
|
|
92
|
+
|
|
84
93
|
def create_face(
|
|
85
94
|
self,
|
|
86
95
|
name: str,
|