-
Notifications
You must be signed in to change notification settings - Fork 47
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
Errors with php occ recognize:classify and no tags created #1074
Comments
Hello 👋 Thank you for taking the time to open this issue with recognize. I know it's frustrating when software I look forward to working with you on this issue |
Mmh, that's a weird one. The code that runs the model is the same for both the on demand classifying and the classify command :/ Could it be that the container runs out of memory and kills the node process? |
Also, are you running the nextcloud cron jobs in a different container, per chance? |
Yes, the cron jobs are running in a sidecar container in the same pod as the nextcloud app. So the cron container sees the identical resources as the nextcloud container. This sidecar uses the same image as the nextcloud container but - of course - overwrites the default entrypoint with nextclouds "cron.sh" script for starting a cron daemon. |
Can you try running the classifier command manually inside both containers?
Maybe it's something to do with the files being stored in /tmp. Some people have had issues with /tmp in docker: https://github.com/nextcloud/recognize#tmp |
sure.... in nexclouds main app container this is the output:
and this in the cron container:
|
Nice, so something in the main container kills the process. Am I correct that your main container has 1.7GB free memory in the above screenshot? You may need more than that. |
No, you are not correct. When reading the output of the "free" command you have to look at the "available" column (which is around 7GB in the above screenshot), not the "free" one. Linux tries to use free memory effectively for caching (which can be seen in the "buff/cache" column), so no mem is wasted. But neverless this memory is available for being used by other processes.
--> Notice nearly identical Memory free/available columns in both container. Meanwhile thinking about this, I assume something in the entrypoint Script or whatever in the nextcloud app container affects memory handling, as both container are based on the same image. |
I'm not sure why the process is getting killed, but that's definitely the problem, you'd need to solve. If I can help more somehow, let me know. |
So in the end I found the root cause... despite my assumption, there WERE indeed memory limits set for the nextcloud container (2GB). After removing them, the occ command works without problems. Sorry for the irritations, shame on me :S |
No worries! I'm glad we found the root cause :) |
Which version of recognize are you using?
6.0.1
Enabled Modes
Object recognition
TensorFlow mode
Normal mode
Downstream App
Files App
Which Nextcloud version do you have installed?
28.0.1
Which Operating system do you have installed?
Kubernetes @ Ubuntu 22.04.3 LTS VM
Which database are you running Nextcloud on?
mariadb:10.7
Which Docker container are you using to run Nextcloud? (if applicable)
nextcloud:28.0.1-fpm
How much RAM does your server have?
12GiB in the K8s VM
What processor Architecture does your CPU have?
x86_64
Describe the Bug
Running Nextcloud Docker image (NOT AIO one!) in a K8s Cluster, there installed the recognize app.
When running
php occ recognize:classify -vvv
for initial recognitions of already existing files, no tags are created, this is the output:
What I'm wondering is: what exactly does "Error while running imagenetclassifier" mean? Where can I find more details what is going wrong here?
These entries are filling the nextcloud.log during the running occ command:
As a plus:
When uploading a new image to Nextcloud, after a short time it gets tagged by recognize without problems:
So I assume, recognize is working at all. This can also be seen in its admin page:
(BTW: There seems to be some issue with landmark recognition, but that's another one)
Expected Behavior
php occ recognize:classify should not run in errors (or give more output what is going wrong)
tags should be created
To Reproduce
Run NC 28.0.1 FPM Docker Image (in K8s), install recognize, run occ... command
Debug log
No response
The text was updated successfully, but these errors were encountered: