tensorflow / tensorflow/tflite-support

Converted Lane Detection Model (PyTorch to TFLite) Fails Inference with Aborted Core Dump

Open
#842 3 comments 0 reactions 1 assignee View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
441
Forks
146
PR merge metrics
No merged PRs in 30d

Description

Description

tflite model fails inference check with 'Aborted (Core dumped)` error and no details. This is using the Coral inference code provided in the initially report issue. I was directed here by the Coral team; details of the original issue are found here.

There is no clear indicator why this is failing currently. Our model was a pytorch-trained model converted to onnx, then to tensorflow, then to tensorflow lite, and quantized from float32 to int8 using the a process detailed below. Included are the model's configuration (as detailed by the conditional lane detection repository format), the tflite model, as well as the conversion scripts and associated conda environment details.

The following process was used to get the tflite mode:

  1. Download and setup repository for conditional lane detection.
  2. Trained a model using pytorch framework with culane dataset format.
  3. Converted the saved .pth file to .onnx using the conditional-lane-detection/tools/pytorch2onnx.py script provided. Command was:
    python tools/pytorch2onnx.py configs/lane_detection_small_train.py lane-detection-model.pth --out lane-detection-model.onnx
  4. Convert the saved .onnx file using the lane_detection_conversion_script to .tflite, which follows Coral documentation on requirements and configurations options for conversion and quantization for float32 to int8
  5. Run the inference code sample provided above in the description, and see the core dump with no other details.

We have been able to run inference on the float32 models and the int conversion model on a local development machine. Maybe you can provide us some insight into why the conversion/quantization appears to be incorrect or failing? Is there a way to get better log information when a core dump occurs, or a troubleshooting technique we are overlooking? Any help would be appreciated. Thanks!

The tflite file is present (simply remove the .txt extension from it to use).

conda_environment.txt
lane_detection_conversion_script.py.txt
lane-detection-model.tflite.txt
lane_detection_small_train.py.txt

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.