Bug 493529 - MacOS: DaSIM and Nano motion tracker not working - uncaught OpenCV exception / invalud OpenCV build?
Summary: MacOS: DaSIM and Nano motion tracker not working - uncaught OpenCV exception ...
Status: RESOLVED FIXED
Alias: None
Product: kdenlive
Classification: Applications
Component: Video Effects & Transitions (show other bugs)
Version: git-master
Platform: macOS (DMG) macOS
: NOR major
Target Milestone: ---
Assignee: Jean-Baptiste Mardelle
URL:
Keywords: triaged
Depends on:
Blocks:
 
Reported: 2024-09-23 10:50 UTC by Schlomo Schapiro
Modified: 2024-12-09 16:47 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 24.12.0
Sentry Crash Report:


Attachments
screenshot of error (2.88 MB, image/png)
2024-09-23 10:50 UTC, Schlomo Schapiro
Details
Windows_crash_Motion-Tracker_Nano (17.50 KB, text/plain)
2024-12-05 16:38 UTC, emohr
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Schlomo Schapiro 2024-09-23 10:50:47 UTC
Created attachment 173986 [details]
screenshot of error

SUMMARY

Cannot use OpenCV motion trackers, "Analyse effect" fails with a "failed to filter source" error:

Current Frame: 1, percentage: libc++abi: terminating due to uncaught exception of type cv::Exception: OpenCV(4.9.0) /Users/gitlab/ws/builds/ GZwHuM5x/0/sysadmin/ci-management/macos-arm- clang/build/libs/opencv/opencv/work/opencv-4.9.0/ modules/dnn/src/onnx/onnx_importer.cpp:4097: error: (-2:Unspecified error) DNN/ONNX: Build OpenCV with Protobuf to import ONNX models in function 'readNetFromONNX'

STEPS TO REPRODUCE
1. install Kdeenlive
2. put OpenCV motion tracking modules into ~/Library/Application\ Support/kdenlive/opencvmodels/
3. load sample video, I used https://www.pexels.com/de-de/video/eine-gruppe-von-jungen-die-eine-musikalische-nummer-auf-der-buhne-spielen-2941132/
4. add Motion Tracker effect, mark a face, select DaSIM and click on "Analyze"

OBSERVED RESULT

error (see screenshot)

EXPECTED RESULT

Motion tracking with OpenCV models

SOFTWARE/OS VERSIONS
Mac OS 14.5 on M3 arm64
Kdenlive Version 24.11.70 (git master) from official DMG
Same problem observed also with 24.08.01 and 24.05.02 installed via DMG from official download
Comment 1 Schlomo Schapiro 2024-09-23 11:57:08 UTC
I did a countercheck on Linux (Kdenlive 24.08.1 via Flatpak) and there it all works.

It seems to me that there is a problem with the MacOS OpenCV build. This is the actual error message:

Build OpenCV with Protobuf to import ONNX models in function 'readNetFromONNX'

It seems like a problem with the builds for MacOS
Comment 2 73584j 2024-09-29 06:55:13 UTC
On the windows version, Kdenlive seems to have a similar issue, as it crashes when trying to use either motion tracking model.
Comment 3 Schlomo Schapiro 2024-12-03 23:15:52 UTC
Hi,

any update on this? Kdenlive 24.11.70 on MacOS still has this problem,

Is there a chance for fixing this?

Kind regards,
Schlomo
Comment 4 Jean-Baptiste Mardelle 2024-12-05 09:49:32 UTC
Yes, I just found some time to work on this. A Merge Request is pending and the fix will hopefully be in the upcoming 24.12.0 binaries:
https://invent.kde.org/packaging/craft-blueprints-kde/-/merge_requests/1083
Comment 5 emohr 2024-12-05 16:38:02 UTC
Created attachment 176370 [details]
Windows_crash_Motion-Tracker_Nano

If it helps, attached the crash log using Motion Tracker Nano under Windows.
Comment 6 Jean-Baptiste Mardelle 2024-12-09 16:47:02 UTC
This is now fixed in our daily build, you can check by downloading here:
https://cdn.kde.org/ci-builds/multimedia/kdenlive/release-24.12/

Our official 24.12.0 packages that will be released next week will contain this fix.