Class KeypointsModel
- Namespace
- OpenCvSharp.Dnn
- Assembly
- OpenCvSharp.dll
This class represents high-level API for keypoints models. KeypointsModel allows to set params for preprocessing input image. KeypointsModel creates net from file with trained weights and config, sets preprocessing input, runs forward pass and returns the x and y coordinates of each detected keypoint.
public class KeypointsModel : Model, IDisposable
- Inheritance
-
KeypointsModel
- Implements
- Inherited Members
Constructors
KeypointsModel(Net)
Create model from deep learning network.
public KeypointsModel(Net network)
Parameters
networkNetNet object.
KeypointsModel(string, string?)
Create keypoints model from network represented in one of the supported formats. An order of @p model and @p config arguments does not matter.
public KeypointsModel(string model, string? config = null)
Parameters
modelstringBinary file contains trained weights.
configstringText file contains network configuration.
Methods
Estimate(InputArray, float)
Given the @p input frame, create input blob, run net.
public Point2f[] Estimate(InputArray frame, float thresh = 0.5)
Parameters
frameInputArrayThe input image.
threshfloatminimum confidence threshold to select a keypoint.
Returns
- Point2f[]
a vector holding the x and y coordinates of each detected keypoint.