core_ml 0.1.0
core_ml: ^0.1.0 copied to clipboard
Flutter bindings for Apple's Core ML framework: compile and load models, inspect their inputs and outputs, and run single, batch and stateful predictions.
import 'package:flutter/material.dart';
import 'demos.dart';
void main() => runApp(const CoreMLExampleApp());
/// Demonstrates the core_ml plugin with five tiny bundled models.
class CoreMLExampleApp extends StatelessWidget {
/// Creates the app.
const CoreMLExampleApp({super.key});
@override
Widget build(BuildContext context) {
ThemeData theme(Brightness brightness) => ThemeData(
colorScheme: ColorScheme.fromSeed(
seedColor: Colors.teal,
brightness: brightness,
),
);
return MaterialApp(
title: 'core_ml',
theme: theme(Brightness.light),
darkTheme: theme(Brightness.dark),
home: const HomePage(),
);
}
}