I am reading this paper on how yolo defines loss function. https://arxiv.org/abs/1506.02640

I did research on other posts, but these posts did not seem to answer my confusion: (How to calculate the class probability of a grid cell in YOLO object detection algorithm? & Yolo Loss function explanation)

Sum-squared error also equally weights errors in large boxes and small boxes. Our error metric should reflect that small deviations in large boxes matter less than in small boxes. To partially address this we predict the square root of the bounding box width and height instead of the width and height directly.

enter image description here

I could not make myself clear why applying square root could help resolve the case Sum-squared error also equally weights errors in large boxes and small boxes and give me any intuitions if possible!

Thanks so much!


The intuition or the goal is that regression errors relative to their respective bounding box size should matter roughly equally. E.g. a 5px deviation on a 500px wide box should have less of an effect on the loss as a 5px deviation in a 20px wide box. The square root downscales high values while less affecting low values of width and height.

The normal sum of squared errors will just punish the deviation independent of the size of the box.

| cite | improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.