Segmentation Fault with tutorial: 'Coding Your Own Image Recognition Program (Python)'

Dear Xavier community,

I followed the well written instructions on Dustin’s page.

Running the self-created python program yield the following system error:

$ ./my-recognition.py 
Segmentation fault (core dumped)

Well, I think there is just the chance to setup the system from scratch.
I am already asking in a separate post about Xavier AGX instructions, as I just can find instructions for the Xavier NX, Orin and so forth.

Any hint appreciated and a great coding day to all readers!

Hi @pitfo, do you get this error when running any of the other jetson-inference apps like video-viewer.py, imagenet.py, or detectnet.py? How about if you run python3 -c 'import jetson_inference' ?

The setup/install instructions are the same for the different Jetson boards. I would try the jetson-inference container or reflash the board if needed.

Hi @dustin_nv,

python3 -c 'import jetson_inference'

Seems to work w/o any side effect. - However, There were just 900MB left, I did install a new M.2 SSD, so it is a wonderful moment In time to recreate the system.

Is there any recommendation which Version for the Xavier AGX would be considered as most recommendable?

OK, that’s a good sign - I would add debug print statements into your my-recognition.py script to see where it’s crashing at (or do a backtrace). And try launching it like python3 my-recognition.py to make sure it’s running with Python 3.

Personally I would recommend flashing the latest JetPack version while you’re at it (at this time, JetPack 5.1.1) JetPack SDK | NVIDIA Developer

A neighbor boat helped me with a 2nd Intel laptop. - I am burning the Ubuntu USB-Stick in this very second. - But you’re right, I am also curious and will instrumentalize the code with printfs to understand what’s going on and if python3 works.

Thank you for the hint and link! J

Quick update: Now without any change my-recognition did work as expected. - However, I received Ubuntu messages about cache corruption.
So the system isn’t stable and I better start from scratch. - Sorry for the bandwidth and thank you for your support and comments.

No problem @pitfo - glad that you were able to get it figured out! 👍

1 Like

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