Comments (5)
we can catch some exception from dlib?
No. dlib has no consideration in this regard. In all the tests I did, the kernel ends up killing the process that consumes all my memory.
Simil that.
Dec 25 15:52:24 Ubuntu-1604-xenial-64-minimal kernel: [1818692.409025] Out of memory: Kill process 2059 (a.out) score 961 or sacrifice child
Dec 25 15:52:24 Ubuntu-1604-xenial-64-minimal kernel: [1818692.409162] Killed process 2059 (a.out) total-vm:99272240kB, anon-rss:64928316kB, file-rss:0kB, shmem-rss:0kB
Dec 25 15:52:25 Ubuntu-1604-xenial-64-minimal kernel: [1818693.695334] oom_reaper: reaped process 2059 (a.out), now anon-rss:0kB, file-rss:0kB, shmem-rss:0kB
See if PHP just crashes immediately and we cannot do anything.
I understand that it would kill the same php process that executes the the background task. So we can not do anything..
We can try to work with threads, but I see it very difficult...
Also, how to notify user on this, as obviously it doesn't have enough memory.
This must find the administrator, through the logs. If it is executed from cron, the report remains in syslog. If it runs as a nextcloud fund task, you probably see it in your log.
p.s: I must go, then continue answering..
from facerecognition.
I was afraid that PHP will just crash. Not sure about you, but I am very worried about this and this is one of the biggest blocker for some "easy install/adoption". Biggest one, I think. I have to think about this a lot, I hope you will too. I have no solution at the moment. We could:
- Forbid cron job (you can take down other apps' cron jobs when you crash, we don't want that) and just go with command
- Be smarter. For example, before doing face detection, update row in column
oc_face_recognition_images.last_try
telling which image size is rescaled. After detection, clear this column. If there is any existing images with this value, assume that there was OOM and that give image scaling is not good enough and either:- Refuse to work any more, until admin resolves it manually (sets different limits)
- Try with lower image size (here we are entering "we-are-smart/dynamic-resizing" territory, which I don't particularly like, unless there are other options)
Huh, hard decisions, will have to think about this more.
from facerecognition.
I also keep thinking about it..
Forbid cron job (you can take down other apps' cron jobs when you crash, we don't want that) and just go with command
When I say an cron job, I mean a particular one, configured by the administrator, and that only does this. If it crash it should not affect other tasks.
However, I think we should suggest effusively, perform the task by hand for the first time, which will be the hardest.
This must be the fundamental test to know if it is viable on the server. If successful probably does not have problems in the future, or they will be isolated by system load.
from facerecognition.
https://github.com/matiasdelellis/facerecognition/wiki/Performance-analysis-of-DLib%E2%80%99s-CNN-face-detection#results-for-the-project
https://github.com/matiasdelellis/facerecognition/wiki/FAQ
😉
from facerecognition.
Referring to issue #97: I am using Nextloud on a machine with 16 GB of memory. I have watched the used memory during face recognition. An image analysis takes about 40 seconds. During this time PHP uses 40 till 60 % of memory. Shortly before the recognition was successfully finished, this value rises to over 90 %.
from facerecognition.
Related Issues (20)
- Always stuck in step5 [5/8 - Executing task CreateClustersTask (Create new persons or update existing persons)] HOT 1
- Nextcloud 28: face recognition + clustering work, but no results in Web interface HOT 6
- feature: add timestamp to log output HOT 2
- Images from groupfolders seems redundant for each user HOT 2
- Fedora 39 pdlib broken dependency HOT 1
- Admin and Personal UI broken after update to Netxcloud 28 HOT 1
- Face clustering runs Out of memory HOT 1
- Clustering fails for large number of faces HOT 1
- pdlib api mismatch HOT 2
- Make the app works with Memories and external storage HOT 1
- too few faces recognized HOT 2
- Big Cluster / Face Group appeared with different People HOT 3
- apt gpg key expired 2024-03-20 HOT 13
- facerecognition not compatible with NextCloud 28.0.3 HOT 3
- Image tag `matiasdelellis/facerecognition-external-model:latest` not available HOT 2
- Show Ignored Faces
- Feature request: Add auto suggestions to name input
- unable to install on ubuntu 20.04 - key expired HOT 3
- symbol lookup error HOT 1
- Call to undefined function when adding a model HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from facerecognition.