google-ai-edge / mediapipe-samples

Apache License 2.0
1.61k stars 415 forks source link

All CodePen examples for `vision` are failing #94

Closed Neilblaze closed 1 year ago

Neilblaze commented 1 year ago

Description

The following CodePen demos (examples) are failing because of dependency incompatibility for MediaPipe Tasks Vision package:

  1. Background Segmenter (web)
  2. MediaPipe GestureRecognizer (web)
  3. MediaPipe HandLandmarker (web)
  4. MediaPipe Image Classifier (web)
  5. MediaPipe Image Embedder (web)
  6. MediaPipe Image Segmentation (web)
  7. MediaPipe Interactive Image Segmentation (web)
  8. MediaPipe Object Detection (web)

I initially assumed that it was an issue with CodePen, but I can confirm that it's valid since I've tested most of them locally too.

cc: @jenperson, @PaulTR

Screenshot šŸ–¼ļø

The error log populates an issue with building the "@mediapipe/tasks-vision" package [@mediapipe/tasks-vision@v0.1.0-alpha-10]

image

Solution ā”

šŸ’” 0.1.0-alpha-10 just got released just 6 hours ago, while 0.1.0-alpha-9 got released 2 days ago. Release versions can be explored over here.

The easy fix is to update the CDN ā†’ https://cdn.skypack.dev/@mediapipe/tasks-vision@latest with either https://cdn.jsdelivr.net/npm/@mediapipe/tasks-vision (stable) or better "https://cdn.skypack.dev/@mediapipe/tasks-vision@0.1.0-alpha-9" (latest stable) & you're good to go! šŸš€


P.S.: Please consider adding an Issue Template as well as Stale bot for this repository or better import the same one from here & set the config value accordingly. If assigned, I'd love to raise a PR for the same! šŸ˜„


OS : Ubuntu (22.04 LTS, x64)   /   Windows 10 Pro (x64) Browser :

jenperson commented 1 year ago

Thank you for bringing this to my attention! There has been a new package release that resolves the issue. Feel free to re-open if this problem persists for you.