ultralytics 8.0.14
Hydra removal fixes and cleanup (#542)
Co-authored-by: ayush chaurasia <ayush.chaurarsia@gmail.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Kamlesh Kumar <patelkamleshpatel364@gmail.com>
This commit is contained in:
@ -10,14 +10,15 @@ from ultralytics.yolo.v8.detect.predict import DetectionPredictor
|
||||
|
||||
class SegmentationPredictor(DetectionPredictor):
|
||||
|
||||
def postprocess(self, preds, img, orig_img):
|
||||
def postprocess(self, preds, img, orig_img, classes=None):
|
||||
# TODO: filter by classes
|
||||
p = ops.non_max_suppression(preds[0],
|
||||
self.args.conf,
|
||||
self.args.iou,
|
||||
agnostic=self.args.agnostic_nms,
|
||||
max_det=self.args.max_det,
|
||||
nm=32)
|
||||
nm=32,
|
||||
classes=self.args.classes)
|
||||
results = []
|
||||
proto = preds[1][-1]
|
||||
for i, pred in enumerate(p):
|
||||
|
Reference in New Issue
Block a user