GpuDelegate class

Metal Delegate for iOS and macOS

Implemented types
Annotations
  • @Deprecated('Manual hardware-acceleration delegates are superseded by LiteRT Next. Use ' 'CompiledModel.fromFile / CompiledModel.fromBuffer with ' 'accelerators: {Accelerator.gpu, Accelerator.cpu}, or ' 'CompiledModel.fromBufferWithGpuFallback. The Interpreter API itself remains ' 'supported for CPU inference. ' 'See https://developers.google.com/edge/litert/next/get_started; planned ' 'for removal in flutter_litert 4.0.0.')

Constructors

GpuDelegate({GpuDelegateOptions? options})
Creates a Metal GPU delegate with optional options.
factory

Properties

base Pointer<TfLiteDelegate>
Get pointer to TfLiteDelegate
no setteroverride
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

bindMetalBufferToTensor(int tensorIndex, int metalBuffer) bool
Binds a Metal buffer to an input or output tensor.
delete() → void
Releases native Metal delegate resources.
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