Add ops.py comment for nm = number of masks (#13353)
Co-authored-by: UltralyticsAssistant <web@ultralytics.com> Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
This commit is contained in:
parent
993ba7a20b
commit
4dac70cad1
1 changed files with 1 additions and 1 deletions
|
|
@ -215,7 +215,7 @@ def non_max_suppression(
|
|||
|
||||
bs = prediction.shape[0] # batch size
|
||||
nc = nc or (prediction.shape[1] - 4) # number of classes
|
||||
nm = prediction.shape[1] - nc - 4
|
||||
nm = prediction.shape[1] - nc - 4 # number of masks
|
||||
mi = 4 + nc # mask start index
|
||||
xc = prediction[:, 4:mi].amax(1) > conf_thres # candidates
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue