OpenCV import fails with "Illegal Instruction (Core Dump)"


I want to install (using pip) openCV inside a virtual environment (venv) on a Jetson Xavier NX development board.

When running import cv2 command

I get >> Illegal Instruction (Core Dump)

on command line?

Do I really have to build it from source? The aim of the project is to isolate the python scripts and versions inside a virtual instance.

Has anyone succeeded in installing Python OpenCV using python3 -m pip install opencv-python


Finally fixed this. It turns out to be a problem with numpy. Rolling back to a previous version fixes it.
My requirements.txt file now includes:

numpy==1.19.4 # Current version (1.19.5) causes “illegal instruction” on arm64


1 Like