paralleldomain.model.annotation.polyline_3d¶
- class Line3D(start, end, class_id, directed=False, instance_id=-1, attributes=<factory>)¶
Represents a 3D Line.
- Parameters:
start (
Point3DBaseGeometry
[TypeVar
(T
,int
,float
)]) –Line3D.start
end (
Point3DBaseGeometry
[TypeVar
(T
,int
,float
)]) –Line3D.end
class_id (
int
) –Line3D.class_id
instance_id (
int
) –Line3D.instance_id
attributes (
Dict
[str
,Any
]) –Line3D.attributes
directed (
bool
) –Line3D.directed
- start¶
the 3D start point of the line in image coordinates
- end¶
the 3D end point of the line in image coordinates
- directed¶
whether the line is directed from start to end (if False the line is bi-directional)
- class_id¶
Class ID of the line. Can be used to lookup more details in
ClassMap
.
- instance_id¶
Instance ID of annotated object. Can be used to cross-reference with other instance annotation types, e.g.,
InstanceSegmentation3D
orInstanceSegmentation3D
. If unknown defaults to -1.
- attributes¶
Dictionary of arbitrary object attributes.
- to_numpy()¶
Returns the start and end coordinates as a numpy array with shape (2 x 3).
- property direction: Point3DBaseGeometry[T]¶
Returns the directional vector of the line.
- class Polyline3D(lines, class_id, instance_id=-1, attributes=<factory>)¶
A polyline made of a collection of 3D Lines
- Parameters:
lines (
List
[Line3DBaseGeometry
[TypeVar
(T
,int
,float
)]]) –Polyline3D.lines
class_id (
int
) –Polyline3D.class_id
instance_id (
int
) –Polyline3D.instance_id
attributes (
Dict
[str
,Any
]) –Polyline3D.attributes
- class_id¶
Class ID of the polyline. Can be used to lookup more details in
ClassMap
.
- instance_id¶
Instance ID of annotated object. Can be used to cross-reference with other instance annotation types, e.g.,
InstanceSegmentation3D
orInstanceSegmentation3D
. If unknown defaults to -1.
- attributes¶
Dictionary of arbitrary object attributes.
- to_numpy()¶
Returns all ordered vertices as a numpy array of shape (N x 3).
- property length¶
Returns the length of the line.
- class Polylines3D(polylines)¶
Collection of 3D Polylines
- Parameters:
polylines (
List
[Polyline3D
]) –Polylines3D.polylines
- polylines¶
Ordered list of
Polyline3D
instances