def convert_points_to_homogeneous(points: torch.Tensor) -> torch.Tensor:
    'Function that converts points from Euclidean to homogeneous space.\n\n    Examples::\n\n        >>> input = torch.rand(2, 4, 3)  # BxNx3\n        >>> output = convert_points_to_homogeneous(input)  # BxNx4\n    '
    if (not isinstance(points, torch.Tensor)):
        raise TypeError('Input type is not a torch.Tensor. Got {}'.format(type(points)))
    if (len(points.shape) < 2):
        raise ValueError('Input must be at least a 2D tensor. Got {}'.format(points.shape))
    return torch.nn.functional.pad(points, [0, 1], 'constant', 1.0)
Function that converts points from Euclidean to homogeneous space.

Examples::

    >>> input = torch.rand(2, 4, 3)  # BxNx3
    >>> output = convert_points_to_homogeneous(input)  # BxNx4
def convert_points_to_homogeneous(points: torch.Tensor) -> torch.Tensor:
    'Function that converts points from Euclidean to homogeneous space.\n\n    Examples::\n\n        >>> input = torch.rand(2, 4, 3)  # BxNx3\n        >>> output = convert_points_to_homogeneous(input)  # BxNx4\n    '
    if (not isinstance(points, torch.Tensor)):
        raise TypeError('Input type is not a torch.Tensor. Got {}'.format(type(points)))
    if (len(points.shape) < 2):
        raise ValueError('Input must be at least a 2D tensor. Got {}'.format(points.shape))
    return torch.nn.functional.pad(points, [0, 1], 'constant', 1.0)