deep-high-resolution-net.pytorch icon indicating copy to clipboard operation
deep-high-resolution-net.pytorch copied to clipboard

why need norm = np.ones((pred.shape[0], 2)) * np.array([h, w]) / 10 in accuracy

Open azuryl opened this issue 3 years ago • 1 comments

in

UDP-Pose/deep-high-resolution-net.pytorch/lib/core/evaluate.py

Line 55 in d742edd norm = np.ones((pred.shape[0], 2)) * np.array([h, w]) / 10

norm = np.ones((pred.shape[0], 2)) * np.array([h, w]) / 10 I did know why use norm and why need /10 and in

https://github.com/leoxiaobin/deep-high-resolution-net.pytorch/blob/ba50a82dce412df97f088c572d86d7977753bf74/lib/core/evaluate.py#L16 def calc_dists(preds, target, normalize):

and why normed_preds = preds[n, c, :] / normalize[n] normed_targets = target[n, c, :] / normalize[n]

when I print the output preds[n, c, :] and target[n, c, :] are very different when target[n, c, 0] > 1 and target[n, c, 1] > 1:such as[ 27,30] and [4,8]

Thank you

azuryl avatar Jan 06 '21 06:01 azuryl

I have the same question, have you found the solution, sir?

ShihuaiXu avatar Aug 23 '21 07:08 ShihuaiXu