GPU Delegation fails with Attempting to use a delegate that only supports static-sized tensors with a graph that has dynamic-sized tensors (tensor#1035 is a dynamic-sized tensor).

#1
by apcameron - opened

Please can you create some tflite models that have static-sized tensors so we can use GPU Delegation and not get the error below.
W Attempting to use a delegate that only supports static-sized tensors with a graph that has dynamic-sized tensors (tensor#1035 is a dynamic-sized tensor).
2026-03-04 11:43:18.349 19600-20216 WhisperModelManager za.alt.andy.translator E Failed to initialize interpreter: Internal error: Error applying delegate: (Fix with AI)
java.lang.IllegalArgumentException: Internal error: Error applying delegate:
at org.tensorflow.lite.NativeInterpreterWrapper.createInterpreter(Native Method)
at org.tensorflow.lite.NativeInterpreterWrapper.init(NativeInterpreterWrapper.java:110)
at org.tensorflow.lite.NativeInterpreterWrapper.(NativeInterpreterWrapper.java:73)
at org.tensorflow.lite.NativeInterpreterWrapperExperimental.(NativeInterpreterWrapperExperimental.java:36)
at org.tensorflow.lite.Interpreter.(Interpreter.java:232)
at za.alt.andy.translator.speech.WhisperModelManager.initializeInterpreter(WhisperModelManager.kt:343)
at za.alt.andy.translator.speech.WhisperModelManager.access$initializeInterpreter(WhisperModelManager.kt:44)
at za.alt.andy.translator.speech.WhisperModelManager$loadModel$1.invokeSuspend(WhisperModelManager.kt:220)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:101)
at kotlinx.coroutines.internal.LimitedDispatcher$Worker.run(LimitedDispatcher.kt:113)
at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:89)
at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:589)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:823)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:720)

To my knowledge there are control flow ops which make the model "dynamic".
And this is not supported by the GPU delegates.

Sign up or log in to comment