engeom 0.2.12__cp38-abi3-macosx_11_0_arm64.whl → 0.2.13__cp38-abi3-macosx_11_0_arm64.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.
- engeom/_plot/matplotlib.py +9 -0
- engeom/airfoil.pyi +17 -0
- engeom/engeom.abi3.so +0 -0
- engeom/geom2.pyi +65 -0
- engeom/geom3.pyi +20 -0
- {engeom-0.2.12.dist-info → engeom-0.2.13.dist-info}/METADATA +1 -1
- {engeom-0.2.12.dist-info → engeom-0.2.13.dist-info}/RECORD +19 -19
- {engeom-0.2.12.dist-info → engeom-0.2.13.dist-info}/WHEEL +1 -1
engeom/_plot/matplotlib.py
CHANGED
@@ -147,6 +147,15 @@ else:
|
|
147
147
|
"""
|
148
148
|
self.ax.plot(curve.points[:, 0], curve.points[:, 1], **kwargs)
|
149
149
|
|
150
|
+
def fill_curve(self, curve: Curve2, **kwargs):
|
151
|
+
"""
|
152
|
+
Fill a curve on a Matplotlib Axes object.
|
153
|
+
:param curve: a Curve2 object (can be closed but doesn't need to be, will be closed automatically)
|
154
|
+
:param kwargs: keyword arguments to pass to the inner Axes.fill function
|
155
|
+
:return:
|
156
|
+
"""
|
157
|
+
self.ax.fill(curve.points[:, 0], curve.points[:, 1], **kwargs)
|
158
|
+
|
150
159
|
def distance(
|
151
160
|
self,
|
152
161
|
distance: Distance2,
|
engeom/airfoil.pyi
CHANGED
@@ -315,6 +315,23 @@ class AirfoilGeometry:
|
|
315
315
|
from .geom2 import Curve2, Circle2
|
316
316
|
from .metrology import Distance2
|
317
317
|
|
318
|
+
@staticmethod
|
319
|
+
def from_bytes(data: bytes) -> AirfoilGeometry:
|
320
|
+
"""
|
321
|
+
Create an instance of `AirfoilGeometry` from a byte string containing the airfoil geometry data serialized in
|
322
|
+
a msgpack format.
|
323
|
+
:param data: The byte string containing the serialized data
|
324
|
+
:return: An instance of `AirfoilGeometry`
|
325
|
+
"""
|
326
|
+
...
|
327
|
+
|
328
|
+
def to_bytes(self) -> bytes:
|
329
|
+
"""
|
330
|
+
Serialize the `AirfoilGeometry` instance to a byte string msgpack representation.
|
331
|
+
:return: A byte string containing the serialized data
|
332
|
+
"""
|
333
|
+
...
|
334
|
+
|
318
335
|
@staticmethod
|
319
336
|
def from_analyze(
|
320
337
|
section: Curve2,
|
engeom/engeom.abi3.so
CHANGED
Binary file
|
engeom/geom2.pyi
CHANGED
@@ -919,6 +919,55 @@ class Curve2:
|
|
919
919
|
"""
|
920
920
|
...
|
921
921
|
|
922
|
+
def offset_vertices(self, offset: float) -> Curve2:
|
923
|
+
"""
|
924
|
+
Create a new curve which is the result of offsetting the vertices of this curve by the
|
925
|
+
given offset. The direction of each vertex offset will be the same as the direction of the
|
926
|
+
surface normal at the curve station corresponding to that vertex, which is the angle
|
927
|
+
bisecting the normals of the two edges that meet at the vertex. Vertices at the ends of
|
928
|
+
the curve (on an open curve) will have the same normal as the edge they are connected to.
|
929
|
+
|
930
|
+
Compared to `offset_segments`, this method will move the vertices of the curve while
|
931
|
+
allowing the distance between the bodies of the initial and resulting segments to change.
|
932
|
+
Generally speaking, use this method if you primarily care about the vertices and not the
|
933
|
+
segments, or if the curvature between adjacent segments is very low.
|
934
|
+
|
935
|
+
:param offset: the distance to offset the vertices by.
|
936
|
+
:return: a new curve with the vertices offset by the given distance.
|
937
|
+
"""
|
938
|
+
...
|
939
|
+
|
940
|
+
def offset_segments(self, offset: float) -> Curve2:
|
941
|
+
"""
|
942
|
+
Create a new curve which is the result of offsetting the segments of this curve by the
|
943
|
+
given offset. The direction of the offset is perpendicular to the direction of the segment,
|
944
|
+
and a positive offset will move the segment outward from the curve, while a negative offset
|
945
|
+
will move it inward. Outward and inward are defined based on the counter-clockwise winding
|
946
|
+
convention.
|
947
|
+
|
948
|
+
Vertices will be moved to the intersection of their adjacent segments.
|
949
|
+
|
950
|
+
Compared to `offset_vertices`, this method will preserve the distance between the segments
|
951
|
+
bodies of the initial and resulting curves, while allowing vertices on outside corners to
|
952
|
+
get farther from the original as necessary for the segments to be straight lines.
|
953
|
+
|
954
|
+
:param offset: the distance to offset the segments by.
|
955
|
+
:return: a new curve with the segments offset by the given distance.
|
956
|
+
"""
|
957
|
+
...
|
958
|
+
|
959
|
+
def __add__(self, other: Curve2) -> Curve2:
|
960
|
+
"""
|
961
|
+
Concatenate two curves together, returning a new curve that is the result of appending the vertices of the
|
962
|
+
second curve to the first curve. Both curves must be open or this will throw an error. The resulting curve
|
963
|
+
will be open.
|
964
|
+
|
965
|
+
:param other: the curve to append to this curve.
|
966
|
+
:return: a new curve that is the result of concatenating the two curves.
|
967
|
+
"""
|
968
|
+
...
|
969
|
+
|
970
|
+
|
922
971
|
|
923
972
|
class Circle2:
|
924
973
|
"""
|
@@ -1225,3 +1274,19 @@ class Aabb2:
|
|
1225
1274
|
:return: a new AABB object that is the result of merging this AABB with the other AABB.
|
1226
1275
|
"""
|
1227
1276
|
...
|
1277
|
+
|
1278
|
+
def indices_contained(self, points: NDArray[float]) -> NDArray[int]:
|
1279
|
+
"""
|
1280
|
+
Get the indices of the points that are contained within the AABB.
|
1281
|
+
:param points: a numpy array of shape (N, 2) containing the points to check.
|
1282
|
+
:return: a numpy array of indices of the points that are contained within the AABB.
|
1283
|
+
"""
|
1284
|
+
...
|
1285
|
+
|
1286
|
+
def contains_point(self, point: Point2) -> bool:
|
1287
|
+
"""
|
1288
|
+
Check if a point is contained within the AABB.
|
1289
|
+
:param point: the point to check.
|
1290
|
+
:return: True if the point is contained within the AABB, False otherwise.
|
1291
|
+
"""
|
1292
|
+
...
|
engeom/geom3.pyi
CHANGED
@@ -1751,6 +1751,26 @@ class Aabb3:
|
|
1751
1751
|
"""
|
1752
1752
|
...
|
1753
1753
|
|
1754
|
+
def indices_contained(self, points: NDArray[float]) -> NDArray[int]:
|
1755
|
+
"""
|
1756
|
+
Get the indices of the points that are contained within this AABB. The points should be a numpy array of shape
|
1757
|
+
(n, 3) where n is the number of points.
|
1758
|
+
|
1759
|
+
:param points: a numpy array of shape (n, 3) containing the points to check.
|
1760
|
+
:return: a numpy array of shape (m,) containing the indices of the points that are contained within this AABB,
|
1761
|
+
where m is the number of points contained within the AABB.
|
1762
|
+
"""
|
1763
|
+
...
|
1764
|
+
|
1765
|
+
def contains_point(self, point: Point3) -> bool:
|
1766
|
+
"""
|
1767
|
+
Check if a point is contained within this AABB.
|
1768
|
+
|
1769
|
+
:param point: the point to check.
|
1770
|
+
:return: True if the point is contained within the AABB, False otherwise.
|
1771
|
+
"""
|
1772
|
+
...
|
1773
|
+
|
1754
1774
|
|
1755
1775
|
class RayBundle3:
|
1756
1776
|
"""
|
@@ -1,25 +1,25 @@
|
|
1
|
-
engeom-0.2.
|
2
|
-
engeom-0.2.
|
3
|
-
engeom/
|
4
|
-
engeom/geom2.pyi,sha256=Gg6Dw9yKOjc_1-sJiBPWDbGgQH5P5g6Ac80XRS-ziSQ,48330
|
5
|
-
engeom/geom3.pyi,sha256=p6wiyIRMNFVBe6zgNGkDVqC1JRysq5OwwO654BPWoOI,76829
|
6
|
-
engeom/geom3/__init__.py,sha256=l8B0iDhJ4YiRbslJLN791XWai2DWrpmZptnzIETMS9g,370
|
7
|
-
engeom/geom2/__init__.py,sha256=JFpiLyROUh6vyakG-7JDSlCMCn4QB2MQ8bz3uVCaAIk,373
|
8
|
-
engeom/plot.py,sha256=LTqqO-h1EJL6wanM0hB79s9ohWwaCIijMOHVplY3vmc,1079
|
9
|
-
engeom/metrology/__init__.py,sha256=XvEhG8uDm1olWwZHDDrQv9LFP5zXhbsGx27PqRq8WE0,304
|
10
|
-
engeom/airfoil.pyi,sha256=VTeJBoS9Iij7p-92R7jCqzPasHmvAUocyzc6BSx7mvM,23557
|
11
|
-
engeom/_plot/pyvista.py,sha256=PylGVOa9RtRIYPyHLy969eyW8yIgAk-URVZT0R7WoQ8,12980
|
12
|
-
engeom/_plot/matplotlib.py,sha256=rFL1CPNMUqGO-fwD45V3-shektBMeNq5U15Zxp96hYw,14824
|
1
|
+
engeom-0.2.13.dist-info/METADATA,sha256=AoVEX7woDJ6gLnN23Izt7SaaJELLRu0Fo56gCpNRcqg,495
|
2
|
+
engeom-0.2.13.dist-info/WHEEL,sha256=MatQr8gCUwamU6XQoLbQL47pvFlKZET0ThYE5zAC_Uo,102
|
3
|
+
engeom/__init__.py,sha256=QN5uETqrN442w41foyrcCPV_x6NP-mrxkPJhdvdey1g,109
|
13
4
|
engeom/_plot/__init__.py,sha256=F_KviZtxzZGwfEjjn8Ep46N4UVl8VpFJWBzbBUE_J7A,30
|
14
5
|
engeom/_plot/common.py,sha256=Py78ufN3yi59hPwv21SoGcqyZUJS-_PmK8tlAKgSG7Q,517
|
6
|
+
engeom/_plot/matplotlib.py,sha256=ahLfgE3QHUFcNig6cHkFu9mwSwfMbDcNqkZmGaBh4Zk,15267
|
7
|
+
engeom/_plot/pyvista.py,sha256=PylGVOa9RtRIYPyHLy969eyW8yIgAk-URVZT0R7WoQ8,12980
|
8
|
+
engeom/airfoil.pyi,sha256=SivSrUo3LZSVgXwIFJtgUUejhPh71y8rekzBwaX6exI,24165
|
15
9
|
engeom/airfoil/__init__.py,sha256=gpS9pVepUu90XJ-ePndNupbUMKI0RGxNXPxD9x0iVHY,274
|
16
|
-
engeom/
|
17
|
-
engeom/__init__.py,sha256=QN5uETqrN442w41foyrcCPV_x6NP-mrxkPJhdvdey1g,109
|
10
|
+
engeom/align.pyi,sha256=QCSKrTLkCoaIubcrPU9J-wDZe1lRP0GbPgWZmonXjo0,997
|
18
11
|
engeom/align/__init__.py,sha256=SEeMqeqLKqJC73Mg8GwPwd9NwWnl-dcCqJ4rPdh8yyc,196
|
19
|
-
engeom/
|
12
|
+
engeom/engeom.abi3.so,sha256=KEgN7xBdNFhhs8W3THAcIjnJqO5XGMDFDb-p3SK8B5I,4094736
|
20
13
|
engeom/engeom.pyi,sha256=BtUBtYZ_MX8Xk2x_FyzVxRXjJQIazQ1xscbCLO_Y3HA,1516
|
21
|
-
engeom/
|
14
|
+
engeom/geom2.pyi,sha256=oUSner8BEJzJLv82POfOGyjAESw-McZzPq51o9VbdYg,51601
|
15
|
+
engeom/geom2/__init__.py,sha256=JFpiLyROUh6vyakG-7JDSlCMCn4QB2MQ8bz3uVCaAIk,373
|
16
|
+
engeom/geom3.pyi,sha256=KPWlcAeIZ_CQyuWh-3SFcQerag0D-gzqJS1fPvGWj40,77669
|
17
|
+
engeom/geom3/__init__.py,sha256=l8B0iDhJ4YiRbslJLN791XWai2DWrpmZptnzIETMS9g,370
|
22
18
|
engeom/metrology.pyi,sha256=9I5un86VB_2gmQBrVYhX8JzILTUADMLB9Em8ttJxrWg,4044
|
23
|
-
engeom/
|
24
|
-
engeom/
|
25
|
-
engeom
|
19
|
+
engeom/metrology/__init__.py,sha256=XvEhG8uDm1olWwZHDDrQv9LFP5zXhbsGx27PqRq8WE0,304
|
20
|
+
engeom/plot.py,sha256=LTqqO-h1EJL6wanM0hB79s9ohWwaCIijMOHVplY3vmc,1079
|
21
|
+
engeom/raster3.pyi,sha256=sBXXYXcDBiDU_OFDQiwa7Q3GcwSiUc4CLy6nJ1MwFqM,790
|
22
|
+
engeom/raster3/__init__.py,sha256=iaayLrvco-ZMZPyeK47ox7rYne_51DNb2T2Q0iNNeKE,289
|
23
|
+
engeom/sensor.pyi,sha256=a9y62FqhG-CFFHnJiC03PqBpFtxtfkH0zoDkk9LXWnU,1399
|
24
|
+
engeom/sensor/__init__.py,sha256=p-1osXrlBX_hXSSlvySszSimMv_4_n273joBcTFx2V0,179
|
25
|
+
engeom-0.2.13.dist-info/RECORD,,
|