Open vollkornholztuer opened 6 months ago
Hi @vollkornholztuer,
There appears to be a problem loading the model in Windows when using the "model_asset_path" in the Base Option.
To address this, could you please try loading it using "model_asset_buffer" as demonstrated below? Kindly let us know if this resolves the issue.
base_options = BaseOptions(model_asset_buffer=open(gestureRecognizerModelPath, "rb").read())
For additional clarity, we suggest following this thread.
Thank you!!
I am not an OP, but the solution that @kuaashish provided worked for me.
Hi @danielkonecny,
Thank you for the confirmation, @vollkornholztuer. Could you please update the status if this solution is working for you?
Have I written custom code (as opposed to using a stock example script provided in MediaPipe)
Yes
OS Platform and Distribution
Windows 11
Mobile device if the issue happens on mobile device
No response
Browser and version if the issue happens on browser
No response
Programming Language and version
Python 3.11.7
MediaPipe version
0.10.11
Bazel version
No response
Solution
GestureRecognizerOptions(base_options=BaseOptions(model_asset="insert/path/here/gesture_recognizer.task)
Android Studio, NDK, SDK versions (if issue is related to building in Android environment)
No response
Xcode & Tulsi version (if issue is related to building for iOS)
No response
Describe the actual behavior
Base option concatenates model_asset_path with path ov .venv/site-packages for no apparent reason and crashes while creating the model. I get RuntimeError errnr=22 (see logs)
Describe the expected behaviour
The mode_asset_pash shoudln't be concatenated with anything and the webcam with gesture recognition should start.
Standalone code/steps you may have used to try to get what you need