Skip to main content
Version: 0.10.0

Type Alias: KeypointDetector<F, L>

KeypointDetector<F, L> = object

Defined in: extensions/cv/tasks/keypointDetection.ts:104

Keypoint and pose detection task runner.

Type Parameters

F

F extends BoxFormat

The bounding box format.

L

L extends PropertyKey

The landmark labels type.

Properties

detectKeypoints()

readonly detectKeypoints: (input, options?) => Promise<KeypointDetection<F, L>[]>

Defined in: extensions/cv/tasks/keypointDetection.ts:120

Performs asynchronous keypoint and bounding box detection on the given input image.

Parameters

input

ImageBuffer

The input image buffer.

options?

DetectKeypointsOptions

Configuration options for keypoint detection. See DetectKeypointsOptions.

Returns

Promise<KeypointDetection<F, L>[]>

A promise resolving to the list of keypoint detections.

Throws

With code RESOURCE_BUSY if the model is in use, or RESOURCE_DISPOSED if disposed.


detectKeypointsWorklet()

readonly detectKeypointsWorklet: (input, options?) => KeypointDetection<F, L>[]

Defined in: extensions/cv/tasks/keypointDetection.ts:129

Synchronous version of detectKeypoints to be executed directly on the caller or worklet thread.

Parameters

input

ImageBuffer

options?

DetectKeypointsOptions

Returns

KeypointDetection<F, L>[]


dispose()

readonly dispose: () => void

Defined in: extensions/cv/tasks/keypointDetection.ts:108

Releases all allocated native resources.

Returns

void