Hi, I am recently to reproduce the code.
And in the 'read_data_from_surface.py'
I find the codes:
# Compute the principal curvature components for the shape index.
mesh.add_attribute("vertex_mean_curvature")
H = mesh.get_attribute("vertex_mean_curvature")
mesh.add_attribute("vertex_gaussian_curvature")
K = mesh.get_attribute("vertex_gaussian_curvature")
elem = np.square(H) - K
# In some cases this equation is less than zero, likely due to the method that computes the mean and gaussian curvature.
# set to an epsilon.
elem[elem<0] = 1e-8
k1 = H + np.sqrt(elem)
k2 = H - np.sqrt(elem)
# Compute the shape index
si = (k1+k2)/(k1-k2)
si = np.arctan(si)*(2/np.pi)
Actually, I don't know how to get the H and K.
In these codes , I mean it just give an attribute to the mesh but there is no value for the attribute.
Do I miss something else?
Hi, I am recently to reproduce the code. And in the 'read_data_from_surface.py' I find the codes:
Actually, I don't know how to get the H and K. In these codes , I mean it just give an attribute to the mesh but there is no value for the attribute. Do I miss something else?