-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
React Native - Face Landmark Detection not working with Tensor3D #7937
Comments
Hi, @Patel-Preet Thank you for bringing this issue to our attention, if possible could you please help me with your It would be great if you guide me with steps to replicate the same issue from my end. Thank you! |
Hi @gaikwadrahul8, Sorry for the delayed response. I have attached the package.json and model zip file as requested. The above code should be enough to replicate the issue. However, let me know if you need additional details. |
After updating the deps to 4.10.0 the new errors is |
Hi, I have a walkaround for the issue here: #6526 (comment) I have been using it in production for a while now so it is working. I am also working on a potential fix for this issue. |
Hi, @Patel-Preet Apologize for the delayed response and could you please refer above comment from @paradite with this workaround and I see a PR #7947 which is submitted by @paradite which may take care of this issue after merging that PR if I'm not wrong. Thank you! |
This issue has been marked stale because it has no recent activity since 7 days. It will be closed if no further activity occurs. Thank you. |
This issue was closed due to lack of activity after being marked stale for past 7 days. |
System information
Deps:
"react": "18.2.0",
"react-native": "0.72.3",
"@tensorflow-models/face-landmarks-detection": "^1.0.5",
"@tensorflow/tfjs": "^4.10.0",
"@tensorflow/tfjs-core": "^3.20.0",
"@tensorflow/tfjs-react-native": "^0.8.0",
"@tensorflow/tfjs-backend-webgl": "^3.20.0",
"expo-gl": "^13.0.1",
Describe the current behavior
According to the docs https://github.com/tensorflow/tfjs-models/tree/master/face-landmarks-detection/src/tfjs the estimateFaces takes Tensor3D as paramater but when executed it throws an error
Error: pixels passed to tf.browser.fromPixels() must be either an HTMLVideoElement, HTMLImageElement, HTMLCanvasElement, ImageData in browser, or OffscreenCanvas, ImageData in webworker or {data: Uint32Array, width: number, height: number}, but was Tensor
#3186 (comment)
#4530 (comment)
#7529
https://js.tensorflow.org/api_react_native/0.5.0/#decodeJpeg (Returns Tensor3D)
Describe the expected behavior
It should have returned the face landmarks.
Standalone code to reproduce the issue
Other info / logs Include any logs or source code that would be helpful to
diagnose the problem. If including tracebacks, please include the full
traceback. Large logs and files should be attached.
The text was updated successfully, but these errors were encountered: