EmbedderOptions class

Dart representation of MediaPipe's "EmbedderOptions" concept.

Embedder options shared across MediaPipe embedding tasks.

See also:

Inheritance
Mixed-in types

Constructors

EmbedderOptions({bool l2Normalize = false, bool quantize = false})
Dart representation of MediaPipe's "EmbedderOptions" concept.
const

Properties

hashCode int
The hash code for this object.
no setterinherited
l2Normalize bool
Whether to normalize the returned feature vector with L2 norm. Use this option only if the model does not already contain a native L2_NORMALIZATION TF Lite Op. In most cases, this is already the case and L2 norm is thus achieved through TF Lite inference.
final
props List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setterinherited
quantize bool
Whether the returned embedding should be quantized to bytes via scalar quantization. Embeddings are implicitly assumed to be unit-norm and therefore any dimension is guaranteed to have a value in -1.0, 1.0. Use the l2_normalize option if this is not the case.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stringify bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited

Methods

assignToStruct(EmbedderOptions struct) → void
Assigns all values to an existing struct. This method should be implemented by all InnerTaskOptions types to hydrate a struct, but not for the creation of that struct. Allocation and management of the actual structs are handled by TaskOptions.copyToNative on the wrapping options object.
override
freeStructFields(EmbedderOptions struct) → void
Deallocates any memory on the struct that would be missed simply by calling calloc.free(struct), which the parent who called this method will do after this method completes.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited