Class DetectionModel
- Namespace
- OpenCvSharp.Dnn
- Assembly
- OpenCvSharp.dll
This class represents high-level API for object detection networks. DetectionModel allows to set params for preprocessing input image. DetectionModel creates net from file with trained weights and config, sets preprocessing input, runs forward pass and return result detections.
public class DetectionModel : Model, IDisposable
- Inheritance
-
DetectionModel
- Implements
- Inherited Members
Constructors
- DetectionModel(Net)
Create model from deep learning network.
- DetectionModel(string, string?)
Create detection model from network represented in one of the supported formats. An order of @p model and @p config arguments does not matter.
Methods
- Detect(InputArray, out int[], out float[], out Rect[], float, float)
Given the @p input frame, create input blob, run net and return result detections.
- GetNmsAcrossClasses()
Getter for nmsAcrossClasses. This variable defaults to false, such that when non max suppression is used during the detect() function, it will do so only per-class.
- SetNmsAcrossClasses(bool)
nmsAcrossClasses defaults to false, such that when non max suppression is used during the detect() function, it will do so per-class. This function allows you to toggle this behaviour.