-
Notifications
You must be signed in to change notification settings - Fork 5.2k
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
Unable to load the hand detection model #35
Comments
We have some custom ops in mediapipe/util/tflite/operations. |
Is their any way i can use these custom operations and include them in my tflite setup. i am very new to this and want help to up the model on android device. |
You may find the creation of the custom op resolver here: And how to use it instead builtin op resolver is here: |
Can any one give a little bit more details on how to incorporate these custom ops to be able to run it in regular python enviroment. |
Got the same error in python when I tried to load the tflite model into the Interpreter.
Code:
I can see that it can be resolved using the tflite::InterpreterBuilder in C api Environment: |
will is possible i compile only the tflite in mediapipe, and use this as instead of offfical tflite? |
To avoid stress you can use it with Tensorflow C++ Lite. And build with Bazel. |
@lamarrr, and then can I load the compiled op in python by using |
I really don't think so because it's a Tensorflow lite package and not Tensorflow's. |
Thanks to @junhwanjang and his awesome repo, now I can load palm detection model without custom op. |
It is work for me. That is important to use python3.7 and install specified version of tensorflow |
the [repo] has been deleted,can you tell me what is the 'specified version of tensorflow' please? |
@caocao1989 Tensorflow - 1.13.1 and python 3.7.3 |
@junhwanjang thank you very much!!! |
@junhwanjang , except for the 'specified version of tensorflow', is there any other modifications of the usage of tflite intenpreter? I still encountered this error:unresolved custom op: Convolution2DTransposeBias using "tensorflow-lite:1.13.0". |
@jiuqiant The ops in mediapipe/util/tflite/operations seems to the cpu impls. I am wondering how the model works on the GPU? @fanzhanggoogle I looked at the op_resolver, which seems to be used by mediapipe when it is using the GPU delegate. But the registrations for ConvTranspose is (nullptr, nullptr, nullptr, nullptr). Which means there is no function in the registration. I am curious as to where the ConvTranspose GPU kernel is implemented. I am trying to run the TFLite model using the GPU delegate, and I am running into some errors. I am running in a EXC_BAD_ACCESS in the function Convolution2DTransposeBianParser::IsSupported. Do you guys have any info? |
do you solve this problem? I meet the same question. |
Can tensorflow lite C++ depoly on Visual studio project and windows system? |
can you tell me how to solve the problem, I meet same error when running "interpreter.allocate_tensors()". The repo has been deleted, Please tell me how to avoid the problem or can you share me your tflite which can directly be used to tflite python API without C++. |
can you share how to resolve this problem? |
have you solved this difficult question? |
So if I just want to run this tflite model on python environment, How to avoid this problem |
@shoutOutYangJie I closed my repo because of some private reason. |
Thanks you very much. You save my life!! Could you introduce roughly what important steps you did ? How to generate this new tflite model without custom ops. |
Can you share how can you avoid custom ops and run this tflite model at phthon platform?
…------------------ Original ------------------
From: Junhwan Jang <[email protected]>
Date: Tue,Nov 19,2019 10:36 AM
To: google/mediapipe <[email protected]>
Cc: shoutOutYangJie <[email protected]>, Mention <[email protected]>
Subject: Re: [google/mediapipe] Unable to load the hand detection model (#35)
@shoutOutYangJie I closed my repo because of some private reason.
You can use "palm_detection_without_custom_op.tflite" in the below link.
https://github.com/metalwhale/hand_tracking
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
@lamarrr Hi, could you please share a little bit more on the TF Lite C++ part? E.g. how to build and be linked with applications for C++ usage? |
@junhwanjang |
@Akshaysharma29 @shoutOutYangJie Did you find the solution? |
@ragavendranbala No I have not changed there custom_ops have you tried that? |
@Akshaysharma29 @shoutOutYangJie @ragavendranbala |
Can you share your code |
…t_embedder Implement text embedder
I am trying to test the given model in my sample android application.
When trying to load the model i face this issue:
java.lang.IllegalStateException: Internal error: Unexpected failure when preparing tensor allocations: Encountered unresolved custom op: Convolution2DTransposeBias.Node number 165 (Convolution2DTransposeBias) failed to prepare.
Code:
AssetFileDescriptor fileDescriptor = activity.getAssets().openFd("palm_detection.tflite");
The text was updated successfully, but these errors were encountered: