DeepForest icon indicating copy to clipboard operation
DeepForest copied to clipboard

Add explanation to docs on non-max suppression.

Open bw4sz opened this issue 2 years ago • 2 comments

how its used in predict_tile, how to change the iou_threshold, and what that means with images.

bw4sz avatar Feb 18 '23 15:02 bw4sz

Hi, I stumbled across this while scratching my head because I wanted to filter predictions by their confidence score. I am wondering how the API works. I used thresh to filter for confidence scores to realize it is done by setting the model property directly
predict_tile has sigma, thresh and iou_threshold as parameters, but sigma and thresh are not used. In that function nms_thresh which is set by the config value. But isn't iou_threshold the same as nms_thresh ( here in predict._predict_image it is and uses the config value for nms. So nms is applied twice?

predict_image uses nms_threshold from the config too.

scrore_thresh from the config seems to have the wrong comment after all, doesn't it relate to nms_thresh?

From how I understand it nms_threshold and score_threshold should be both settable on inference either by config, parameter or model property. I haven't found where the default score threshold comes from but setting it from within the predict functions works.

All the best

cwinkelmann avatar Sep 02 '24 18:09 cwinkelmann

Thanks for the post, I'll have a look this week, this has been a weak point in the model properties, in fact something we hope to all together get rid of in 2.0

bw4sz avatar Sep 11 '24 16:09 bw4sz