hanson-young / nniefacelib

nniefacelib是一个在海思35xx系列芯片上运行的人脸算法库
BSD 2-Clause "Simplified" License
556 stars 180 forks source link

RetinaFace计算得到的矩形框位置错误 #2

Closed BenjaminLiu1003 closed 4 years ago

BenjaminLiu1003 commented 4 years ago

nnie_face_api.c中的结算人脸矩形框位置错误,应该以15为间隔 ` for(int i = 0; i < results->len; i ++) { anchor_t res = (anchor_t )list_at(results, i)->val; printf("result rect: %d, %f, %f, %f, %f\n", i ,res.finalbox.x1, res.finalbox.y1, res.finalbox.x2, res.finalbox.y2); as32ResultDet[i5 + 0] = res.finalbox.x1; as32ResultDet[i5 + 1] = res.finalbox.x1; as32ResultDet[i5 + 2] = res.finalbox.y1; as32ResultDet[i5 + 3] = res.finalbox.x2; as32ResultDet[i*5 + 4] = res.finalbox.y2;

    for (int j = 0; j < LANDMARKS; ++j) {
        as32ResultDet[i*5 + j * 2 + 5] = res.pts[j].x;
        as32ResultDet[i*5 + j * 2 + 6] = res.pts[j].y;
        printf("result lds: %d, %f, %f\n", j + 1 ,res.pts[j].x, res.pts[j].y);
    }
}

`

hanson-young commented 4 years ago

OK,这是个错误,在调试的时候主要关注了results里面的数据,没检查这个,感谢指正