SamsungLabs / NeuralHaircut

Neural Haircut: Prior-Guided Strand-Based Hair Reconstruction. ICCV 2023
Other
538 stars 48 forks source link

A problem about strand curvatures. #29

Open XiaokunSun opened 1 month ago

XiaokunSun commented 1 month ago

Hi! I noticed that you mentioned in neuralhaircut that the incorporation of curvature loss can better model curly strands. How do you define curvature? My understanding is that curvature represents the rate of change of orientation, and the implementation code is similar to:

# strand.shape = [N, 100, 3]
strand_ori = strand[:, 1:, :] - strand[:, :-1, :]
strand_ori= strand_ori/ (torch.norm(strand_ori, dim=-1)[:, :, None] + 1e-20)
strand_cur= strand_ori[:, 1:, :] - strand_ori[:, :-1, :]

Do I understand correctly? Looking forward to your reply