Sudo python Illegal instruction

Hi,

I test my python code in jetson device, and I find that I can’t run my code when I use sudo command, just like sudo python -c "import cv2", error happend.
image

It is not Illegal instruction (core dumped) error, as I have set .bashrc with export OPENBLAS_CORETYPE=ARMV8.

I check it in my TX2, Nano and xavier agx, and same error happend,whether jetpack 4.6(l4t 332.6.1) and jetpack 4.5.1(l4t 32.5.1).

So can you help me solve it? Thanks!

Hi,
Do you have customization to the system image? We try it on Jetpacl 4.6/Jetson Nano developer kit, and don’t observe the issue. The commands are executed without error:

nvidia@nvidia-desktop:~$ cat /etc/nv_tegra_release
# R32 (release), REVISION: 6.1, GCID: 27863751, BOARD: t210ref, EABI: aarch64, DATE: Mon Jul 26 19:20:30 UTC 2021
nvidia@nvidia-desktop:~$ sudo python -c "import cv2"
nvidia@nvidia-desktop:~$ sudo python3 -c "import cv2"

No, I dont customization to the system image, and I tested in TX2, the same error happend.

nvidia@nvidia:~$ cat /etc/nv_tegra_release
# R32 (release), REVISION: 6.1, GCID: 27863751, BOARD: t186ref, EABI: aarch64, DATE: Mon Jul 26 19:36:31 UTC 2021
nvidia@nvidia:~$ sudo python -c "import cv2"
[sudo] password for nvidia: 
Illegal instruction
nvidia@nvidia:~$ sudo python3 -c "import cv2"
Illegal instruction

Hi,

This is a known issue in NumPy v1.19.5.
Please downgrade your NumPy to version 1.19.4 instead.

$ pip3 install numpy==1.19.4

Thanks.

2 Likes

Thanks, the problem have been solved!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.