Flutter with MediaPipe ML models

Overview

Flutter Pipe

platform-ios



🌟 Flutter with MediaPipe Project 🌟




This is Flutter project using MediaPipe ML models.

Face Detection Face Mesh
Hand Detection Pose Estimation



Features

  • Detect face on real-time
  • Detect face landmark on real-time
  • Detect hand on real-time
  • Estimate body pose on real-time
  • Visualize inference results



MediaPipe

mediapipe
MediaPipe offers cross-platform, customizable ML solutions for live and streaming media.

mediapipe.dev

mediapipe code




App Store & Play Store

App Store

Play Store

You might also like...

Image caching system for flutter

image_cacheing image_cacheing is an image caching package. It is currently tested for Android applications. ImageCacheing widget takes url as a param.

May 31, 2021

A simple and easy flutter demo to crop image

flutter_image_crop A simple demo to crop image on flutter easily. A Chinese version of this document can be found here Flutter_image_crop Plugin will

Jul 8, 2021

A flutter package which makes it easy to track a series of images.

A flutter package which makes it easy to track a series of images.

A flutter package which makes it easy to track a series of images.

Oct 7, 2022

A flutter tool to generate beautiful code snippets in the form of an image.

A flutter tool to generate beautiful code snippets in the form of an image.

A flutter tool to generate beautiful code snippets in the form of an image.

Jan 18, 2022

A OpenGLES context canvas in flutter.

gl_canvas A OpenGLES context canvas in flutter. Usage // New a GLCanvas require a builder GLCanvas( builder: _builder, ) The builder should return

Oct 17, 2022

Simple and effective cross platform image saver for flutter, supported web and desktop

Simple and effective cross platform image saver for flutter, supported web and desktop

Oct 5, 2022

The iMateral Pro Icon pack available as Flutter Icons

The iMateral Pro Icon pack available as Flutter Icons

imaterial_pro_flutter This flutter package allows you to use the IMaterial Pro Icons. πŸŽ– Installation In the dependencies: section of your pubspec.yam

Oct 5, 2022

a package for flutter canvas paint dash line path easily.

a package for flutter canvas paint dash line path easily.

dash_painter a package for flutter canvas paint dash line path easily. 1. DashPainter 如何使用 DashPainter εͺ负责对 θ·―εΎ„ Path ηš„θ™šηΊΏεŒ–η»˜εˆΆοΌŒδΈζ‰Ώζ‹…η»„δ»ΆθŒθƒ½γ€‚ δΈ€θˆ¬η”¨εœ¨ζ‹₯ζœ‰ Canvas ε―Ήθ±‘ηš„ε›ž

Oct 9, 2022

Flutter package for Image Carousel It is an image carousel widget.

Flutter package for Image Carousel It is an image carousel widget.

Snapshot Carousel Flutter package for Image Carousel It is an image carousel widget. Supported platforms Flutter Android Flutter iOS Flutter web Flutt

Jun 3, 2021
Comments
  • Build Error: ld: framework not found TensorFlowLiteC

    Build Error: ld: framework not found TensorFlowLiteC

    I am unable to build the project for iOS. Here are the steps to reproduce the error:

    1. Download the project
    2. run sh install.sh
    3. run flutter pub add get
    4. Open the project in Visual Studio Code
    5. Setup the signing for Xcode
    6. run pod install
    7. run flutter run

    This produces the following error:

    Ld /Users/vijeshrao/Library/Developer/Xcode/DerivedData/Runner-hggazerwaeetoqeyyebckgveptau/Build/Intermediates.noindex/Pods.build/Release-iphoneos/tflite_flutter.build/Objects-normal/armv7/Binary/tflite_flutter normal armv7 (in target 'tflite_flutter' from project 'Pods')
        cd /Users/vijeshrao/Downloads/FlutterWithMediaPipe-main\ 2/ios/Pods
        /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -target armv7-apple-ios9.0 -dynamiclib -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS15.0.sdk -L/Users/vijeshrao/Library/Developer/Xcode/DerivedData/Runner-hggazerwaeetoqeyyebckgveptau/Build/Products/Release-iphoneos/tflite_flutter -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphoneos -L/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS15.0.sdk/usr/lib/swift -F/Users/vijeshrao/Library/Developer/Xcode/DerivedData/Runner-hggazerwaeetoqeyyebckgveptau/Build/Products/Release-iphoneos/tflite_flutter -F/Users/vijeshrao/Documents/flutter/bin/cache/artifacts/engine/ios-release/Flutter.xcframework/ios-arm64_armv7 -filelist /Users/vijeshrao/Library/Developer/Xcode/DerivedData/Runner-hggazerwaeetoqeyyebckgveptau/Build/Intermediates.noindex/Pods.build/Release-iphoneos/tflite_flutter.build/Objects-normal/armv7/tflite_flutter.LinkFileList -install_name @rpath/tflite_flutter.framework/tflite_flutter -Xlinker -rpath -Xlinker /usr/lib/swift -Xlinker -rpath -Xlinker @executable_path/Frameworks -Xlinker -rpath -Xlinker @loader_path/Frameworks -dead_strip -Xlinker -object_path_lto -Xlinker /Users/vijeshrao/Library/Developer/Xcode/DerivedData/Runner-hggazerwaeetoqeyyebckgveptau/Build/Intermediates.noindex/Pods.build/Release-iphoneos/tflite_flutter.build/Objects-normal/armv7/tflite_flutter_lto.o -fembed-bitcode-marker -fobjc-arc -fobjc-link-runtime -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphoneos -L/usr/lib/swift -Xlinker -add_ast_path -Xlinker /Users/vijeshrao/Library/Developer/Xcode/DerivedData/Runner-hggazerwaeetoqeyyebckgveptau/Build/Intermediates.noindex/Pods.build/Release-iphoneos/tflite_flutter.build/Objects-normal/armv7/tflite_flutter.swiftmodule -all_load -lc++ -framework TensorFlowLiteC -framework Flutter -framework Foundation -compatibility_version 1 -current_version 1 -Xlinker -dependency_info -Xlinker /Users/vijeshrao/Library/Developer/Xcode/DerivedData/Runner-hggazerwaeetoqeyyebckgveptau/Build/Intermediates.noindex/Pods.build/Release-iphoneos/tflite_flutter.build/Objects-normal/armv7/tflite_flutter_dependency_info.dat -o /Users/vijeshrao/Library/Developer/Xcode/DerivedData/Runner-hggazerwaeetoqeyyebckgveptau/Build/Intermediates.noindex/Pods.build/Release-iphoneos/tflite_flutter.build/Objects-normal/armv7/Binary/tflite_flutter
    
    ld: framework not found TensorFlowLiteC
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    
    

    How can I solve this issue? Please let me know.

    Thank you in advance..!

    opened by vrao9 2
  • Build Error on Android Device: keystore.password (No such file or directory)

    Build Error on Android Device: keystore.password (No such file or directory)

    Hi,

    On macos developing environment with an Android device, I did:

    1. sh install.sh
    2. flutter pub get
    3. flutter run

    But received error like this:

    FAILURE: Build failed with an exception.
    
    * Where:
    Build file '/Users/*path*/FlutterWithMediaPipe/android/app/build.gradle' line: 57
    
    * What went wrong:
    A problem occurred evaluating project ':app'.
    > /Users/*path*/FlutterWithMediaPipe/android/keystore/keystore.password (No such file or directory)
    
    opened by PeterTF656 1
  • FaceDetector stuck if multiple faces present

    FaceDetector stuck if multiple faces present

    Thank you for this repository! Face Detector works fine when there is one face present, but when there are 2 or more Non maximum supression algorithm gets stuck in infinite while loop. It doesn't filter out non-intersecting boxes properly. I have slightly modified your code in non_maximum_supression.dart to

    var picks = <int>[];
      while (I.isNotEmpty) {
        var ind0 = positions.sublist(positions.length - 1, positions.length);
        var ind1 = positions.sublist(0, positions.length - 1);
    
        var xx1 = _maximum(_itemIndex(_x1, ind0)[0], _itemIndex(_x1, ind1));
        var yy1 = _maximum(_itemIndex(_y1, ind0)[0], _itemIndex(_y1, ind1));
        var xx2 = _minimum(_itemIndex(_x2, ind0)[0], _itemIndex(_x2, ind1));
        var yy2 = _minimum(_itemIndex(_y2, ind0)[0], _itemIndex(_y2, ind1));
        var w = _maximum(0.0, xx2 - xx1);
        var h = _maximum(0.0, yy2 - yy1);
        var inter = w * h;
        var o = inter /
            (_sum(_itemIndex(area, ind0)[0], _itemIndex(area, ind1)) - inter);
    
        picks.add(ind0[0]);
    
        List<double> newI = [];
        List<int> newPositions = [];
        o.asMap().forEach((key, value) {
          if (value <= threshold) {
            newI.add(I[key]);
            newPositions.add(positions[key]);
          }
        });
    
        I = newI;
        positions = newPositions;
      }
    
      List<Detection> results = [];
    
      for (var pick in picks) {
        results.add(detections[pick]);
      }
      return results;
    

    and also in face_detection_service.dart

    
        for (var detection in detections) {
          Rect? bbox;
          final score = detection.score;
          if (score > threshold) {
            bbox = Rect.fromLTRB(
              inputImage.width * detection.xMin,
              inputImage.height * detection.yMin,
              inputImage.width * detection.width,
              inputImage.height * detection.height,
            );
    
            bbox = _imageProcessor.inverseTransformRect(
                bbox, image.height, image.width);
          }
          rectFaces.add({'bbox': bbox, 'score': score});
        }
        rectFaces.sort((a, b) => b['score'].compareTo(a['score']));
    
        return rectFaces;
    

    It detects and returns multiple boxes for each face present. I hope it helps, thanks again for this project.

    opened by Pasmikh 0
  • Issue with Camera Controller

    Issue with Camera Controller

    I am running this application on a google pixel 4a. I am getting these issues for all 4 models of media pipe..

    Encountering the following errors:

    ======== Exception caught by foundation library ==================================================== The following _CastError was thrown while dispatching notifications for CameraController: Null check operator used on a null value

    When the exception was thrown, this was the stack: #0 _CameraPageState.onNewCameraSelected. (package:flutter_with_mediapipe/pages/camera_page.dart:131:28) #1 ChangeNotifier.notifyListeners (package:flutter/src/foundation/change_notifier.dart:243:25) #2 ValueNotifier.value= (package:flutter/src/foundation/change_notifier.dart:309:5) #3 CameraController.initialize. (package:camera/src/camera_controller.dart:267:9) #11 Where.whereType. (package:stream_transform/src/where.dart:21:30) ... The CameraController sending notification was: CameraController#a6084(CameraValue(isRecordingVideo: false, isInitialized: true, errorDescription: null, previewSize: Size(720.0, 480.0), isStreamingImages: true, flashMode: FlashMode.auto, exposureMode: ExposureMode.auto, focusMode: FocusMode.auto, exposurePointSupported: true, focusPointSupported: true, deviceOrientation: DeviceOrientation.portraitUp, lockedCaptureOrientation: null, recordingOrientation: null))

    opened by muck27 0
Owner
Jaehee Kim
Interested in AI, Deep learning, Flutter
Jaehee Kim
A flutter carousel widget, support infinite scroll, and custom child widget.

carousel_slider A carousel slider widget. Features Infinite scroll Custom child widgets Auto play Supported platforms Flutter Android Flutter iOS Flut

serenader 1.4k Dec 30, 2022
A Flutter widget that paints an image and moves it at a slower speed than the main scrolling content.

A Flutter widget that paints an image and moves it at a slower speed than the main scrolling content. Installation Add dependency to your pubspec.yaml

Anatoly Pulyaevskiy 272 Dec 23, 2022
πŸ“Έ Easy to use yet very customizable zoomable image widget for Flutter, Photo View provides a gesture sensitive zoomable widget. Photo View is largely used to show interacive images and other stuff such as SVG.

Flutter Photo View A simple zoomable image/content widget for Flutter. PhotoView enables images to become able to zoom and pan with user gestures such

Fire Slime Games 1.7k Jan 3, 2023
SVG parsing, rendering, and widget library for Flutter

flutter_svg Draw SVG (and some Android VectorDrawable (XML)) files on a Flutter Widget. Getting Started This is a Dart-native rendering library. Issue

Dan Field 1.5k Jan 6, 2023
A Flutter plugin for Android and iOS supports cropping images

Image Cropper A Flutter plugin for Android and iOS supports cropping images. This plugin is based on two different native libraries so it comes with d

HungHD 891 Dec 28, 2022
Download, cache and show images in a flutter app

Cached network image A flutter library to show images from the internet and keep them in the cache directory. How to use The CachedNetworkImage can be

Baseflow 2.1k Jan 3, 2023
Flutter plugin that allows you to display multi image picker on iOS and Android. πŸ‘ŒπŸ”πŸŽ‰

IMPORTANT: This repository has been archived and no longer mantained. As I don't have time anymore to work on the package it became very outdated. For

Radoslav Vitanov 898 Apr 29, 2021
Use lottie in flutter for both iOS and Android

flutter_lottie Use Lottie in Flutter. Supports both iOS and Android using lottie-ios and lottie-android Current Status Supports most features that bot

Cameron Smith 160 Nov 25, 2022
A Flutter package for manipulating bitmaps

Flutter Bitmap A minimalist Flutter package to perform fast bitmaps operations. The focus here is to provide a cool bitmap manipulation interface. The

Renan 152 Dec 23, 2022
A flutter plugin which provides Crop Widget for cropping images.

A flutter plugin which provides Crop Widget for cropping images. crop_your_image provides only minimum UI for deciding cropping area inside images. Other UI parts, such as "Crop" button or "Change Aspect Ratio" button, need to be prepared by each app developers.

Chooyan 96 Dec 31, 2022