DECA icon indicating copy to clipboard operation
DECA copied to clipboard

Calculate median distance

Open asw91666 opened this issue 1 year ago • 0 comments

Hello!

I have a question regarding the method of calculating the median distance. When computing the median distance, do you perform the np.median() operation along both the vertices axis and the batch axis?

For example, let's say we have pred_vertices with the shape [100,5023,3], and we've identified the corresponding ground truth vertices, which is in the shape of [100,5023,3].

then I can get median distance through this code:

l2_norm = np.sqrt(np.sum((pred_vertices - gt_vertices) ** 2, axis=2)) # [B,5023]
median_distance = np.median(np.median(l2_norm, axis=1), axis=0)

Is that right?

asw91666 avatar Nov 07 '23 06:11 asw91666