terryky / tflite_gles_app

GPU accelerated deep learning inference applications for RaspberryPi / JetsonNano / Linux PC using TensorflowLite GPUDelegate / TensorRT
MIT License
488 stars 130 forks source link

Raspberry Pi 4 compile issues #31

Open MyraBaba opened 1 year ago

MyraBaba commented 1 year ago

Hi,

I try to compile gl2handpose in rpi4 it gives below error:

g++ -o gl2handpose -Wl,--whole-archive main.o tflite_handpose.o render_handpose.o shapes.o touch_event.o custom_ops/transpose_conv_bias.o /home/pi/bcwork/tflite_gles_app/common/assertgl.o /home/pi/bcwork/tflite_gles_app/common/assertegl.o /home/pi/bcwork/tflite_gles_app/common/util_egl.o /home/pi/bcwork/tflite_gles_app/common/util_shader.o /home/pi/bcwork/tflite_gles_app/common/util_matrix.o /home/pi/bcwork/tflite_gles_app/common/util_texture.o /home/pi/bcwork/tflite_gles_app/common/util_render2d.o /home/pi/bcwork/tflite_gles_app/common/util_debugstr.o /home/pi/bcwork/tflite_gles_app/common/util_pmeter.o /home/pi/bcwork/tflite_gles_app/common/util_tflite.o /home/pi/bcwork/tflite_gles_app/common/winsys/winsys_x11.o /home/pi/bcwork/tflite_gles_app/common/util_camera_capture.o /home/pi/bcwork/tflite_gles_app/common/util_v4l2.o /home/pi/bcwork/tflite_gles_app/common/util_drm.o render_imgui.o /home/pi/bcwork/tflite_gles_app/third_party/imgui/imgui.o /home/pi/bcwork/tflite_gles_app/third_party/imgui/imgui_draw.o /home/pi/bcwork/tflite_gles_app/third_party/imgui/imgui_widgets.o /home/pi/bcwork/tflite_gles_app/third_party/imgui/examples/imgui_impl_opengl3.o -Wl,--copy-dt-needed-entries -Wl,--allow-multiple-definition -L/home/pi/bcwork/tflite_gles_app/third_party/tensorflow/current/lite/lib/current/ -L/home/pi/lib -lm -lEGL -lGLESv2 -lX11 -pthread -ldrm -ltensorflowlite -ltensorflowlite_gpu_delegate -Wl,--no-whole-archive -rdynamic /usr/bin/ld: cannot find -ltensorflowlite /usr/bin/ld: cannot find -ltensorflowlite_gpu_delegate

In my raspbery there is already libtensorflow-lite.a but not tensorflowlite_gpu_delegate lib. more over -l-ltensorflowlite but there is libtensorflow-lite.a ?

what will be the proper compiling environment ? just clone the repo to my Desktop ubuntu and compile than copy to rpi ? or do I need any docker something ?

Best

terryky commented 1 year ago

Did you build the tensorflow library following the below procedure described in README ?

MyraBaba commented 1 year ago

No it was already builded.

Tried to steps in Mac OS X but some other errors.

Now restarting all steps in my ubuntu 20.04 and let you know.

Best

On 28 Jul 2022, at 16:00, Yoshiteru, K. @.***> wrote:

Did you build the tensorflow library following the below procedure described in README ?

32bit: https://github.com/terryky/tflite_gles_app#22-build-for-aarch64-linux-jetson-nano-raspberry-pi https://github.com/terryky/tflite_gles_app#22-build-for-aarch64-linux-jetson-nano-raspberry-pi or 64bit: https://github.com/terryky/tflite_gles_app#23-build-for-armv7l-linux-raspberry-pi https://github.com/terryky/tflite_gles_app#23-build-for-armv7l-linux-raspberry-pi — Reply to this email directly, view it on GitHub https://github.com/terryky/tflite_gles_app/issues/31#issuecomment-1198108969, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEFRZHYOTS746IIH4H6DMBDVWJ76LANCNFSM545EHXNQ. You are receiving this because you authored the thread.

MyraBaba commented 1 year ago

Now all is successfully worked for handpose.

Is there an option video or cam input or do we need to modify code ?

Best

terryky commented 1 year ago

USB camera can be used without any source code modification.

To use a mp4 video, follow the below instructions. https://github.com/terryky/tflite_gles_app#32-recorded-video-file