-
Notifications
You must be signed in to change notification settings - Fork 125
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
Cannot allocate tensors in C++ #180
Comments
Hey, you could checkout this answer for a quick solution: #137 (comment) My suggestions:
Ahhhh, okay so you're on the right track, but unfortunately, the commit we picked for the current libedgetpu release also had a build bug when building libtensorflow-lite (I know :( ).
If you use the commit in that lib, you'll also need to build libedgetpu on that repo, the point is that libedgetpu.so and libtensorflow-lite.a are both built from the same commit. |
I already tried compiling TensorFlow Lite by doing a checkout on tensorflow/tensorflow@d855adf and cherry-picking tensorflow/tensorflow@72cd947, but by doing so I'm getting errors from the linker when I try to compile my code:
|
@FabienSailliet humn that's a linker error, are you copying the headers from the same commits and the correct I believe this one uses this commit for both libedgetpu and libtensorflow-lite. Be sure to set Cheers! |
Thanks, I forgot to update my includes, it is now working if I use the diploria3 release of libedgetpu. However, if I use the last one (eel2), I am getting this during the compilation:
Maybe the compiler you used to compile it is too recent, I have g++ 8.3.0 on the dev board running Mendel Linux. |
@FabienSailliet Can you share:
|
My bad, I took the wrong .so file, with the eel2 release of the lib and TensorFlow Lite compiled from tensorflow/tensorflow@d855adf after aplying the patch tensorflow/tensorflow@72cd947 I can now run it. Thank you very much! |
Hello,
I am trying to run inferences on the TPU of a Coral dev board using TensorFlow Lite with C++, following this indications on the Coral website.
Here is the code I am trying to run:
I am compiling on the dev board using the latest
libedgetpu.so
found there. To build the TensorFlow Lite static library following the indications from the Coral website, I first tried building it on the commit indicated there. I had compilation and linking issues, so I used the commit indicated in the sources of this lib, which allows me to compile TensorFlow Lite and my program without any issue.When I run it, I get the following error:
The indicated data type value is not the same if I run it again. I tried multiple detection and classification models from the Coral website and I tried a model I compiled from this TensorFlow example model using
edgetpu_compiler
and it gives me the same error, with a varying number.The only difference I found is using the
mobilenet_ssd_v2_coco_quant_postprocess_edgetpu.tflite
model from the Python example, which always gives:The text was updated successfully, but these errors were encountered: