Fix bug in bounding box regression loss.

This commit is contained in:
Davis King 2020-08-29 09:09:54 -04:00
parent c9809e067f
commit 0e721e5cae

View File

@ -1582,9 +1582,9 @@ namespace dlib
double dw = out_data[dets[i].tensor_offset_dw]; double dw = out_data[dets[i].tensor_offset_dw];
double dh = out_data[dets[i].tensor_offset_dh]; double dh = out_data[dets[i].tensor_offset_dh];
dpoint p = dcenter(dets[i].rect_bbr); dpoint p = dcenter(dets[i].rect);
double w = dets[i].rect_bbr.width()-1; double w = dets[i].rect.width()-1;
double h = dets[i].rect_bbr.height()-1; double h = dets[i].rect.height()-1;
drectangle truth_box = (*truth)[hittruth.second].rect; drectangle truth_box = (*truth)[hittruth.second].rect;
dpoint p_truth = dcenter(truth_box); dpoint p_truth = dcenter(truth_box);