rknn-toolkit2 icon indicating copy to clipboard operation
rknn-toolkit2 copied to clipboard

运行examples/onnx/yolov5/下的test.py示例时 报如下错误

Open bleachlight opened this issue 1 year ago • 6 comments

E build: Catch exception when building RKNN model! E build: Traceback (most recent call last): E build: File "rknn/api/rknn_base.py", line 1836, in rknn.api.rknn_base.RKNNBase.build E build: File "rknn/api/rknn_base.py", line 377, in rknn.api.rknn_base.RKNNBase._generate_rknn E build: File "rknn/api/rknn_base.py", line 223, in rknn.api.rknn_base.RKNNBase._build_rknn E build: ImportError: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.29' not found (required by /home/rk3588/anaconda3/envs/rknn38/lib/python3.8/site-packages/rknn/api/lib/linux-x86_64/cp38/librknnc.so)

bleachlight avatar Jun 05 '23 08:06 bleachlight

I got the same problem, did you solve it? :)

ManciuCen avatar Jun 08 '23 05:06 ManciuCen

Did you solve it? :)

459737087 avatar Jun 19 '23 08:06 459737087

Just a solution to myself, use ubuntu20 instead of ubuntu18 can solve this problem. By the way, please don't try to upgrade or degrade the GLIBC library on ubuntu18 easily, which may cause your system booting failed.

ManciuCen avatar Jun 20 '23 01:06 ManciuCen

wget http://ftp.gnu.org/gnu/glibc/glibc-2.29.tar.gz
tar -zxf glibc-2.29.tar.gz
cd glibc-2.29

mkdir build
cd build/
sudo apt-get install gawk bison -y
../configure --prefix=/usr/local --disable-sanity-checks

make -j18
make install
cd /lib/x86_64-linux-gnu
ll
cp /usr/local/lib/libm-2.29.so /lib/x86_64-linux-gnu/

ln -sf libm-2.29.so libm.so.6
ldd --version

459737087 avatar Jun 20 '23 02:06 459737087

when i install rknntoolkit2 with python=3.8, there exists the error. I solved the error by install rknntoolkit2 with python=3.6. image

ShengkaiWu avatar Jul 04 '23 08:07 ShengkaiWu

You can reinstall glibc, but it will take a long time, or use Python 3.6 to install without any issues

gaoxumustwin avatar Oct 30 '23 06:10 gaoxumustwin