oberluz / pycoral

Python API for ML inferencing and transfer-learning on Coral devices
https://coral.ai
Apache License 2.0
34 stars 2 forks source link

GLIBC import error #7

Closed David-OConnor closed 10 months ago

David-OConnor commented 10 months ago

Hi! Thank you again for building this! Setup: Ubuntu 20. Python3.11.

Step: import tflite_runtime.interpreter as tflite. Error:

ImportError: /lib/x86_64-linux-gnu/libc.so.6 version `GLIBC_2.34` not found...

How would you approach this? Ty!

oberluz commented 10 months ago

Hi,

The 3.11 wheels are built using debian bookworm. Look in scripts/build.sh line 47:

311) echo "debian:bookworm" ;;

which uses another version of libc as per your error message. You could try changing that line to ubuntu:20.04 and building it with:

$ DOCKER_CPUS=k8 scripts/build.sh --python_versions 311

It may not work because the native python version for ubuntu 20.04 is 3.8

To fix it you would need to modify ./libedgetpu/docker/Dockerfile and ./libcoral/docker/Dockerfile to install python 3.11 and the various packages and use those. Note that python 3.11 requires you to use a virtual environment.