blueprints.tube module#
- class blueprints.tube.BaseTube[source]#
Bases:
TubeTypeBaseTube is a base class for sites and geoms that can be defined by two points forming a tube like object.
- classmethod from_points(head, tail, radius=1, **kwargs)[source]#
Constructs a Tube like object from point head to point tail. Euler angles are set such that the resulting orientation has pitch and yaw but no roll. Therefore the floors horizon is always parallel to the orientation.
- Parameters:
head (
np.ndarray | list[int | float]) – Descriptiontail (
np.ndarray | list[int | float]) – Descriptionradius (
int | float, optional) – Description**kwargs – Description
- Returns:
Description
- Return type:
blue.Thing
- property head: ndarray#
Returns the head position of the tube like object. The positions are derived even if the object was not constructed with the from points method.
- Returns:
The head position.
- Return type:
np.ndarray
- property tail: ndarray#
Returns the tail position of the tube like object. The positions are derived even if the object was not constructed with the from points method.
- Returns:
The tail position.
- Return type:
np.ndarray