You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Inner products of two vectors belonging to the tangent space of SE(2) return different values when computation is performed using point_type="vector" and point_type="matrix".
The values are significantly different, ie floating point operations may not be causing it.
Steps/Code to Reproduce
Running the script below returns False:
import numpy as np
from geomstats.geometry.special_euclidean import SpecialEuclidean
GROUP_MAT = SpecialEuclidean(n=2, point_type="matrix")
GROUP_VECT = SpecialEuclidean(n=2, point_type="vector")
# vector form
point_vec = GROUP_VECT.random_point()
v1_vect = np.random.rand(3) # any random length 3 vector belongs to SE(2)
v2_vect = np.random.rand(3)
ip_vect = GROUP_VECT.metric.inner_product(tangent_vec_a=v1_vect, tangent_vec_b=v2_vect, base_point=point_vec)
# matrix form
point_mat = GROUP_VECT.matrix_from_vector(point_vec)
# v1_mat, v2_mat should be in the tangent space
v1_mat = GROUP_VECT.matrix_from_vector(v1_vect)
v2_mat = GROUP_VECT.matrix_from_vector(v2_vect)
ip_mat = GROUP_MAT.metric.inner_product(tangent_vec_a=v1_mat, tangent_vec_b=v2_mat, base_point=point_mat)
print(np.allclose(ip_vect, ip_mat))
Expected Behaviour
Inner products should be about the same: np.allclose(ip_vect, ip_mat)=True
Actual Behaviour
For example
Vector form:
<v1, v2> = 0.5463887341252732
Matrix form:
<v1, v2> = 3.2790017553516457
Your environment
Geomstats: v2.5.0
Model Name: MacBook Pro
Processor Name: ARM64
The text was updated successfully, but these errors were encountered:
Describe the bug
Inner products of two vectors belonging to the tangent space of SE(2) return different values when computation is performed using
point_type="vector"
andpoint_type="matrix"
.The values are significantly different, ie floating point operations may not be causing it.
Steps/Code to Reproduce
Running the script below returns
False
:Expected Behaviour
Inner products should be about the same:
np.allclose(ip_vect, ip_mat)=True
Actual Behaviour
For example
Vector form:
<v1, v2> = 0.5463887341252732
Matrix form:
<v1, v2> = 3.2790017553516457
Your environment
The text was updated successfully, but these errors were encountered: