GPU coder error with Nivida Jetson device

I am using the Matlab 2023b, I have no issue to compile the InceptionV3 classification to the Nvidia Jetson orin 32 GB. Now I got NVIDIA JETSON ORIN 64 BIT, I compiled the executable using GPU coder. I got issue. I upgraded matlab to 2024b, I have the same issue.
i am using the following codes
opencv_linkflags = '`pkg-config --cflags --libs opencv4`';
coder.updateBuildInfo('addLinkFlags',opencv_linkflags);
coder.updateBuildInfo('addIncludePaths', '/usr/include/opencv4/'); %both remove or add this line, the GPU coder compilation process does not work.
fatal error: opencv2/imgproc/imgproc.hpp: No such file or directory
57 | #include <opencv2/imgproc/imgproc.hpp>
Any idea to help solve the issue?

 採用された回答

Chao Luo
Chao Luo 2024 年 7 月 8 日
編集済み: Chao Luo 2024 年 7 月 8 日

0 投票

Seems a bug here that the include path is considered as relative path based on the MATLAB_WORKSPACE on the Jetson board.
One workaroud is using addCompileFlags instead:
coder.updateBuildInfo("addCompileFlags", '-I /usr/include/opencv4');

1 件のコメント

Liwei
Liwei 2024 年 7 月 8 日
編集済み: Liwei 2024 年 7 月 8 日
Thanks. The alternative solution you provided works.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeDeep Learning Toolbox についてさらに検索

製品

リリース

R2024a

質問済み:

2024 年 7 月 8 日

編集済み:

2024 年 7 月 8 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by