Skip to content

Segmentation Fault when running on Raspberry Pi 3B+ #3296

Description

@rashedkoutayni

I am trying to run ONNX Runtime on RaspberryPi 3 B+, which has armv7l quad-core CPU.
In order to perform the cross-compilation for the Python wheel file for the ARM architecture, I followed the instructions mentioned here:
https://github.com/microsoft/onnxruntime/blob/master/dockerfiles/README.md#arm-32v7
and I got the wheel file (onnxruntime-1.2.0-cp35-cp35m-linux_armv7l.whl).
Furthermore, I could successfully install ONNX and ONNX Runtime on the mentioned Raspberry Pi.

I have an ONNX model that I exported from PyTorch 1.4, as well as some other models from the ONNX model zoo.

When I load the ONNX model and check it, everything seems to be fine:
# Load the model :
model_path = "myModel.onnx"
onnx_model = onnx.load(model_path)

# Check the model :
onnx.checker.check_model(onnx_model)
print('The model is checked!')

However, when I create an ONNX Runtime session, I get segmentation fault:
print("Creating session...")
session = onnxruntime.InferenceSession(model_path)
print("Session created.")

The output:
The model is checked!
Creating session...
Speicherzugriffsfehler

where:
Speicherzugriffsfehler = Memory access error

Which is Segmentation Fault on another RaspberryPi 3B.

ONNX Version: 1.2.3
ONNX Runtime Version: 1.2.0
Raspbian OS Version: Linux raspberrypi 4.14.52-v7+ #1123 SMP Wed Jun 27 17:35:49 BST 2018 armv7l GNU/Linux

The same happens when I try to run the session for other models from the model zoo ..
However, It works fine on my Desktop x86_64 Ubuntu.

Any suggestions please ? Thanks !

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions