detectFromFilepath method

Future<List<Hand>> detectFromFilepath(
  1. String path
)

Detects hands in an image file at path.

Convenience wrapper that reads the file and calls detect. Not available on Flutter Web (uses dart:io).

Throws StateError if initialize has not been called successfully. Throws FileSystemException if the file cannot be read.

Implementation

Future<List<Hand>> detectFromFilepath(String path) async {
  final bytes = await File(path).readAsBytes();
  return detect(bytes);
}