ENOENT when running .eim in docker on Raspberry Pi 4 Model B Rev 1.2

details below. The the /dev/shm files and /tmp/tmp/** files are getting created. also, I had to comment out the arch switch in /usr/lib/node_modules/edge-impulse-linux/build/cli/linux/runner-downloader.js and force it to be aarch64 to get edge-impulse-linux-runner to not complain and give the cryptic message shown in the top of the image below.

Docker
root@pi4:/# uname -a
Linux pi4 6.1.19-v8+ #1637 SMP PREEMPT Tue Mar 14 11:11:47 GMT 2023 aarch64 aarch64 aarch64 GNU/Linux

Host pi4
root@pi4:/# uname -a
Linux pi4 6.1.19-v8+ #1637 SMP PREEMPT Tue Mar 14 11:11:47 GMT 2023 aarch64 aarch64 aarch64 GNU/Linux

Host pi4
root@pi4:/# file project-1-linux-aarch64-v2.eim
project-1-linux-aarch64-v2.eim: ELF 64-bit LSB executable, ARM aarch64, version 1 (GNU/Linux), dynamically linked, interpreter /lib/ld-linux-aarch64.so.1, for GNU/Linux 3.7.0, with debug_info, not stripped

Docker

SOLVED
ok, so I needed to compile for arm7.

root@pi4:/# file inteladata-project-1-linux-aarch64-v2.eim
inteladata-project-1-linux-aarch64-v2.eim: ELF 64-bit LSB executable, ARM aarch64, version 1 (GNU/Linux), dynamically linked, interpreter /lib/ld-linux-aarch64.so.1, for GNU/Linux 3.7.0, with debug_info, not stripped
root@pi4:/# ls /lib/ld-linux-aarch64.so.1
ls: cannot access '/lib/ld-linux-aarch64.so.1': No such file or directory
root@pi4:/# ls /lib/ld-linux-armhf.so.3
/lib/ld-linux-armhf.so.3
root@pi4:/# file inteladata-project-1-linux-armv7-v3.eim
inteladata-project-1-linux-armv7-v3.eim: ELF 32-bit LSB executable, ARM, EABI5 version 1 (GNU/Linux), dynamically linked, interpreter /lib/ld-linux-armhf.so.3, for GNU/Linux 3.2.0, with debug_info, not stripped

@inteladata,

uname will give the architecture of the host system even if running it inside a 32-bits container.

You should be able to use the aarch64 binary and it will give you better performances. Just make sure to use 64-bits versions for your docker engine and container.

Aurelien

Thanks @aurel … your reply lead me to the root cause. I used Raspberry Pi Imager and mindlessly selected the 32-bit version. I re-imaged my SD card with 64-bit which resolved everything. I can run the aarch64 model now and I got a 20ms inference time speedup.
Thanks again :slight_smile:

3 Likes