Summary: | digiKam crash when I start face recognition | ||
---|---|---|---|
Product: | [Applications] digikam | Reporter: | christian.rioult |
Component: | Faces-Recognition | Assignee: | Digikam Developers <digikam-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | crash | CC: | caulier.gilles, guenter.k, hannes, hatl, k |
Priority: | NOR | Keywords: | drkonqi |
Version: | 4.0.0 | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 4.3.0 | |
Sentry Crash Report: | |||
Attachments: |
New crash information added by DrKonqi
New crash information added by DrKonqi |
Description
christian.rioult
2014-05-31 12:19:32 UTC
*** Bug 334509 has been marked as a duplicate of this bug. *** OpenSuse 12.3, latest updates as of 1.6.2014 digikam --version Qt: 4.8.4 KDE Development Platform: 4.13.0 digiKam: 4.0.0 There are three radio buttons for face detection: *detect *detect and recognize *recognize Only "detect and recognize" set crashes. Both other two go through. KDE-Crash Reporter does not work at the moment, digikam disapears simply after crash. This is what gdb says on crash: OpenCV Error: Bad argument (This LBPH model is not computed yet. Did you call the train method?) in predict, file /home/abuild/rpmbuild/BUILD/digikam-4.0.0-rc/extra/libkface/libkface/recognition-opencv-lbph/facerec_borrowed.cpp, line 324 digikam(12845)/KFACE: cv::Exception: /home/abuild/rpmbuild/BUILD/digikam-4.0.0-rc/extra/libkface/libkface/recognition-opencv-lbph/facerec_borrowed.cpp:324: error: (-5) This LBPH model is not computed yet. Did you call the train method? in function predict <this message above several times> Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7fff757fa700 (LWP 12913)] Digikam::FaceTags::getOrCreateTagForIdentity (attributes=...) at /usr/src/debug/digikam-4.0.0/core/libs/database/faces/facetags.cpp:286 286 /usr/src/debug/digikam-4.0.0/core/libs/database/faces/facetags.cpp: Datei oder Verzeichnis nicht gefunden. ### bt #0 Digikam::FaceTags::getOrCreateTagForIdentity (attributes=...) at /usr/src/debug/digikam-4.0.0/core/libs/database/faces/facetags.cpp:286 #1 0x00000000006f4a37 in Digikam::DatabaseWriter::process (this=0x4b2d2d0, package=...) at /usr/src/debug/digikam-4.0.0/core/utilities/facemanagement/facepipeline.cpp:661 #2 0x00000000006f5264 in Digikam::DatabaseWriter::qt_static_metacall ( _o=<optimized out>, _c=<optimized out>, _id=<optimized out>, _a=<optimized out>) at /usr/src/debug/digikam-4.0.0/build/core/digikam/facepipeline_p.moc:494 #3 0x00007ffff295877e in QObject::event (this=0x4b2d2d0, e=<optimized out>) at kernel/qobject.cpp:1203 #4 0x00007ffff1a7086c in QApplicationPrivate::notify_helper ( this=this@entry=0xcbc490, receiver=receiver@entry=0x4b2d2d0, e=e@entry= 0x7fff68025970) at kernel/qapplication.cpp:4562 #5 0x00007ffff1a74ceb in QApplication::notify (this=this@entry=0x7fffffffd9d0, receiver=receiver@entry=0x4b2d2d0, e=e@entry=0x7fff68025970) at kernel/qapplication.cpp:4423 #6 0x00007ffff33a6366 in KApplication::notify (this=0x7fffffffd9d0, receiver=0x4b2d2d0, event=0x7fff68025970) at /usr/src/debug/kdelibs-4.13.0/kdeui/kernel/kapplication.cpp:311 #7 0x00007ffff2943d8e in QCoreApplication::notifyInternal (this=0x7fffffffd9d0, receiver=receiver@entry=0x4b2d2d0, event=event@entry=0x7fff68025970) at kernel/qcoreapplication.cpp:946 #8 0x00007ffff29476f1 in sendEvent (event=0x7fff68025970, receiver=0x4b2d2d0) at kernel/qcoreapplication.h:231 #9 QCoreApplicationPrivate::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=0, data=0x3833190) at kernel/qcoreapplication.cpp:1570 #10 0x00007ffff2947973 in QCoreApplication::sendPostedEvents ( receiver=receiver@entry=0x0, event_type=event_type@entry=0) at kernel/qcoreapplication.cpp:1463 #11 0x00007ffff2972133 in sendPostedEvents () at kernel/qcoreapplication.h:236 #12 postEventSourceDispatch (s=0x7fff40001d00) at kernel/qeventdispatcher_glib.cpp:279 #13 0x00007fffea37b7d5 in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0 #14 0x00007fffea37bb08 in ?? () from /usr/lib64/libglib-2.0.so.0 #15 0x00007fffea37bbc4 in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0 #16 0x00007ffff29722c6 in QEventDispatcherGlib::processEvents (this=0x7fff400008c0, flags=...) at kernel/qeventdispatcher_glib.cpp:424 #17 0x00007ffff2942adf in QEventLoop::processEvents (this=this@entry=0x7fff757f9d20, flags=...) at kernel/qeventloop.cpp:149 #18 0x00007ffff2942d68 in QEventLoop::exec (this=this@entry=0x7fff757f9d20, flags=...) at kernel/qeventloop.cpp:204 #19 0x00007ffff563947b in Digikam::WorkerObjectRunnable::run (this=0x5b52130) ---Type <return> to continue, or q <return> to quit--- at /usr/src/debug/digikam-4.0.0/core/libs/threads/threadmanager.cpp:196 #20 0x00007ffff283bc9d in QThreadPoolThread::run (this=0x3832ff0) at concurrent/qthreadpool.cpp:107 #21 0x00007ffff28480cc in QThreadPrivate::start (arg=0x3832ff0) at thread/qthread_unix.cpp:338 #22 0x00007fffef53ae0f in start_thread () from /lib64/libpthread.so.0 #23 0x00007ffff10ae44d in clone () from /lib64/libc.so.6 Git commit fa909aa96e7e41225551cd9e866618717f1ea546 by Gilles Caulier. Committed on 11/06/2014 at 21:06. Pushed by cgilles into branch 'master'. use a better C++ exception wrapper to handle non OpenCV exceptions (as pure C++ one) Related: bug 330342, bug 329873, bug 326742, bug 326586, bug 326585, bug 324774, bug 323888, bug 323361, bug 320812, bug 312440, bug 309027, bug 308645, bug 301611, bug 297558, bug 285517 M +4 -0 libkface/facedetector.cpp M +17 -2 libkface/recognitiondatabase.cpp http://commits.kde.org/libkface/fa909aa96e7e41225551cd9e866618717f1ea546 With next digiKam 4.1.0, i fixed libkface to handle all C++ exception (and not only OpenCV exception). So, at least, digiKam must crash lesser now. If you want to review this entry again, use current implementation from git/master, or wait next 4.1.0 release... Thanks to update your feedback Gilles Caulier Created attachment 87206 [details]
New crash information added by DrKonqi
digikam (4.0.0) on KDE Platform 4.13.0 using Qt 4.8.6
- What I was doing when the application crashed:
Started the face recognition
Progress goes to 4%
crashes afterwards
-- Backtrace (Reduced):
#6 isEmpty (this=0x3d) at /usr/include/qt4/QtCore/qmap.h:203
#7 Digikam::FaceTags::getOrCreateTagForIdentity (attributes=...) at /build/buildd/digikam-4.0.0/core/libs/database/faces/facetags.cpp:286
#8 0x00000000006f0205 in Digikam::DatabaseWriter::process (this=0x88438c0, package=...) at /build/buildd/digikam-4.0.0/core/utilities/facemanagement/facepipeline.cpp:661
#9 0x00000000006f09f1 in Digikam::DatabaseWriter::qt_static_metacall (_o=<optimized out>, _c=<optimized out>, _id=<optimized out>, _a=<optimized out>) at /build/buildd/digikam-4.0.0/obj-x86_64-linux-gnu/core/digikam/facepipeline_p.moc:493
#10 0x00007fb0421adc1e in QObject::event (this=0x88438c0, e=<optimized out>) at kernel/qobject.cpp:1194
Git commit 4662dd94102f8144bc65ce1cb66d6b6cb1d500fd by Gilles Caulier. Committed on 18/06/2014 at 14:22. Pushed by cgilles into branch 'master'. Libkface now depand of last stable OpenCV library version 2.4.9 This prevent internal crash int Cv:Algorithm that we cannot handle in libkface as exception. Now, Face Recognition do not crash but still report Exception at training operations, especially about wrong Cv:Matrix size : digikam(8673)/digikam (core) Digikam::DImg::load:"/mnt/data2/photos/GILLES/NEW/Adrien/2010-04-13/20100413_009.jpg" : JPEG file identified OpenCV Error: Assertion failed (0 <= _dims && _dims <= CV_MAX_DIM) in setSize, file /mnt/devel/opencv/modules/core/src/matrix.cpp, line 89 digikam(8673)/KFACE: cv::Exception training LBPH: /mnt/devel/opencv/modules/core/src/matrix.cpp:89: error: (-215) 0 <=_dims && _dims <= CV_MAX_DIM in function setSize It still a problem somwhere, but it's better than previous state. Related: bug 330342, bug 329873, bug 326742, bug 326586, bug 326585, bug 324774, bug 323888, bug 323361, bug 320812, bug 312440, bug 309027, bug 308645, bug 301611, bug 297558, bug 285517 M +1 -1 CMakeLists.txt http://commits.kde.org/libkface/4662dd94102f8144bc65ce1cb66d6b6cb1d500fd Git commit 1fff86f31e3bf47a2a2cfa6eaa98bb1bdf1a863b by Gilles Caulier. Committed on 24/06/2014 at 12:32. Pushed by cgilles into branch 'master'. add more test before to commit/checkout compressed histogram data in Face database, to prevent crashes, especially if data are corrupted from database. Related: bug 330342, bug 329873, bug 326742, bug 326586, bug 326585, bug 324774, bug 323888, bug 320812, bug 312440, bug 309027, bug 308645, bug 301611, bug 297558, bug 285517 M +62 -28 libkface/database/trainingdb.cpp http://commits.kde.org/libkface/1fff86f31e3bf47a2a2cfa6eaa98bb1bdf1a863b Git commit d48f66e8fc4adfaaea4f5928c28aabb6057775c1 by Gilles Caulier. Committed on 24/06/2014 at 13:00. Pushed by cgilles into branch 'master'. Check if QMap is not null before to pass it to FaceTags API, to prevent Qt crash M +9 -3 utilities/facemanagement/facepipeline.cpp http://commits.kde.org/digikam/d48f66e8fc4adfaaea4f5928c28aabb6057775c1 With next digiKam 4.1.0, a lots of improvements/fixes have be done around face management. Please give us a fresh feedback. Note i recommend to delete face recognition database to prevent dysfunction due to possible wrong data store in this container. Look where file is located in my computer : [gilles@localhost database]$ pwd /home/gilles/.kde4/share/apps/libkface/database [gilles@localhost database]$ ls -al total 397028 drwx------ 2 gilles gilles 4096 juin 24 14:22 ./ drwx------ 3 gilles gilles 4096 juin 18 19:08 ../ -rw-r--r-- 1 gilles gilles 406543360 juin 24 14:22 recognition.db [gilles@localhost database]$ Created attachment 88150 [details]
New crash information added by DrKonqi
digikam (4.0.0) on KDE Platform 4.12.5 using Qt 4.8.5
- What I was doing when the application crashed:
From the left bar, select the People tab. Then start face recognition. I selected one album, then clicked on search.
-- Backtrace (Reduced):
#6 isEmpty (this=0x2d) at /usr/include/qt4/QtCore/qmap.h:203
#7 Digikam::FaceTags::getOrCreateTagForIdentity (attributes=...) at /portage_builddir/portage/media-gfx/digikam-4.0.0/work/digikam-4.0.0/core/libs/database/faces/facetags.cpp:286
#8 0x00000000006fa024 in Digikam::DatabaseWriter::process (this=0x6f59d00, package=...) at /portage_builddir/portage/media-gfx/digikam-4.0.0/work/digikam-4.0.0/core/utilities/facemanagement/facepipeline.cpp:661
#9 0x00000000006fa833 in Digikam::DatabaseWriter::qt_static_metacall (_o=<optimized out>, _c=<optimized out>, _id=<optimized out>, _a=<optimized out>) at /portage_builddir/portage/media-gfx/digikam-4.0.0/work/digikam-4.0.0_build/digikam/facepipeline_p.moc:493
#10 0x00007fc277f6d9fe in QObject::event (this=0x6f59d00, e=<optimized out>) at kernel/qobject.cpp:1194
Most changes about this problem have been introduced in digiKam 4.1.0 through libkface. digiKam 4.2.0 is just released. Please check with this version... Gilles Caulier and also, remove libkface database located here : Linux: ~/.kde4/share/apps/libkface/database/recognition.db OSX: ~/Library/Preferences/KDE/share/apps/libkface/database/recognition.db Windows: ~/AppData/Roaming/.kde/share/apps/libkface/database/recognition.db ... before to retry to start face recognition. Gilles Caulier I think for me the upgrade to 4.2.0 solved this issue. 4.2.0 hasn't crashed yet although I've done face recognition a few times in the way that caused the crash from me in 4.0.0. Haven't tested 4.1.0. However, in 4.2.0 CPU usage during face recognition can be extremely high, such that e.g. I cannot type continuously into this text box while face recognition is running. (Maybe that setting there about CPU cores would fix this, I haven't tried yet.) Fine. I close this file now. Re-open if necessary... Gilles Caulier |