predict method

Future<SegmentationResult> predict(
  1. Uint8List originalImageBytes
)

Implementation

Future<SegmentationResult> predict(Uint8List originalImageBytes) async {
  final inputTensor = await PreProcessing.toTensorData(
    originalImageBytes,
    targetWidth: inputWidth,
    targetHeight: inputHeight,
  );
  final outputs = await forward(inputTensor, originalImageBytes);
  return getResult(outputs, originalImageBytes);
}