irtk.transform.rotate2D¶
- irtk.transform.rotate2D(angle: float, use_degree: bool = True) torch.Tensor ¶
Create a 2D rotation matrix.
- Parameters:
angle (float) – The angle of rotation.
use_degree (bool, optional) – If True, the angle is in degrees. If False, it’s in radians. Defaults to True.
- Returns:
A 3x3 2D rotation matrix.
- Return type:
torch.Tensor