Open hans-brgs opened 1 year ago
Hello @joezoug,
Could you please look into this issue. Thank you
Did you try setting the runtime dir (https://source.corp.google.com/piper///depot/google3/third_party/mediapipe/util/resource_util_windows.cc;rcl=526658482;l=26) ?
If you don't do that, you will need to include the files as runtime dependencies via your Build as Bazel uses a runtime map to look up the locations of any file that it is loading on Windows.
Have I written custom code (as opposed to using a stock example script provided in MediaPipe)
No
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
C++
MediaPipe version
V0.10.3
Bazel version
6.1.1
Solution
All examples requiring a runtime file
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
While attempting to run the hand tracking example (or other example) on Windows 11, the build succeeds without any issues, but the execution fails with an error related to file paths.
Describe the expected behaviour
When I encountered the error, I began an investigation into the code that determined the path to the resource files required for execution.
In the compilation file located at "mediapipe_release\mediapipe\util\BUILD", I identified a platform-specific implementation for Windows, defined in the "resource_util_windows.cc" file.
To address the issue, I modified the compilation configuration to utilize the default resource utility file for Windows builds, making the change as follows:
This change resolving the error. So, it appears that the implementation of resource_util_windows.cc may need to be revised or adjusted for compatibility with the current setup on Windows 11.
Standalone code/steps you may have used to try to get what you need
Build Details
Command: bazel build --config=windows //mediapipe/examples/desktop/hand_tracking:hand_tracking_cpu
.bazelrc Configuration:
Command to run :
Other info / Complete Logs