Dynamic State

class py123d.datatypes.DynamicStateSE2[source]

The dynamic state of a vehicle in SE2 (2D plane).

Public Data Attributes:

velocity_2d

2D velocity vector in the ego frame.

acceleration_2d

2D acceleration vector in the ego frame.

angular_velocity

Angular velocity around the Z axis (yaw).

array

NumPy array representation of shape (5,), indexed by DynamicStateSE2Index.

Inherited from ArrayMixin

array

The array representation of the geometric entity.

shape

Return the shape of the array.

Public Methods:

from_array(array[, copy])

Create a DynamicStateSE2 from NumPy array of shape (5,), indexed by DynamicStateSE2Index.

Inherited from ArrayMixin

from_array(array[, copy])

Create an instance from a NumPy array.

from_list(values)

Create an instance from a list of values.

tolist()

Convert the array to a Python list.

to_list()

Convert the array to a Python list.

copy()

Return a copy of the object with a copied array.


copy()

Return a copy of the object with a copied array.

Return type:

ArrayMixin

classmethod from_list(values)

Create an instance from a list of values.

Return type:

Self

Parameters:

values (list)

property shape: tuple

Return the shape of the array.

to_list()

Convert the array to a Python list.

Return type:

list

tolist()

Convert the array to a Python list.

Return type:

list

__init__(velocity, acceleration, angular_velocity)[source]

Initialize a DynamicStateSE2 instance.

Parameters:
  • velocity (Vector2D) – 2D velocity vector in the ego frame.

  • acceleration (Vector2D) – 2D acceleration vector in the ego frame.

  • angular_velocity (float) – Angular velocity around the Z axis (yaw).

classmethod from_array(array, copy=True)[source]

Create a DynamicStateSE2 from NumPy array of shape (5,), indexed by DynamicStateSE2Index.

Parameters:
  • array (ndarray[tuple[Any, ...], dtype[float64]]) – The array containing the dynamic state information.

  • copy (bool) – Whether to copy the array data.

Return type:

DynamicStateSE2

Returns:

A DynamicStateSE2 instance.

property velocity_2d: Vector2D

2D velocity vector in the ego frame.

property acceleration_2d: Vector2D

2D acceleration vector in the ego frame.

property angular_velocity: float

Angular velocity around the Z axis (yaw).

property array: ndarray[tuple[Any, ...], dtype[float64]]

NumPy array representation of shape (5,), indexed by DynamicStateSE2Index.

class py123d.datatypes.DynamicStateSE3[source]

The dynamic state of a vehicle in SE3 (3D space). All components are in the ego frame.

Public Data Attributes:

velocity_3d

3D velocity vector in the ego frame.

velocity_2d

2D velocity vector in the ego frame.

acceleration_3d

3D acceleration vector in the ego frame.

acceleration_2d

2D acceleration vector in the ego frame.

angular_velocity

3D angular velocity vector in the ego frame.

array

NumPy array representation of shape (9,), indexed by DynamicStateSE3Index.

dynamic_state_se2

The DynamicStateSE2 projection of this SE3 dynamic state.

Inherited from ArrayMixin

array

The array representation of the geometric entity.

shape

Return the shape of the array.

Public Methods:

from_array(array[, copy])

Create a DynamicStateSE3 from NumPy array of shape (9,), indexed by DynamicStateSE3Index.

Inherited from ArrayMixin

from_array(array[, copy])

Create an instance from a NumPy array.

from_list(values)

Create an instance from a list of values.

tolist()

Convert the array to a Python list.

to_list()

Convert the array to a Python list.

copy()

Return a copy of the object with a copied array.


__init__(velocity, acceleration, angular_velocity)[source]

Initialize a DynamicStateSE3 instance.

Parameters:
  • velocity (Vector3D) – 3D velocity vector in the ego frame.

  • acceleration (Vector3D) – 3D acceleration vector in the ego frame.

  • angular_velocity (Vector3D) – 3D angular velocity vector in the ego frame.

classmethod from_array(array, copy=True)[source]

Create a DynamicStateSE3 from NumPy array of shape (9,), indexed by DynamicStateSE3Index.

Parameters:
  • array (ndarray[tuple[Any, ...], dtype[float64]]) – The array containing the dynamic state information.

  • copy (bool) – Whether to copy the array data.

Return type:

DynamicStateSE3

Returns:

A DynamicStateSE3 instance.

property velocity_3d: Vector3D

3D velocity vector in the ego frame.

property velocity_2d: Vector2D

2D velocity vector in the ego frame.

property acceleration_3d: Vector3D

3D acceleration vector in the ego frame.

property acceleration_2d: Vector2D

2D acceleration vector in the ego frame.

property angular_velocity: Vector3D

3D angular velocity vector in the ego frame.

property array: ndarray[tuple[Any, ...], dtype[float64]]

NumPy array representation of shape (9,), indexed by DynamicStateSE3Index.

property dynamic_state_se2: DynamicStateSE2

The DynamicStateSE2 projection of this SE3 dynamic state.

copy()

Return a copy of the object with a copied array.

Return type:

ArrayMixin

classmethod from_list(values)

Create an instance from a list of values.

Return type:

Self

Parameters:

values (list)

property shape: tuple

Return the shape of the array.

to_list()

Convert the array to a Python list.

Return type:

list

tolist()

Convert the array to a Python list.

Return type:

list