Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Click on "review people found" button takes really long now #770

Open
axeljerabek opened this issue Aug 4, 2024 · 7 comments
Open

Click on "review people found" button takes really long now #770

axeljerabek opened this issue Aug 4, 2024 · 7 comments

Comments

@axeljerabek
Copy link

Hey, Thanks for reporting issues back to Nextcloud Face Recognition. Please, try to complete this report in detail so we can help you easier. 😄

Make sure you read all the documentation, and the FAQ, and that the issue has not been reported before. 😉

Expected behaviour

Click and it shows detected people

Actual behaviour

A click takes over one hour on a non-high-end machine, with 100k pictures.

Tell us what happens instead

Steps to reproduce

  1. click on "review people found button"

Server configuration

  • Operating system:

  • Ubuntu 24.04

  • Pdlib version:

  • newest

  • How is DLib installed: Make sure it is working correctly with this tool

  • How is PDlib installed: Make sure it is working correctly with this tool

  • PHP version:

  • 8.3 latest

  • Web server:

  • Apache2 latest

  • Database:

  • mariadb latest

  • Nextcloud version:
    from 28-30, latest

Client configuration

  • Browser:
    Google Chrome

  • Operating system:
    Any

Logs

Background task log with debug.

sudo -u apache php occ -vvv face:background_job
Insert your background log here

Web server error log

Web server error log
Insert your webserver log here

Nextcloud log (data/nextcloud.log)

Nextcloud log
Insert your Nextcloud log here

Browser log

Browser log
Insert your browser log here, this could for example include:

a) The javascript console log
b) The network log
c) ...
@mrishab
Copy link

mrishab commented Aug 16, 2024

I am facing the same problem. I set up facerecognize on existing dataset with 92918 images. The background_job finished successfully. In the settings > Facerecognize, when I click "Review people found", the API call to clusters endpoint fails with Gateway timeout error. There are 73109 faces with 33746 clusters.

For another user with 15253 images, 13354 faces and 5911 clusters, the API is able to respond in time.

I am using dockerize nextcloud. I have manually set up PDLIB. Here's the reference to docker image: https://github.com/mrishab/anton-apps/blob/master/nextcloud/Dockerfile.

@mrishab
Copy link

mrishab commented Aug 16, 2024

I am facing the same problem. I set up facerecognize on existing dataset with 92918 images. The background_job finished successfully. In the settings > Facerecognize, when I click "Review people found", the API call to clusters endpoint fails with Gateway timeout error. There are 73109 faces with 33746 clusters.

For another user with 15253 images, 13354 faces and 5911 clusters, the API is able to respond in time.

I am using dockerize nextcloud. I have manually set up PDLIB. Here's the reference to docker image: https://github.com/mrishab/anton-apps/blob/master/nextcloud/Dockerfile.

I was actually able to resolve by increasing the timeout setting on my reverse proxy. The request does take about a minute to respond but it's still workable.

@matiasdelellis
Copy link
Owner

Hi, The code for this function is somewhat archaic. Since I hope to recommend Memories, I haven't spent enough time on it yet.
I still ask you, did you try memories? It is important because if it is more responsive it should do a similar implementation

@axeljerabek
Copy link
Author

Well, "responsive" is maybe something else. But it is way faster at least. The problem is not to show the persons, but the button itself takes ages to show the clusters. And the "review people found" button does not exist in memories. The problem also did not occur in the older versions with about the same amount of persons/clusters. It exists mostly since the introduction of those two buttons on top, with the ignored persons.

@matiasdelellis
Copy link
Owner

Just leave it here for reference..

SELECT person, COUNT(*) AS FacesCount
FROM `oc_facerecog_faces` AS Faces
INNER JOIN `oc_facerecog_images` AS Images ON Images.id = Faces.image AND  person IS NOT NULL
INNER JOIN `oc_facerecog_persons` AS Persons ON Persons.id = Faces.person AND  name IS NULL
WHERE Persons.user = 'test'
GROUP BY person
HAVING FacesCount > 3
ORDER BY FacesCount DESC
LIMIT 50

I would have to implement a similar sentence, but for me it is still slow. 😞

@axeljerabek
Copy link
Author

Now, it does not react anymore if the "review people found" button is clicked.

@xegby
Copy link

xegby commented Oct 11, 2024

Now, it does not react anymore if the "review people found" button is clicked.

Maybe your problem is related to #779

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants