Skip to content

ArgumentError (Invalid argument(s): Unable to create interpreter.) #284

@YashOEncureIT

Description

@YashOEncureIT

I am facing this issue with plugin , please check files and everything .

void _loadModel() async {
// Enable delegates
final options = InterpreterOptions();

if (Platform.isAndroid) {
  options.addDelegate(XNNPackDelegate());
}

// doesn't work on emulator
// if (Platform.isAndroid) {
//   options.addDelegate(GpuDelegateV2());
// }

if (Platform.isIOS) {
  options.addDelegate(GpuDelegate());
}

// Creating the interpreter using Interpreter.fromAsset
_interpreter = await Interpreter.fromAsset(
  'assets/models/model_float16.tflite',
  options: options,
);

debugPrint('Interpreter loaded successfully');

}

Assets ->> assets/models/model_float16.tflite

please let me know if I miss anything with configuration .

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions